Skip to content

Hero

Edit on GitHub

Full-width hero blocks for prominent page-level messaging with text and media layouts.

@volvo-cars/css v3.3.1
volvocars.com
Show codeHide code
<section class="text-hero" style="min-height: 740px">
<h1 slot="title">Care. By Volvo</h1>
<div slot="body">
<p>All-electric Volvo EX60</p>
<p>
A transparent monthly cost that includes service and financing. Now with
free home charging.
</p>
</div>
<div slot="action" class="button-group">
<a class="button-filled" href="#">Choose your EX60</a>
<a class="button-filled" data-color="subtle" href="#">Read more</a>
</div>
</section>
volvocars.com
Show codeHide code
<section class="media-hero">
<h1 slot="title">Care. By Volvo</h1>
<div slot="body">
<p>
All-electric Volvo EX60 A transparent monthly cost that includes service
and financing. Now with free home charging.
</p>
</div>
<div slot="action" class="button-group">
<a class="button-filled" href="#">Choose your EX60</a>
<a class="button-filled" data-color="subtle" href="#">Read more</a>
</div>
<img slot="media" src="/images/decorative/ex60-road.avif" alt="" />
</section>
volvocars.com
Show codeHide code
<section class="media-hero">
<img slot="media" src="/images/decorative/ex60-road.avif" alt="" />
<h1 slot="title">Care. By Volvo</h1>
<div slot="body">
<p>
All-electric Volvo EX60 A transparent monthly cost that includes service
and financing. Now with free home charging.
</p>
</div>
<div slot="action" class="button-group">
<a class="button-filled" href="#">Choose your EX60</a>
<a class="button-filled" data-color="subtle" href="#">Read more</a>
</div>
</section>

Place the media slot before the title, body, and action slots. Keep all four as direct children of .media-hero.

volvocars.com
Show codeHide code
<section class="media-hero">
<h1 slot="title">Care. By Volvo</h1>
<img slot="media" src="/images/decorative/ex60-road.avif" alt="" />
<div slot="body">
<p>
All-electric Volvo EX60 A transparent monthly cost that includes service
and financing. Now with free home charging.
</p>
</div>
<div slot="action" class="button-group">
<a class="button-filled" href="#">Choose your EX60</a>
<a class="button-filled" data-color="subtle" href="#">Read more</a>
</div>
</section>

Place the media slot between the title and supporting content. Keep all slots as direct children of .media-hero. This order stays in one column at every breakpoint, with body text and actions aligned with the title. Include body text, actions, or both.