# Fabric swatch book filter

> Pinked fabric swatches with real textures: linen, wool, corduroy, silk, denim and cotton, ready to tick.

- Category: [Filters](https://library.aimran.es/components/filters)
- Built with: HTML + CSS
- Live editor: https://library.aimran.es/blocks/uv-f-fabric-book
- Library: AIMRAN Library (https://library.aimran.es), free, no sign-up, by Aimran Oukham

## Where to use it

Fashion, upholstery and furniture shops often filter by material, and a swatch says more than a word. Each square is clipped with a pinking-shears polygon and textured with layered CSS gradients for weave, knit, ribs or sheen. Selected swatches lift with a slight tilt, show white stitching and get a small ticked label.

The first colour marks the tick and the selected names, the second colours the label card. Edit the colours and gradients of each fabric in the code to match your stock, and keep the names short for small screens.

## Code

### HTML

```html
<fieldset class="uvq05-fb"><legend>Fabric</legend><div class="gr"><label style="--r:-3deg"><input type="checkbox"><span class="sh"><span class="sw"></span><b class="tg" aria-hidden="true"></b></span><span class="nm">Linen</span></label><label style="--r:2deg"><input type="checkbox" checked><span class="sh"><span class="sw"></span><b class="tg" aria-hidden="true"></b></span><span class="nm">Wool</span></label><label style="--r:-2deg"><input type="checkbox"><span class="sh"><span class="sw"></span><b class="tg" aria-hidden="true"></b></span><span class="nm">Corduroy</span></label><label style="--r:3deg"><input type="checkbox" checked><span class="sh"><span class="sw"></span><b class="tg" aria-hidden="true"></b></span><span class="nm">Silk</span></label><label style="--r:-1deg"><input type="checkbox"><span class="sh"><span class="sw"></span><b class="tg" aria-hidden="true"></b></span><span class="nm">Denim</span></label><label style="--r:2deg"><input type="checkbox"><span class="sh"><span class="sw"></span><b class="tg" aria-hidden="true"></b></span><span class="nm">Cotton</span></label></div><p class="ct"><span>Fabrics chosen:</span> <span class="n"></span></p></fieldset>
```

### CSS

```css
.uvq05-fb {
  --c1: #c2410c;
  --c2: #fff7ed;
  --s: 16px;
  /* tamaño */
  --k: 1;
  /* velocidad */
  --fg: #1d1d1f;
  /* texto */
  --bg: #f5f5f7;
  /* fondo */
}

.uvq05-fb {
  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;
  border: 0;
  margin: 0;
  padding: 0;
  min-width: 0;
  width: 16.5em;
  counter-reset: uvq05-fb;
}

.uvq05-fb legend {
  padding: 0;
  margin: 0 0 .8em;
  font-weight: 700;
}

.uvq05-fb .gr {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: .9em .7em;
}

.uvq05-fb label {
  position: relative;
  cursor: pointer;
}

.uvq05-fb input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
  pointer-events: none;
}

.uvq05-fb input:checked {
  counter-increment: uvq05-fb;
}

.uvq05-fb .sh {
  position: relative;
  display: block;
  filter: drop-shadow(0 .15em .2em rgba(0,0,0,.22));
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.34,1.56,.64,1),filter calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb .sw {
  position: relative;
  display: block;
  height: 3.7em;
  clip-path: polygon(0.00% 0%,8.33% 3%,16.67% 0%,25.00% 3%,33.33% 0%,41.67% 3%,50.00% 0%,58.33% 3%,66.67% 0%,75.00% 3%,83.33% 0%,91.67% 3%,100.00% 0%,97% 8.33%,100% 16.67%,97% 25.00%,100% 33.33%,97% 41.67%,100% 50.00%,97% 58.33%,100% 66.67%,97% 75.00%,100% 83.33%,97% 91.67%,100% 100.00%,91.67% 97%,83.33% 100%,75.00% 97%,66.67% 100%,58.33% 97%,50.00% 100%,41.67% 97%,33.33% 100%,25.00% 97%,16.67% 100%,8.33% 97%,0.00% 100%,3% 91.67%,0% 83.33%,3% 75.00%,0% 66.67%,3% 58.33%,0% 50.00%,3% 41.67%,0% 33.33%,3% 25.00%,0% 16.67%,3% 8.33%);
  --st: rgba(255,255,255,.75);
}

.uvq05-fb .sw::after {
  content: "";
  position: absolute;
  inset: .38em;
  border: 1.5px dashed var(--st);
  border-radius: .15em;
  opacity: 0;
  transition: opacity calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:nth-of-type(1) .sw {
  background: repeating-linear-gradient(0deg,rgba(80,60,30,.13) 0 1px,transparent 1px 3px),repeating-linear-gradient(90deg,rgba(255,255,255,.28) 0 1px,transparent 1px 4px);
  background-color: #d9c9a8;
  --st: rgba(60,40,20,.5);
}

.uvq05-fb label:nth-of-type(2) .sw {
  background: linear-gradient(135deg,rgba(0,0,0,.22) 25%,transparent 25%) 0 0/.5em .5em,linear-gradient(225deg,rgba(0,0,0,.22) 25%,transparent 25%) 0 0/.5em .5em,linear-gradient(45deg,rgba(255,255,255,.1) 25%,transparent 25%) 0 0/.5em .5em;
  background-color: #9b3d32;
}

.uvq05-fb label:nth-of-type(3) .sw {
  background: repeating-linear-gradient(90deg,rgba(255,255,255,.18) 0 .1em,rgba(0,0,0,.24) .18em .26em,transparent .26em .3em);
  background-color: #6b7a3c;
}

.uvq05-fb label:nth-of-type(4) .sw {
  background: linear-gradient(115deg,transparent 25%,rgba(255,255,255,.65) 45%,transparent 62%) 0 0/250% 100%,linear-gradient(200deg,rgba(255,255,255,.22),rgba(0,0,0,.2));
  background-color: #c99bc4;
}

.uvq05-fb label:nth-of-type(5) .sw {
  background: repeating-linear-gradient(45deg,rgba(255,255,255,.2) 0 1px,transparent 1px 3px),repeating-linear-gradient(-45deg,rgba(0,0,0,.2) 0 1px,transparent 1px 4px);
  background-color: #33507e;
}

.uvq05-fb label:nth-of-type(6) .sw {
  background: radial-gradient(rgba(0,0,0,.1) 1px,transparent 1.3px) 0 0/.3em .3em;
  background-color: #f2eee6;
  --st: rgba(60,40,20,.5);
}

.uvq05-fb label:nth-of-type(4) .sw {
  transition: background-position calc(0.9s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:nth-of-type(4):hover .sw {
  background-position: 100% 0,0 0;
}

.uvq05-fb .tg {
  position: absolute;
  right: -.35em;
  top: -.45em;
  width: 1.15em;
  height: 1.15em;
  border-radius: .25em;
  background: var(--c2);
  box-shadow: 0 0 0 1px rgba(0,0,0,.15),0 .15em .3em rgba(0,0,0,.25);
  transform: scale(0) rotate(-25deg);
  transition: transform calc(0.4s / var(--k)) cubic-bezier(.34,1.56,.64,1);
}

.uvq05-fb .tg::after {
  content: "";
  position: absolute;
  left: .4em;
  top: .18em;
  width: .25em;
  height: .5em;
  border: solid var(--c1);
  border-width: 0 .14em .14em 0;
  transform: rotate(45deg);
}

.uvq05-fb .nm {
  display: block;
  margin-top: .45em;
  font-size: .75em;
  font-weight: 600;
  text-align: center;
  transition: color calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:hover .sw {
  animation: uvq05-fbw calc(0.7s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:active .sh {
  transform: scale(.94);
}

.uvq05-fb input:checked+.sh {
  transform: translateY(-.3em) rotate(var(--r));
  filter: drop-shadow(0 .5em .45em rgba(0,0,0,.3));
}

.uvq05-fb input:checked+.sh .sw::after {
  opacity: 1;
}

.uvq05-fb input:checked+.sh .tg {
  transform: none;
}

.uvq05-fb input:checked~.nm {
  color: var(--c1);
  font-weight: 800;
}

.uvq05-fb input:focus-visible+.sh {
  outline: 2px solid var(--c1);
  outline-offset: .3em;
  border-radius: .2em;
}

.uvq05-fb .ct {
  margin: .9em 0 0;
  font-size: .8em;
  color: color-mix(in srgb,var(--fg) 58%,transparent);
}

.uvq05-fb .n::before {
  content: counter(uvq05-fb);
  font-weight: 800;
  color: var(--fg);
}

@keyframes uvq05-fbw {
  30% {
    transform: skewY(2.5deg);
  }
  60% {
    transform: skewY(-1.5deg);
  }
}

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

### React

```tsx
import type { CSSProperties } from "react";

const css = `
.uvq05-fb {
  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;
  border: 0;
  margin: 0;
  padding: 0;
  min-width: 0;
  width: 16.5em;
  counter-reset: uvq05-fb;
}

.uvq05-fb legend {
  padding: 0;
  margin: 0 0 .8em;
  font-weight: 700;
}

.uvq05-fb .gr {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: .9em .7em;
}

.uvq05-fb label {
  position: relative;
  cursor: pointer;
}

.uvq05-fb input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
  pointer-events: none;
}

.uvq05-fb input:checked {
  counter-increment: uvq05-fb;
}

.uvq05-fb .sh {
  position: relative;
  display: block;
  filter: drop-shadow(0 .15em .2em rgba(0,0,0,.22));
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.34,1.56,.64,1),filter calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb .sw {
  position: relative;
  display: block;
  height: 3.7em;
  clip-path: polygon(0.00% 0%,8.33% 3%,16.67% 0%,25.00% 3%,33.33% 0%,41.67% 3%,50.00% 0%,58.33% 3%,66.67% 0%,75.00% 3%,83.33% 0%,91.67% 3%,100.00% 0%,97% 8.33%,100% 16.67%,97% 25.00%,100% 33.33%,97% 41.67%,100% 50.00%,97% 58.33%,100% 66.67%,97% 75.00%,100% 83.33%,97% 91.67%,100% 100.00%,91.67% 97%,83.33% 100%,75.00% 97%,66.67% 100%,58.33% 97%,50.00% 100%,41.67% 97%,33.33% 100%,25.00% 97%,16.67% 100%,8.33% 97%,0.00% 100%,3% 91.67%,0% 83.33%,3% 75.00%,0% 66.67%,3% 58.33%,0% 50.00%,3% 41.67%,0% 33.33%,3% 25.00%,0% 16.67%,3% 8.33%);
  --st: rgba(255,255,255,.75);
}

.uvq05-fb .sw::after {
  content: "";
  position: absolute;
  inset: .38em;
  border: 1.5px dashed var(--st);
  border-radius: .15em;
  opacity: 0;
  transition: opacity calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:nth-of-type(1) .sw {
  background: repeating-linear-gradient(0deg,rgba(80,60,30,.13) 0 1px,transparent 1px 3px),repeating-linear-gradient(90deg,rgba(255,255,255,.28) 0 1px,transparent 1px 4px);
  background-color: #d9c9a8;
  --st: rgba(60,40,20,.5);
}

.uvq05-fb label:nth-of-type(2) .sw {
  background: linear-gradient(135deg,rgba(0,0,0,.22) 25%,transparent 25%) 0 0/.5em .5em,linear-gradient(225deg,rgba(0,0,0,.22) 25%,transparent 25%) 0 0/.5em .5em,linear-gradient(45deg,rgba(255,255,255,.1) 25%,transparent 25%) 0 0/.5em .5em;
  background-color: #9b3d32;
}

.uvq05-fb label:nth-of-type(3) .sw {
  background: repeating-linear-gradient(90deg,rgba(255,255,255,.18) 0 .1em,rgba(0,0,0,.24) .18em .26em,transparent .26em .3em);
  background-color: #6b7a3c;
}

.uvq05-fb label:nth-of-type(4) .sw {
  background: linear-gradient(115deg,transparent 25%,rgba(255,255,255,.65) 45%,transparent 62%) 0 0/250% 100%,linear-gradient(200deg,rgba(255,255,255,.22),rgba(0,0,0,.2));
  background-color: #c99bc4;
}

.uvq05-fb label:nth-of-type(5) .sw {
  background: repeating-linear-gradient(45deg,rgba(255,255,255,.2) 0 1px,transparent 1px 3px),repeating-linear-gradient(-45deg,rgba(0,0,0,.2) 0 1px,transparent 1px 4px);
  background-color: #33507e;
}

.uvq05-fb label:nth-of-type(6) .sw {
  background: radial-gradient(rgba(0,0,0,.1) 1px,transparent 1.3px) 0 0/.3em .3em;
  background-color: #f2eee6;
  --st: rgba(60,40,20,.5);
}

.uvq05-fb label:nth-of-type(4) .sw {
  transition: background-position calc(0.9s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:nth-of-type(4):hover .sw {
  background-position: 100% 0,0 0;
}

.uvq05-fb .tg {
  position: absolute;
  right: -.35em;
  top: -.45em;
  width: 1.15em;
  height: 1.15em;
  border-radius: .25em;
  background: var(--c2);
  box-shadow: 0 0 0 1px rgba(0,0,0,.15),0 .15em .3em rgba(0,0,0,.25);
  transform: scale(0) rotate(-25deg);
  transition: transform calc(0.4s / var(--k)) cubic-bezier(.34,1.56,.64,1);
}

.uvq05-fb .tg::after {
  content: "";
  position: absolute;
  left: .4em;
  top: .18em;
  width: .25em;
  height: .5em;
  border: solid var(--c1);
  border-width: 0 .14em .14em 0;
  transform: rotate(45deg);
}

.uvq05-fb .nm {
  display: block;
  margin-top: .45em;
  font-size: .75em;
  font-weight: 600;
  text-align: center;
  transition: color calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:hover .sw {
  animation: uvq05-fbw calc(0.7s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:active .sh {
  transform: scale(.94);
}

.uvq05-fb input:checked+.sh {
  transform: translateY(-.3em) rotate(var(--r));
  filter: drop-shadow(0 .5em .45em rgba(0,0,0,.3));
}

.uvq05-fb input:checked+.sh .sw::after {
  opacity: 1;
}

.uvq05-fb input:checked+.sh .tg {
  transform: none;
}

.uvq05-fb input:checked~.nm {
  color: var(--c1);
  font-weight: 800;
}

.uvq05-fb input:focus-visible+.sh {
  outline: 2px solid var(--c1);
  outline-offset: .3em;
  border-radius: .2em;
}

.uvq05-fb .ct {
  margin: .9em 0 0;
  font-size: .8em;
  color: color-mix(in srgb,var(--fg) 58%,transparent);
}

.uvq05-fb .n::before {
  content: counter(uvq05-fb);
  font-weight: 800;
  color: var(--fg);
}

@keyframes uvq05-fbw {
  30% {
    transform: skewY(2.5deg);
  }
  60% {
    transform: skewY(-1.5deg);
  }
}

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

export default function FFabricBook() {
  return (
    <>
      <style>{css}</style>
      <div
        style={{
          "--c1": "#c2410c",
          "--c2": "#fff7ed",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <fieldset className="uvq05-fb"><legend>Fabric</legend><div className="gr"><label style={{ "--r": "-3deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Linen</span></label><label style={{ "--r": "2deg" } as CSSProperties}><input type="checkbox" checked={true} /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Wool</span></label><label style={{ "--r": "-2deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Corduroy</span></label><label style={{ "--r": "3deg" } as CSSProperties}><input type="checkbox" checked={true} /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Silk</span></label><label style={{ "--r": "-1deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Denim</span></label><label style={{ "--r": "2deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Cotton</span></label></div><p className="ct"><span>Fabrics chosen:</span> <span className="n"></span></p></fieldset>
      </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 “Fabric swatch book filter” block (Filters) from AIMRAN Library to my project.

## What it is
Pinked fabric swatches with real textures: linen, wool, corduroy, silk, denim and cotton, ready to tick.

## Chosen settings
- Main color: #c2410c
- Secondary color: #fff7ed
- Size: 16px (from 12 to 24px)
- Speed: 1x (from 0.5 to 2x)
- Text: "Tejido"

## 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
import type { CSSProperties } from "react";

const css = `
.uvq05-fb {
  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;
  border: 0;
  margin: 0;
  padding: 0;
  min-width: 0;
  width: 16.5em;
  counter-reset: uvq05-fb;
}

.uvq05-fb legend {
  padding: 0;
  margin: 0 0 .8em;
  font-weight: 700;
}

.uvq05-fb .gr {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: .9em .7em;
}

.uvq05-fb label {
  position: relative;
  cursor: pointer;
}

.uvq05-fb input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  margin: 0;
  pointer-events: none;
}

.uvq05-fb input:checked {
  counter-increment: uvq05-fb;
}

.uvq05-fb .sh {
  position: relative;
  display: block;
  filter: drop-shadow(0 .15em .2em rgba(0,0,0,.22));
  transition: transform calc(0.45s / var(--k)) cubic-bezier(.34,1.56,.64,1),filter calc(0.45s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb .sw {
  position: relative;
  display: block;
  height: 3.7em;
  clip-path: polygon(0.00% 0%,8.33% 3%,16.67% 0%,25.00% 3%,33.33% 0%,41.67% 3%,50.00% 0%,58.33% 3%,66.67% 0%,75.00% 3%,83.33% 0%,91.67% 3%,100.00% 0%,97% 8.33%,100% 16.67%,97% 25.00%,100% 33.33%,97% 41.67%,100% 50.00%,97% 58.33%,100% 66.67%,97% 75.00%,100% 83.33%,97% 91.67%,100% 100.00%,91.67% 97%,83.33% 100%,75.00% 97%,66.67% 100%,58.33% 97%,50.00% 100%,41.67% 97%,33.33% 100%,25.00% 97%,16.67% 100%,8.33% 97%,0.00% 100%,3% 91.67%,0% 83.33%,3% 75.00%,0% 66.67%,3% 58.33%,0% 50.00%,3% 41.67%,0% 33.33%,3% 25.00%,0% 16.67%,3% 8.33%);
  --st: rgba(255,255,255,.75);
}

.uvq05-fb .sw::after {
  content: "";
  position: absolute;
  inset: .38em;
  border: 1.5px dashed var(--st);
  border-radius: .15em;
  opacity: 0;
  transition: opacity calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:nth-of-type(1) .sw {
  background: repeating-linear-gradient(0deg,rgba(80,60,30,.13) 0 1px,transparent 1px 3px),repeating-linear-gradient(90deg,rgba(255,255,255,.28) 0 1px,transparent 1px 4px);
  background-color: #d9c9a8;
  --st: rgba(60,40,20,.5);
}

.uvq05-fb label:nth-of-type(2) .sw {
  background: linear-gradient(135deg,rgba(0,0,0,.22) 25%,transparent 25%) 0 0/.5em .5em,linear-gradient(225deg,rgba(0,0,0,.22) 25%,transparent 25%) 0 0/.5em .5em,linear-gradient(45deg,rgba(255,255,255,.1) 25%,transparent 25%) 0 0/.5em .5em;
  background-color: #9b3d32;
}

.uvq05-fb label:nth-of-type(3) .sw {
  background: repeating-linear-gradient(90deg,rgba(255,255,255,.18) 0 .1em,rgba(0,0,0,.24) .18em .26em,transparent .26em .3em);
  background-color: #6b7a3c;
}

.uvq05-fb label:nth-of-type(4) .sw {
  background: linear-gradient(115deg,transparent 25%,rgba(255,255,255,.65) 45%,transparent 62%) 0 0/250% 100%,linear-gradient(200deg,rgba(255,255,255,.22),rgba(0,0,0,.2));
  background-color: #c99bc4;
}

.uvq05-fb label:nth-of-type(5) .sw {
  background: repeating-linear-gradient(45deg,rgba(255,255,255,.2) 0 1px,transparent 1px 3px),repeating-linear-gradient(-45deg,rgba(0,0,0,.2) 0 1px,transparent 1px 4px);
  background-color: #33507e;
}

.uvq05-fb label:nth-of-type(6) .sw {
  background: radial-gradient(rgba(0,0,0,.1) 1px,transparent 1.3px) 0 0/.3em .3em;
  background-color: #f2eee6;
  --st: rgba(60,40,20,.5);
}

.uvq05-fb label:nth-of-type(4) .sw {
  transition: background-position calc(0.9s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:nth-of-type(4):hover .sw {
  background-position: 100% 0,0 0;
}

.uvq05-fb .tg {
  position: absolute;
  right: -.35em;
  top: -.45em;
  width: 1.15em;
  height: 1.15em;
  border-radius: .25em;
  background: var(--c2);
  box-shadow: 0 0 0 1px rgba(0,0,0,.15),0 .15em .3em rgba(0,0,0,.25);
  transform: scale(0) rotate(-25deg);
  transition: transform calc(0.4s / var(--k)) cubic-bezier(.34,1.56,.64,1);
}

.uvq05-fb .tg::after {
  content: "";
  position: absolute;
  left: .4em;
  top: .18em;
  width: .25em;
  height: .5em;
  border: solid var(--c1);
  border-width: 0 .14em .14em 0;
  transform: rotate(45deg);
}

.uvq05-fb .nm {
  display: block;
  margin-top: .45em;
  font-size: .75em;
  font-weight: 600;
  text-align: center;
  transition: color calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:hover .sw {
  animation: uvq05-fbw calc(0.7s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq05-fb label:active .sh {
  transform: scale(.94);
}

.uvq05-fb input:checked+.sh {
  transform: translateY(-.3em) rotate(var(--r));
  filter: drop-shadow(0 .5em .45em rgba(0,0,0,.3));
}

.uvq05-fb input:checked+.sh .sw::after {
  opacity: 1;
}

.uvq05-fb input:checked+.sh .tg {
  transform: none;
}

.uvq05-fb input:checked~.nm {
  color: var(--c1);
  font-weight: 800;
}

.uvq05-fb input:focus-visible+.sh {
  outline: 2px solid var(--c1);
  outline-offset: .3em;
  border-radius: .2em;
}

.uvq05-fb .ct {
  margin: .9em 0 0;
  font-size: .8em;
  color: color-mix(in srgb,var(--fg) 58%,transparent);
}

.uvq05-fb .n::before {
  content: counter(uvq05-fb);
  font-weight: 800;
  color: var(--fg);
}

@keyframes uvq05-fbw {
  30% {
    transform: skewY(2.5deg);
  }
  60% {
    transform: skewY(-1.5deg);
  }
}

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

export default function FFabricBook() {
  return (
    <>
      <style>{css}</style>
      <div
        style={{
          "--c1": "#c2410c",
          "--c2": "#fff7ed",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <fieldset className="uvq05-fb"><legend>Fabric</legend><div className="gr"><label style={{ "--r": "-3deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Linen</span></label><label style={{ "--r": "2deg" } as CSSProperties}><input type="checkbox" checked={true} /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Wool</span></label><label style={{ "--r": "-2deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Corduroy</span></label><label style={{ "--r": "3deg" } as CSSProperties}><input type="checkbox" checked={true} /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Silk</span></label><label style={{ "--r": "-1deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Denim</span></label><label style={{ "--r": "2deg" } as CSSProperties}><input type="checkbox" /><span className="sh"><span className="sw"></span><b className="tg" aria-hidden="true"></b></span><span className="nm">Cotton</span></label></div><p className="ct"><span>Fabrics chosen:</span> <span className="n"></span></p></fieldset>
      </div>
    </>
  );
}
```

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