/* Small details in the margins of the original academic page. */
.no-js .space-trail { display: none; }
.email-copy-mark { margin-left: 2px; font-size: 12px; opacity: .5; }
[data-copy-email]:hover .email-copy-mark, [data-copy-email]:focus-visible .email-copy-mark { opacity: 1; }
.sidebar [data-copy-email] { display: inline; color: inherit; }
.personal-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; overflow: hidden; pointer-events: none; }
.personal-progress > span { display: block; height: 100%; background: rgba(255, 255, 255, .7); transform: scaleX(0); transform-origin: left; }

/* The dotted arm and hand belong to the white page edge above the footer. */
body.has-robot-study { padding-bottom: 280px; }
.robot-study { position: absolute; right: max(18px, calc((100vw - 1800px) / 2 + 18px)); bottom: 100%; width: 360px; margin: 0; pointer-events: none; user-select: none; }
.robot-study__drawing { display: block; width: 100%; height: auto; }

/* Read down to climb; read back up to return to the launch pad. */
.space-trail { position: fixed; right: max(28px, calc((100vw - 1800px) / 2 + 28px)); top: 136px; width: 56px; height: min(480px, calc(100dvh - 420px)); z-index: 12; pointer-events: none; color: #917aa2; }
.space-trail__moon { position: absolute; left: 17px; top: -35px; width: 23px; height: 23px; }
.space-trail__moon svg, .space-trail__pad svg { display: block; width: 100%; height: 100%; }
.space-trail__line { position: absolute; left: 27px; top: 0; bottom: 0; width: 1px; background: repeating-linear-gradient(to bottom, #ded2e6 0 2px, transparent 2px 9px); }
.space-trail__pad { position: absolute; left: -2px; bottom: -8px; width: 60px; height: 19px; }
.space-trail__dust { opacity: 0; }
.space-trail.is-launching .space-trail__dust { opacity: .8; }
.space-return { position: absolute; left: 0; top: 0; width: 56px; height: 92px; padding: 0; border: 0; background: transparent; pointer-events: auto; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.space-return:focus-visible { outline: 2px solid #5a1a8a; outline-offset: 4px; border-radius: 4px; }
.space-rocket { display: block; width: 100%; height: 100%; overflow: visible; transform: rotate(var(--space-tilt, 0deg)); transform-origin: 50% 70%; transition: transform .2s ease-out; filter: drop-shadow(0 2px 1px #59377515); }
.space-rocket__flame { opacity: 0; transform: scaleY(var(--space-thrust, .6)); transform-box: fill-box; transform-origin: top; transition: opacity .2s; }
.space-trail.is-flying .space-rocket__flame { opacity: .9; }
.space-trail.is-descending .space-rocket__flame { opacity: .45; }
.space-rocket__stars { opacity: 0; transition: opacity .3s; }
.space-trail.is-orbit .space-rocket__stars { opacity: 1; }
.space-trail__readout { position: absolute; top: calc(100% + 18px); left: -9px; width: 74px; text-align: center; font: 9px/1.5 Georgia, serif; letter-spacing: .7px; }
.space-trail__state { display: block; font-size: 8px; color: #a28cad; }

/* On a full-width article, the rocket becomes a small return-to-top button. */
.space-trail.is-compact { top: auto; bottom: 18px; right: 10px; width: 40px; height: 88px; }
.space-trail.is-compact .space-trail__line,
.space-trail.is-compact .space-trail__moon,
.space-trail.is-compact .space-trail__pad,
.space-trail.is-compact .space-trail__readout { display: none; }
.space-trail.is-compact .space-return { width: 40px; height: 66px; opacity: 0; pointer-events: none; }
.space-trail.is-compact.has-progress .space-return { opacity: 1; pointer-events: auto; }

@media (max-width: 1199px) {
  .sidebar > div[itemscope] { display: grid; grid-template-columns: 90px minmax(0, 1fr); column-gap: 15px; row-gap: 8px; }
  .sidebar .author__avatar { display: block; width: 90px; grid-row: 1 / span 2; }
  .sidebar .author__avatar img { width: 90px; height: 108px; max-width: 90px; }
  .sidebar .author__content { display: block; min-width: 0; padding: 0; }
  .sidebar .author__urls-wrapper { display: block; grid-column: 2; }
}
@media (max-width: 600px) {
  .masthead__inner-wrap { padding-inline: 12px; }
  .greedy-nav .visible-links { display: flex; gap: 18px; }
  .masthead .masthead__menu-item { margin: 0; }
  .greedy-nav .visible-links a { margin-inline: 0; font-size: 15px; white-space: nowrap; }
  body.has-robot-study { padding-bottom: 210px; }
  .robot-study { width: min(290px, calc(100vw - 28px)); right: 14px; }
  .space-trail.is-compact { width: 34px; right: 7px; }
  .space-trail.is-compact .space-return { width: 34px; height: 56px; }
}
@media (prefers-reduced-motion: reduce) {
  .space-rocket, .space-rocket__flame, .space-rocket__stars { transition: none; }
  .space-rocket__flame, .space-trail__dust { display: none; }
  .masthead, #main, .page__footer { animation: none; }
}
