:root {
  --header-height: 54px;
  --page-bg: #0b0b0b;
  --text: #f4f4f2;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-height); }
body {
  margin: 0;
  overflow-x: hidden;
  background: var(--page-bg);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
}
a { color: inherit; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 8px;
  left: 8px;
  transform: translateY(-160%);
  padding: 10px 14px;
  background: #fff;
  color: #000;
}
.skip-link:focus { transform: none; }

.site-header {
  position: fixed;
  z-index: 40;
  inset: 0 0 auto;
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 2.1vw;
  overflow: hidden;
  border-bottom: 1px solid rgba(255,255,255,.12);
  background: #050505;
  color: rgba(255,255,255,.82);
  font-size: 9px;
  letter-spacing: .08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.site-header a { text-decoration: none; }
.site-header nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(12px, 1.75vw, 30px);
  overflow-x: auto;
  scrollbar-width: none;
}
.site-header nav::-webkit-scrollbar { display: none; }
.site-header nav a { opacity: .62; transition: opacity .2s ease; }
.site-header nav a:hover,
.site-header nav a:focus-visible,
.site-header nav a.is-active { opacity: 1; }

main { padding-top: var(--header-height); }
[data-section] { scroll-margin-top: var(--header-height); }

.frame-pair { position: relative; height: 180vh; }
.hold-frame { position: relative; height: 190vh; }
.sticky-frame {
  position: sticky;
  top: var(--header-height);
  height: calc(100vh - var(--header-height));
  overflow: hidden;
  background: #fff;
}
.frame-pair--dark .sticky-frame,
.hold-frame--dark .sticky-frame { background: #050505; }
.frame-pair--light .sticky-frame,
.single-frame--light { background: #f5f3ef; }

.frame {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  user-select: none;
  -webkit-user-drag: none;
}
.frame > img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  user-select: none;
  -webkit-user-drag: none;
}
.frame-a { opacity: 1; }
.frame-b {
  opacity: 0;
  transform: scale(1.006);
  will-change: opacity, transform;
}

.single-frame {
  position: relative;
  height: calc(100vh - var(--header-height));
  min-height: 506px;
  overflow: hidden;
}

.interaction-layer {
  position: absolute;
  z-index: 5;
  left: 50%;
  top: 50%;
  width: min(100%, calc((100vh - var(--header-height)) * 16 / 9));
  height: min(100%, calc(100vw * 9 / 16));
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.interaction-layer a { pointer-events: auto; cursor: pointer; }
.interaction-layer a:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }

.contact-hotspot {
  position: absolute;
  left: 4.55%;
  top: 80.25%;
  width: 13.55%;
  height: 7.15%;
  display: block;
  background: transparent;
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(255,255,255,.12);
}

.elsewhere-layout {
  color: #111;
  font-family: Georgia, "Times New Roman", serif;
}
.elsewhere-paper {
  position: absolute;
  inset: 0;
  background: #fdfdfc;
  clip-path: polygon(0 0, 60.35% 0, 73.55% 100%, 0 100%);
}
.elsewhere-content { position: absolute; inset: 0; pointer-events: none; }
.elsewhere-content a { pointer-events: auto; }
.elsewhere-kicker,
.elsewhere-thanks,
.elsewhere-bio { margin: 0; }
.elsewhere-kicker {
  position: absolute;
  left: 7.35%;
  top: 7.8%;
  font-size: clamp(14px, 1.28vw, 25px);
  line-height: 1;
}
.elsewhere-links {
  position: absolute;
  left: 7.35%;
  top: 17.2%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: clamp(19px, 3.4vh, 37px);
}
.elsewhere-links a {
  display: inline-block;
  color: #111;
  font-size: clamp(28px, 2.65vw, 51px);
  line-height: .98;
  text-decoration-line: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: .32em;
  text-decoration-color: rgba(17,17,17,.55);
}
.elsewhere-links a:hover,
.elsewhere-links a:focus-visible { text-decoration-color: currentColor; }
.elsewhere-thanks {
  position: absolute;
  left: 7.35%;
  top: 54.7%;
  font-size: clamp(12px, 1.02vw, 20px);
  line-height: 1.2;
  font-style: italic;
}
.elsewhere-bio {
  position: absolute;
  left: 7.35%;
  top: 66.1%;
  width: 31.5%;
  color: rgba(30,30,30,.57);
  font-size: clamp(10px, .78vw, 15px);
  line-height: 1.55;
  letter-spacing: .002em;
}
.elsewhere-bio p { margin: 0; }
.elsewhere-bio p + p { margin-top: 1.45em; }

.progress {
  position: fixed;
  z-index: 45;
  right: 0;
  top: var(--header-height);
  width: 2px;
  height: calc(100vh - var(--header-height));
  background: rgba(255,255,255,.16);
}
.progress span { display: block; width: 100%; height: 0; background: #fff; }

@media (max-width: 760px) {
  :root { --header-height: 48px; }
  .site-header { padding: 0 14px; gap: 18px; }
  .brand { flex: 0 0 auto; }
  .site-header nav { justify-content: flex-start; }
  .frame-pair { height: 150vh; }
  .hold-frame { height: 165vh; }
  .single-frame { height: calc(100vh - var(--header-height)); min-height: 312px; }
}

/* Content-sized ending for phones and compact landscape screens. */
@media (max-width: 760px), (max-width: 920px) and (max-height: 520px) {
  #elsewhere.single-frame {
    height: auto;
    min-height: calc(100svh - var(--header-height));
    overflow: hidden;
    background: #fdfdfc;
  }
  #elsewhere > .frame { position: absolute; inset: 0; }
  #elsewhere > .frame > img { object-fit: cover; object-position: 78% center; }
  #elsewhere .interaction-layer.elsewhere-layout {
    position: relative;
    left: auto;
    top: auto;
    width: 100%;
    height: auto;
    min-height: calc(100svh - var(--header-height));
    transform: none;
  }
  #elsewhere .elsewhere-paper { clip-path: polygon(0 0, 72% 0, 88% 100%, 0 100%); }
  #elsewhere .elsewhere-content {
    position: relative;
    inset: auto;
    min-height: calc(100svh - var(--header-height));
    padding: clamp(28px, 6.5vh, 54px) 7.35% clamp(30px, 6vh, 52px);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }
  #elsewhere .elsewhere-kicker,
  #elsewhere .elsewhere-links,
  #elsewhere .elsewhere-thanks,
  #elsewhere .elsewhere-bio { position: static; }
  #elsewhere .elsewhere-kicker {
    margin-bottom: clamp(30px, 7vh, 58px);
    font-size: clamp(11px, 3.2vw, 15px);
    line-height: 1;
  }
  #elsewhere .elsewhere-links { gap: clamp(18px, 4.2vh, 32px); }
  #elsewhere .elsewhere-links a { font-size: clamp(25px, 7.2vw, 38px); line-height: 1; }
  #elsewhere .elsewhere-thanks {
    margin-top: clamp(42px, 8vh, 76px);
    font-size: clamp(11px, 3vw, 15px);
    line-height: 1.25;
  }
  #elsewhere .elsewhere-bio {
    width: min(68%, 360px);
    margin-top: auto;
    padding-top: clamp(54px, 10vh, 100px);
    font-size: clamp(9px, 2.35vw, 12px);
    line-height: 1.52;
  }
  #elsewhere .elsewhere-bio p + p { margin-top: 1.25em; }
}

@media (max-width: 920px) and (max-height: 520px) and (orientation: landscape) {
  #elsewhere .elsewhere-content { min-height: 500px; padding-top: 24px; padding-bottom: 28px; }
  #elsewhere .elsewhere-kicker { margin-bottom: 22px; font-size: 11px; }
  #elsewhere .elsewhere-links { gap: 13px; }
  #elsewhere .elsewhere-links a { font-size: 24px; }
  #elsewhere .elsewhere-thanks { margin-top: 30px; font-size: 11px; }
  #elsewhere .elsewhere-bio { width: min(48%, 360px); padding-top: 44px; font-size: 9px; line-height: 1.45; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .frame-b { transform: none; }
  .site-header nav a { transition: none; }
}
