# Stone arcade tabs

> A stone arcade with four arches: the chosen one lets the sun through and its shape slides across the floor when you switch.

- Category: [Navigation](https://library.aimran.es/components/navigation)
- Built with: HTML + CSS
- Live editor: https://library.aimran.es/blocks/uv-nav-arcade-tabs
- Library: AIMRAN Library (https://library.aimran.es), free, no sign-up, by Aimran Oukham

## Where to use it

Tabs built like a classical arcade in travertine: names are carved into the frieze and each arch is a tab. The chosen arch opens onto a bright sky while the others stay in the shade of the loggia, and a patch of sunlight in the shape of the arch slides across the tiled floor. It suits architecture studios, hotels, museums and property sites.

The main color sets the sunlight and the secondary color the stone. Four arches fit best; keep the carved names to one word and use the panel below for a short line about each section.

## Code

### HTML

```html
<div class="uvq12-ar"><div class="pt" role="tablist" aria-label="Architecture"><button type="button" role="tab" id="uvq12-ar-t0" aria-selected="true" aria-controls="uvq12-ar-p0" tabindex="0"><span class="fz">Studio</span><span class="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t1" aria-selected="false" aria-controls="uvq12-ar-p1" tabindex="-1"><span class="fz">Works</span><span class="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t2" aria-selected="false" aria-controls="uvq12-ar-p2" tabindex="-1"><span class="fz">Team</span><span class="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t3" aria-selected="false" aria-controls="uvq12-ar-p3" tabindex="-1"><span class="fz">Contact</span><span class="op" aria-hidden="true"></span></button></div><div class="fl" aria-hidden="true"><span class="sun"></span></div><div class="pn" role="tabpanel" id="uvq12-ar-p0" aria-labelledby="uvq12-ar-t0">Architecture and restoration since 1998.</div><div class="pn" role="tabpanel" id="uvq12-ar-p1" aria-labelledby="uvq12-ar-t1" hidden>Thirty buildings in six cities.</div><div class="pn" role="tabpanel" id="uvq12-ar-p2" aria-labelledby="uvq12-ar-t2" hidden>Nine people between Madrid and Porto.</div><div class="pn" role="tabpanel" id="uvq12-ar-p3" aria-labelledby="uvq12-ar-t3" hidden>Calle del Prado, 14. Come and see us.</div></div>
```

### CSS

```css
.uvq12-ar {
  --c1: #fbbf24;
  --c2: #e8dcc6;
  --s: 16px;
  /* tamaño */
  --k: 1;
  /* velocidad */
  --fg: #1d1d1f;
  /* texto */
  --bg: #f5f5f7;
  /* fondo */
}

.uvq12-ar {
  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;
  width: 20em;
  --i: 0;
}

.uvq12-ar .pt {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  padding: 0 .45em;
  border-radius: .4em .4em 0 0;
  background: repeating-linear-gradient(180deg,transparent 0 1.05em,rgba(120,90,60,.14) 1.05em calc(1.05em + 1px)),linear-gradient(180deg,color-mix(in srgb,var(--c2) 85%,#fff),var(--c2));
  box-shadow: inset 0 .5em 0 -.3em color-mix(in srgb,var(--c2) 75%,#7c5c3b),0 1em 2em -1.2em rgba(0,0,0,.4);
}

.uvq12-ar [role="tab"] {
  font: inherit;
  color: inherit;
  border: 0;
  margin: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  height: 8.2em;
  border-radius: .3em;
}

.uvq12-ar .fz {
  position: absolute;
  left: 0;
  right: 0;
  top: .55em;
  text-align: center;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-size: .6em;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #7c5c3b;
  transition: color calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .op {
  position: absolute;
  left: .5em;
  right: .5em;
  top: 2em;
  bottom: 0;
  border-radius: 2em 2em 0 0;
  background: linear-gradient(180deg,#3b2a1e,#5b4331);
  box-shadow: inset 0 .4em .8em rgba(0,0,0,.45),0 0 0 .16em color-mix(in srgb,var(--c2) 70%,#a8896a);
  transition: background calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1),box-shadow calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .op::after {
  content: "";
  position: absolute;
  left: 50%;
  top: -.36em;
  width: .6em;
  height: .55em;
  margin-left: -.3em;
  clip-path: polygon(0 0,100% 0,80% 100%,20% 100%);
  background: color-mix(in srgb,var(--c2) 70%,#a8896a);
}

.uvq12-ar [role="tab"]:hover .op {
  background: linear-gradient(180deg,#4a3627,#6b513c);
}

.uvq12-ar [aria-selected="true"] .op {
  background: linear-gradient(180deg,#bae6fd,color-mix(in srgb,var(--c1) 55%,#fff) 70%,var(--c1));
  box-shadow: inset 0 0 1.2em rgba(255,255,255,.5),0 0 0 .16em color-mix(in srgb,var(--c2) 70%,#a8896a);
}

.uvq12-ar [aria-selected="true"] .fz {
  color: #3f2a17;
}

.uvq12-ar [role="tab"]:active .op {
  transform: scale(.98);
}

.uvq12-ar [role="tab"]:focus-visible {
  outline: 2px solid #7c5c3b;
  outline-offset: -2px;
}

.uvq12-ar .fl {
  position: relative;
  height: 3.4em;
  overflow: hidden;
  border-radius: 0 0 .4em .4em;
  background: repeating-linear-gradient(90deg,transparent 0 2.4em,rgba(0,0,0,.12) 2.4em calc(2.4em + 1px)),repeating-linear-gradient(180deg,transparent 0 .8em,rgba(0,0,0,.1) .8em calc(.8em + 1px)),linear-gradient(180deg,#a8896a,#c9b18f);
}

.uvq12-ar .sun {
  position: absolute;
  top: 0;
  left: calc(.45em + (100% - .9em) * var(--i) / 4 + .5em);
  width: calc((100% - .9em) / 4 - 1em);
  height: 110%;
  border-radius: 0 0 50% 50% / 0 0 35% 35%;
  background: linear-gradient(180deg,color-mix(in srgb,var(--c1) 70%,#fff),color-mix(in srgb,var(--c1) 25%,transparent));
  opacity: .85;
  transform: skewX(-32deg);
  transform-origin: 0 0;
  transition: left calc(0.7s / var(--k)) cubic-bezier(.22,1,.36,1);
}

.uvq12-ar .pn {
  margin: .8em .3em 0;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-size: .92em;
  line-height: 1.45;
  color: color-mix(in srgb,var(--fg) 80%,transparent);
  animation: uvq12-ar calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .pn[hidden] {
  display: none;
}

@keyframes uvq12-ar {
  from {
    opacity: 0;
  }
}

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

### JavaScript

```js
document.querySelectorAll(".uvq12-ar").forEach(el => {
  const ps=[...el.querySelectorAll('[role="tabpanel"]')];const tb=[...el.querySelectorAll('[role="tab"]')];const sel=(t,f)=>{const i=tb.indexOf(t);tb.forEach((x,j)=>{x.setAttribute("aria-selected",String(j===i));x.tabIndex=j===i?0:-1});ps.forEach((p,j)=>{p.hidden=j!==i});el.style.setProperty("--i",i);if(f)t.focus()};tb.forEach(t=>t.addEventListener("click",()=>sel(t)));el.addEventListener("keydown",e=>{const i=tb.indexOf(document.activeElement);if(i<0)return;const n={ArrowRight:i+1,ArrowDown:i+1,ArrowLeft:i-1,ArrowUp:i-1,Home:0,End:tb.length-1}[e.key];if(n===undefined)return;e.preventDefault();sel(tb[(n+tb.length)%tb.length],1)});
});
```

### 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 = `
.uvq12-ar {
  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;
  width: 20em;
  --i: 0;
}

.uvq12-ar .pt {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  padding: 0 .45em;
  border-radius: .4em .4em 0 0;
  background: repeating-linear-gradient(180deg,transparent 0 1.05em,rgba(120,90,60,.14) 1.05em calc(1.05em + 1px)),linear-gradient(180deg,color-mix(in srgb,var(--c2) 85%,#fff),var(--c2));
  box-shadow: inset 0 .5em 0 -.3em color-mix(in srgb,var(--c2) 75%,#7c5c3b),0 1em 2em -1.2em rgba(0,0,0,.4);
}

.uvq12-ar [role="tab"] {
  font: inherit;
  color: inherit;
  border: 0;
  margin: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  height: 8.2em;
  border-radius: .3em;
}

.uvq12-ar .fz {
  position: absolute;
  left: 0;
  right: 0;
  top: .55em;
  text-align: center;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-size: .6em;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #7c5c3b;
  transition: color calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .op {
  position: absolute;
  left: .5em;
  right: .5em;
  top: 2em;
  bottom: 0;
  border-radius: 2em 2em 0 0;
  background: linear-gradient(180deg,#3b2a1e,#5b4331);
  box-shadow: inset 0 .4em .8em rgba(0,0,0,.45),0 0 0 .16em color-mix(in srgb,var(--c2) 70%,#a8896a);
  transition: background calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1),box-shadow calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .op::after {
  content: "";
  position: absolute;
  left: 50%;
  top: -.36em;
  width: .6em;
  height: .55em;
  margin-left: -.3em;
  clip-path: polygon(0 0,100% 0,80% 100%,20% 100%);
  background: color-mix(in srgb,var(--c2) 70%,#a8896a);
}

.uvq12-ar [role="tab"]:hover .op {
  background: linear-gradient(180deg,#4a3627,#6b513c);
}

.uvq12-ar [aria-selected="true"] .op {
  background: linear-gradient(180deg,#bae6fd,color-mix(in srgb,var(--c1) 55%,#fff) 70%,var(--c1));
  box-shadow: inset 0 0 1.2em rgba(255,255,255,.5),0 0 0 .16em color-mix(in srgb,var(--c2) 70%,#a8896a);
}

.uvq12-ar [aria-selected="true"] .fz {
  color: #3f2a17;
}

.uvq12-ar [role="tab"]:active .op {
  transform: scale(.98);
}

.uvq12-ar [role="tab"]:focus-visible {
  outline: 2px solid #7c5c3b;
  outline-offset: -2px;
}

.uvq12-ar .fl {
  position: relative;
  height: 3.4em;
  overflow: hidden;
  border-radius: 0 0 .4em .4em;
  background: repeating-linear-gradient(90deg,transparent 0 2.4em,rgba(0,0,0,.12) 2.4em calc(2.4em + 1px)),repeating-linear-gradient(180deg,transparent 0 .8em,rgba(0,0,0,.1) .8em calc(.8em + 1px)),linear-gradient(180deg,#a8896a,#c9b18f);
}

.uvq12-ar .sun {
  position: absolute;
  top: 0;
  left: calc(.45em + (100% - .9em) * var(--i) / 4 + .5em);
  width: calc((100% - .9em) / 4 - 1em);
  height: 110%;
  border-radius: 0 0 50% 50% / 0 0 35% 35%;
  background: linear-gradient(180deg,color-mix(in srgb,var(--c1) 70%,#fff),color-mix(in srgb,var(--c1) 25%,transparent));
  opacity: .85;
  transform: skewX(-32deg);
  transform-origin: 0 0;
  transition: left calc(0.7s / var(--k)) cubic-bezier(.22,1,.36,1);
}

.uvq12-ar .pn {
  margin: .8em .3em 0;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-size: .92em;
  line-height: 1.45;
  color: color-mix(in srgb,var(--fg) 80%,transparent);
  animation: uvq12-ar calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .pn[hidden] {
  display: none;
}

@keyframes uvq12-ar {
  from {
    opacity: 0;
  }
}

@media (prefers-reduced-motion:reduce) {
  .uvq12-ar,.uvq12-ar *,.uvq12-ar *::before,.uvq12-ar *::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 ps=[...el.querySelectorAll('[role="tabpanel"]')];const tb=[...el.querySelectorAll('[role="tab"]')];const sel=(t,f)=>{const i=tb.indexOf(t);tb.forEach((x,j)=>{x.setAttribute("aria-selected",String(j===i));x.tabIndex=j===i?0:-1});ps.forEach((p,j)=>{p.hidden=j!==i});el.style.setProperty("--i",i);if(f)t.focus()};tb.forEach(t=>t.addEventListener("click",()=>sel(t)));el.addEventListener("keydown",e=>{const i=tb.indexOf(document.activeElement);if(i<0)return;const n={ArrowRight:i+1,ArrowDown:i+1,ArrowLeft:i-1,ArrowUp:i-1,Home:0,End:tb.length-1}[e.key];if(n===undefined)return;e.preventDefault();sel(tb[(n+tb.length)%tb.length],1)});
}

export default function NavArcadeTabs() {
  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": "#fbbf24",
          "--c2": "#e8dcc6",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <div className="uvq12-ar"><div className="pt" role="tablist" aria-label="Architecture"><button type="button" role="tab" id="uvq12-ar-t0" aria-selected="true" aria-controls="uvq12-ar-p0" tabIndex={0}><span className="fz">Studio</span><span className="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t1" aria-selected="false" aria-controls="uvq12-ar-p1" tabIndex={-1}><span className="fz">Works</span><span className="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t2" aria-selected="false" aria-controls="uvq12-ar-p2" tabIndex={-1}><span className="fz">Team</span><span className="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t3" aria-selected="false" aria-controls="uvq12-ar-p3" tabIndex={-1}><span className="fz">Contact</span><span className="op" aria-hidden="true"></span></button></div><div className="fl" aria-hidden="true"><span className="sun"></span></div><div className="pn" role="tabpanel" id="uvq12-ar-p0" aria-labelledby="uvq12-ar-t0">Architecture and restoration since 1998.</div><div className="pn" role="tabpanel" id="uvq12-ar-p1" aria-labelledby="uvq12-ar-t1" hidden={true}>Thirty buildings in six cities.</div><div className="pn" role="tabpanel" id="uvq12-ar-p2" aria-labelledby="uvq12-ar-t2" hidden={true}>Nine people between Madrid and Porto.</div><div className="pn" role="tabpanel" id="uvq12-ar-p3" aria-labelledby="uvq12-ar-t3" hidden={true}>Calle del Prado, 14. Come and see us.</div></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 “Stone arcade tabs” block (Navigation) from AIMRAN Library to my project.

## What it is
A stone arcade with four arches: the chosen one lets the sun through and its shape slides across the floor when you switch.

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

## 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 = `
.uvq12-ar {
  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;
  width: 20em;
  --i: 0;
}

.uvq12-ar .pt {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  padding: 0 .45em;
  border-radius: .4em .4em 0 0;
  background: repeating-linear-gradient(180deg,transparent 0 1.05em,rgba(120,90,60,.14) 1.05em calc(1.05em + 1px)),linear-gradient(180deg,color-mix(in srgb,var(--c2) 85%,#fff),var(--c2));
  box-shadow: inset 0 .5em 0 -.3em color-mix(in srgb,var(--c2) 75%,#7c5c3b),0 1em 2em -1.2em rgba(0,0,0,.4);
}

.uvq12-ar [role="tab"] {
  font: inherit;
  color: inherit;
  border: 0;
  margin: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  height: 8.2em;
  border-radius: .3em;
}

.uvq12-ar .fz {
  position: absolute;
  left: 0;
  right: 0;
  top: .55em;
  text-align: center;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-size: .6em;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #7c5c3b;
  transition: color calc(0.3s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .op {
  position: absolute;
  left: .5em;
  right: .5em;
  top: 2em;
  bottom: 0;
  border-radius: 2em 2em 0 0;
  background: linear-gradient(180deg,#3b2a1e,#5b4331);
  box-shadow: inset 0 .4em .8em rgba(0,0,0,.45),0 0 0 .16em color-mix(in srgb,var(--c2) 70%,#a8896a);
  transition: background calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1),box-shadow calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .op::after {
  content: "";
  position: absolute;
  left: 50%;
  top: -.36em;
  width: .6em;
  height: .55em;
  margin-left: -.3em;
  clip-path: polygon(0 0,100% 0,80% 100%,20% 100%);
  background: color-mix(in srgb,var(--c2) 70%,#a8896a);
}

.uvq12-ar [role="tab"]:hover .op {
  background: linear-gradient(180deg,#4a3627,#6b513c);
}

.uvq12-ar [aria-selected="true"] .op {
  background: linear-gradient(180deg,#bae6fd,color-mix(in srgb,var(--c1) 55%,#fff) 70%,var(--c1));
  box-shadow: inset 0 0 1.2em rgba(255,255,255,.5),0 0 0 .16em color-mix(in srgb,var(--c2) 70%,#a8896a);
}

.uvq12-ar [aria-selected="true"] .fz {
  color: #3f2a17;
}

.uvq12-ar [role="tab"]:active .op {
  transform: scale(.98);
}

.uvq12-ar [role="tab"]:focus-visible {
  outline: 2px solid #7c5c3b;
  outline-offset: -2px;
}

.uvq12-ar .fl {
  position: relative;
  height: 3.4em;
  overflow: hidden;
  border-radius: 0 0 .4em .4em;
  background: repeating-linear-gradient(90deg,transparent 0 2.4em,rgba(0,0,0,.12) 2.4em calc(2.4em + 1px)),repeating-linear-gradient(180deg,transparent 0 .8em,rgba(0,0,0,.1) .8em calc(.8em + 1px)),linear-gradient(180deg,#a8896a,#c9b18f);
}

.uvq12-ar .sun {
  position: absolute;
  top: 0;
  left: calc(.45em + (100% - .9em) * var(--i) / 4 + .5em);
  width: calc((100% - .9em) / 4 - 1em);
  height: 110%;
  border-radius: 0 0 50% 50% / 0 0 35% 35%;
  background: linear-gradient(180deg,color-mix(in srgb,var(--c1) 70%,#fff),color-mix(in srgb,var(--c1) 25%,transparent));
  opacity: .85;
  transform: skewX(-32deg);
  transform-origin: 0 0;
  transition: left calc(0.7s / var(--k)) cubic-bezier(.22,1,.36,1);
}

.uvq12-ar .pn {
  margin: .8em .3em 0;
  font-family: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  font-size: .92em;
  line-height: 1.45;
  color: color-mix(in srgb,var(--fg) 80%,transparent);
  animation: uvq12-ar calc(0.5s / var(--k)) cubic-bezier(.25,.1,.25,1);
}

.uvq12-ar .pn[hidden] {
  display: none;
}

@keyframes uvq12-ar {
  from {
    opacity: 0;
  }
}

@media (prefers-reduced-motion:reduce) {
  .uvq12-ar,.uvq12-ar *,.uvq12-ar *::before,.uvq12-ar *::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 ps=[...el.querySelectorAll('[role="tabpanel"]')];const tb=[...el.querySelectorAll('[role="tab"]')];const sel=(t,f)=>{const i=tb.indexOf(t);tb.forEach((x,j)=>{x.setAttribute("aria-selected",String(j===i));x.tabIndex=j===i?0:-1});ps.forEach((p,j)=>{p.hidden=j!==i});el.style.setProperty("--i",i);if(f)t.focus()};tb.forEach(t=>t.addEventListener("click",()=>sel(t)));el.addEventListener("keydown",e=>{const i=tb.indexOf(document.activeElement);if(i<0)return;const n={ArrowRight:i+1,ArrowDown:i+1,ArrowLeft:i-1,ArrowUp:i-1,Home:0,End:tb.length-1}[e.key];if(n===undefined)return;e.preventDefault();sel(tb[(n+tb.length)%tb.length],1)});
}

export default function NavArcadeTabs() {
  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": "#fbbf24",
          "--c2": "#e8dcc6",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <div className="uvq12-ar"><div className="pt" role="tablist" aria-label="Architecture"><button type="button" role="tab" id="uvq12-ar-t0" aria-selected="true" aria-controls="uvq12-ar-p0" tabIndex={0}><span className="fz">Studio</span><span className="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t1" aria-selected="false" aria-controls="uvq12-ar-p1" tabIndex={-1}><span className="fz">Works</span><span className="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t2" aria-selected="false" aria-controls="uvq12-ar-p2" tabIndex={-1}><span className="fz">Team</span><span className="op" aria-hidden="true"></span></button><button type="button" role="tab" id="uvq12-ar-t3" aria-selected="false" aria-controls="uvq12-ar-p3" tabIndex={-1}><span className="fz">Contact</span><span className="op" aria-hidden="true"></span></button></div><div className="fl" aria-hidden="true"><span className="sun"></span></div><div className="pn" role="tabpanel" id="uvq12-ar-p0" aria-labelledby="uvq12-ar-t0">Architecture and restoration since 1998.</div><div className="pn" role="tabpanel" id="uvq12-ar-p1" aria-labelledby="uvq12-ar-t1" hidden={true}>Thirty buildings in six cities.</div><div className="pn" role="tabpanel" id="uvq12-ar-p2" aria-labelledby="uvq12-ar-t2" hidden={true}>Nine people between Madrid and Porto.</div><div className="pn" role="tabpanel" id="uvq12-ar-p3" aria-labelledby="uvq12-ar-t3" hidden={true}>Calle del Prado, 14. Come and see us.</div></div>
      </div>
    </>
  );
}
```

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