/* Put the veil on the scene so it never dims editorial type or media. */
[data-mb-universe] { pointer-events: none; isolation: isolate; }
[data-mb-universe]::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(11,11,11,.64), rgba(11,11,11,.46) 40%, rgba(11,11,11,.22) 70%, rgba(11,11,11,.14));
  transition: opacity .7s ease;
}
[data-mb-universe="film"]::after { opacity: 0; transition: none; }
#scene[data-mb-universe] + .vignette { background: none; }
/* The observation stays exposed in the gutters and between exhibits.
   The dark backing travels with the actual type as the grid reflows. */
main :is(h1,h2,h3,.lede,.hero-controls,.feat-meta,.chapter-intro,.tool-index,
  .creation > summary,.caption,figcaption,.asset-kind,.facts,.audit-proof,
  .evidence-table,.sheet-prompt,.prose,.routes,.chapter-no,.eyebrow,.case-meta) {
  position: relative;
  isolation: isolate;
}
main :is(h1,h2,h3,.lede,.hero-controls,.feat-meta,.chapter-intro,.tool-index,
  .creation > summary,.caption,figcaption,.asset-kind,.facts,.audit-proof,
  .evidence-table,.sheet-prompt,.prose,.routes,.chapter-no,.eyebrow,.case-meta)::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -10px -14px;
  background: rgba(11,11,11,.83);
  filter: blur(7px);
  pointer-events: none;
}
.hero-controls, .work :is(.eyebrow,.discipline-title,.feat-meta) { width: fit-content; max-width: 100%; }
@media (min-width: 641px) {
  .feat:nth-child(even) .feat-meta { justify-self: end; }
}
.hero :is(.display,.lede,.hero-controls)::before {
  inset: -18px max(-22px, calc(-1 * var(--gutter)));
  filter: blur(14px);
}
.universe-control { display: inline-flex; align-items: center; gap: .75rem; align-self: flex-start; font-size: .875rem; color: var(--text-2); }
.universe-control select { background: var(--void); color: var(--text); font: inherit; border: 1px solid currentColor; padding: .3em .5em; }
body:has(#scene.scene-fallback) .universe-control { visibility: hidden; }
#scene.scene-fallback, [data-mb-universe].scene-fallback { background: radial-gradient(ellipse at 70% 30%, #16161b, #0b0b0b 70%); }
[data-mb-still]::after { transition: none; }
@media (prefers-reduced-motion: reduce) {
  [data-mb-universe]::after { transition: none; }
}

/* The homepage keeps the original applications' and cases' presentation independent. */
#work :is(.eyebrow,.discipline-title,.feat-meta,figcaption)::before {
  inset: -42% -6%;
  background: radial-gradient(ellipse closest-side, rgba(6,5,12,.54) 25%, rgba(6,5,12,.29) 70%, transparent);
  filter: blur(9px);
  border-radius: 50%;
}
#work .feat-title { text-shadow: none; }
#work .work-cover { display: grid; width: 100%; justify-items: center; }
#work .feat-meta:hover .feat-title, #work .feat-meta:focus-visible .feat-title {
  text-decoration: underline;
  text-decoration-thickness: .045em;
  text-underline-offset: .1em;
}
#work .feat-link.has-film .frame { transform: none; }
#work .feat-link.has-film .frame::after { content: none; }
#work .work-film { width: 100%; background: #100e11; }
#work .work-phone {
  position: relative;
  width: min(74%, calc(68svh * 564 / 1173), 335px);
  aspect-ratio: 564/1173;
  isolation: isolate;
}
#work .work-phone::before {
  content: "";
  position: absolute;
  inset: 1.4% 2%;
  border-radius: 13% / 6%;
  background: #0c090b;
}
#work .work-phone .frame {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 91.8%;
  height: auto;
  max-height: 94%;
  aspect-ratio: 9/16;
}
#work .work-phone video { position: absolute; inset: 0; object-fit: contain; }
#work .work-phone .work-hardware {
  position: absolute;
  inset: 0;
  pointer-events: none;
  filter: sepia(1) saturate(4) hue-rotate(291deg) brightness(.53);
}
@media (max-width: 640px) {
  #work .work-phone { width: min(67vw, calc(64svh * 564 / 1173)); }
}

/* Tint the case while keeping the camera and sensor glass neutral. */
#work :is(.work-phone,.exhibit-phone)::after {
  content: "";
  position: absolute;
  inset: 0;
  background: url("media/atelier/iphone-frame.png") center / 100% 100% no-repeat;
  clip-path: inset(5% 29% 86% 29%);
  pointer-events: none;
}
