:root {
  --bg: #0c0c0d;
  --surface: #161618;
  --line: #2a2a2e;          /* dividers only */
  --control: #67656b;       /* borders of controls: 3.2:1 on --bg */
  --text: #f2efe9;
  --text-soft: #d6d2ca;
  --muted: #9a968f;
  --accent: #ED2021;        /* Mediamax brand red: logo, focus, underlines, fills (4.49:1 on --bg, never for text) */
  --accent-fill: #D41C1E;   /* button fills, white text 5.3:1 */
  --accent-fill-hover: #BE181A;
  --accent-text: #F2484A;   /* red text on --bg (badges, quote, link hover), 5.4:1 */
  --radius: 14px;
  --serif: "Fraunces", Georgia, serif;
  --sans: "Inter", system-ui, sans-serif;
  --gutter: clamp(16px, 5vw, 56px);
  --content: 1320px;
  /* Inline inset that puts full-bleed bands (nav, hero, stats, footer) on the same edges as the 1320 px sections */
  --inset: max(var(--gutter), calc((100% - var(--content)) / 2 + var(--gutter)));
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; margin: 0; }
html { scroll-behavior: smooth; scrollbar-color: var(--line) var(--bg); accent-color: var(--accent); }
body { background: var(--bg); color: var(--text); font: 16px/1.6 var(--sans); caret-color: var(--accent); }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; text-align: left; padding: 0; }
i, em { font-style: italic; }
/* Components set their own display (inline-flex, grid…); hidden must still win */
[hidden] { display: none !important; }
ul { list-style: none; padding: 0; }
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
section[id] { scroll-margin-top: 88px; }
.icon { width: 1em; height: 1em; fill: currentColor; flex: none; }
.close .icon { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.skip-link {
  position: fixed; left: var(--gutter); top: 12px; z-index: 20;
  padding: 10px 18px; border-radius: 999px; background: var(--accent-fill); color: #fff; font-weight: 500;
  transform: translateY(-160%); transition: transform .2s var(--ease-out);
}
.skip-link:focus-visible { transform: none; }

/* Nav */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 10;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 10px var(--inset);
  background: rgba(12, 12, 13, .8); backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(42, 42, 46, .6);
}
.logo { display: inline-flex; align-items: center; gap: 12px; min-height: 44px; flex: none; }
/* 40 px tile: its AA glyph is ~18 px tall, the same cap height as the wordmark beside it */
.logo-mark { width: 40px; height: 40px; border-radius: 15%; }
.logo-word { height: 18px; width: auto; }
.footer-logo { height: 56px; width: auto; margin-bottom: 4px; }
.nav nav { display: flex; gap: clamp(12px, 3vw, 32px); font-size: 14px; color: var(--muted); }
.nav-right { display: flex; align-items: center; }
/* Language switch: codes on desktop, a disclosure menu on phones.
   The active language is marked by weight and colour, so red underlines always mean "section in view" */
.lang { display: flex; margin-left: clamp(12px, 2vw, 24px); padding-left: clamp(8px, 1.5vw, 16px); border-left: 1px solid var(--line); }
.lang a { display: inline-flex; align-items: center; justify-content: center; min-width: 36px; min-height: 44px; font-size: 13px; letter-spacing: .04em; color: var(--muted); transition: color .2s; }
.lang a:hover { color: var(--text); }
.lang a[aria-current] { color: var(--text); font-weight: 600; }
.lang-menu { display: none; position: relative; margin-left: 8px; }
.lang-menu summary {
  list-style: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 4px 0 8px;
  font: 500 13px var(--sans); letter-spacing: .04em; color: var(--text); cursor: pointer;
}
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary::after {
  content: ""; width: 9px; height: 6px; transition: rotate .2s var(--ease-out);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%239a968f' stroke-width='1.5'/%3E%3C/svg%3E") center / contain no-repeat;
}
.lang-menu[open] summary::after { rotate: 180deg; }
.lang-menu ul {
  position: absolute; right: 0; top: calc(100% + 6px); min-width: 168px; padding: 6px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 32px rgba(0, 0, 0, .5);
}
.lang-menu a { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: 6px; font-size: 15px; color: var(--text-soft); }
.lang-menu a:hover { background: rgba(242, 239, 233, .06); color: var(--text); }
.lang-menu a[aria-current] { color: var(--text); font-weight: 600; }
.nav nav a { display: inline-flex; align-items: center; min-height: 44px; transition: color .2s; }
.nav nav a:hover { color: var(--text); }
.nav nav a[aria-current] { color: var(--text); text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: 8px; }

/* Hero */
.hero { position: relative; min-height: 92vh; display: grid; align-items: end; padding: 0 var(--inset) 12vh; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; }
/* The trailer source carries thin black side bars: the 1.08 scale crops them out */
.hero-bg video { width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; opacity: .6; filter: grayscale(.15); transform: scale(1.08); }
.hero-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, var(--bg) 6%, transparent 55%), linear-gradient(to right, rgba(12,12,13,.92), transparent 65%); }
.hero-content { position: relative; max-width: 760px; }
h1 { font: 600 clamp(46px, 8.4vw, 104px)/.95 var(--serif); letter-spacing: -.025em; text-wrap: balance; }
h2 { font: 600 clamp(30px, 4.5vw, 48px)/1.1 var(--serif); letter-spacing: -.01em; text-wrap: balance; }
.lede { font-size: clamp(17px, 2vw, 20px); color: var(--text-soft); margin: 24px 0 34px; max-width: 34em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* The one authored moment: the opening frame settles like a slow push-in ending */
@media (prefers-reduced-motion: no-preference) {
  .hero-bg video { animation: settle 2.6s var(--ease-out) both; }
  @keyframes settle { from { transform: scale(1.16); filter: grayscale(.15) brightness(.5); } }
}

.hero-toggle {
  position: absolute; right: var(--inset); bottom: 32px; z-index: 1;
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px;
  border: 1px solid var(--control); border-radius: 999px; background: rgba(12, 12, 13, .6); backdrop-filter: blur(6px);
  color: var(--text-soft); font-size: 13px; transition: border-color .2s, color .2s;
}
.hero-toggle[hidden] { display: none; }
.hero-toggle:hover { border-color: var(--text); color: var(--text); }
.hero-toggle .icon-play, .hero-toggle.paused .icon-pause { display: none; }
.hero-toggle.paused .icon-play { display: block; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 12px 22px; border-radius: 999px; font-weight: 500; font-size: 15px; transition: background-color .2s, border-color .2s, color .2s; }
.btn.primary { background: var(--accent-fill); color: #fff; }
.btn.primary:hover { background: var(--accent-fill-hover); }
.btn.ghost { border: 1px solid var(--control); }
.btn.ghost:hover { border-color: var(--text); }
.text-link { color: var(--text); text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 5px; transition: color .2s; }
.text-link:hover { color: var(--accent-text); }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 1fr; border-block: 1px solid var(--line); margin: 0 var(--inset); }
.stats div { padding: 26px 16px; text-align: center; }
.stats div + div { border-left: 1px solid var(--line); }
.stats strong { display: block; font: 600 32px var(--serif); font-variant-numeric: lining-nums tabular-nums; white-space: nowrap; }
.stats span { color: var(--muted); font-size: 14px; }

/* Sections */
.section { padding: clamp(72px, 10vw, 128px) var(--gutter); max-width: var(--content); margin: 0 auto; }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 12px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { min-height: 44px; padding: 8px 18px; border: 1px solid var(--control); border-radius: 999px; font-size: 14px; color: var(--text-soft); transition: color .2s, background-color .2s, border-color .2s; }
.chip:hover { color: var(--text); border-color: var(--text); }
.chip[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.grid-status { color: var(--muted); font-size: 14px; margin-bottom: 28px; }

/* Grid: one lead piece full width, two featured side by side, the rest three-up */
.grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 40px 24px; }
.card { position: relative; grid-column: span 2; }
.card.featured { grid-column: span 3; }
/* Lead: image beside its title, capped at 640 px because Hybris only exists as a 640 px thumbnail */
.card.lead { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 640px) 1fr; gap: 0 48px; align-items: end; }
.card.lead .meta { padding: 0 0 8px; }
.card[hidden] { display: none; }
.thumb { position: relative; aspect-ratio: 16/9; border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.thumb img { position: relative; width: 100%; height: 100%; object-fit: cover; transition: filter .4s var(--ease-out); }
/* Vertical videos: YouTube pads the thumbnail with black bars; show a blurred fill behind and mask the bars off the sharp image */
.thumb.pillar::before { content: ""; position: absolute; inset: 0; background: var(--fill) center / cover; filter: blur(18px) brightness(.5) saturate(1.2); transform: scale(2.9); }
.thumb.pillar img { -webkit-mask-image: linear-gradient(to right, transparent 31.4%, #000 31.6%, #000 68.4%, transparent 68.6%); mask-image: linear-gradient(to right, transparent 31.4%, #000 31.6%, #000 68.4%, transparent 68.6%); }
.card:hover .thumb img, .card:focus-within .thumb img { filter: brightness(1.12); }
.play-disc {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%;
  width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(12, 12, 13, .7); backdrop-filter: blur(6px); color: var(--text); font-size: 20px;
  transition: background-color .2s, color .2s, scale .3s var(--ease-out);
}
.card.lead .play-disc { width: 72px; height: 72px; font-size: 26px; }
.card:hover .play-disc, .card:focus-within .play-disc, .feature:hover .play-disc, .feature:focus-within .play-disc { background: var(--accent); color: #fff; scale: 1.06; }
.meta { padding-top: 14px; }
.badge { font-size: 13px; color: var(--accent-text); }
.meta h3 { font: 400 20px/1.25 var(--serif); margin: 2px 0 4px; text-wrap: balance; }
.card.featured .meta h3 { font-size: clamp(22px, 2.2vw, 28px); }
.card.lead .meta h3 { font-size: clamp(26px, 3vw, 38px); }
/* The title button covers the whole card, so the card is one click target with one accessible name */
.card-link::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.card-link:focus-visible { outline: none; }
.card-link:focus-visible::after { outline: 2px solid var(--accent); outline-offset: 6px; }
.meta p { display: flex; gap: 12px; color: var(--muted); font-size: 14px; }
.grid-foot { display: flex; flex-direction: column; align-items: center; gap: 20px; margin-top: 48px; }
.grid-foot .aside { color: var(--muted); font-size: 15px; text-align: center; }
.noscript { grid-column: 1 / -1; color: var(--text-soft); }

/* Atelier */
.atelier { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.atelier-intro > p { color: var(--text-soft); margin-top: 20px; max-width: 36em; }
.offers { margin-top: 28px; border-top: 1px solid var(--line); }
.offers li { padding: 18px 0; border-bottom: 1px solid var(--line); }
.offers h3 { font: 400 21px/1.3 var(--serif); }
.offers p { color: var(--muted); font-size: 15px; margin-top: 4px; max-width: 34em; }
.atelier-intro .tools { color: var(--muted); font-size: 14px; margin-top: 20px; }
.feature { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 16/9; }
.feature img { width: 100%; height: 100%; object-fit: cover; }
.play-cover { position: absolute; inset: 0; display: block; width: 100%; }
/* .feature clips overflow, so the focus ring is drawn inside the frame */
.play-cover:focus-visible { outline-offset: -4px; border-radius: var(--radius); }
.feature-cap { position: absolute; left: 16px; bottom: 14px; right: 16px; width: fit-content; font-size: 14px; padding: 6px 14px; background: rgba(12, 12, 13, .8); border-radius: 999px; }

/* About */
.about { display: grid; grid-template-columns: minmax(260px, 420px) 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.about p { font-size: 18px; color: var(--text-soft); margin-top: 20px; max-width: 36em; }
.about .quote { font: italic 400 clamp(22px, 2.4vw, 28px)/1.3 var(--serif); color: var(--accent-text); margin-top: 12px; }
.portrait img { width: 100%; aspect-ratio: 3/4; object-fit: cover; object-position: center top; border-radius: var(--radius); }
.portrait figcaption { margin-top: 10px; font-size: 14px; color: var(--muted); }

/* Contact */
.contact { text-align: center; border-top: 1px solid var(--line); }
.contact > p:first-of-type { color: var(--text-soft); font-size: 18px; margin: 16px 0 32px; }
.contact-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.contact-links { color: var(--muted); margin-top: 28px; }
footer { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; color: var(--muted); font-size: 14px; padding: 40px var(--inset) 32px; border-top: 1px solid var(--line); }
footer address { font-style: normal; line-height: 1.5; }
/* Discreet client access link (Synology portal), on the footer's axis under the address */
.footer-upload {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px;
  font-size: 13px; color: var(--muted); transition: color .2s;
}
.footer-upload .icon { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.footer-upload:hover { color: var(--text); }
.footer-upload + .footer-upload { margin-top: -12px; } /* Palm Studio, right under the cloud */

/* Player */
dialog { border: 0; padding: 0; background: transparent; color: var(--text); width: min(1100px, 94vw); margin: auto; }
dialog::backdrop { background: rgba(0, 0, 0, .94); backdrop-filter: blur(6px); }
.player-head { display: flex; align-items: center; gap: 16px; margin-bottom: 12px; }
#player-title { flex: 1; font: 400 20px/1.3 var(--serif); }
.player-yt { flex: none; display: inline-flex; align-items: center; min-height: 44px; font-size: 14px; }
.close { flex: none; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--control); font-size: 20px; transition: border-color .2s, background-color .2s; }
.close:hover { border-color: var(--text); background: var(--surface); }
.ratio { aspect-ratio: 16/9; border-radius: 10px; overflow: hidden; background: #000 center / cover no-repeat; }
.ratio.vertical { aspect-ratio: 9/16; height: min(78vh, 760px); width: auto; margin: 0 auto; }
.ratio iframe { width: 100%; height: 100%; border: 0; }

@media (max-width: 1000px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .card, .card.featured { grid-column: span 1; }
  .card.lead { display: block; grid-column: 1 / -1; }
  .card.lead .meta { padding-top: 14px; }
}

@media (max-width: 760px) {
  .nav { gap: 12px; }
  /* Phones: the AA monogram alone; the wordmark does not fit at a legible size beside four links */
  .logo-word { display: none; }
  .logo-mark { width: 36px; height: 36px; }
  .nav nav { gap: 8px; font-size: 13px; }
  .lang { display: none; }
  .lang-menu { display: block; }
  .nav nav a { white-space: nowrap; }
  .hero { min-height: 88svh; }
  .hero-bg video { object-position: 40% 40%; opacity: .7; }
  .hero-bg::after { background: linear-gradient(to top, var(--bg) 12%, rgba(12,12,13,.35) 60%, rgba(12,12,13,.55)); }
  .hero-toggle { padding: 0; width: 44px; justify-content: center; }
  .hero-toggle .toggle-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats div:nth-child(3) { border-left: 0; }
  .stats div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .grid { grid-template-columns: 1fr; }
  .atelier, .about { grid-template-columns: 1fr; }
  .player-head { flex-wrap: wrap; }
  #player-title { flex-basis: calc(100% - 64px); font-size: 18px; }
  .player-yt { order: 3; }
  .feature-cap { border-radius: 10px; }
  .cap-extra { display: none; }
}

@media (max-width: 360px) {
  .nav { gap: 8px; }
  .logo-mark { width: 32px; height: 32px; }
  .nav nav { gap: 5px; font-size: 12px; }
  .lang-menu { margin-left: 2px; }
}
