---
title: "Media"
description: "Website blocks - Media: Blocks for pictures, video, audio and social content: single pictures with a large view, galleries with shared controls, text beside media, native video and audio players, playlists, before / after comparisons and locally rendered social posts."
slug: "website-media"
---

import { DocPage, PageHeader, DocText, DocLink } from "../../lib/components/index";

<DocPage meta={meta}>

<PageHeader slug="website-media" title="Media" introStyle="max-width:42rem;">
  Blocks for pictures, video, audio and social content: single pictures with a large view, galleries with shared controls, text beside media, native video and audio players, playlists, before / after comparisons and locally rendered social posts. Every block is CSS-only and built from the library's components and tokens.
</PageHeader>

<h2 id="template" class="h2-display">The template</h2>

<DocText>The Media blocks composed into one page - the source is the page. Every photo and the Slideshow button are routes of <DocLink href="routing.html">defuss-dom-router</DocLink> (<code>#/photos/3</code>) that open the slideshow on that photo - a photo is linkable, Esc returns to <code>#/</code>; the language switch translates the frame with <DocLink href="translation.html">defuss-i18n</DocLink>.</DocText>

<div class="flex flex-wrap items-center gap-2 mb-6">
  <a class="btn" href="full-website-media.html" target="_blank" rel="noopener"><i data-lucide="maximize-2"></i> Open full screen</a>
</div>

```html example label="A media page" schema="none" hint="A photo is a route that opens the slideshow (#/photos/3); the switch translates the frame. Text Media, a Media Gallery, a Video Player with transcript, a podcast Audio Player over its Playlist, a Before After slider and Social Posts - only Media blocks." previewStyle="align-items:stretch;"
<style>
  @import url('https://fonts.googleapis.com/css2?family=Instrument+Sans:wght@400;500;600;700&family=Instrument+Serif:ital@0;1&display=swap');
  /* Acme Stories, the company's media room, on one 76rem grid with ONE language: an Instrument Serif title per
     section, Instrument Sans for everything else, square-cornered pictures, sections numbered 01-05 on a hairline,
     one accent. The film always plays in a dark screening band. Moves: a customs stamp on the first picture, film
     frames around the stills in Cinema, the podcast cover turning like a record while it plays. Looks: Gallery
     (white walls and vermilion, follows light / dark), Cinema (black, amber, grain over the stills) and Archive
     (warm paper, sepia prints, brown ink). */
  #site-media {
    --background: oklch(0.99 0 0);
    --foreground: oklch(0.18 0 0);
    --card: oklch(1 0 0);
    --card-foreground: var(--foreground);
    --muted: oklch(0.96 0 0);
    --muted-foreground: oklch(0.44 0 0);
    --border: oklch(0.18 0 0 / 0.12);
    --input: oklch(0.18 0 0 / 0.24);
    --primary: oklch(0.18 0 0);
    --primary-foreground: oklch(0.99 0 0);
    --secondary: oklch(0.96 0 0);
    --secondary-foreground: var(--foreground);
    --accent: oklch(0.58 0.2 32);
    --accent-foreground: oklch(0.99 0 0);
    --ring: var(--md-brand);
    /* one corner for every box in the site - pictures, players, cards, buttons alike */
    --radius: 0.375rem;
    --radius-sm: var(--radius);
    --radius-md: var(--radius);
    --radius-lg: var(--radius);
    --radius-xl: var(--radius);
    --md-title: 'Instrument Serif', Georgia, serif;
    --md-stamp: oklch(0.5 0.16 255);
    --md-photo: saturate(1);
    color-scheme: light;
    container-type: inline-size;
    counter-reset: md;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    width: 100%;
    overflow-x: clip;
    background: var(--background);
    color: var(--foreground);
    font:
      400 1rem/1.55 'Instrument Sans',
      var(--font-sans);
  }
  .dark #site-media[data-look='gallery'] {
    color-scheme: dark;
    --background: oklch(0.17 0 0);
    --foreground: oklch(0.95 0 0);
    --card: oklch(0.21 0 0);
    --muted: oklch(0.24 0 0);
    --muted-foreground: oklch(0.74 0 0);
    --border: oklch(0.95 0 0 / 0.12);
    --input: oklch(0.95 0 0 / 0.24);
    --primary: oklch(0.95 0 0);
    --primary-foreground: oklch(0.17 0 0);
    --secondary: oklch(0.24 0 0);
    --accent: oklch(0.7 0.17 35);
    --md-stamp: oklch(0.75 0.12 255);
  }
  #site-media[data-look='cinema'] {
    color-scheme: dark;
    --background: oklch(0.12 0 0);
    --foreground: oklch(0.94 0.01 85);
    --card: oklch(0.16 0 0);
    --muted: oklch(0.2 0 0);
    --muted-foreground: oklch(0.74 0.01 85);
    --border: oklch(0.94 0.01 85 / 0.12);
    --input: oklch(0.94 0.01 85 / 0.24);
    --primary: oklch(0.82 0.13 80);
    --primary-foreground: oklch(0.12 0 0);
    --secondary: oklch(0.2 0 0);
    --secondary-foreground: var(--foreground);
    --accent: oklch(0.82 0.13 80);
    --accent-foreground: oklch(0.12 0 0);
    --md-stamp: oklch(0.82 0.13 80);
  }
  #site-media[data-look='archive'] {
    color-scheme: light;
    --background: oklch(0.955 0.018 78);
    --foreground: oklch(0.26 0.03 50);
    --card: oklch(0.975 0.014 78);
    --muted: oklch(0.925 0.022 75);
    --muted-foreground: oklch(0.46 0.035 55);
    --border: oklch(0.26 0.03 50 / 0.14);
    --input: oklch(0.26 0.03 50 / 0.26);
    --primary: oklch(0.36 0.06 45);
    --primary-foreground: oklch(0.975 0.014 78);
    --secondary: oklch(0.925 0.022 75);
    --secondary-foreground: var(--foreground);
    --accent: oklch(0.48 0.12 40);
    --accent-foreground: oklch(0.975 0.014 78);
    --md-stamp: oklch(0.45 0.12 30);
    --md-photo: sepia(0.55) saturate(0.8) contrast(1.02);
  }
  #site-media .md-look-only {
    display: none;
  }
  #site-media[data-look='cinema'] .md-look-only[data-for='cinema'] {
    display: block;
  }
  /* one grid for every section */
  #site-media > :not(template) {
    box-sizing: border-box;
    width: 100%;
    padding-inline: max(clamp(1rem, 4vw, 2.5rem), calc((100% - 76rem) / 2));
  }
  #site-media .md-bar {
    border-block-end: 1px solid var(--border);
    background: var(--background);
    color: var(--foreground);
  }
  #site-media .md-bar .mk-header-inner {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.75rem 1.5rem;
    max-width: none;
    min-height: 4.5rem;
    margin: 0;
    padding: 0.75rem 0;
  }
  #site-media .md-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 1.5rem;
    margin-inline-end: auto;
  }
  #site-media .md-nav a {
    padding-block: 0.375rem;
    color: var(--muted-foreground);
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
  }
  #site-media .md-nav a:hover,
  #site-media .md-nav a[aria-current] {
    color: var(--foreground);
  }
  #site-media .md-brand {
    color: var(--foreground);
    text-decoration: none;
    font: 400 1.625rem/1 var(--md-title);
  }
  #site-media .md-brand i {
    color: var(--md-brand);
  }
  #site-media .md-bar-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  #site-media .md-bar .select {
    min-width: 8rem;
  }
  /* sections: a number on a hairline, then the content */
  #site-media > .md-section {
    counter-increment: md;
    padding-block: clamp(3rem, 6vw, 4.5rem);
  }
  #site-media > .md-section::before {
    content: counter(md, decimal-leading-zero);
    display: block;
    margin-block-end: 1.5rem;
    padding-block-start: 0.75rem;
    border-block-start: 1px solid var(--foreground);
    color: var(--md-brand);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
  }
  #site-media
    :is(.mk-text-media-title, .mk-media-gallery-head h2, .mk-video-player-caption h3, .mk-audio-player-title) {
    font-family: var(--md-title);
    font-style: normal;
    font-weight: 400;
    letter-spacing: -0.01em;
  }
  #site-media img {
    filter: var(--md-photo);
  }
  /* the opening: copy beside the first picture, a customs stamp on it */
  #site-media .md-hero {
    padding-block: clamp(3.5rem, 8vw, 6rem);
  }
  #site-media .mk-text-media {
    max-width: none;
    margin: 0;
  }
  #site-media .mk-text-media-title {
    font-size: clamp(2.75rem, 6.5vw, 5rem);
    line-height: 0.98;
  }
  #site-media .mk-text-media-text {
    font-size: 1.125rem;
    color: var(--muted-foreground);
  }
  #site-media .mk-text-media-eyebrow {
    color: var(--md-brand);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
  }
  #site-media .mk-text-media-media {
    position: relative;
    overflow: visible;
  }
  #site-media .mk-text-media-media img {
    border-radius: var(--radius);
  }
  #site-media .md-stamp {
    position: absolute;
    z-index: 2;
    left: -1.75rem;
    bottom: -1.75rem;
    display: grid;
    place-items: center;
    width: 7.5rem;
    aspect-ratio: 1;
    margin: 0;
    padding: 1.25rem;
    border: 3px double var(--md-stamp);
    border-radius: 50%;
    color: var(--md-stamp);
    background: var(--background);
    text-align: center;
    font:
      700 0.6875rem/1.2 'Instrument Sans',
      sans-serif;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    rotate: -12deg;
  }
  #site-media .md-stamp b {
    display: block;
    font-size: 1.375rem;
    letter-spacing: 0.04em;
  }
  @container (width < 40rem) {
    #site-media .md-stamp {
      left: 0.75rem;
      bottom: -1.25rem;
      width: 6rem;
      padding: 1rem;
    }
  }
  /* photos: the grid, film frames in Cinema */
  #site-media .mk-media-gallery {
    position: relative;
    isolation: isolate;
    max-width: none;
    margin: 0;
  }
  #site-media .mk-media-gallery-head h2 {
    font-size: clamp(2rem, 4vw, 3rem);
  }
  #site-media .mk-media-gallery-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
    gap: 0.75rem;
  }
  #site-media .mk-media-gallery-grid figure {
    border-radius: var(--radius);
  }
  #site-media[data-look='cinema'] .mk-media-gallery-grid figure {
    padding: 0.85rem 0;
    border-radius: 0;
    background:
      repeating-linear-gradient(90deg, oklch(0.93 0.02 85 / 0.85) 0 0.45rem, transparent 0.45rem 1.05rem) 0 0.2rem /
        100% 0.4rem no-repeat,
      repeating-linear-gradient(90deg, oklch(0.93 0.02 85 / 0.85) 0 0.45rem, transparent 0.45rem 1.05rem) 0
        calc(100% - 0.2rem) / 100% 0.4rem no-repeat,
      oklch(0.06 0 0);
  }
  #site-media[data-look='cinema'] .mk-media-gallery-grid img {
    filter: sepia(0.35) contrast(1.1) saturate(0.8);
  }
  #site-media .md-grain {
    z-index: 1;
    pointer-events: none;
    mix-blend-mode: overlay;
    opacity: 0.22;
  }
  /* the film: always in a dark screening band */
  #site-media > .md-film {
    color-scheme: dark;
    --background: oklch(0.14 0 0);
    --foreground: oklch(0.95 0.005 85);
    --card: oklch(0.18 0 0);
    --muted: oklch(0.22 0 0);
    --muted-foreground: oklch(0.74 0.005 85);
    --border: oklch(0.95 0.005 85 / 0.14);
    background: var(--background);
    color: var(--foreground);
  }
  #site-media > .md-film::before {
    border-color: var(--foreground);
  }
  #site-media .mk-video-player {
    max-width: none;
    margin: 0;
  }
  #site-media .mk-video-player-caption h3 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
  }
  /* listen: the player beside the episodes */
  #site-media .md-listen {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
    align-items: start;
  }
  @container (width > 56rem) {
    #site-media .md-listen {
      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
  }
  #site-media .md-listen::before {
    grid-column: 1 / -1;
    margin-block-end: 0 !important;
  }
  #site-media .mk-audio-player,
  #site-media .mk-playlist {
    border-radius: var(--radius-xl);
  }
  #site-media .mk-audio-player-cover {
    border-radius: 50%;
    animation: md-spin 6s linear infinite paused;
  }
  #site-media .mk-audio-player:has(audio:not([paused])) .mk-audio-player-cover {
    animation-play-state: running;
  }
  @keyframes md-spin {
    to {
      rotate: 360deg;
    }
  }
  /* compare and share: the before / after beside what people posted */
  #site-media .md-pair {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 2rem;
    align-items: start;
  }
  @container (width > 56rem) {
    #site-media .md-pair {
      grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
      gap: 2.5rem;
    }
  }
  #site-media .md-pair::before {
    grid-column: 1 / -1;
    margin-block-end: 0 !important;
  }
  #site-media .md-pair .mk-before-after {
    max-width: none;
    margin: 0;
  }
  #site-media .md-posts {
    display: grid;
    gap: 1rem;
  }
  #site-media .mk-social-post {
    border-radius: var(--radius-xl);
  }
  /* the opening's two calls to action */
  #site-media .md-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-block-start: 0.75rem;
  }
  /* Lisbon: every picture lifts and sharpens under the pointer, the others step back */
  #site-media .mk-media-gallery-grid figure {
    position: relative;
    overflow: hidden;
  }
  #site-media .mk-media-gallery-grid img {
    transition:
      scale 0.6s cubic-bezier(0.2, 0.7, 0.2, 1),
      filter 0.4s;
  }
  #site-media .mk-media-gallery-grid a:is(:hover, :focus-visible) img {
    scale: 1.07;
  }
  #site-media .mk-media-gallery-grid:has(a:is(:hover, :focus-visible)) a:not(:is(:hover, :focus-visible)) img {
    filter: var(--md-photo) saturate(0.35) brightness(0.8);
  }
  #site-media .mk-media-gallery-grid figcaption {
    position: absolute;
    inset: auto 0 0;
    padding: 2.5rem 1rem 0.85rem;
    background: linear-gradient(transparent, oklch(0.1 0 0 / 0.7));
    color: oklch(0.98 0 0);
    font: 400 1.25rem/1.1 var(--md-title);
    translate: 0 100%;
    transition: translate 0.35s cubic-bezier(0.2, 0.7, 0.2, 1);
  }
  #site-media .mk-media-gallery-grid a:is(:hover, :focus-visible) figcaption {
    translate: 0 0;
  }
  #site-media .mk-media-gallery-grid a:focus-visible {
    outline: 2px solid var(--ring);
    outline-offset: 3px;
    border-radius: var(--radius);
  }
  /* a hovered episode: a quiet tint, never the accent */
  #site-media .mk-playlist-item label:hover {
    background: var(--muted);
  }
  /* the podcast: the cover beside the episode, the player as wide as its column */
  #site-media .mk-audio-player[data-variant='podcast'] {
    grid-template-columns: minmax(0, 1fr);
    align-content: start;
  }
  #site-media .mk-audio-player[data-variant='podcast'] .mk-audio-player-cover {
    width: 8rem;
    height: 8rem;
  }
  #site-media .mk-audio-player-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
  }
  #site-media .mk-audio-player-controls audio {
    flex: 1 1 14rem;
    min-width: 0;
  }
  @media (prefers-reduced-motion: reduce) {
    #site-media .mk-audio-player-cover {
      animation: none;
    }
    #site-media .mk-media-gallery-grid :is(img, figcaption) {
      transition: none;
    }
  }
  /* light or dark: the Swap writes the page's dark class - every look has a light and a dark palette */
  #site-media .site-mode {
    flex: none;
    border: 1px solid var(--input);
    border-radius: var(--radius-md);
    background: var(--background);
    color: var(--foreground);
  }
  #site-media .site-mode:hover {
    background: var(--accent);
    color: var(--accent-foreground);
  }
  #site-media [hidden] {
    display: none !important;
  }
  /* the playlist: the episode playing shows its bars */
  #site-media .mk-playlist-item label {
    cursor: pointer;
  }
  /* more stories: three cards, each a page */
  #site-media .md-stories-title {
    margin: 0 0 1.75rem;
    font: 400 clamp(2rem, 4vw, 2.75rem)/1.1 var(--md-title);
  }
  #site-media .md-story-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
    gap: 2rem 1.5rem;
  }
  #site-media .md-story {
    position: relative;
    display: grid;
    align-content: start;
    gap: 0.5rem;
  }
  #site-media .md-story img {
    width: 100%;
    aspect-ratio: 10 / 7;
    object-fit: cover;
    border-radius: var(--radius);
  }
  #site-media :is(.md-story-eyebrow) {
    margin-block-start: 0.5rem;
    color: var(--muted-foreground);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
  }
  #site-media .md-story-title {
    margin: 0;
    font: 400 1.5rem/1.2 var(--md-title);
  }
  #site-media .md-story-title a {
    color: var(--foreground);
    text-decoration: none;
  }
  #site-media .md-story-title a::after {
    content: '';
    position: absolute;
    inset: 0;
  }
  #site-media .md-story:hover .md-story-title a {
    text-decoration: underline;
    text-underline-offset: 4px;
  }
  #site-media .md-story p {
    margin: 0;
    color: var(--muted-foreground);
  }
  /* a story's page: a reading column */
  #site-media > [data-media-view='story'] {
    padding-block: clamp(2.5rem, 5vw, 4rem) clamp(3.5rem, 7vw, 5.5rem);
  }
  #site-media .md-page {
    display: grid;
    gap: 1.25rem;
    max-width: 48rem;
    margin-inline: auto;
  }
  #site-media .md-back {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    width: fit-content;
    color: var(--muted-foreground);
    font-weight: 600;
    text-decoration: none;
  }
  #site-media .md-back:hover {
    color: var(--foreground);
  }
  #site-media .md-back svg {
    width: 1rem;
    height: 1rem;
  }
  #site-media .md-page-title {
    margin: 0;
    font: 400 clamp(2.5rem, 6vw, 4rem)/1.05 var(--md-title);
    letter-spacing: -0.01em;
    text-wrap: balance;
  }
  #site-media .md-page-lead {
    margin: 0;
    color: var(--muted-foreground);
    font-size: 1.25rem;
    line-height: 1.5;
  }
  #site-media .md-page-photo {
    margin: 0.5rem 0;
  }
  #site-media .md-page-photo img {
    display: block;
    width: 100%;
    aspect-ratio: 2 / 1;
    object-fit: cover;
    border-radius: var(--radius);
  }
  #site-media .md-page-body {
    display: grid;
    gap: 1rem;
    font-size: 1.125rem;
    line-height: 1.7;
  }
  #site-media .md-page-body p {
    margin: 0;
  }
  #site-media .md-pager {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr));
    gap: 1rem;
    margin-block-start: 2rem;
    padding-block-start: 1.5rem;
    border-block-start: 1px solid var(--foreground);
  }
  #site-media .md-pager a {
    display: grid;
    gap: 0.25rem;
    color: var(--foreground);
    text-decoration: none;
  }
  #site-media .md-pager a + a {
    text-align: end;
  }
  #site-media .md-pager span {
    color: var(--muted-foreground);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
  }
  #site-media .md-pager strong {
    font: 400 1.375rem/1.2 var(--md-title);
  }
  #site-media .md-pager a:hover strong {
    text-decoration: underline;
    text-underline-offset: 4px;
  }
  /* the footer: the Site Footer block under a hairline */
  #site-media .md-footer {
    border-block-start: 1px solid var(--foreground);
    background: var(--background);
    color: var(--foreground);
  }
  #site-media .md-footer .mk-footer-inner {
    max-width: none;
    margin: 0;
    padding: clamp(3rem, 6vw, 4.5rem) 0 2rem;
  }
  @container (width > 48rem) {
    #site-media .md-footer .mk-footer-top {
      grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr);
      gap: 4rem;
    }
  }
  #site-media .md-footer .mk-footer-brand-name {
    color: var(--foreground);
    font: 400 1.75rem/1 var(--md-title);
  }
  #site-media .md-footer .mk-footer-brand-name i {
    color: var(--md-brand);
  }
  #site-media .md-footer .mk-footer-heading {
    color: var(--foreground);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
  }
  #site-media .md-footer :is(.mk-footer-list a, .mk-footer-social a) {
    color: var(--muted-foreground);
    text-decoration: none;
  }
  #site-media .md-footer :is(.mk-footer-list a, .mk-footer-social a):hover {
    color: var(--foreground);
  }
  /* -- modes: each look in light and dark, derived from the palettes above (the other mode of each look) -- */
  :root:not(.dark) #site-media[data-look='gallery'] {
    --accent: oklch(0.945 0.045 32);
    --accent-foreground: oklch(0.18 0 0);
  }
  .dark #site-media[data-look='gallery'] {
    --accent: oklch(0.26 0.05 35);
    --accent-foreground: oklch(0.95 0 0);
  }
  .dark #site-media[data-look='cinema'] {
    --accent: oklch(0.24 0.05 80);
    --accent-foreground: oklch(0.94 0.01 85);
  }
  :root:not(.dark) #site-media[data-look='cinema'] {
    color-scheme: light;
    --background: oklch(0.985 0 0);
    --foreground: oklch(0.2 0.01 85);
    --card: oklch(0.997 0 0);
    --card-foreground: oklch(0.2 0.01 85);
    --muted: oklch(0.95 0 0);
    --muted-foreground: oklch(0.46 0.01 85);
    --border: oklch(0.2 0.01 85 / 0.12);
    --input: oklch(0.2 0.01 85 / 0.12);
    --primary: oklch(0.55 0.13 80);
    --primary-foreground: oklch(0.985 0.005 80);
    --secondary: oklch(0.955 0 0);
    --secondary-foreground: oklch(0.25 0.01 85);
    --accent: oklch(0.94 0.025 80);
    --accent-foreground: oklch(0.2 0.01 85);
    --ring: oklch(0.57 0.13 80);
    --md-stamp: oklch(0.57 0.13 80);
    --popover: oklch(0.997 0 0);
    --popover-foreground: oklch(0.2 0 0);
  }
  :root:not(.dark) #site-media[data-look='archive'] {
    --accent: oklch(0.91 0.045 40);
    --accent-foreground: oklch(0.26 0.03 50);
  }
  .dark #site-media[data-look='archive'] {
    color-scheme: dark;
    --background: oklch(0.17 0.018 78);
    --foreground: oklch(0.94 0.03 50);
    --card: oklch(0.205 0.014 78);
    --card-foreground: oklch(0.94 0.03 50);
    --muted: oklch(0.24 0.022 75);
    --muted-foreground: oklch(0.74 0.03 55);
    --border: oklch(0.95 0.02 50 / 0.14);
    --input: oklch(0.95 0.02 50 / 0.14);
    --primary: oklch(0.66 0.06 45);
    --primary-foreground: oklch(0.17 0.03 45);
    --secondary: oklch(0.25 0.022 75);
    --secondary-foreground: oklch(0.9 0.03 50);
    --accent: oklch(0.26 0.042 40);
    --accent-foreground: oklch(0.94 0.03 50);
    --ring: oklch(0.72 0.12 40);
    --md-stamp: oklch(0.69 0.12 30);
    --popover: oklch(0.215 0 0);
    --popover-foreground: oklch(0.94 0 0);
  }
  /* -- modes: end -- */
  /* the brand's ink for text - eyebrows, section numbers, the wordmark's mark, the focus ring (--accent is the hover
     surface, a tint too faint for text): vermilion, amber or sepia, 4.5:1 on each look's ground in both modes */
  :root:not(.dark) #site-media {
    --md-brand: oklch(0.53 0.2 32);
  }
  .dark #site-media {
    --md-brand: oklch(0.74 0.15 35);
  }
  :root:not(.dark) #site-media[data-look='cinema'] {
    --md-brand: oklch(0.5 0.11 75);
  }
  .dark #site-media[data-look='cinema'] {
    --md-brand: oklch(0.82 0.13 80);
  }
  :root:not(.dark) #site-media[data-look='archive'] {
    --md-brand: oklch(0.47 0.12 40);
  }
  .dark #site-media[data-look='archive'] {
    --md-brand: oklch(0.75 0.1 45);
  }
</style>
<div id="site-media" data-look="gallery" data-i18n-component>
  <header class="mk-header md-bar">
    <div class="mk-header-inner">
      <a class="mk-header-brand md-brand" href="#/" data-router-link>Acme <i>Stories</i></a>
      <nav
        class="mk-header-nav md-nav"
        data-media-nav
        aria-label="Sections"
        data-i18n-aria-label-en="Sections"
        data-i18n-aria-label-de="Bereiche"
      >
        <a href="#md-photos" data-i18n-target="nav-photos">Photos</a>
        <a href="#md-film" data-i18n-target="nav-film">Film</a>
        <a href="#md-listen">Podcast</a>
        <a href="#md-stories" data-i18n-target="nav-stories">Stories</a>
      </nav>
      <div class="mk-header-actions md-bar-controls">
        <select
          class="select"
          data-size="sm"
          data-site-look
          aria-label="Look"
          data-i18n-aria-label-en="Look"
          data-i18n-aria-label-de="Stil"
          style="width: auto"
        >
          <option value="gallery" data-i18n-target="look-gallery">Gallery</option>
          <option value="cinema" data-i18n-target="look-cinema">Cinema</option>
          <option value="archive" data-i18n-target="look-archive">Archive</option>
        </select>
        <div
          class="language-switcher"
          data-app-locale
          role="group"
          aria-label="Language"
          data-i18n-aria-label-en="Language"
          data-i18n-aria-label-de="Sprache"
          data-languages="en de"
          data-value="en"
          data-size="sm"
          data-display="icon"
          data-flag-shape="squircle"
          data-flag-style="glossy"
          data-align="end"
        ></div>
        <label class="swap site-mode" data-variant="rotate" data-size="sm">
          <input
            type="checkbox"
            data-site-mode
            aria-label="Dark mode"
            data-i18n-aria-label-en="Dark mode"
            data-i18n-aria-label-de="Dunkler Modus"
          />
          <span class="swap-on" aria-hidden="true"><i data-lucide="moon"></i></span>
          <span class="swap-off" aria-hidden="true"><i data-lucide="sun"></i></span>
        </label>
      </div>
    </div>
  </header>
  <section class="mk-text-media md-hero" aria-labelledby="tm-1" data-media-view="home">
    <div class="mk-text-media-layout">
      <div class="mk-text-media-copy">
        <span class="mk-text-media-eyebrow" data-i18n-target="eyebrow">Offline first</span>
        <h2 class="mk-text-media-title" id="tm-1" data-i18n-target="tm-title">Your work travels with you</h2>
        <p class="mk-text-media-text" data-i18n-target="tm-text"
          >Every change is saved on your device first and synced when you are back online - on a plane, in a tunnel, at
          the cabin.</p
        >
        <ul class="mk-text-media-list"
          ><li><i data-lucide="check"></i><span data-i18n-target="tm-wait">Edits never wait for the network</span></li
          ><li><i data-lucide="check"></i><span data-i18n-target="tm-conflicts">Conflicts resolve themselves</span></li
          ><li><i data-lucide="check"></i><span data-i18n-target="tm-devices">Works on every device</span></li></ul
        >
        <div class="md-cta">
          <a class="btn" data-size="lg" href="#/stories/sync" data-router-link
            ><span data-i18n-target="tm-link">How sync works</span> <i data-lucide="arrow-right"></i
          ></a>
          <a class="btn" data-variant="outline" data-size="lg" href="#md-film"
            ><i data-lucide="play"></i> <span data-i18n-target="tm-watch">Watch the film</span></a
          >
        </div>
      </div>
      <figure class="mk-text-media-media"
        ><img src="images/photos/48-1000x750.webp" alt="A laptop on a café table" /><p
          class="md-stamp"
          aria-hidden="true"
          ><span><b>LIS</b><span data-i18n-target="stamp">works offline · 2026</span></span></p
        ></figure
      >
    </div>
  </section>
  <section class="mk-media-gallery md-section" id="md-photos" aria-labelledby="mg-title" data-media-view="home">
    <div
      class="shader md-grain md-look-only"
      data-for="cinema"
      data-variant="background"
      data-effect="grain-gradient"
      data-colors="oklch(0.5 0 0) oklch(0.7 0.05 80)"
      data-speed="2"
      data-fps="24"
      aria-hidden="true"
    ></div>
    <header class="mk-media-gallery-head">
      <h2 id="mg-title" data-i18n-target="mg-title">Lisbon, autumn 2026</h2>
      <span data-i18n-target="mg-count">8 photos</span>
      <div class="mk-media-gallery-tools">
        <div
          class="mk-media-gallery-views"
          role="radiogroup"
          aria-label="Layout"
          data-i18n-aria-label-en="Layout"
          data-i18n-aria-label-de="Ansicht"
        >
          <label
            ><input type="radio" name="mg-view" value="grid" checked /><i data-lucide="layout-grid"></i
            ><span class="sr-only" data-i18n-target="view-grid">Grid</span></label
          >
          <label
            ><input type="radio" name="mg-view" value="masonry" /><i data-lucide="layout-dashboard"></i
            ><span class="sr-only" data-i18n-target="view-masonry">Masonry</span></label
          >
          <label
            ><input type="radio" name="mg-view" value="strip" /><i data-lucide="gallery-horizontal"></i
            ><span class="sr-only" data-i18n-target="view-strip">Filmstrip</span></label
          >
        </div>
        <a class="btn" data-variant="outline" data-size="sm" href="#/photos/1" data-router-link
          ><i data-lucide="play"></i> <span data-i18n-target="slideshow">Slideshow</span></a
        >
      </div>
    </header>
    <ul class="mk-media-gallery-grid">
      <li
        ><a href="#/photos/1" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/211-800x600.webp" alt="Boats moored in a harbour" /><figcaption
              data-i18n-target="mg-c1"
              >The harbour</figcaption
            ></figure
          ></a
        ></li
      >
      <li
        ><a href="#/photos/2" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/240-600x800.webp" alt="A person on white stone stairs" /><figcaption
              data-i18n-target="mg-c2"
              >White stairs</figcaption
            ></figure
          ></a
        ></li
      >
      <li
        ><a href="#/photos/3" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/164-800x500.webp" alt="Houses and boats along a canal" /><figcaption
              data-i18n-target="mg-c3"
              >Canal houses</figcaption
            ></figure
          ></a
        ></li
      >
      <li
        ><a href="#/photos/4" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/210-600x600.webp" alt="A red brick wall" /><figcaption data-i18n-target="mg-c4"
              >A red wall</figcaption
            ></figure
          ></a
        ></li
      >
      <li
        ><a href="#/photos/5" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/292-800x600.webp" alt="Vegetables on a cutting board" /><figcaption
              data-i18n-target="mg-c5"
              >Market morning</figcaption
            ></figure
          ></a
        ></li
      >
      <li
        ><a href="#/photos/6" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/111-600x900.webp" alt="A vintage car parked in the street" /><figcaption
              data-i18n-target="mg-c6"
              >An old car</figcaption
            ></figure
          ></a
        ></li
      >
      <li
        ><a href="#/photos/7" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/14-800x600.webp" alt="A rocky shore and the open sea" /><figcaption
              data-i18n-target="mg-c7"
              >The open sea</figcaption
            ></figure
          ></a
        ></li
      >
      <li
        ><a href="#/photos/8" data-router-link style="display: block"
          ><figure
            ><img src="images/photos/288-700x500.webp" alt="The rooftops of an old town" /><figcaption
              data-i18n-target="mg-c8"
              >Over the rooftops</figcaption
            ></figure
          ></a
        ></li
      >
    </ul>
    <dialog
      class="mk-media-gallery-viewer"
      id="mg-viewer"
      aria-label="Slideshow: Lisbon, autumn 2026"
      data-i18n-aria-label-en="Slideshow: Lisbon, autumn 2026"
      data-i18n-aria-label-de="Diashow: Lissabon, Herbst 2026"
    >
      <div class="mk-media-gallery-viewer-inner">
        <ul
          class="mk-media-gallery-track"
          tabindex="0"
          aria-label="Photos - scroll sideways"
          data-i18n-aria-label-en="Photos - scroll sideways"
          data-i18n-aria-label-de="Fotos - seitwärts scrollen"
        >
          <li
            ><img src="images/photos/211-1600x1200.webp" alt="Boats moored in a harbour" /><p
              >1 / 8 · <span data-i18n-target="cap-1">Boats moored in a harbour</span></p
            ></li
          >
          <li
            ><img src="images/photos/240-1200x1600.webp" alt="A person on white stone stairs" /><p
              >2 / 8 · <span data-i18n-target="cap-2">A person on white stone stairs</span></p
            ></li
          >
          <li
            ><img src="images/photos/164-1600x1000.webp" alt="Houses and boats along a canal" /><p
              >3 / 8 · <span data-i18n-target="cap-3">Houses and boats along a canal</span></p
            ></li
          >
          <li
            ><img src="images/photos/210-1200x1200.webp" alt="A red brick wall" /><p
              >4 / 8 · <span data-i18n-target="cap-4">A red brick wall</span></p
            ></li
          >
          <li
            ><img src="images/photos/292-1600x1200.webp" alt="Vegetables on a cutting board" /><p
              >5 / 8 · <span data-i18n-target="cap-5">Vegetables on a cutting board</span></p
            ></li
          >
          <li
            ><img src="images/photos/111-1200x1800.webp" alt="A vintage car parked in the street" /><p
              >6 / 8 · <span data-i18n-target="cap-6">A vintage car parked in the street</span></p
            ></li
          >
          <li
            ><img src="images/photos/14-1600x1200.webp" alt="A rocky shore and the open sea" /><p
              >7 / 8 · <span data-i18n-target="cap-7">A rocky shore and the open sea</span></p
            ></li
          >
          <li
            ><img src="images/photos/288-1400x1000.webp" alt="The rooftops of an old town" /><p
              >8 / 8 · <span data-i18n-target="cap-8">The rooftops of an old town</span></p
            ></li
          >
        </ul>
        <p class="mk-media-gallery-hint" data-i18n-target="mg-hint">Swipe, scroll or use ← → · Esc closes</p>
        <form method="dialog"
          ><button
            class="mk-media-gallery-close"
            aria-label="Close slideshow"
            data-i18n-aria-label-en="Close slideshow"
            data-i18n-aria-label-de="Diashow schließen"
            ><i data-lucide="x"></i></button
        ></form>
      </div>
    </dialog>
  </section>
  <section class="md-section md-film" id="md-film" aria-labelledby="vp-title" data-media-view="home">
    <figure class="mk-video-player" data-variant="transcript">
      <div class="mk-video-player-layout">
        <div class="mk-video-player-frame">
          <video id="vp-3" controls preload="metadata" playsinline poster="images/photos/257-1280x720.webp">
            <source src="videos/demo.webm" type="video/webm" />
            <source src="videos/demo.mp4" type="video/mp4" />
            <track kind="captions" src="videos/demo.en.vtt" srclang="en" label="English" default />
            Your browser does not support video. <a href="videos/demo.mp4">Download the video</a>.
          </video>
        </div>
        <section class="mk-video-player-transcript" aria-labelledby="vp-tr" tabindex="0">
          <h3 id="vp-tr" data-i18n-target="transcript">Transcript</h3>
          <p><time datetime="PT0S">0:00</time><span data-i18n-target="tr-1">Plan the week on one calm board.</span></p>
          <p
            ><time datetime="PT2S">0:02</time
            ><span data-i18n-target="tr-2">Drafts, docs and tasks stay linked.</span></p
          >
          <p
            ><time datetime="PT4S">0:04</time
            ><span data-i18n-target="tr-3">Ship it - and everyone sees what changed.</span></p
          >
        </section>
      </div>
      <figcaption class="mk-video-player-caption"
        ><h3 id="vp-title" data-i18n-target="vp-caption">Acme in 60 seconds</h3></figcaption
      >
    </figure>
  </section>
  <div class="md-section md-listen" id="md-listen" data-media-view="home">
    <article class="mk-audio-player" data-variant="podcast" aria-labelledby="ap-3">
      <img class="mk-audio-player-cover" src="images/photos/39-600x600.webp" alt="Cover of The Calm Letter podcast" />
      <div class="mk-audio-player-body">
        <span class="mk-audio-player-show"
          ><span data-i18n-target="ap-show">The Calm Letter · Episode</span>
          <span data-episode-field="n">42</span></span
        >
        <h3 class="mk-audio-player-title" id="ap-3" data-episode-field="title">Why we never ship on Fridays</h3>
        <span class="mk-audio-player-meta"
          ><span data-episode-field="guest">With Alex Moreau and Sophie Tan</span> ·
          <time datetime="2026-09-30" data-episode-date>30 Sep 2026</time></span
        >
        <div class="mk-audio-player-controls">
          <audio controls preload="none" src="videos/demo-audio.mp3" data-episode-audio></audio>
          <a class="btn" data-variant="outline" data-size="sm" href="videos/demo-audio.mp3" download
            ><i data-lucide="download"></i> MP3</a
          >
        </div>
        <details class="mk-audio-player-notes">
          <summary data-i18n-target="ap-notes">Show notes</summary>
          <p data-episode-field="notes"
            >Alex and Sophie explain why Acme ships on Thursdays, what happens when a release goes wrong, and how a
            quiet weekend became a rule.</p
          >
          <ul data-episode-chapters
            ><li>0:00 Intro</li
            ><li>0:04 The Thursday rule</li
            ><li>0:09 When it goes wrong</li></ul
          >
        </details>
      </div>
    </article>
    <ol
      class="mk-playlist"
      role="radiogroup"
      aria-label="The Calm Letter - episodes"
      data-i18n-aria-label-en="The Calm Letter - episodes"
      data-i18n-aria-label-de="The Calm Letter - Folgen"
    >
      <li class="mk-playlist-item" data-variant="episode">
        <label>
          <input type="radio" name="episode" value="42" checked />
          <span class="mk-playlist-item-index" aria-hidden="true"
            ><span>42</span><i class="mk-playlist-item-bars"><b></b><b></b><b></b></i
          ></span>
          <img class="mk-playlist-item-cover" src="images/photos/s-ep-42-160x160.webp" alt="" />
          <span class="mk-playlist-item-text"
            ><strong>Why we never ship on Fridays</strong
            ><small>The Calm Letter · <time datetime="2026-09-30">2026-09-30</time></small
            ><span class="mk-playlist-item-desc" data-i18n-target="ep-d42"
              >Alex and Sophie on release rhythms, weekends and why boring deploys are the best deploys.</span
            ></span
          >
          <span class="mk-playlist-item-duration">32 min</span>
        </label>
      </li>
      <li class="mk-playlist-item" data-variant="episode">
        <label>
          <input type="radio" name="episode" value="41" />
          <span class="mk-playlist-item-index" aria-hidden="true"
            ><span>41</span><i class="mk-playlist-item-bars"><b></b><b></b><b></b></i
          ></span>
          <img class="mk-playlist-item-cover" src="images/photos/s-ep-41-160x160.webp" alt="" />
          <span class="mk-playlist-item-text"
            ><strong>Writing decisions down</strong
            ><small>The Calm Letter · <time datetime="2026-09-23">2026-09-23</time></small
            ><span class="mk-playlist-item-desc" data-i18n-target="ep-d41"
              >Hannah explains how her team replaced status meetings with a written decision log.</span
            ></span
          >
          <span class="mk-playlist-item-duration">28 min</span>
        </label>
      </li>
      <li class="mk-playlist-item" data-variant="episode">
        <label>
          <input type="radio" name="episode" value="40" />
          <span class="mk-playlist-item-index" aria-hidden="true"
            ><span>40</span><i class="mk-playlist-item-bars"><b></b><b></b><b></b></i
          ></span>
          <img class="mk-playlist-item-cover" src="images/photos/s-ep-40-160x160.webp" alt="" />
          <span class="mk-playlist-item-text"
            ><strong>Support on Fridays</strong
            ><small>The Calm Letter · <time datetime="2026-09-16">2026-09-16</time></small
            ><span class="mk-playlist-item-desc" data-i18n-target="ep-d40"
              >Why the CEO still answers support tickets every Friday - and what it changed in the product.</span
            ></span
          >
          <span class="mk-playlist-item-duration">25 min</span>
        </label>
      </li>
      <li class="mk-playlist-item" data-variant="episode">
        <label>
          <input type="radio" name="episode" value="39" />
          <span class="mk-playlist-item-index" aria-hidden="true"
            ><span>39</span><i class="mk-playlist-item-bars"><b></b><b></b><b></b></i
          ></span>
          <img class="mk-playlist-item-cover" src="images/photos/s-ep-39-160x160.webp" alt="" />
          <span class="mk-playlist-item-text"
            ><strong>Designing for one hand</strong
            ><small>The Calm Letter · <time datetime="2026-09-09">2026-09-09</time></small
            ><span class="mk-playlist-item-desc" data-i18n-target="ep-d39"
              >Priya on phone apps you can use while holding a coffee - reach, gestures and big targets.</span
            ></span
          >
          <span class="mk-playlist-item-duration">30 min</span>
        </label>
      </li>
    </ol>
  </div>
  <div class="md-section md-pair" data-media-view="home">
    <figure class="mk-before-after" data-variant="toggle">
      <div class="mk-before-after-stage">
        <img
          class="mk-before-after-before"
          src="images/photos/s-ba-room-1200x800-gray.webp"
          alt="Before: the living room, grey and empty"
        />
        <img
          class="mk-before-after-after"
          src="images/photos/s-ba-room-1200x800.webp"
          alt="After: the living room, furnished and warm"
        />
      </div>
      <div class="switch-item mk-before-after-toggle"
        ><input class="switch" type="checkbox" role="switch" id="ba-toggle" /><label
          for="ba-toggle"
          data-i18n-target="ba-after"
          >Show after</label
        ></div
      >
    </figure>
    <div class="md-posts">
      <article class="mk-social-post" data-variant="quote">
        <header class="mk-social-post-head">
          <span class="avatar"><img class="avatar-image" src="images/mk-portrait2.png" alt="" /></span>
          <div class="mk-social-post-who"
            ><a class="mk-social-post-name" href="https://x.com/" target="_blank" rel="noopener"
              >Hannah Lee<svg
                class="mk-social-post-verified"
                viewBox="0 0 24 24"
                width="16"
                height="16"
                role="img"
                aria-label="Verified account"
              >
                <path
                  fill="currentColor"
                  d="M12 1.5 14.6 4l3.6-.4.9 3.5 3.2 1.8-1.4 3.3 1.4 3.3-3.2 1.8-.9 3.5-3.6-.4L12 22.5 9.4 20l-3.6.4-.9-3.5-3.2-1.8L3.1 12 1.7 8.7l3.2-1.8.9-3.5 3.6.4Z"
                />
                <path
                  d="m7.5 12.2 3 3 6-6.4"
                  fill="none"
                  stroke="#fff"
                  stroke-width="2"
                  stroke-linecap="round"
                  stroke-linejoin="round"
                /></svg></a
            ><span class="mk-social-post-handle">@hannahdesigns</span></div
          >
          <span class="mk-social-post-network" role="img" aria-label="Posted on X"
            ><svg viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true">
              <path
                d="M18.9 2H22l-6.8 7.8L23.2 22h-6.3l-4.9-6.4L6.4 22H3.3l7.3-8.3L.8 2h6.4l4.4 5.9L18.9 2Zm-1.1 18h1.7L6.3 3.9H4.5L17.8 20Z"
              /></svg
          ></span>
        </header>
        <div class="mk-social-post-text"
          ><p data-i18n-target="post-1"
            >Acme is the first tool my designers asked to keep after the trial. That never happens.</p
          ></div
        >
        <footer class="mk-social-post-foot">
          <a class="mk-social-post-time" href="https://x.com/" target="_blank" rel="noopener"
            ><time datetime="2026-09-12" data-i18n-target="post-1-date">Sep 12, 2026</time></a
          >
          <ul class="mk-social-post-stats"
            ><li><i data-lucide="heart"></i>320<span class="sr-only"> likes</span></li></ul
          >
        </footer>
      </article>
      <article class="mk-social-post" data-variant="quote">
        <header class="mk-social-post-head">
          <span class="avatar"><img class="avatar-image" src="images/mk-portrait.png" alt="" /></span>
          <div class="mk-social-post-who"
            ><a class="mk-social-post-name" href="https://x.com/" target="_blank" rel="noopener"
              >Marco Rossi<svg
                class="mk-social-post-verified"
                viewBox="0 0 24 24"
                width="16"
                height="16"
                role="img"
                aria-label="Verified account"
              >
                <path
                  fill="currentColor"
                  d="M12 1.5 14.6 4l3.6-.4.9 3.5 3.2 1.8-1.4 3.3 1.4 3.3-3.2 1.8-.9 3.5-3.6-.4L12 22.5 9.4 20l-3.6.4-.9-3.5-3.2-1.8L3.1 12 1.7 8.7l3.2-1.8.9-3.5 3.6.4Z"
                />
                <path
                  d="m7.5 12.2 3 3 6-6.4"
                  fill="none"
                  stroke="#fff"
                  stroke-width="2"
                  stroke-linecap="round"
                  stroke-linejoin="round"
                /></svg></a
            ><span class="mk-social-post-handle">@marco</span></div
          >
          <span class="mk-social-post-network" role="img" aria-label="Posted on X"
            ><svg viewBox="0 0 24 24" width="16" height="16" fill="currentColor" aria-hidden="true">
              <path
                d="M18.9 2H22l-6.8 7.8L23.2 22h-6.3l-4.9-6.4L6.4 22H3.3l7.3-8.3L.8 2h6.4l4.4 5.9L18.9 2Zm-1.1 18h1.7L6.3 3.9H4.5L17.8 20Z"
              /></svg
          ></span>
        </header>
        <div class="mk-social-post-text"
          ><p data-i18n-target="post-2"
            >Our weekly sync went from 90 minutes to 20. I have my Thursday afternoons back.</p
          ></div
        >
        <footer class="mk-social-post-foot">
          <a class="mk-social-post-time" href="https://x.com/" target="_blank" rel="noopener"
            ><time datetime="2026-08-30" data-i18n-target="post-2-date">Aug 30, 2026</time></a
          >
          <ul class="mk-social-post-stats"
            ><li><i data-lucide="heart"></i>188<span class="sr-only"> likes</span></li></ul
          >
        </footer>
      </article>
    </div>
  </div>
  <!-- more stories: each opens its page -->
  <section class="md-section md-stories" id="md-stories" aria-labelledby="md-stories-title" data-media-view="home">
    <h2 class="md-stories-title" id="md-stories-title" data-i18n-target="st-title">More stories</h2>
    <div class="md-story-grid">
      <article class="md-story">
        <img
          src="images/photos/48-800x560.webp"
          alt="A laptop on a café table"
          data-i18n-alt-en="A laptop on a café table"
          data-i18n-alt-de="Ein Laptop auf einem Cafétisch"
        />
        <span class="md-story-eyebrow" data-i18n-target="st-sync-eyebrow">Offline first</span>
        <h3 class="md-story-title"
          ><a href="#/stories/sync" data-router-link data-i18n-target="st-sync-title">How sync works</a></h3
        >
        <p data-i18n-target="st-sync-text"
          >Every change is saved on your device first. Here is what happens next - in plain words.</p
        >
      </article>
      <article class="md-story">
        <img
          src="images/photos/288-800x560.webp"
          alt="The rooftops of an old town"
          data-i18n-alt-en="The rooftops of an old town"
          data-i18n-alt-de="Die Dächer einer Altstadt"
        />
        <span class="md-story-eyebrow" data-i18n-target="st-lisbon-eyebrow">Photo walk</span>
        <h3 class="md-story-title"
          ><a href="#/stories/lisbon" data-router-link data-i18n-target="st-lisbon-title"
            >Lisbon in eight pictures</a
          ></h3
        >
        <p data-i18n-target="st-lisbon-text"
          >An autumn morning from the harbour to the rooftops - the walk behind our gallery.</p
        >
      </article>
      <article class="md-story">
        <img
          src="images/photos/39-800x560.webp"
          alt="A record turning on a turntable"
          data-i18n-alt-en="A record turning on a turntable"
          data-i18n-alt-de="Eine Schallplatte auf einem Plattenspieler"
        />
        <span class="md-story-eyebrow">Podcast</span>
        <h3 class="md-story-title"
          ><a href="#/stories/letter" data-router-link data-i18n-target="st-letter-title">Behind The Calm Letter</a></h3
        >
        <p data-i18n-target="st-letter-text"
          >How a weekly email became a podcast - recorded in one take, every Tuesday.</p
        >
      </article>
    </div>
  </section>
  <!-- a story: its page, filled from the data block -->
  <div data-media-view="story" hidden>
    <article class="md-page" aria-labelledby="sp-title">
      <a class="md-back" href="#/" data-router-link
        ><i data-lucide="arrow-left"></i> <span data-i18n-target="sp-back">All stories</span></a
      >
      <span class="md-story-eyebrow" data-story-field="eyebrow"></span>
      <h1 class="md-page-title" id="sp-title" data-story-field="title"></h1>
      <p class="md-page-lead" data-story-field="lead"></p>
      <figure class="md-page-photo"><img src="images/photos/48-1600x800.webp" alt="" data-story-photo /></figure>
      <div class="md-page-body" data-story-body></div>
      <p
        ><a class="btn" data-variant="outline" href="#md-film" data-story-link
          ><span data-story-field="link"></span> <i data-lucide="arrow-right"></i></a
      ></p>
      <nav
        class="md-pager"
        aria-label="More stories"
        data-i18n-aria-label-en="More stories"
        data-i18n-aria-label-de="Weitere Geschichten"
      >
        <a href="#/stories/letter" data-router-link data-story-pager="prev"
          ><span data-i18n-target="sp-prev">Previous story</span><strong data-pager-title></strong
        ></a>
        <a href="#/stories/lisbon" data-router-link data-story-pager="next"
          ><span data-i18n-target="sp-next">Next story</span><strong data-pager-title></strong
        ></a>
      </nav>
    </article>
  </div>
  <!-- the footer: the Site Footer block -->
  <footer class="mk-footer md-footer">
    <div class="mk-footer-inner">
      <div class="mk-footer-top">
        <div class="mk-footer-about">
          <a class="mk-footer-brand md-brand" href="#/" data-router-link
            ><span class="mk-footer-brand-name">Acme <i>Stories</i></span></a
          >
          <p data-i18n-target="ft-line"
            >Photos, films and a podcast from the people who build Acme - in Lisbon and on the road.</p
          >
          <div class="mk-footer-social">
            <a
              href="https://www.youtube.com/"
              target="_blank"
              rel="noopener"
              aria-label="Acme Stories on YouTube"
              data-i18n-aria-label-en="Acme Stories on YouTube"
              data-i18n-aria-label-de="Acme Stories auf YouTube"
              ><i data-lucide="circle-play"></i
            ></a>
            <a
              href="https://www.instagram.com/"
              target="_blank"
              rel="noopener"
              aria-label="Acme Stories on Instagram"
              data-i18n-aria-label-en="Acme Stories on Instagram"
              data-i18n-aria-label-de="Acme Stories auf Instagram"
              ><i data-lucide="camera"></i
            ></a>
            <a
              href="https://x.com/"
              target="_blank"
              rel="noopener"
              aria-label="Acme Stories on X"
              data-i18n-aria-label-en="Acme Stories on X"
              data-i18n-aria-label-de="Acme Stories auf X"
              ><svg viewBox="0 0 24 24" width="18" height="18" fill="currentColor" aria-hidden="true">
                <path
                  d="M18.9 2H22l-6.8 7.8L23.2 22h-6.3l-4.9-6.4L6.4 22H3.3l7.3-8.3L.8 2h6.4l4.4 5.9L18.9 2Zm-1.1 18h1.7L6.3 3.9H4.5L17.8 20Z"
                /></svg
            ></a>
          </div>
        </div>
        <nav
          class="mk-footer-nav"
          aria-label="Footer"
          data-i18n-aria-label-en="Footer"
          data-i18n-aria-label-de="Fußzeile"
        >
          <div class="mk-footer-col">
            <h3 class="mk-footer-heading" data-i18n-target="ft-watch">Watch and listen</h3>
            <ul class="mk-footer-list">
              <li><a href="#md-photos" data-i18n-target="ft-photos">Photos</a></li>
              <li><a href="#/photos/1" data-router-link data-i18n-target="ft-slides">Slideshow</a></li>
              <li><a href="#md-film" data-i18n-target="ft-film">Film</a></li>
              <li><a href="#md-listen">Podcast</a></li>
            </ul>
          </div>
          <div class="mk-footer-col">
            <h3 class="mk-footer-heading" data-i18n-target="ft-stories">Stories</h3>
            <ul class="mk-footer-list">
              <li><a href="#/stories/sync" data-router-link data-i18n-target="ft-s1">How sync works</a></li>
              <li><a href="#/stories/lisbon" data-router-link data-i18n-target="ft-s2">Lisbon in eight pictures</a></li>
              <li><a href="#/stories/letter" data-router-link data-i18n-target="ft-s3">Behind The Calm Letter</a></li>
            </ul>
          </div>
          <div class="mk-footer-col">
            <h3 class="mk-footer-heading" data-i18n-target="ft-contact">Contact</h3>
            <ul class="mk-footer-list">
              <li><a href="mailto:stories@acme.example">stories@acme.example</a></li>
              <li><a href="mailto:podcast@acme.example">podcast@acme.example</a></li>
            </ul>
          </div>
        </nav>
      </div>
      <hr class="separator mk-footer-rule" />
      <div class="mk-footer-bottom">
        <p class="mk-footer-copy" data-i18n-target="ft-copy">© 2026 Acme, Lda. · Photos and films by the Acme team.</p>
      </div>
    </div>
  </footer>
  <!-- the pages the routes name, in English and German -->
  <script type="application/json" id="media-data">
    {
      "episodes": {
        "39": {
          "title": "Designing for one hand",
          "date": "2026-09-09",
          "en": {
            "guest": "With Priya Natarajan",
            "notes": "Priya walks through the redesign of Acme's phone app for one-handed use, with the measurements behind every change.",
            "chapters": ["0:00 Intro", "0:05 The thumb zone", "0:10 Big targets"]
          },
          "de": {
            "guest": "Mit Priya Natarajan",
            "notes": "Priya zeigt die Neugestaltung der Acme-App für die Bedienung mit einer Hand - mit den Messungen hinter jeder Änderung.",
            "chapters": ["0:00 Einstieg", "0:05 Die Daumenzone", "0:10 Große Ziele"]
          }
        },
        "40": {
          "title": "Support on Fridays",
          "date": "2026-09-16",
          "en": {
            "guest": "With Alex Moreau",
            "notes": "Alex on a habit he kept from the first year: one day a week in the support inbox, and the three features it led to.",
            "chapters": ["0:00 Intro", "0:04 The Friday inbox", "0:09 Three features"]
          },
          "de": {
            "guest": "Mit Alex Moreau",
            "notes": "Alex über eine Gewohnheit aus dem ersten Jahr: ein Tag pro Woche im Support-Postfach - und die drei Funktionen, die daraus entstanden.",
            "chapters": ["0:00 Einstieg", "0:04 Das Freitagspostfach", "0:09 Drei Funktionen"]
          }
        },
        "41": {
          "title": "Writing decisions down",
          "date": "2026-09-23",
          "en": {
            "guest": "With Hannah Lee",
            "notes": "Hannah explains how her team replaced status meetings with written decisions - and what they kept.",
            "chapters": ["0:00 Intro", "0:05 The decision log", "0:10 What we kept"]
          },
          "de": {
            "guest": "Mit Hannah Lee",
            "notes": "Hannah erklärt, wie ihr Team Status-Meetings durch schriftliche Entscheidungen ersetzt hat - und was geblieben ist.",
            "chapters": ["0:00 Einstieg", "0:05 Das Entscheidungslog", "0:10 Was geblieben ist"]
          }
        },
        "42": {
          "title": "Why we never ship on Fridays",
          "date": "2026-09-30",
          "en": {
            "guest": "With Alex Moreau and Sophie Tan",
            "notes": "Alex and Sophie explain why Acme ships on Thursdays, what happens when a release goes wrong, and how a quiet weekend became a rule.",
            "chapters": ["0:00 Intro", "0:04 The Thursday rule", "0:09 When it goes wrong"]
          },
          "de": {
            "guest": "Mit Alex Moreau und Sophie Tan",
            "notes": "Alex und Sophie erklären, warum Acme donnerstags ausliefert, was passiert, wenn ein Release schiefgeht, und wie aus einem ruhigen Wochenende eine Regel wurde.",
            "chapters": ["0:00 Einstieg", "0:04 Die Donnerstagsregel", "0:09 Wenn es schiefgeht"]
          }
        }
      },
      "stories": {
        "sync": {
          "photo": 48,
          "href": "#md-film",
          "en": {
            "eyebrow": "Offline first",
            "title": "How sync works",
            "lead": "Every change is saved on your device first. Here is what happens next - in plain words.",
            "body": [
              "When you type, Acme writes the change to your device before it does anything else. There is no spinner and no waiting for a server: the edit is yours the moment you make it.",
              "When a connection comes back, your device and our servers compare notes. Each change carries who made it and when, so two edits to the same paragraph merge instead of overwriting each other.",
              "If two people change the very same word, you see both versions side by side and pick one. In the last year that happened in fewer than one in ten thousand edits."
            ],
            "link": "Watch the film",
            "alt": "A laptop on a café table"
          },
          "de": {
            "eyebrow": "Offline zuerst",
            "title": "So funktioniert der Sync",
            "lead": "Jede Änderung landet zuerst auf deinem Gerät. Was danach passiert - in einfachen Worten.",
            "body": [
              "Wenn du tippst, schreibt Acme die Änderung zuerst auf dein Gerät. Kein Ladekreis, kein Warten auf einen Server: Die Änderung gehört dir, sobald du sie machst.",
              "Sobald wieder eine Verbindung da ist, gleichen dein Gerät und unsere Server ihre Notizen ab. Jede Änderung trägt mit, wer sie wann gemacht hat - zwei Änderungen am selben Absatz werden zusammengeführt, statt sich zu überschreiben.",
              "Ändern zwei Menschen genau dasselbe Wort, siehst du beide Fassungen nebeneinander und wählst eine. Im letzten Jahr kam das bei weniger als einer von zehntausend Änderungen vor."
            ],
            "link": "Den Film ansehen",
            "alt": "Ein Laptop auf einem Cafétisch"
          }
        },
        "lisbon": {
          "photo": 288,
          "href": "#/photos/1",
          "en": {
            "eyebrow": "Photo walk",
            "title": "Lisbon in eight pictures",
            "lead": "An autumn morning from the harbour to the rooftops - the walk behind our gallery.",
            "body": [
              "We started at the harbour before seven, when the boats were still tied up and the light came in low over the river.",
              "From there the walk climbed through the old town: white stairs, a canal of moored boats, a red wall that turned orange as the sun rose.",
              "By noon we were on the rooftops. All eight photos are in the gallery - open the slideshow and step through them in the order we took them."
            ],
            "link": "Open the slideshow",
            "alt": "The rooftops of an old town"
          },
          "de": {
            "eyebrow": "Fotospaziergang",
            "title": "Lissabon in acht Bildern",
            "lead": "Ein Herbstmorgen vom Hafen bis über die Dächer - der Spaziergang hinter unserer Galerie.",
            "body": [
              "Wir fingen vor sieben am Hafen an, als die Boote noch vertäut waren und das Licht flach über den Fluss kam.",
              "Von dort stieg der Weg durch die Altstadt: weiße Treppen, ein Kanal voller Boote, eine rote Mauer, die mit der Sonne orange wurde.",
              "Mittags waren wir über den Dächern. Alle acht Fotos sind in der Galerie - öffne die Diashow und geh sie in der Reihenfolge durch, in der wir sie aufgenommen haben."
            ],
            "link": "Diashow öffnen",
            "alt": "Die Dächer einer Altstadt"
          }
        },
        "letter": {
          "photo": 39,
          "href": "#md-listen",
          "en": {
            "eyebrow": "Podcast",
            "title": "Behind The Calm Letter",
            "lead": "How a weekly email became a podcast - recorded in one take, every Tuesday.",
            "body": [
              "The Calm Letter started as a weekly email from Alex to every customer. Two years ago people began to ask for an audio version they could hear on the way to work.",
              "Each episode is recorded on Tuesday in one take, edited only for coughs, and published the same evening. Guests are colleagues and customers - never sponsors.",
              "Every episode has show notes with chapters, so you can jump to the part you need."
            ],
            "link": "Listen to the latest episode",
            "alt": "A record turning on a turntable"
          },
          "de": {
            "eyebrow": "Podcast",
            "title": "Hinter The Calm Letter",
            "lead": "Wie aus einer wöchentlichen E-Mail ein Podcast wurde - jeden Dienstag in einem Take aufgenommen.",
            "body": [
              "The Calm Letter begann als wöchentliche E-Mail von Alex an alle Kunden. Vor zwei Jahren fragten die ersten nach einer Audiofassung für den Weg zur Arbeit.",
              "Jede Folge wird dienstags in einem Take aufgenommen, nur um Huster gekürzt und noch am selben Abend veröffentlicht. Zu Gast sind Kolleginnen, Kollegen und Kunden - nie Sponsoren.",
              "Zu jeder Folge gibt es Shownotes mit Kapiteln, damit du direkt zu dem Teil springen kannst, den du brauchst."
            ],
            "link": "Die neueste Folge hören",
            "alt": "Eine Schallplatte auf einem Plattenspieler"
          }
        }
      }
    }
  </script>
  <!-- the translations: one template per target and language (defuss-i18n) -->
  <template data-i18n-for="stamp" data-i18n-locale="en">works offline · 2026</template>
  <template data-i18n-for="stamp" data-i18n-locale="de">funktioniert offline · 2026</template>
  <template data-i18n-for="look-gallery" data-i18n-locale="en">Gallery</template>
  <template data-i18n-for="look-gallery" data-i18n-locale="de">Galerie</template>
  <template data-i18n-for="look-cinema" data-i18n-locale="en">Cinema</template>
  <template data-i18n-for="look-cinema" data-i18n-locale="de">Kino</template>
  <template data-i18n-for="look-archive" data-i18n-locale="en">Archive</template>
  <template data-i18n-for="look-archive" data-i18n-locale="de">Archiv</template>
  <template data-i18n-for="eyebrow" data-i18n-locale="en">Offline first</template>
  <template data-i18n-for="eyebrow" data-i18n-locale="de">Zuerst offline</template>
  <template data-i18n-for="tm-title" data-i18n-locale="en">Your work travels with you</template>
  <template data-i18n-for="tm-title" data-i18n-locale="de">Deine Arbeit reist mit</template>
  <template data-i18n-for="tm-wait" data-i18n-locale="en">Edits never wait for the network</template>
  <template data-i18n-for="tm-wait" data-i18n-locale="de">Änderungen warten nie auf das Netz</template>
  <template data-i18n-for="tm-conflicts" data-i18n-locale="en">Conflicts resolve themselves</template>
  <template data-i18n-for="tm-conflicts" data-i18n-locale="de">Konflikte lösen sich von selbst</template>
  <template data-i18n-for="tm-devices" data-i18n-locale="en">Works on every device</template>
  <template data-i18n-for="tm-devices" data-i18n-locale="de">Funktioniert auf jedem Gerät</template>
  <template data-i18n-for="mg-c1" data-i18n-locale="en">The harbour</template>
  <template data-i18n-for="mg-c1" data-i18n-locale="de">Der Hafen</template>
  <template data-i18n-for="mg-c2" data-i18n-locale="en">White stairs</template>
  <template data-i18n-for="mg-c2" data-i18n-locale="de">Weiße Treppen</template>
  <template data-i18n-for="mg-c3" data-i18n-locale="en">Canal houses</template>
  <template data-i18n-for="mg-c3" data-i18n-locale="de">Häuser am Kanal</template>
  <template data-i18n-for="mg-c4" data-i18n-locale="en">A red wall</template>
  <template data-i18n-for="mg-c4" data-i18n-locale="de">Eine rote Mauer</template>
  <template data-i18n-for="mg-c5" data-i18n-locale="en">Market morning</template>
  <template data-i18n-for="mg-c5" data-i18n-locale="de">Markt am Morgen</template>
  <template data-i18n-for="mg-c6" data-i18n-locale="en">An old car</template>
  <template data-i18n-for="mg-c6" data-i18n-locale="de">Ein alter Wagen</template>
  <template data-i18n-for="mg-c7" data-i18n-locale="en">The open sea</template>
  <template data-i18n-for="mg-c7" data-i18n-locale="de">Das offene Meer</template>
  <template data-i18n-for="mg-c8" data-i18n-locale="en">Over the rooftops</template>
  <template data-i18n-for="mg-c8" data-i18n-locale="de">Über den Dächern</template>
  <template data-i18n-for="tm-watch" data-i18n-locale="en">Watch the film</template>
  <template data-i18n-for="tm-watch" data-i18n-locale="de">Den Film ansehen</template>
  <template data-i18n-for="tm-link" data-i18n-locale="en">How sync works</template>
  <template data-i18n-for="tm-link" data-i18n-locale="de">So funktioniert Sync</template>
  <template data-i18n-for="mg-count" data-i18n-locale="en">8 photos</template>
  <template data-i18n-for="mg-count" data-i18n-locale="de">8 Fotos</template>
  <template data-i18n-for="mg-title" data-i18n-locale="en">Lisbon, autumn 2026</template>
  <template data-i18n-for="mg-title" data-i18n-locale="de">Lissabon, Herbst 2026</template>
  <template data-i18n-for="view-grid" data-i18n-locale="en">Grid</template>
  <template data-i18n-for="view-grid" data-i18n-locale="de">Raster</template>
  <template data-i18n-for="view-masonry" data-i18n-locale="en">Masonry</template>
  <template data-i18n-for="view-masonry" data-i18n-locale="de">Mauerwerk</template>
  <template data-i18n-for="view-strip" data-i18n-locale="en">Filmstrip</template>
  <template data-i18n-for="view-strip" data-i18n-locale="de">Filmstreifen</template>
  <template data-i18n-for="slideshow" data-i18n-locale="en">Slideshow</template>
  <template data-i18n-for="slideshow" data-i18n-locale="de">Diashow</template>
  <template data-i18n-for="mg-hint" data-i18n-locale="en">Swipe, scroll or use ← → · Esc closes</template>
  <template data-i18n-for="mg-hint" data-i18n-locale="de">Wischen, scrollen oder ← → · Esc schließt</template>
  <template data-i18n-for="transcript" data-i18n-locale="en">Transcript</template>
  <template data-i18n-for="transcript" data-i18n-locale="de">Transkript</template>
  <template data-i18n-for="vp-caption" data-i18n-locale="en">Acme in 60 seconds</template>
  <template data-i18n-for="vp-caption" data-i18n-locale="de">Acme in 60 Sekunden</template>
  <template data-i18n-for="ap-show" data-i18n-locale="en">The Calm Letter · Episode</template>
  <template data-i18n-for="ap-show" data-i18n-locale="de">The Calm Letter · Folge</template>
  <template data-i18n-for="ap-notes" data-i18n-locale="en">Show notes</template>
  <template data-i18n-for="ap-notes" data-i18n-locale="de">Shownotes</template>
  <template data-i18n-for="nav-photos" data-i18n-locale="en">Photos</template>
  <template data-i18n-for="nav-photos" data-i18n-locale="de">Fotos</template>
  <template data-i18n-for="nav-film" data-i18n-locale="en">Film</template>
  <template data-i18n-for="nav-film" data-i18n-locale="de">Film</template>
  <template data-i18n-for="nav-stories" data-i18n-locale="en">Stories</template>
  <template data-i18n-for="nav-stories" data-i18n-locale="de">Geschichten</template>
  <template data-i18n-for="tm-text" data-i18n-locale="en"
    >Every change is saved on your device first and synced when you are back online - on a plane, in a tunnel, at the
    cabin.</template
  >
  <template data-i18n-for="tm-text" data-i18n-locale="de"
    >Jede Änderung wird zuerst auf deinem Gerät gespeichert und synchronisiert, sobald du wieder online bist - im
    Flugzeug, im Tunnel, in der Hütte.</template
  >
  <template data-i18n-for="tr-1" data-i18n-locale="en">Plan the week on one calm board.</template>
  <template data-i18n-for="tr-1" data-i18n-locale="de">Plane die Woche auf einem ruhigen Board.</template>
  <template data-i18n-for="tr-2" data-i18n-locale="en">Drafts, docs and tasks stay linked.</template>
  <template data-i18n-for="tr-2" data-i18n-locale="de">Entwürfe, Dokumente und Aufgaben bleiben verknüpft.</template>
  <template data-i18n-for="tr-3" data-i18n-locale="en">Ship it - and everyone sees what changed.</template>
  <template data-i18n-for="tr-3" data-i18n-locale="de">Ausliefern - und alle sehen, was sich geändert hat.</template>
  <template data-i18n-for="ep-d42" data-i18n-locale="en"
    >Alex and Sophie on release rhythms, weekends and why boring deploys are the best deploys.</template
  >
  <template data-i18n-for="ep-d42" data-i18n-locale="de"
    >Alex und Sophie über Release-Rhythmen, Wochenenden und warum langweilige Deploys die besten sind.</template
  >
  <template data-i18n-for="ep-d41" data-i18n-locale="en"
    >Hannah explains how her team replaced status meetings with a written decision log.</template
  >
  <template data-i18n-for="ep-d41" data-i18n-locale="de"
    >Hannah erklärt, wie ihr Team Status-Meetings durch ein schriftliches Entscheidungslog ersetzt hat.</template
  >
  <template data-i18n-for="ep-d40" data-i18n-locale="en"
    >Why the CEO still answers support tickets every Friday - and what it changed in the product.</template
  >
  <template data-i18n-for="ep-d40" data-i18n-locale="de"
    >Warum der CEO freitags noch immer Support-Tickets beantwortet - und was das am Produkt verändert hat.</template
  >
  <template data-i18n-for="ep-d39" data-i18n-locale="en"
    >Priya on phone apps you can use while holding a coffee - reach, gestures and big targets.</template
  >
  <template data-i18n-for="ep-d39" data-i18n-locale="de"
    >Priya über Apps, die man mit einem Kaffee in der Hand bedienen kann - Reichweite, Gesten und große Ziele.</template
  >
  <template data-i18n-for="ba-after" data-i18n-locale="en">Show after</template>
  <template data-i18n-for="ba-after" data-i18n-locale="de">Nachher zeigen</template>
  <template data-i18n-for="post-1" data-i18n-locale="en"
    >Acme is the first tool my designers asked to keep after the trial. That never happens.</template
  >
  <template data-i18n-for="post-1" data-i18n-locale="de"
    >Acme ist das erste Werkzeug, das mein Designteam nach dem Test behalten wollte. Das passiert sonst nie.</template
  >
  <template data-i18n-for="post-2" data-i18n-locale="en"
    >Our weekly sync went from 90 minutes to 20. I have my Thursday afternoons back.</template
  >
  <template data-i18n-for="post-2" data-i18n-locale="de"
    >Unser Wochentermin schrumpfte von 90 auf 20 Minuten. Ich habe meine Donnerstagnachmittage zurück.</template
  >
  <template data-i18n-for="post-1-date" data-i18n-locale="en">Sep 12, 2026</template>
  <template data-i18n-for="post-1-date" data-i18n-locale="de">12. Sept. 2026</template>
  <template data-i18n-for="post-2-date" data-i18n-locale="en">Aug 30, 2026</template>
  <template data-i18n-for="post-2-date" data-i18n-locale="de">30. Aug. 2026</template>
  <template data-i18n-for="st-title" data-i18n-locale="en">More stories</template>
  <template data-i18n-for="st-title" data-i18n-locale="de">Weitere Geschichten</template>
  <template data-i18n-for="st-sync-eyebrow" data-i18n-locale="en">Offline first</template>
  <template data-i18n-for="st-sync-eyebrow" data-i18n-locale="de">Offline zuerst</template>
  <template data-i18n-for="st-sync-title" data-i18n-locale="en">How sync works</template>
  <template data-i18n-for="st-sync-title" data-i18n-locale="de">So funktioniert der Sync</template>
  <template data-i18n-for="st-sync-text" data-i18n-locale="en"
    >Every change is saved on your device first. Here is what happens next - in plain words.</template
  >
  <template data-i18n-for="st-sync-text" data-i18n-locale="de"
    >Jede Änderung landet zuerst auf deinem Gerät. Was danach passiert - in einfachen Worten.</template
  >
  <template data-i18n-for="st-lisbon-eyebrow" data-i18n-locale="en">Photo walk</template>
  <template data-i18n-for="st-lisbon-eyebrow" data-i18n-locale="de">Fotospaziergang</template>
  <template data-i18n-for="st-lisbon-title" data-i18n-locale="en">Lisbon in eight pictures</template>
  <template data-i18n-for="st-lisbon-title" data-i18n-locale="de">Lissabon in acht Bildern</template>
  <template data-i18n-for="st-lisbon-text" data-i18n-locale="en"
    >An autumn morning from the harbour to the rooftops - the walk behind our gallery.</template
  >
  <template data-i18n-for="st-lisbon-text" data-i18n-locale="de"
    >Ein Herbstmorgen vom Hafen bis über die Dächer - der Spaziergang hinter unserer Galerie.</template
  >
  <template data-i18n-for="st-letter-title" data-i18n-locale="en">Behind The Calm Letter</template>
  <template data-i18n-for="st-letter-title" data-i18n-locale="de">Hinter The Calm Letter</template>
  <template data-i18n-for="st-letter-text" data-i18n-locale="en"
    >How a weekly email became a podcast - recorded in one take, every Tuesday.</template
  >
  <template data-i18n-for="st-letter-text" data-i18n-locale="de"
    >Wie aus einer wöchentlichen E-Mail ein Podcast wurde - jeden Dienstag in einem Take aufgenommen.</template
  >
  <template data-i18n-for="sp-back" data-i18n-locale="en">All stories</template>
  <template data-i18n-for="sp-back" data-i18n-locale="de">Alle Geschichten</template>
  <template data-i18n-for="sp-prev" data-i18n-locale="en">Previous story</template>
  <template data-i18n-for="sp-prev" data-i18n-locale="de">Vorige Geschichte</template>
  <template data-i18n-for="sp-next" data-i18n-locale="en">Next story</template>
  <template data-i18n-for="sp-next" data-i18n-locale="de">Nächste Geschichte</template>
  <template data-i18n-for="ft-line" data-i18n-locale="en"
    >Photos, films and a podcast from the people who build Acme - in Lisbon and on the road.</template
  >
  <template data-i18n-for="ft-line" data-i18n-locale="de"
    >Fotos, Filme und ein Podcast von den Menschen, die Acme bauen - in Lissabon und unterwegs.</template
  >
  <template data-i18n-for="ft-watch" data-i18n-locale="en">Watch and listen</template>
  <template data-i18n-for="ft-watch" data-i18n-locale="de">Sehen und hören</template>
  <template data-i18n-for="ft-photos" data-i18n-locale="en">Photos</template>
  <template data-i18n-for="ft-photos" data-i18n-locale="de">Fotos</template>
  <template data-i18n-for="ft-slides" data-i18n-locale="en">Slideshow</template>
  <template data-i18n-for="ft-slides" data-i18n-locale="de">Diashow</template>
  <template data-i18n-for="ft-film" data-i18n-locale="en">Film</template>
  <template data-i18n-for="ft-film" data-i18n-locale="de">Film</template>
  <template data-i18n-for="ft-stories" data-i18n-locale="en">Stories</template>
  <template data-i18n-for="ft-stories" data-i18n-locale="de">Geschichten</template>
  <template data-i18n-for="ft-s1" data-i18n-locale="en">How sync works</template>
  <template data-i18n-for="ft-s1" data-i18n-locale="de">So funktioniert der Sync</template>
  <template data-i18n-for="ft-s2" data-i18n-locale="en">Lisbon in eight pictures</template>
  <template data-i18n-for="ft-s2" data-i18n-locale="de">Lissabon in acht Bildern</template>
  <template data-i18n-for="ft-s3" data-i18n-locale="en">Behind The Calm Letter</template>
  <template data-i18n-for="ft-s3" data-i18n-locale="de">Hinter The Calm Letter</template>
  <template data-i18n-for="ft-contact" data-i18n-locale="en">Contact</template>
  <template data-i18n-for="ft-contact" data-i18n-locale="de">Kontakt</template>
  <template data-i18n-for="ft-copy" data-i18n-locale="en"
    >© 2026 Acme, Lda. · Photos and films by the Acme team.</template
  >
  <template data-i18n-for="ft-copy" data-i18n-locale="de">© 2026 Acme, Lda. · Fotos und Filme vom Acme-Team.</template>
  <template data-i18n-for="cap-1" data-i18n-locale="en">Boats moored in a harbour</template>
  <template data-i18n-for="cap-1" data-i18n-locale="de">Boote im Hafen vertäut</template>
  <template data-i18n-for="cap-2" data-i18n-locale="en">A person on white stone stairs</template>
  <template data-i18n-for="cap-2" data-i18n-locale="de">Ein Mensch auf weißen Steintreppen</template>
  <template data-i18n-for="cap-3" data-i18n-locale="en">Houses and boats along a canal</template>
  <template data-i18n-for="cap-3" data-i18n-locale="de">Häuser und Boote an einem Kanal</template>
  <template data-i18n-for="cap-4" data-i18n-locale="en">A red brick wall</template>
  <template data-i18n-for="cap-4" data-i18n-locale="de">Eine rote Backsteinmauer</template>
  <template data-i18n-for="cap-5" data-i18n-locale="en">Vegetables on a cutting board</template>
  <template data-i18n-for="cap-5" data-i18n-locale="de">Gemüse auf einem Schneidebrett</template>
  <template data-i18n-for="cap-6" data-i18n-locale="en">A vintage car parked in the street</template>
  <template data-i18n-for="cap-6" data-i18n-locale="de">Ein Oldtimer am Straßenrand</template>
  <template data-i18n-for="cap-7" data-i18n-locale="en">A rocky shore and the open sea</template>
  <template data-i18n-for="cap-7" data-i18n-locale="de">Eine felsige Küste und das offene Meer</template>
  <template data-i18n-for="cap-8" data-i18n-locale="en">The rooftops of an old town</template>
  <template data-i18n-for="cap-8" data-i18n-locale="de">Die Dächer einer Altstadt</template>
</div>
<script type="module">
  // routing and translation: defuss-dom-router owns the address, defuss-i18n the language
  import { createRouter } from 'https://cdn.jsdelivr.net/npm/defuss-dom-router@0.1.1/dist/index.js';
  import { createDomI18n, createI18n } from 'https://cdn.jsdelivr.net/npm/defuss-i18n@0.2.0/dist/core.js';

  // df$ comes with the component bundle - a full-screen page loads it after this module
  addEventListener('DOMContentLoaded', async () => {
    // light or dark: the switch writes the page's dark class (every look has both palettes); it follows the class when
    // something else sets it (the docs card follows the site's mode)
    const siteMode = df$('#site-media [data-site-mode]');
    const syncMode = () => siteMode.prop('checked', document.documentElement.classList.contains('dark'));
    siteMode.on('change', () => {
      document.documentElement.classList.toggle('dark', siteMode.prop('checked'));
      document.dispatchEvent(new CustomEvent('defuss-theme-change'));
    });
    new MutationObserver(syncMode).observe(document.documentElement, { attributes: true, attributeFilter: ['class'] });
    syncMode();

    const site = df$('#site-media').get(0);

    // -- translation: the markup is the catalog (the templates at the end of the page)
    const locale = createI18n({
      locale: 'en', // the demos start in English; the language select offers German
    });
    createDomI18n(df$).bind(site, locale);
    // the Language Switcher sets the locale on a pick and follows it when something else sets it
    df$.shadcn.languageSwitcher.bind(df$('[data-app-locale]').get(0), locale);

    // -- the look: one of the site's designs. An element with data-look-set takes that look's attributes (a shader's
    // effect, colors or contrast); a shader reads its colors again on defuss-theme-change
    const lookRoot = df$('#site-media').get(0);
    const look = df$('#site-media [data-site-look]');
    const applyLook = (name) => {
      lookRoot.dataset.look = name;
      df$('#site-media [data-look-set]').each((_i, el) => {
        const sets = JSON.parse(el.dataset.lookSet);
        for (const [attr, value] of Object.entries({ ...sets.default, ...sets[name] })) el.setAttribute(attr, value);
      });
      document.dispatchEvent(new CustomEvent('defuss-theme-change'));
    };
    look.val(lookRoot.dataset.look).on('change', () => applyLook(look.val()));

    // -- the stories and the podcast's episodes come from one data block in English and German, drawn again when the
    // language changes
    const DATA = JSON.parse(df$('#media-data').text());
    const STORIES = Object.keys(DATA.stories);
    const tr = (item) => item[locale.locale] ?? item.en;
    const fill = (scope, attr, values) =>
      scope.find('[' + attr + ']').each((_i, el) => {
        const key = el.getAttribute(attr);
        if (key in values) df$(el).text(values[key]);
      });
    const day = (iso) => locale.formatDate(Date.parse(iso + 'T12:00:00Z'), { dateStyle: 'medium', timeZone: 'UTC' });

    // -- the playlist plays its item: picking an episode puts it into the player above and starts it
    const player = df$('#site-media .mk-audio-player');
    const audio = df$('#site-media [data-episode-audio]').get(0);
    const episode = () => df$('#site-media input[name="episode"]:checked').val() || '42';
    const drawEpisode = () => {
      const n = episode();
      const item = DATA.episodes[n];
      const t = tr(item);
      fill(player, 'data-episode-field', { ...t, n, title: item.title });
      player.find('[data-episode-date]').attr('datetime', item.date).text(day(item.date));
      const list = player.find('[data-episode-chapters]').html('');
      for (const line of t.chapters) list.append(df$('<li></li>').text(line));
    };
    df$('#site-media input[name="episode"]').on('change', () => {
      drawEpisode();
      audio.currentTime = 0;
      audio.play().catch(() => {});
    });

    const drawStory = (key) => {
      const item = DATA.stories[key];
      const t = tr(item);
      const page = df$('#site-media [data-media-view="story"]');
      fill(page, 'data-story-field', t);
      page
        .find('[data-story-photo]')
        .attr('src', 'images/photos/' + item.photo + '-1600x800.webp')
        .attr('alt', t.alt);
      const body = page.find('[data-story-body]').html('');
      for (const text of t.body) body.append(df$('<p></p>').text(text));
      page.find('[data-story-link]').attr('href', item.href);
      const i = STORIES.indexOf(key);
      const around = {
        prev: STORIES[(i - 1 + STORIES.length) % STORIES.length],
        next: STORIES[(i + 1) % STORIES.length],
      };
      for (const [dir, to] of Object.entries(around)) {
        const link = page.find('[data-story-pager="' + dir + '"]');
        link.attr('href', '#/stories/' + to);
        link.find('[data-pager-title]').text(tr(DATA.stories[to]).title);
      }
    };

    // -- routing
    const routes = [
      { id: 'page', path: '/' },
      { id: 'photo', path: '/photos/:n' },
      { id: 'story', path: '/stories/:id' },
      { id: 'missing', path: '*' },
    ];
    const viewer = df$('#mg-viewer').get(0);
    const slides = df$('#mg-viewer .mk-media-gallery-track > li');
    let story = null;
    const draw = () => {
      drawEpisode();
      if (story) drawStory(story);
    };
    locale.subscribe(draw);
    const showView = (view) => {
      df$('#site-media [data-media-view]').each((_i, part) => {
        part.hidden = part.dataset.mediaView !== view;
      });
    };
    // a photo route opens the slideshow on that photo over the front page, a story route the story's page; any other
    // route closes the slideshow
    // the story shown last (undefined before the first view)
    let shownStory;
    const show = (to) => {
      story = to.routeId === 'story' && DATA.stories[to.params.id] ? to.params.id : null;
      draw();
      showView(story ? 'story' : 'home');
      // a story opens at its start, the front page again at its top - the first view stays where the reader is; a
      // photo opens in the slideshow above the page
      if (shownStory !== undefined && story !== shownStory)
        df$(story ? '#site-media [data-media-view="story"]' : '#site-media')
          .get(0)
          ?.scrollIntoView({ block: 'start', behavior: 'instant' });
      shownStory = story;
      const slide = to.routeId === 'photo' ? slides.get(Number(to.params.n) - 1) : undefined;
      if (!slide) return viewer.open && viewer.close();
      if (!viewer.open) viewer.showModal();
      slide.scrollIntoView({ block: 'nearest', inline: 'start' });
    };
    // closing the slideshow (Esc, ×) leaves the photo's address
    viewer.addEventListener('close', () => {
      if (!location.hash.startsWith('#/photos/')) return;
      if (router.getSnapshot().current) router.navigate('#/');
      else location.hash = '/';
    });
    // the header's and the footer's section links are in-page anchors of the front page: from a story they bring the
    // front page back first
    addEventListener('hashchange', () => {
      const id = location.hash.slice(1);
      if (!id || id.startsWith('/')) return;
      const target = df$('#site-media [id="' + id + '"]').get(0);
      if (!target || !target.closest('[hidden]')) return;
      story = null;
      showView('home');
      target.scrollIntoView({ behavior: 'instant' });
    });
    const router = createRouter({ mode: 'hash', routes, prepare: ({ to }) => ({ commit: () => show(to) }) });
    router.attachLinks(site);
    if ((await router.start()).status === 'rejected') {
      // no address the router may own - a docs preview is an about:srcdoc frame: the same routes match its hash
      const preview = createRouter({ mode: 'hash', routes, baseUrl: 'https://preview.invalid/' });
      const follow = () => {
        if (location.hash && !location.hash.startsWith('#/')) return;
        show(preview.resolve(location.hash || '#/'));
      };
      addEventListener('hashchange', follow);
      follow();
    }
  });
</script>
```

<h2 id="blocks" class="h2-display">The blocks</h2>

<div class="grid gap-4 mb-8" style="grid-template-columns:repeat(auto-fill,minmax(16rem,1fr))">
  <a class="card" data-size="sm" href="gallery-item.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Gallery Item</h3>
      <p class="card-description">Presents one image with a caption and enlarged-view action - the picture opens a large view in a native modal dialog.</p>
    </div>
  </a>
  <a class="card" data-size="sm" href="media-gallery.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Media Gallery</h3>
      <p class="card-description">Coordinates a collection of images with shared viewing controls - switch between grid, masonry and filmstrip, and open a slideshow of every picture.</p>
    </div>
  </a>
  <a class="card" data-size="sm" href="text-media.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Text Media</h3>
      <p class="card-description">Pairs explanatory text with an image, illustration, or video - side by side, reversed, or with the text card overlapping the picture.</p>
    </div>
  </a>
  <a class="card" data-size="sm" href="video-player.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Video Player</h3>
      <p class="card-description">Plays one video with playback controls and captions - native controls, a WebVTT captions track, title and details, chapters or a transcript.</p>
    </div>
  </a>
  <a class="card" data-size="sm" href="audio-player.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Audio Player</h3>
      <p class="card-description">Plays one audio recording with playback controls and metadata - cover art, title, show and episode, the native player and a download link.</p>
    </div>
  </a>
  <a class="card" data-size="sm" href="playlist-item.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Playlist Item</h3>
      <p class="card-description">Represents one selectable track or episode within a playlist - number, cover, title, artist and length; the selected one shows "now playing" bars.</p>
    </div>
  </a>
  <a class="card" data-size="sm" href="before-after.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Before After</h3>
      <p class="card-description">Compares two images through aligned views or a slider - drag a divider, toggle between them, or set them side by side.</p>
    </div>
  </a>
  <a class="card" data-size="sm" href="social-post.html" style="text-decoration:none;color:inherit">
    <div class="card-header">
      <h3 class="card-title card-title-sm">Social Post</h3>
      <p class="card-description">Displays one embedded or locally rendered social post - author, text with links, media, time and engagement, as a post, a photo post or a quote.</p>
    </div>
  </a>
</div>

</DocPage>
