# Film leader countdown loader

> A sepia film leader with its circular sweep and the numbers 3, 2, 1 flickering between grain and scratches.

- Category: [Loaders](https://library.aimran.es/components/loaders)
- Built with: HTML + CSS
- Live editor: https://library.aimran.es/blocks/uv-ld-film-leader
- Library: AIMRAN Library (https://library.aimran.es), free, no sign-up, by Aimran Oukham

## Where to use it

The classic cinema countdown rebuilt in CSS: a film strip with moving sprocket holes, a sepia frame with crosshair and rings, a wedge that sweeps around each second and a number that counts down through a registered integer property. Grain, a scratch and a slight flicker finish it. It suits video platforms, trailers and film festivals.

The main color sets the film tint and the second the ink of lines and numbers, so you can go from sepia to cold black and white. Use it right before a video starts or while a clip renders.

## Code

### HTML

```html
<div class="uvq10-flm" role="status"><span class="sr">Loading</span><div class="fr" aria-hidden="true"><i class="sw"></i><i class="cx"></i><i class="ci a"></i><i class="ci b"></i><span class="n"></span><i class="gr"></i></div></div>
```

### CSS

```css
.uvq10-flm {
  --c1: #cdbb98;
  --c2: #2b241c;
  --s: 16px;
  /* tamaño */
  --k: 1;
  /* velocidad */
  --fg: #1d1d1f;
  /* texto */
  --bg: #f5f5f7;
  /* fondo */
}

@property --uvq10-a {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@property --uvq10-n {
  syntax: "<integer>";
  inherits: true;
  initial-value: 3;
}

.uvq10-flm {
  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: grid;
  place-items: center;
  width: 9.6em;
  height: 8em;
  border-radius: .3em;
  background: #16130f;
  box-shadow: 0 1em 1.6em -1em rgba(0,0,0,.6);
}

.uvq10-flm .sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.uvq10-flm::before,.uvq10-flm::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: .5em;
  background: linear-gradient(var(--bg) 0 .55em,transparent .55em) 0 0/100% 1em;
  border-radius: .1em;
  animation: uvq10-flm-h calc(0.3s / var(--k)) linear infinite;
}

.uvq10-flm::before {
  left: .4em;
}

.uvq10-flm::after {
  right: .4em;
}

.uvq10-flm .fr {
  position: relative;
  width: 7.2em;
  height: 6.6em;
  border-radius: .35em;
  overflow: hidden;
  background: radial-gradient(circle,transparent 45%,rgba(0,0,0,.5)),var(--c1);
  animation: uvq10-flm-k calc(0.5s / var(--k)) steps(1) infinite;
}

.uvq10-flm .sw {
  position: absolute;
  inset: -1em;
  background: conic-gradient(rgba(0,0,0,.32) var(--uvq10-a),transparent 0);
  animation: uvq10-flm-a calc(1s / var(--k)) linear infinite;
}

.uvq10-flm .cx {
  position: absolute;
  inset: 0;
  background: linear-gradient(var(--c2),var(--c2)) 50% 0/1.5px 100% no-repeat,linear-gradient(var(--c2),var(--c2)) 0 50%/100% 1.5px no-repeat;
  opacity: .75;
}

.uvq10-flm .ci {
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 50%;
  border: .12em solid var(--c2);
}

.uvq10-flm .ci.a {
  width: 5.4em;
  height: 5.4em;
  margin: -2.7em;
}

.uvq10-flm .ci.b {
  width: 4.4em;
  height: 4.4em;
  margin: -2.2em;
  border-width: .08em;
}

.uvq10-flm .n {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font: 800 3.4em/1 system-ui,sans-serif;
  color: var(--c2);
  counter-reset: uvq10-n var(--uvq10-n);
  animation: uvq10-flm-n calc(3s / var(--k)) linear infinite;
}

.uvq10-flm .n::before {
  content: counter(uvq10-n);
}

.uvq10-flm .gr {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 22% 30%,rgba(255,255,255,.6) 0 1px,transparent 1.6px),radial-gradient(circle at 70% 62%,rgba(0,0,0,.6) 0 1.2px,transparent 2px),radial-gradient(circle at 44% 82%,rgba(0,0,0,.5) 0 1px,transparent 1.6px),radial-gradient(circle at 84% 18%,rgba(255,255,255,.5) 0 1px,transparent 1.5px),linear-gradient(90deg,transparent 31%,rgba(0,0,0,.25) 31% calc(31% + 1px),transparent 0);
  animation: uvq10-flm-g calc(0.5s / var(--k)) steps(1) infinite;
}

@keyframes uvq10-flm-a {
  to {
    --uvq10-a: 360deg;
  }
}

@keyframes uvq10-flm-n {
  0%,33.3% {
    --uvq10-n: 3;
  }
  33.34%,66.6% {
    --uvq10-n: 2;
  }
  66.7%,100% {
    --uvq10-n: 1;
  }
}

@keyframes uvq10-flm-h {
  to {
    background-position: 0 1em;
  }
}

@keyframes uvq10-flm-k {
  0% {
    filter: brightness(1);
  }
  30% {
    filter: brightness(1.08);
  }
  60% {
    filter: brightness(.94);
  }
  80% {
    filter: brightness(1.04);
  }
}

@keyframes uvq10-flm-g {
  0% {
    transform: translate(0,0);
  }
  25% {
    transform: translate(1.4em,-.8em) scaleX(-1);
  }
  50% {
    transform: translate(-1em,1.1em);
  }
  75% {
    transform: translate(.6em,.4em) scaleY(-1);
  }
}

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

### React

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

const css = `
@property --uvq10-a {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@property --uvq10-n {
  syntax: "<integer>";
  inherits: true;
  initial-value: 3;
}

.uvq10-flm {
  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: grid;
  place-items: center;
  width: 9.6em;
  height: 8em;
  border-radius: .3em;
  background: #16130f;
  box-shadow: 0 1em 1.6em -1em rgba(0,0,0,.6);
}

.uvq10-flm .sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.uvq10-flm::before,.uvq10-flm::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: .5em;
  background: linear-gradient(var(--bg) 0 .55em,transparent .55em) 0 0/100% 1em;
  border-radius: .1em;
  animation: uvq10-flm-h calc(0.3s / var(--k)) linear infinite;
}

.uvq10-flm::before {
  left: .4em;
}

.uvq10-flm::after {
  right: .4em;
}

.uvq10-flm .fr {
  position: relative;
  width: 7.2em;
  height: 6.6em;
  border-radius: .35em;
  overflow: hidden;
  background: radial-gradient(circle,transparent 45%,rgba(0,0,0,.5)),var(--c1);
  animation: uvq10-flm-k calc(0.5s / var(--k)) steps(1) infinite;
}

.uvq10-flm .sw {
  position: absolute;
  inset: -1em;
  background: conic-gradient(rgba(0,0,0,.32) var(--uvq10-a),transparent 0);
  animation: uvq10-flm-a calc(1s / var(--k)) linear infinite;
}

.uvq10-flm .cx {
  position: absolute;
  inset: 0;
  background: linear-gradient(var(--c2),var(--c2)) 50% 0/1.5px 100% no-repeat,linear-gradient(var(--c2),var(--c2)) 0 50%/100% 1.5px no-repeat;
  opacity: .75;
}

.uvq10-flm .ci {
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 50%;
  border: .12em solid var(--c2);
}

.uvq10-flm .ci.a {
  width: 5.4em;
  height: 5.4em;
  margin: -2.7em;
}

.uvq10-flm .ci.b {
  width: 4.4em;
  height: 4.4em;
  margin: -2.2em;
  border-width: .08em;
}

.uvq10-flm .n {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font: 800 3.4em/1 system-ui,sans-serif;
  color: var(--c2);
  counter-reset: uvq10-n var(--uvq10-n);
  animation: uvq10-flm-n calc(3s / var(--k)) linear infinite;
}

.uvq10-flm .n::before {
  content: counter(uvq10-n);
}

.uvq10-flm .gr {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 22% 30%,rgba(255,255,255,.6) 0 1px,transparent 1.6px),radial-gradient(circle at 70% 62%,rgba(0,0,0,.6) 0 1.2px,transparent 2px),radial-gradient(circle at 44% 82%,rgba(0,0,0,.5) 0 1px,transparent 1.6px),radial-gradient(circle at 84% 18%,rgba(255,255,255,.5) 0 1px,transparent 1.5px),linear-gradient(90deg,transparent 31%,rgba(0,0,0,.25) 31% calc(31% + 1px),transparent 0);
  animation: uvq10-flm-g calc(0.5s / var(--k)) steps(1) infinite;
}

@keyframes uvq10-flm-a {
  to {
    --uvq10-a: 360deg;
  }
}

@keyframes uvq10-flm-n {
  0%,33.3% {
    --uvq10-n: 3;
  }
  33.34%,66.6% {
    --uvq10-n: 2;
  }
  66.7%,100% {
    --uvq10-n: 1;
  }
}

@keyframes uvq10-flm-h {
  to {
    background-position: 0 1em;
  }
}

@keyframes uvq10-flm-k {
  0% {
    filter: brightness(1);
  }
  30% {
    filter: brightness(1.08);
  }
  60% {
    filter: brightness(.94);
  }
  80% {
    filter: brightness(1.04);
  }
}

@keyframes uvq10-flm-g {
  0% {
    transform: translate(0,0);
  }
  25% {
    transform: translate(1.4em,-.8em) scaleX(-1);
  }
  50% {
    transform: translate(-1em,1.1em);
  }
  75% {
    transform: translate(.6em,.4em) scaleY(-1);
  }
}

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

export default function LdFilmLeader() {
  return (
    <>
      <style>{css}</style>
      <div
        style={{
          "--c1": "#cdbb98",
          "--c2": "#2b241c",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <div className="uvq10-flm" role="status"><span className="sr">Loading</span><div className="fr" aria-hidden="true"><i className="sw"></i><i className="cx"></i><i className="ci a"></i><i className="ci b"></i><span className="n"></span><i className="gr"></i></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 “Film leader countdown loader” block (Loaders) from AIMRAN Library to my project.

## What it is
A sepia film leader with its circular sweep and the numbers 3, 2, 1 flickering between grain and scratches.

## Chosen settings
- Main color: #cdbb98
- Secondary color: #2b241c
- Size: 16px (from 12 to 24px)
- Speed: 1x (from 0.5 to 2x)

## 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 = `
@property --uvq10-a {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@property --uvq10-n {
  syntax: "<integer>";
  inherits: true;
  initial-value: 3;
}

.uvq10-flm {
  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: grid;
  place-items: center;
  width: 9.6em;
  height: 8em;
  border-radius: .3em;
  background: #16130f;
  box-shadow: 0 1em 1.6em -1em rgba(0,0,0,.6);
}

.uvq10-flm .sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.uvq10-flm::before,.uvq10-flm::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: .5em;
  background: linear-gradient(var(--bg) 0 .55em,transparent .55em) 0 0/100% 1em;
  border-radius: .1em;
  animation: uvq10-flm-h calc(0.3s / var(--k)) linear infinite;
}

.uvq10-flm::before {
  left: .4em;
}

.uvq10-flm::after {
  right: .4em;
}

.uvq10-flm .fr {
  position: relative;
  width: 7.2em;
  height: 6.6em;
  border-radius: .35em;
  overflow: hidden;
  background: radial-gradient(circle,transparent 45%,rgba(0,0,0,.5)),var(--c1);
  animation: uvq10-flm-k calc(0.5s / var(--k)) steps(1) infinite;
}

.uvq10-flm .sw {
  position: absolute;
  inset: -1em;
  background: conic-gradient(rgba(0,0,0,.32) var(--uvq10-a),transparent 0);
  animation: uvq10-flm-a calc(1s / var(--k)) linear infinite;
}

.uvq10-flm .cx {
  position: absolute;
  inset: 0;
  background: linear-gradient(var(--c2),var(--c2)) 50% 0/1.5px 100% no-repeat,linear-gradient(var(--c2),var(--c2)) 0 50%/100% 1.5px no-repeat;
  opacity: .75;
}

.uvq10-flm .ci {
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 50%;
  border: .12em solid var(--c2);
}

.uvq10-flm .ci.a {
  width: 5.4em;
  height: 5.4em;
  margin: -2.7em;
}

.uvq10-flm .ci.b {
  width: 4.4em;
  height: 4.4em;
  margin: -2.2em;
  border-width: .08em;
}

.uvq10-flm .n {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font: 800 3.4em/1 system-ui,sans-serif;
  color: var(--c2);
  counter-reset: uvq10-n var(--uvq10-n);
  animation: uvq10-flm-n calc(3s / var(--k)) linear infinite;
}

.uvq10-flm .n::before {
  content: counter(uvq10-n);
}

.uvq10-flm .gr {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 22% 30%,rgba(255,255,255,.6) 0 1px,transparent 1.6px),radial-gradient(circle at 70% 62%,rgba(0,0,0,.6) 0 1.2px,transparent 2px),radial-gradient(circle at 44% 82%,rgba(0,0,0,.5) 0 1px,transparent 1.6px),radial-gradient(circle at 84% 18%,rgba(255,255,255,.5) 0 1px,transparent 1.5px),linear-gradient(90deg,transparent 31%,rgba(0,0,0,.25) 31% calc(31% + 1px),transparent 0);
  animation: uvq10-flm-g calc(0.5s / var(--k)) steps(1) infinite;
}

@keyframes uvq10-flm-a {
  to {
    --uvq10-a: 360deg;
  }
}

@keyframes uvq10-flm-n {
  0%,33.3% {
    --uvq10-n: 3;
  }
  33.34%,66.6% {
    --uvq10-n: 2;
  }
  66.7%,100% {
    --uvq10-n: 1;
  }
}

@keyframes uvq10-flm-h {
  to {
    background-position: 0 1em;
  }
}

@keyframes uvq10-flm-k {
  0% {
    filter: brightness(1);
  }
  30% {
    filter: brightness(1.08);
  }
  60% {
    filter: brightness(.94);
  }
  80% {
    filter: brightness(1.04);
  }
}

@keyframes uvq10-flm-g {
  0% {
    transform: translate(0,0);
  }
  25% {
    transform: translate(1.4em,-.8em) scaleX(-1);
  }
  50% {
    transform: translate(-1em,1.1em);
  }
  75% {
    transform: translate(.6em,.4em) scaleY(-1);
  }
}

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

export default function LdFilmLeader() {
  return (
    <>
      <style>{css}</style>
      <div
        style={{
          "--c1": "#cdbb98",
          "--c2": "#2b241c",
          "--s": "16px",
          "--k": "1",
          "--fg": "#1d1d1f",
          "--bg": "#f5f5f7",
        } as CSSProperties}
      >
        <div className="uvq10-flm" role="status"><span className="sr">Loading</span><div className="fr" aria-hidden="true"><i className="sw"></i><i className="cx"></i><i className="ci a"></i><i className="ci b"></i><span className="n"></span><i className="gr"></i></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.
````
