# Thumb Nav (`.z-thumbnav`)

> Thumbnail navigation for lightboxes and galleries, with an overlay highlight on hover/active.

- **Kind:** css
- **Category:** navigation

## CSS Variables

| Variable | Default | Scope | Affects | Description |
| --- | --- | --- | --- | --- |
| `--z-thumbnav-item-padding-horizontal` | `1rem` | `.z-thumbnav` | `margin-inline-start`, `padding-inline-start` | Horizontal spacing between thumbnails (padding and margin). |
| `--z-thumbnav-item-padding-vertical` | `1rem` | `.z-thumbnav-vertical` | `margin-block-start`, `padding-block-start` | Vertical spacing between thumbnails (padding and margin). |
| `--z-thumbnav-overlay-active-opacity` | `0` | `.z-thumbnav` | `opacity` | Overlay opacity on the active thumbnail. |
| `--z-thumbnav-overlay-bg` | `linear-gradient( 180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.4) )` | `.z-thumbnav > * > *::after` | `background-image` | Overlay background image (gradient) shown over thumbnails. |
| `--z-thumbnav-overlay-hover-opacity` | `0` | `.z-thumbnav` | `opacity` | Overlay opacity while hovered. |
| `--z-thumbnav-overlay-transition` | `opacity 0.1s ease-in-out` | `.z-thumbnav` | `transition` | Transition timing of the overlay. |

## CSS Classes

| Class | Role | Applies to | Description |
| --- | --- | --- | --- |
| `.z-thumbnav` | `root` | `.z-thumbnav` | Root class of the thumbnail navigation list. |
| `.z-thumbnav-vertical` | `element` | `.z-thumbnav` | Vertical thumbnail orientation. |

## Accessibility

> When generated by the lightbox, the list becomes a `role="tablist"`; standalone thumbnavs should label their links.

## Notes

- Thumbnav is a CSS layer; the lightbox generates items from `data-thumb` URLs.

## Guides

- [Styling with cls and stl](https://next.0build.dev/docs/guides/styling.md)
- [Translating Components](https://next.0build.dev/docs/guides/i18n.md)
- [Icon Resolution](https://next.0build.dev/docs/guides/icons.md)
- [The data-source Convention](https://next.0build.dev/docs/guides/data-source.md)
- [Openers & Triggers](https://next.0build.dev/docs/guides/triggers.md)
- [Dialog Behavior](https://next.0build.dev/docs/guides/dialogs.md)
- [Utilities](https://next.0build.dev/docs/guides/utilities.md)
- [Runtime](https://next.0build.dev/docs/guides/runtime.md)

## Related

- [Lightbox](https://next.0build.dev/docs/components/lightbox.md)
- [Dot Nav](https://next.0build.dev/docs/components/dotnav.md)
