:root {
  --fg: #ededea;
  --mid: #9a9a96;
  --dim: #5e5e5b;
  --dimmer: #3f3f3d;
  --line: #3a3a38;
  --shadow: 0 0 8px #000000e6;
  /* Clear of a phone's notch, rounded corners and home indicator. */
  --pad-x: max(clamp(24px, 8.9vw, 128px), env(safe-area-inset-left) + 16px, env(safe-area-inset-right) + 16px);
  --pad-top: max(clamp(28px, 7.1vh, 64px), env(safe-area-inset-top) + 12px);
  --pad-bottom: max(24px, env(safe-area-inset-bottom) + 12px);
  --font: Helvetica, "Helvetica Neue", Arial, sans-serif;
  --s: 1;
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  background: #000;
  color: var(--fg);
}

body {
  font: 300 16px/24px var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  font-synthesis: none;
  overflow-x: hidden;
}

::selection {
  background: var(--fg);
  color: #000;
}

a {
  color: inherit;
  text-decoration: underline 1px #ededea4d;
  text-underline-offset: .24em;
  transition: color .3s, opacity .3s, text-decoration-color .3s;
}

a:hover {
  color: #fff;
  text-decoration-color: #ededeab3;
}

:focus-visible {
  outline: 1px solid var(--fg);
  outline-offset: 4px;
}

.caps {
  font: 400 11px/20px var(--font);
  letter-spacing: .05em;
  text-transform: uppercase;
}

.mid {
  color: var(--mid);
}

/* Scene: one full-viewport frame; everything inside is absolutely placed. */

.scene {
  position: relative;
  height: 100vh;
  overflow: clip;
}

.core-glow,
.still,
.galaxy,
.defs {
  position: absolute;
  pointer-events: none;
}

/* Hidden until JS has placed it, so it never visibly jumps into position. */
.core-glow {
  z-index: 2;
  width: calc(var(--s) * 460px);
  height: calc(var(--s) * 350px);
  background: radial-gradient(closest-side, #ffffff10, #ffffff05 50%, transparent);
  transform: translate(-50%, -50%) rotate(-24deg);
  opacity: 0;
  transition: opacity .6s ease;
}

.still {
  mix-blend-mode: screen;
  z-index: 3;
  display: none;
}

.no-webgl .still {
  display: block;
}

.galaxy {
  z-index: 3;
  inset: 0;
  width: 100%;
  height: 100%;
}

.defs {
  width: 0;
  height: 0;
}

/* Text */

.intro {
  position: absolute;
  z-index: 5;
  top: var(--pad-top);
  left: var(--pad-x);
  width: 264px;
  max-width: calc(100vw - 2 * var(--pad-x));
  font-size: 13px;
  line-height: 19px;
}

.name {
  font-size: inherit;
  font-weight: 700;
}

.bio {
  margin-top: 4px;
  text-shadow: var(--shadow);
  text-wrap: pretty;
}

/* A label in small caps, then icon links that fill to a white chip on hover or focus. */
.follow,
.contact {
  display: flex;
  align-items: center;
  gap: 8px;
  font: 400 11px/20px var(--font);
  letter-spacing: .05em;
  text-transform: uppercase;
  white-space: nowrap;
  text-shadow: var(--shadow);
}

.follow {
  margin-top: 14px;
}

/* The icon chips overhang the line instead of opening it up. */
.icon-links {
  display: flex;
  margin-block: -3.5px;
}

.icon-links a {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: var(--mid);
  transition: color .2s ease, background-color .2s ease;
}

.icon-links a:is(:hover, :focus-visible) {
  background: var(--fg);
  color: #000;
}

.icon-links svg {
  width: 12px;
  height: 12px;
  fill: currentColor;
}

/* The bottom row: Find me at on the left, the place and time on the right, set alike. */
.contact,
.clock {
  position: absolute;
  z-index: 5;
  bottom: clamp(24px, 8.4vh, 76px);
}

.contact {
  left: var(--pad-x);
}

.clock {
  right: var(--pad-x);
  display: flex;
  gap: 12px;
  color: var(--mid);
  font-variant-numeric: tabular-nums;
}

.clock .place {
  color: var(--fg);
}

/* The mark answers hover and focus; there is nothing to click through to. */
.star[data-action="mark"] {
  cursor: default;
}

/* Stars */

.sky {
  position: absolute;
  z-index: 4;
  inset: 0;
  pointer-events: none;
}

.core-label,
.star {
  position: absolute;
  pointer-events: auto;
}

.core-label {
  display: flex;
  flex-direction: column;
  white-space: nowrap;
  text-shadow: var(--shadow);
}

.core-label .m,
.star .rest .m {
  color: var(--mid);
}

.core-label span,
.star .rest span {
  transition: color .5s ease;
}

.star {
  /* JS moves each star along its orbit with a transform. */
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  color: var(--fg);
  text-decoration: none;
  outline: none;
  will-change: transform;
}

/* A caption changing sides fades out and back in; one with no room fades out
   until it has some, and lets the pointer through to whatever it would cover. */
.star.is-flipping .rest {
  opacity: 0;
  transition-duration: .2s;
}

.star.is-hushed .rest {
  opacity: 0;
  pointer-events: none;
}

/* The lit star, its caption and hologram paint over the other stars. */
.star.is-active {
  z-index: 1;
}

.star::before {
  content: "";
  position: absolute;
  left: -32px;
  top: -32px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
}

.mark {
  position: absolute;
  left: -40px;
  top: -40px;
  width: 80px;
  height: 80px;
  overflow: visible;
}

.mark * {
  transform-box: fill-box;
  transform-origin: center;
  transition: opacity .5s ease, transform .6s cubic-bezier(.2, .7, .2, 1);
}

/* Stepped: a slow breath reads the same at 6 updates a second as at 60, for a tenth of the work. */
.glow {
  transform: scale(.68);
  animation: breathe 5.5s steps(33) infinite alternate;
}

.star:nth-of-type(2) .glow { animation-delay: -1.8s; }
.star:nth-of-type(3) .glow { animation-delay: -3.6s; }

@keyframes breathe {
  from { opacity: .72; }
  to { opacity: 1; }
}

.cross {
  stroke: var(--fg);
  stroke-width: .8;
  opacity: .38;
  /* Short ticks at rest; full length once the star is lit. */
  transform: scale(.43);
  vector-effect: non-scaling-stroke;
}

.dot {
  fill: #fff;
}

/* The film's whole marker blinks, like a camera's recording light, until it
   or another star is lit. */
.star[data-action="film"] .mark {
  animation: blink 1.6s ease-in-out infinite;
  will-change: opacity;
}

.star[data-action="film"].is-active .mark,
.has-active .star[data-action="film"] .mark {
  animation: none;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: .12; }
}

/* Lock-on reticle around the lit star. */

.ring {
  fill: none;
  stroke: var(--fg);
  stroke-width: 1;
  opacity: 0;
  transform: scale(.55);
}

.reticle {
  opacity: 0;
  scale: .6;
  transition: opacity .4s ease, scale .7s cubic-bezier(.2, .7, .2, 1);
}

.seg,
.tickring,
.lock {
  fill: none;
  stroke: var(--fg);
}

.seg {
  stroke-width: 1.4;
  stroke-dasharray: 17 8;
  opacity: .85;
  animation: spin 14s linear infinite;
}

.tickring {
  stroke-width: 2.4;
  stroke-dasharray: .4 2.6;
  opacity: .45;
  animation: spin 36s linear infinite reverse;
}

.lock {
  stroke-width: 1;
  opacity: .7;
}

@keyframes spin {
  to { rotate: 360deg; }
}

/* Hologram: the work, projected from its star. JS sizes the panel and aims the perspective lines. */

.holo {
  position: absolute;
  left: 0;
  top: 0;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, visibility 0s linear .25s;
}

.beam {
  position: absolute;
  overflow: visible;
}

/* Perspective lines, as dots, from the reticle to all four corners of the panel. */
.beam line {
  stroke: var(--fg);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-dasharray: 0 5;
  opacity: .5;
}

.holo-panel {
  position: absolute;
  display: block;
  border: 1px solid #ededea80;
  box-shadow: 0 0 32px #ffffff1c, inset 0 0 28px #ffffff10;
  transform: perspective(1600px) rotateY(var(--tilt));
  transform-origin: var(--origin) center;
}

/* Zero-size markers on the panel's corners; JS reads where the tilt puts them. */
.holo-panel .corner {
  position: absolute;
  width: 0;
  height: 0;
}

.corner.tl { left: 0; top: 0; }
.corner.tr { right: 0; top: 0; }
.corner.bl { left: 0; bottom: 0; }
.corner.br { right: 0; bottom: 0; }

.star[data-side="right"] .holo-panel {
  --tilt: 10deg;
  --origin: left;
  --wipe: inset(0 100% 0 0);
}

.star[data-side="left"] .holo-panel {
  --tilt: -10deg;
  --origin: right;
  --wipe: inset(0 0 0 100%);
}

.holo-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 7px;
  font: 400 9px/12px var(--font);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #ededeab3;
  white-space: nowrap;
}

.holo-time {
  font-variant-numeric: tabular-nums;
}

.holo-screen {
  position: absolute;
  inset: 0;
  display: block;
  overflow: hidden;
}

.holo-screen::before,
.holo-screen::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  pointer-events: none;
}

.holo-screen::before {
  background: repeating-linear-gradient(to bottom, #ffffff12 0 1px, transparent 1px 3px);
}

.holo-screen::after {
  background: linear-gradient(to bottom, transparent 40%, #ffffff17 50%, transparent 60%) 0 100% / 100% 300%;
  animation: sweep 4.2s linear infinite;
}

@keyframes sweep {
  to { background-position: 0 0; }
}

.holo-media {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .9;
  /* Clicks on a <video> don't follow its link; let them land on the panel. */
  pointer-events: none;
}

.holo-progress {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  margin-top: 9px;
  height: 5px;
  background: repeating-linear-gradient(to right, #ededea40 0 1px, transparent 1px 5px);
}

.holo-progress span {
  display: block;
  height: 100%;
  clip-path: inset(0 100% 0 0);
  background: repeating-linear-gradient(to right, var(--fg) 0 1px, transparent 1px 5px);
}

.holo-panel .b {
  position: absolute;
  width: 14px;
  height: 14px;
  border: 0 solid var(--fg);
}

.b.tl { left: -6px; top: -6px; border-top-width: 1px; border-left-width: 1px; }
.b.tr { right: -6px; top: -6px; border-top-width: 1px; border-right-width: 1px; }
.b.bl { left: -6px; bottom: -6px; border-bottom-width: 1px; border-left-width: 1px; }
.b.br { right: -6px; bottom: -6px; border-bottom-width: 1px; border-right-width: 1px; }

.label {
  position: absolute;
  display: flex;
  flex-direction: column;
  white-space: nowrap;
  text-shadow: var(--shadow);
  transition: opacity .35s ease, transform .5s cubic-bezier(.2, .7, .2, 1);
}

.star[data-side="left"] .label {
  right: 36px;
  align-items: flex-end;
  text-align: right;
}

.star[data-side="right"] .label {
  left: 36px;
  align-items: flex-start;
}

/* With no room beside it, a resting caption centres above or below its star,
   or hangs to one side: above-left ends just past the star. */
.star:is([data-side="above"], [data-side="below"]) .label {
  left: 0;
  translate: -50% 0;
  align-items: center;
  text-align: center;
}

.star[data-side$="-left"] .label {
  right: -10px;
  align-items: flex-end;
  text-align: right;
}

.star[data-side$="-right"] .label {
  left: -10px;
  align-items: flex-start;
}

.star[data-side^="above"] .rest {
  top: auto;
  bottom: 22px;
}

.star[data-side^="below"] .rest {
  top: 22px;
}

/* On a phone a long name takes two lines, so it fits beside its star. The
   caption hangs off a zero-width star, so it needs an explicit width to wrap at. */
.is-narrow .rest .t {
  width: max-content;
  max-width: 156px;
  white-space: normal;
}

.rest {
  top: -20px;
}

/* Lit caption: a small-caps eyebrow, the title large in sentence case with
   tight tracking, then the action. The title's first line sits level with the star. */
.open {
  top: -43px;
  opacity: 0;
  transform: translateY(5px);
  pointer-events: none;
}

/* JS sets the caption's offset to keep it clear of the hologram and its perspective lines. */
.star[data-holo] .open {
  top: var(--caption-y);
}

.open .m {
  color: var(--mid);
}

.open .title {
  margin-top: 2px;
  font: 300 32px/34px var(--font);
  letter-spacing: -.02em;
}

.open .cta {
  margin-top: 8px;
}

/* Drawn, since Helvetica has no ▶ and the fallback glyph sits heavy and low. */
.cta-play::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 8px;
  margin-right: 8px;
  background: currentColor;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

/* Active star: bigger glow, the reticle, open label; everything else steps back. */

.star.is-active .glow {
  transform: scale(1);
}

.star.is-active .cross {
  opacity: .55;
  transform: none;
}

.star.is-active .rest {
  opacity: 0;
}

.star.is-active .open {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.star.is-active .ring {
  opacity: .6;
  transform: scale(1);
}

.star.is-active .reticle {
  opacity: 1;
  scale: 1;
}

.star.is-active .holo {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transition: opacity .25s ease, visibility 0s;
}

.star.is-active .holo-panel {
  animation: holo-flicker .5s linear both;
}

.star.is-active .holo-screen {
  animation: holo-wipe .6s cubic-bezier(.2, .7, .2, 1) both;
}

@keyframes holo-flicker {
  0% { opacity: 0; }
  10% { opacity: .85; }
  18% { opacity: .2; }
  30% { opacity: .95; }
  38% { opacity: .45; }
  52%, 100% { opacity: 1; }
}

@keyframes holo-wipe {
  from { clip-path: var(--wipe); }
  to { clip-path: inset(0); }
}

.has-active .star:not(.is-active) .dot {
  opacity: .4;
}

.has-active .star:not(.is-active) .cross {
  opacity: .2;
}

.has-active .star:not(.is-active) .glow {
  opacity: .55;
  animation: none;
}

.has-active .star:not(.is-active) .rest .t,
.has-active .core-label .t {
  color: var(--dim);
}

.has-active .star:not(.is-active) .rest .m,
.has-active .core-label .m {
  color: var(--dimmer);
}

/* Entrance: the words fade up as soon as the page paints, without waiting for
   the script; the stars and the core's label wait until it has placed them. */

[data-reveal] {
  animation: reveal .9s cubic-bezier(.2, .7, .2, 1) var(--d, 0s) backwards;
}

@keyframes reveal {
  from {
    opacity: 0;
    translate: 0 6px;
  }
}

.sky [data-reveal] {
  animation: none;
  opacity: 0;
  translate: 0 6px;
  transition: opacity .9s ease var(--d, 0s), translate .9s cubic-bezier(.2, .7, .2, 1) var(--d, 0s);
}

.is-ready .sky [data-reveal] {
  opacity: 1;
  translate: 0 0;
}

.is-ready .core-glow {
  opacity: 1;
}

/* Parts that only show on a lit star only move while it is lit. */
.star:not(.is-active) :is(.seg, .tickring),
.star:not(.is-active) .holo-screen::after {
  animation-play-state: paused;
}

.has-media :is(.core-glow, .still) {
  opacity: .45;
}

/* The mark forms over the core: its label steps aside until the stars let go.
   As specific as the entrance rule it follows, so it wins. */
.has-form .sky .core-label {
  opacity: 0;
  transition: opacity .4s ease;
}

/* When a caption takes the core label's spot, the label fades out, moves to a
   clear spot and fades back in. */
.core-label span {
  transition-duration: .25s;
}

.core-label.is-hushed :is(.t, .m) {
  color: transparent;
}

/* The galaxy's words fade out once a screen covers them, and back in as it
   shrinks away. */
.scene :is(.intro, .contact, .clock, .sky) {
  transition: opacity .3s ease;
}

.screen-open .scene :is(.intro, .contact, .clock, .sky) {
  opacity: 0;
}

/* Screens: the film, and ashler.com sped up. A screen opens out of its star
   as a widening circle (JS clips .screen-body), so the dialog itself is bare. */

.screen {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  padding: 0;
  border: 0;
  background: none;
  color: var(--fg);
  overflow: hidden;
  --ratio: 16 / 9;
}

#website,
#product {
  --ratio: 16 / 10;
}

/* The mark's screen is a square of open sky: no frame, just its stars. */
#mark {
  --ratio: 1 / 1;
}

#mark .player {
  border: 0;
  background: none;
}

.mark-stars {
  display: block;
  width: 100%;
  height: 100%;
}

.screen-body {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  overflow-y: auto;
  background: #000000d6;
}

.screen::backdrop {
  background: transparent;
}

.screen-top {
  position: absolute;
  top: var(--pad-top);
  left: var(--pad-x);
  right: var(--pad-x);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.screen-id {
  font-size: 13px;
  line-height: 19px;
}

.screen-id .name {
  margin-bottom: 4px;
}

/* Line-drawn glyphs: Helvetica has no arrows, and phones swap the fallback
   ↗ for an emoji. */
.glyph {
  width: 7px;
  height: 7px;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-width: 1px;
  stroke-linecap: square;
  vector-effect: non-scaling-stroke;
}

.close {
  border: 0;
  background: none;
  color: var(--fg);
  text-decoration: underline 1px #ededea4d;
  text-underline-offset: .24em;
  white-space: nowrap;
  cursor: pointer;
  transition: color .3s, text-decoration-color .3s;
}

.close:hover {
  color: #fff;
  text-decoration-color: #ededeab3;
}

.close .glyph {
  margin-right: 8px;
}

.screen-main {
  width: min(912px, calc(100vw - 2 * var(--pad-x)), calc((100vh - 320px) * var(--ratio)));
  margin-top: 40px;
}

/* Set like a lit star's caption: the eyebrow, then the title. */
.screen-head {
  margin-bottom: 20px;
}

.screen-title {
  margin-top: 2px;
  font: 300 32px/34px var(--font);
  letter-spacing: -.02em;
}

.player {
  position: relative;
  aspect-ratio: var(--ratio);
  border: 1px solid var(--line);
  background: #000;
  overflow: hidden;
}

.play {
  position: absolute;
  inset: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

.play img,
.screen-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.play img {
  transition: filter .5s ease;
}

.play:hover img {
  filter: brightness(1.08);
}

.play-icon {
  position: absolute;
  left: 7.9%;
  bottom: 5.8%;
  width: clamp(48px, 8.3%, 76px);
  height: auto;
  transition: transform .5s cubic-bezier(.2, .7, .2, 1);
}

.play:hover .play-icon {
  transform: scale(1.06);
}

.player iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.screen-links {
  display: flex;
  justify-content: space-between;
  gap: 16px 28px;
  margin-top: 19px;
}

.screen-links nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 28px;
}

.screen-links .glyph {
  margin-left: 7px;
}

/* The warp's streaking stars, drawn over the screen as it opens or closes. */
.warp {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* Discourage saving: no dragging, long-press menus or selecting the media. */
img,
video,
canvas,
.star {
  -webkit-touch-callout: none;
  -webkit-user-drag: none;
  user-select: none;
}

/* Narrow screens: words on top, the galaxy below. */

.is-narrow .intro {
  width: 300px;
  font-size: 14px;
  line-height: 21px;
}

/* Phones keep the top for the words and bring the bottom row down; without
   room for both ends, Find me at steps out. */
.is-narrow :is(.contact, .clock) {
  bottom: var(--pad-bottom);
}

.is-narrow .contact.is-tight .lead {
  display: none;
}

/* With the label gone, the first glyph lines up with the text above. */
.is-narrow .contact.is-tight .icon-links {
  margin-left: -7px;
}

/* A long title takes two lines beside its star; the caption hangs off a
   zero-width star, so it needs an explicit width to wrap at. */
.is-narrow .open .title {
  width: max-content;
  max-width: 210px;
  font-size: 22px;
  line-height: 26px;
  white-space: normal;
}

.is-narrow .star .open {
  top: -35px;
}

/* On a phone the mark forms right beside its star: its caption sits centred
   under the mark, and the other captions step out of its way. */
.is-narrow .star[data-side="core"] .open {
  left: var(--caption-x);
  top: var(--caption-y);
  translate: -50% 0;
  align-items: center;
  text-align: center;
}

.is-narrow.has-form .star:not(.is-active) .rest {
  opacity: 0;
}

.is-narrow .holo-panel {
  --tilt: 0deg;
}

.is-narrow .beam {
  display: none;
}

/* On a phone a screen gets the whole view: no title block, the way back on one line. */
.is-narrow .screen-top {
  position: static;
  justify-content: flex-end;
  padding: var(--pad-top) var(--pad-x) 0;
}

.is-narrow .screen-id {
  display: none;
}

.is-narrow .screen-body {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.is-narrow .screen-main {
  width: auto;
  margin: auto var(--pad-x);
}

.is-narrow .screen-title {
  font-size: 24px;
  line-height: 28px;
}

.is-narrow .screen-links {
  flex-direction: column;
  gap: 6px;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition-duration: 0s !important;
    transition-delay: 0s !important;
  }
}
