Zoeken...  ⌘K GitHub

VideoHero2 video

Hero met video achtergrond en overlay tekst.

/video-hero-2
src/components/video/VideoHero2.astro
---
/**
 * VideoHero2
 * Hero met video-achtergrond en overlay-tekst
 */
interface Props {
  headline?: string;
  sub?: string;
  cta?: { label: string; href: string };
}
const {
  headline = 'Marketing die meetbare groei oplevert',
  sub = 'Van strategie tot executie — BLURR begeleidt ambitieuze merken naar duurzame online groei.',
  cta = { label: 'Bekijk onze werkwijze', href: '#werkwijze' },
} = Astro.props;
---

<section class="vh2">
  <div class="vh2__bg">
    <video
      class="vh2__video"
      autoplay
      muted
      loop
      playsinline
      aria-hidden="true"
    >
      <source src="https://www.w3schools.com/html/mov_bbb.mp4" type="video/mp4" />
    </video>
    <div class="vh2__overlay"></div>
  </div>
  <div class="vh2__content">
    <div class="vh2__inner">
      <p class="vh2__eyebrow">Digital Marketing Agency</p>
      <h1 class="vh2__headline">{headline}</h1>
      <p class="vh2__sub">{sub}</p>
      <div class="vh2__actions">
        <a class="vh2__cta" href={cta.href}>{cta.label}</a>
        <a class="vh2__cta-ghost" href="#cases">Bekijk cases</a>
      </div>
    </div>
  </div>
</section>

<style>
  .vh2 {
    position: relative;
    min-height: 100svh;
    display: flex;
    align-items: center;
    overflow: hidden;
  }
  .vh2__bg {
    position: absolute;
    inset: 0;
  }
  .vh2__video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }
  .vh2__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(10,10,10,0.82) 0%, rgba(10,10,10,0.5) 100%);
  }
  .vh2__content {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 6rem 1.5rem;
  }
  .vh2__inner {
    max-width: 760px;
    margin: 0 auto;
  }
  .vh2__eyebrow {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-accent, #6366f1);
    margin: 0 0 1rem;
  }
  .vh2__headline {
    font-size: clamp(2rem, 5vw, 3.75rem);
    font-weight: 800;
    color: #fff;
    margin: 0 0 1.25rem;
    line-height: 1.1;
    letter-spacing: -0.025em;
  }
  .vh2__sub {
    font-size: clamp(1rem, 1.8vw, 1.15rem);
    color: rgba(255,255,255,0.7);
    line-height: 1.65;
    margin: 0 0 2.5rem;
    max-width: 580px;
  }
  .vh2__actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
  }
  .vh2__cta {
    display: inline-block;
    padding: 0.9rem 2rem;
    background: var(--color-accent, #6366f1);
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 700;
    transition: opacity 0.2s;
  }
  .vh2__cta:hover { opacity: 0.88; }
  .vh2__cta-ghost {
    display: inline-block;
    padding: 0.9rem 2rem;
    border: 1.5px solid rgba(255,255,255,0.3);
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    transition: border-color 0.2s, background 0.2s;
  }
  .vh2__cta-ghost:hover {
    border-color: rgba(255,255,255,0.6);
    background: rgba(255,255,255,0.07);
  }
</style>

Props

Prop Type Default Beschrijving
headline string Headline
sub string Subtitel
cta { label: string; href: string } CTA

* = verplicht