# Wax seal envelope button

> The letter slides into the envelope, the flap closes and a wax seal drops onto it before the envelope opens again.

- Category: [Buttons](https://library.aimran.es/components/buttons)
- Built with: HTML + CSS
- Live editor: https://library.aimran.es/blocks/uv-btn-wax-seal
- Library: AIMRAN Library (https://library.aimran.es), free, no sign-up, by Aimran Oukham

## Where to use it

A send button with ceremony: a kraft envelope holds a letter with your label written in italic serif. On click the letter drops inside, the flap folds down over it in 3D and a burgundy wax seal with an embossed star lands on the tip with a small squash. A short status line confirms the send, also for screen reader users. It suits invitations, weddings and thank you notes.

The main color is the wax and the secondary color is the paper, so navy wax on white or gold on black are quick changes. Keep the label to two or three words so it fits on the card, and the envelope reopens by itself after a few seconds.

## Code

### HTML

```html
<div class="uvq01-env"><button class="e" type="button"><span class="bk" aria-hidden="true"></span><span class="fl" aria-hidden="true"></span><span class="lt"><span>Send invitation</span></span><span class="fr" aria-hidden="true"></span><span class="sl" aria-hidden="true"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.6" stroke-linejoin="round"><path d="M12 4.5l2.2 4.6 5 .6-3.7 3.4 1 5-4.5-2.5-4.5 2.5 1-5-3.7-3.4 5-.6z"/></svg></span></button><span class="ok" role="status"></span><span class="msg" hidden>Sent</span></div>
```

### CSS

```css
.uvq01-env {
  --c1: #8e1b2c;
  --c2: #e8d9bd;
  --s: 16px;
  /* tamaño */
  --k: 1;
  /* velocidad */
  --fg: #1d1d1f;
  /* texto */
  --bg: #f5f5f7;
  /* fondo */
}

.uvq01-env {
  font-family: -apple-system,BlinkMacSystemFont,"SF Pro Text","Inter",system-ui,sans-serif;
  font-size: var(--s);
  color: var(--fg);
  -webkit-tap-highlight-color: transparent;
  position: relative;
  display: inline-grid;
  justify-items: center;
  padding-top: 2.2em;
}

.uvq01-env .e {
  font: inherit;
  color: inherit;
  border: 0;
  margin: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  display: block;
  width: 12em;
  height: 7em;
  border-radius: .35em;
  transition: transform calc(0.3s / var(--k)) cubic-bezier(.34,1.56,.64,1);
}

.uvq01-env .bk {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: color-mix(in srgb,var(--c2) 84%,#000);
  box-shadow: 0 14px 26px -14px rgba(60,40,10,.6);
}

.uvq01-env .fl {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 56%;
  z-index: 2;
  background: linear-gradient(180deg,color-mix(in srgb,var(--c2) 90%,#000),var(--c2));
  clip-path: polygon(0 0,100% 0,50% 100%);
  transform-origin: 50% 0;
  transform: perspective(30em) rotateX(180deg);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1) calc(0.25s / var(--k)),z-index 0s linear calc(0.45s / var(--k));
}

.uvq01-env .lt {
  position: absolute;
  left: .7em;
  right: .7em;
  top: -1.8em;
  height: 5.4em;
  z-index: 3;
  display: grid;
  justify-items: center;
  align-content: start;
  padding: 1em .6em 0;
  border-radius: .2em;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-style: italic;
  font-weight: 600;
  font-size: 1em;
  line-height: 1.15;
  text-align: center;
  white-space: normal;
  color: #3b2a1e;
  background: repeating-linear-gradient(180deg,transparent 0 .9em,rgba(59,42,30,.1) .9em calc(.9em + 1px)) 0 2.8em/100% 100% no-repeat,#fffdf7;
  box-shadow: 0 1px 3px rgba(0,0,0,.18);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.22,1,.36,1) calc(0.6s / var(--k));
}

.uvq01-env .fr {
  position: absolute;
  inset: 0;
  z-index: 4;
  border-radius: inherit;
  background: linear-gradient(to top right,transparent calc(50% - 1px),rgba(0,0,0,.12) 50%,transparent calc(50% + 1px)) 0 100%/50% 100% no-repeat,linear-gradient(to top left,transparent calc(50% - 1px),rgba(0,0,0,.12) 50%,transparent calc(50% + 1px)) 100% 100%/50% 100% no-repeat,var(--c2);
  clip-path: polygon(0 0,50% 55%,100% 0,100% 100%,0 100%);
}

.uvq01-env .sl {
  position: absolute;
  left: 50%;
  top: 56%;
  z-index: 6;
  display: grid;
  place-items: center;
  width: 2.1em;
  height: 2.1em;
  margin: -1.05em 0 0 -1.05em;
  border-radius: 47% 53% 50% 48%/52% 47% 53% 48%;
  color: color-mix(in srgb,var(--c1) 55%,#000);
  background: radial-gradient(circle at 35% 30%,color-mix(in srgb,var(--c1) 65%,#fff),var(--c1) 50%,color-mix(in srgb,var(--c1) 65%,#000));
  box-shadow: inset 0 0 0 .2em color-mix(in srgb,var(--c1) 80%,#000),0 .15em .3em rgba(0,0,0,.35);
  opacity: 0;
  scale: 0;
}

.uvq01-env .sl svg {
  width: 1.2em;
  height: 1.2em;
}

.uvq01-env .ok {
  position: absolute;
  top: .3em;
  left: 0;
  right: 0;
  text-align: center;
  font-weight: 700;
  color: var(--fg);
  opacity: 0;
  translate: 0 .5em;
  transition: opacity calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1),translate calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
  pointer-events: none;
}

.uvq01-env .e:hover .lt {
  transform: translateY(-.35em);
  transition-delay: 0s;
}

.uvq01-env.is-sent .lt {
  transform: translateY(3.3em);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq01-env.is-sent .fl {
  z-index: 5;
  transform: perspective(30em) rotateX(0);
  transition: transform calc(0.4s / var(--k)) cubic-bezier(.25,.1,.25,1) calc(0.4s / var(--k)),z-index 0s linear calc(0.6s / var(--k));
}

.uvq01-env.is-sent .sl {
  animation: uvq01-env-sl calc(0.45s / var(--k)) cubic-bezier(.34,1.56,.64,1) calc(0.85s / var(--k)) forwards;
}

.uvq01-env.is-sent .ok {
  opacity: 1;
  translate: 0 0;
  transition-delay: calc(1s / var(--k));
}

.uvq01-env .e:active {
  transform: scale(.98);
}

.uvq01-env .e:focus-visible {
  outline: 2px solid var(--c1);
  outline-offset: 3px;
}

@keyframes uvq01-env-sl {
  0% {
    opacity: 0;
    scale: 1.8;
  }
  60% {
    opacity: 1;
    scale: .9;
  }
  100% {
    opacity: 1;
    scale: 1;
  }
}

@media (prefers-reduced-motion:reduce) {
  .uvq01-env,.uvq01-env *,.uvq01-env *::before,.uvq01-env *::after {
    animation-duration: .01ms!important;
    animation-iteration-count: 1!important;
    transition-duration: .01ms!important;
  }
}
```

### JavaScript

```js
document.querySelectorAll(".uvq01-env").forEach(el => {
  const ok=el.querySelector(".ok"),msg=el.querySelector(".msg");let busy=false,tm=0;const k=()=>parseFloat(getComputedStyle(el).getPropertyValue("--k"))||1;
el.querySelector(".e").addEventListener("click",()=>{if(busy)return;busy=true;el.classList.add("is-sent");ok.textContent=msg.textContent;tm=setTimeout(()=>{el.classList.remove("is-sent");busy=false;setTimeout(()=>{if(!busy)ok.textContent=""},400)},3600/k())});
return()=>clearTimeout(tm)
});
```

### React

```tsx
// @ts-nocheck: setup() es JavaScript del DOM sin tipos, el mismo de la pestaña JS.
import { useEffect, useRef, type CSSProperties } from "react";

const css = `
.uvq01-env {
  font-family: -apple-system,BlinkMacSystemFont,"SF Pro Text","Inter",system-ui,sans-serif;
  font-size: var(--s);
  color: var(--fg);
  -webkit-tap-highlight-color: transparent;
  position: relative;
  display: inline-grid;
  justify-items: center;
  padding-top: 2.2em;
}

.uvq01-env .e {
  font: inherit;
  color: inherit;
  border: 0;
  margin: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  display: block;
  width: 12em;
  height: 7em;
  border-radius: .35em;
  transition: transform calc(0.3s / var(--k)) cubic-bezier(.34,1.56,.64,1);
}

.uvq01-env .bk {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: color-mix(in srgb,var(--c2) 84%,#000);
  box-shadow: 0 14px 26px -14px rgba(60,40,10,.6);
}

.uvq01-env .fl {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 56%;
  z-index: 2;
  background: linear-gradient(180deg,color-mix(in srgb,var(--c2) 90%,#000),var(--c2));
  clip-path: polygon(0 0,100% 0,50% 100%);
  transform-origin: 50% 0;
  transform: perspective(30em) rotateX(180deg);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1) calc(0.25s / var(--k)),z-index 0s linear calc(0.45s / var(--k));
}

.uvq01-env .lt {
  position: absolute;
  left: .7em;
  right: .7em;
  top: -1.8em;
  height: 5.4em;
  z-index: 3;
  display: grid;
  justify-items: center;
  align-content: start;
  padding: 1em .6em 0;
  border-radius: .2em;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-style: italic;
  font-weight: 600;
  font-size: 1em;
  line-height: 1.15;
  text-align: center;
  white-space: normal;
  color: #3b2a1e;
  background: repeating-linear-gradient(180deg,transparent 0 .9em,rgba(59,42,30,.1) .9em calc(.9em + 1px)) 0 2.8em/100% 100% no-repeat,#fffdf7;
  box-shadow: 0 1px 3px rgba(0,0,0,.18);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.22,1,.36,1) calc(0.6s / var(--k));
}

.uvq01-env .fr {
  position: absolute;
  inset: 0;
  z-index: 4;
  border-radius: inherit;
  background: linear-gradient(to top right,transparent calc(50% - 1px),rgba(0,0,0,.12) 50%,transparent calc(50% + 1px)) 0 100%/50% 100% no-repeat,linear-gradient(to top left,transparent calc(50% - 1px),rgba(0,0,0,.12) 50%,transparent calc(50% + 1px)) 100% 100%/50% 100% no-repeat,var(--c2);
  clip-path: polygon(0 0,50% 55%,100% 0,100% 100%,0 100%);
}

.uvq01-env .sl {
  position: absolute;
  left: 50%;
  top: 56%;
  z-index: 6;
  display: grid;
  place-items: center;
  width: 2.1em;
  height: 2.1em;
  margin: -1.05em 0 0 -1.05em;
  border-radius: 47% 53% 50% 48%/52% 47% 53% 48%;
  color: color-mix(in srgb,var(--c1) 55%,#000);
  background: radial-gradient(circle at 35% 30%,color-mix(in srgb,var(--c1) 65%,#fff),var(--c1) 50%,color-mix(in srgb,var(--c1) 65%,#000));
  box-shadow: inset 0 0 0 .2em color-mix(in srgb,var(--c1) 80%,#000),0 .15em .3em rgba(0,0,0,.35);
  opacity: 0;
  scale: 0;
}

.uvq01-env .sl svg {
  width: 1.2em;
  height: 1.2em;
}

.uvq01-env .ok {
  position: absolute;
  top: .3em;
  left: 0;
  right: 0;
  text-align: center;
  font-weight: 700;
  color: var(--fg);
  opacity: 0;
  translate: 0 .5em;
  transition: opacity calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1),translate calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
  pointer-events: none;
}

.uvq01-env .e:hover .lt {
  transform: translateY(-.35em);
  transition-delay: 0s;
}

.uvq01-env.is-sent .lt {
  transform: translateY(3.3em);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq01-env.is-sent .fl {
  z-index: 5;
  transform: perspective(30em) rotateX(0);
  transition: transform calc(0.4s / var(--k)) cubic-bezier(.25,.1,.25,1) calc(0.4s / var(--k)),z-index 0s linear calc(0.6s / var(--k));
}

.uvq01-env.is-sent .sl {
  animation: uvq01-env-sl calc(0.45s / var(--k)) cubic-bezier(.34,1.56,.64,1) calc(0.85s / var(--k)) forwards;
}

.uvq01-env.is-sent .ok {
  opacity: 1;
  translate: 0 0;
  transition-delay: calc(1s / var(--k));
}

.uvq01-env .e:active {
  transform: scale(.98);
}

.uvq01-env .e:focus-visible {
  outline: 2px solid var(--c1);
  outline-offset: 3px;
}

@keyframes uvq01-env-sl {
  0% {
    opacity: 0;
    scale: 1.8;
  }
  60% {
    opacity: 1;
    scale: .9;
  }
  100% {
    opacity: 1;
    scale: 1;
  }
}

@media (prefers-reduced-motion:reduce) {
  .uvq01-env,.uvq01-env *,.uvq01-env *::before,.uvq01-env *::after {
    animation-duration: .01ms!important;
    animation-iteration-count: 1!important;
    transition-duration: .01ms!important;
  }
}
`;

// Interacción en JavaScript del DOM: la misma que en la pestaña JS.
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function setup(el: any) {
  const ok=el.querySelector(".ok"),msg=el.querySelector(".msg");let busy=false,tm=0;const k=()=>parseFloat(getComputedStyle(el).getPropertyValue("--k"))||1;
el.querySelector(".e").addEventListener("click",()=>{if(busy)return;busy=true;el.classList.add("is-sent");ok.textContent=msg.textContent;tm=setTimeout(()=>{el.classList.remove("is-sent");busy=false;setTimeout(()=>{if(!busy)ok.textContent=""},400)},3600/k())});
return()=>clearTimeout(tm)
}

export default function BtnWaxSeal() {
  const ref = useRef<HTMLDivElement>(null);

  useEffect(() => {
    const el = ref.current?.firstElementChild;
    return el ? setup(el) : undefined;
  }, []);

  return (
    <>
      <style>{css}</style>
      <div
        ref={ref} style={{
          "--c1": "#8e1b2c",
          "--c2": "#e8d9bd",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <div className="uvq01-env"><button className="e" type="button"><span className="bk" aria-hidden="true"></span><span className="fl" aria-hidden="true"></span><span className="lt"><span>Send invitation</span></span><span className="fr" aria-hidden="true"></span><span className="sl" aria-hidden="true"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="1.6" strokeLinejoin="round"><path d="M12 4.5l2.2 4.6 5 .6-3.7 3.4 1 5-4.5-2.5-4.5 2.5 1-5-3.7-3.4 5-.6z" /></svg></span></button><span className="ok" role="status"></span><span className="msg" hidden={true}>Sent</span></div>
      </div>
    </>
  );
}
```

## Prompt for AI assistants

Paste this into ChatGPT, Claude, Cursor, v0 or Lovable to adapt the block to your stack (Tailwind, Vue, Svelte…):

````text
I want to add the “Wax seal envelope button” block (Buttons) from AIMRAN Library to my project.

## What it is
The letter slides into the envelope, the flap closes and a wax seal drops onto it before the envelope opens again.

## Chosen settings
- Main color: #8e1b2c
- Secondary color: #e8d9bd
- Size: 16px (from 12 to 24px)
- Speed: 1x (from 0.5 to 2x)
- Text: "Enviar invitación"

## What I need
1. Add it to my project with the same look and animation as the reference code: same sizes, colours, radii, shadows, timings and easing.
2. It is built with plain HTML and CSS (the reference wraps it in a React component with its CSS). If my project uses something else (Vue, Svelte, Astro, plain HTML…), translate it without losing any behaviour. If I use Tailwind, turn the styles into classes; if not, keep the CSS in its own file.
3. Expose the settings above as props (or CSS variables) with those values as defaults.
4. Make it work well on phones: nothing that depends only on hover, touch targets of at least 44 px and no overflow on 320 px screens.
5. Make it look right in light and dark mode.
6. Keep it accessible: semantic HTML, roles and aria-* where needed, visible focus and keyboard support.
7. Respect prefers-reduced-motion: with reduced motion, no big animations but the same end result.

## Reference code
```tsx
// @ts-nocheck: setup() es JavaScript del DOM sin tipos, el mismo de la pestaña JS.
import { useEffect, useRef, type CSSProperties } from "react";

const css = `
.uvq01-env {
  font-family: -apple-system,BlinkMacSystemFont,"SF Pro Text","Inter",system-ui,sans-serif;
  font-size: var(--s);
  color: var(--fg);
  -webkit-tap-highlight-color: transparent;
  position: relative;
  display: inline-grid;
  justify-items: center;
  padding-top: 2.2em;
}

.uvq01-env .e {
  font: inherit;
  color: inherit;
  border: 0;
  margin: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  display: block;
  width: 12em;
  height: 7em;
  border-radius: .35em;
  transition: transform calc(0.3s / var(--k)) cubic-bezier(.34,1.56,.64,1);
}

.uvq01-env .bk {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: color-mix(in srgb,var(--c2) 84%,#000);
  box-shadow: 0 14px 26px -14px rgba(60,40,10,.6);
}

.uvq01-env .fl {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 56%;
  z-index: 2;
  background: linear-gradient(180deg,color-mix(in srgb,var(--c2) 90%,#000),var(--c2));
  clip-path: polygon(0 0,100% 0,50% 100%);
  transform-origin: 50% 0;
  transform: perspective(30em) rotateX(180deg);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1) calc(0.25s / var(--k)),z-index 0s linear calc(0.45s / var(--k));
}

.uvq01-env .lt {
  position: absolute;
  left: .7em;
  right: .7em;
  top: -1.8em;
  height: 5.4em;
  z-index: 3;
  display: grid;
  justify-items: center;
  align-content: start;
  padding: 1em .6em 0;
  border-radius: .2em;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-style: italic;
  font-weight: 600;
  font-size: 1em;
  line-height: 1.15;
  text-align: center;
  white-space: normal;
  color: #3b2a1e;
  background: repeating-linear-gradient(180deg,transparent 0 .9em,rgba(59,42,30,.1) .9em calc(.9em + 1px)) 0 2.8em/100% 100% no-repeat,#fffdf7;
  box-shadow: 0 1px 3px rgba(0,0,0,.18);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.22,1,.36,1) calc(0.6s / var(--k));
}

.uvq01-env .fr {
  position: absolute;
  inset: 0;
  z-index: 4;
  border-radius: inherit;
  background: linear-gradient(to top right,transparent calc(50% - 1px),rgba(0,0,0,.12) 50%,transparent calc(50% + 1px)) 0 100%/50% 100% no-repeat,linear-gradient(to top left,transparent calc(50% - 1px),rgba(0,0,0,.12) 50%,transparent calc(50% + 1px)) 100% 100%/50% 100% no-repeat,var(--c2);
  clip-path: polygon(0 0,50% 55%,100% 0,100% 100%,0 100%);
}

.uvq01-env .sl {
  position: absolute;
  left: 50%;
  top: 56%;
  z-index: 6;
  display: grid;
  place-items: center;
  width: 2.1em;
  height: 2.1em;
  margin: -1.05em 0 0 -1.05em;
  border-radius: 47% 53% 50% 48%/52% 47% 53% 48%;
  color: color-mix(in srgb,var(--c1) 55%,#000);
  background: radial-gradient(circle at 35% 30%,color-mix(in srgb,var(--c1) 65%,#fff),var(--c1) 50%,color-mix(in srgb,var(--c1) 65%,#000));
  box-shadow: inset 0 0 0 .2em color-mix(in srgb,var(--c1) 80%,#000),0 .15em .3em rgba(0,0,0,.35);
  opacity: 0;
  scale: 0;
}

.uvq01-env .sl svg {
  width: 1.2em;
  height: 1.2em;
}

.uvq01-env .ok {
  position: absolute;
  top: .3em;
  left: 0;
  right: 0;
  text-align: center;
  font-weight: 700;
  color: var(--fg);
  opacity: 0;
  translate: 0 .5em;
  transition: opacity calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1),translate calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
  pointer-events: none;
}

.uvq01-env .e:hover .lt {
  transform: translateY(-.35em);
  transition-delay: 0s;
}

.uvq01-env.is-sent .lt {
  transform: translateY(3.3em);
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq01-env.is-sent .fl {
  z-index: 5;
  transform: perspective(30em) rotateX(0);
  transition: transform calc(0.4s / var(--k)) cubic-bezier(.25,.1,.25,1) calc(0.4s / var(--k)),z-index 0s linear calc(0.6s / var(--k));
}

.uvq01-env.is-sent .sl {
  animation: uvq01-env-sl calc(0.45s / var(--k)) cubic-bezier(.34,1.56,.64,1) calc(0.85s / var(--k)) forwards;
}

.uvq01-env.is-sent .ok {
  opacity: 1;
  translate: 0 0;
  transition-delay: calc(1s / var(--k));
}

.uvq01-env .e:active {
  transform: scale(.98);
}

.uvq01-env .e:focus-visible {
  outline: 2px solid var(--c1);
  outline-offset: 3px;
}

@keyframes uvq01-env-sl {
  0% {
    opacity: 0;
    scale: 1.8;
  }
  60% {
    opacity: 1;
    scale: .9;
  }
  100% {
    opacity: 1;
    scale: 1;
  }
}

@media (prefers-reduced-motion:reduce) {
  .uvq01-env,.uvq01-env *,.uvq01-env *::before,.uvq01-env *::after {
    animation-duration: .01ms!important;
    animation-iteration-count: 1!important;
    transition-duration: .01ms!important;
  }
}
`;

// Interacción en JavaScript del DOM: la misma que en la pestaña JS.
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function setup(el: any) {
  const ok=el.querySelector(".ok"),msg=el.querySelector(".msg");let busy=false,tm=0;const k=()=>parseFloat(getComputedStyle(el).getPropertyValue("--k"))||1;
el.querySelector(".e").addEventListener("click",()=>{if(busy)return;busy=true;el.classList.add("is-sent");ok.textContent=msg.textContent;tm=setTimeout(()=>{el.classList.remove("is-sent");busy=false;setTimeout(()=>{if(!busy)ok.textContent=""},400)},3600/k())});
return()=>clearTimeout(tm)
}

export default function BtnWaxSeal() {
  const ref = useRef<HTMLDivElement>(null);

  useEffect(() => {
    const el = ref.current?.firstElementChild;
    return el ? setup(el) : undefined;
  }, []);

  return (
    <>
      <style>{css}</style>
      <div
        ref={ref} style={{
          "--c1": "#8e1b2c",
          "--c2": "#e8d9bd",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <div className="uvq01-env"><button className="e" type="button"><span className="bk" aria-hidden="true"></span><span className="fl" aria-hidden="true"></span><span className="lt"><span>Send invitation</span></span><span className="fr" aria-hidden="true"></span><span className="sl" aria-hidden="true"><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="1.6" strokeLinejoin="round"><path d="M12 4.5l2.2 4.6 5 .6-3.7 3.4 1 5-4.5-2.5-4.5 2.5 1-5-3.7-3.4 5-.6z" /></svg></span></button><span className="ok" role="status"></span><span className="msg" hidden={true}>Sent</span></div>
      </div>
    </>
  );
}
```

Give me the complete final code, ready to paste, and tell me in one line where to put it in my project.
````
