/* FrontierSat picture gallery */

:root {
  color-scheme: dark;

  /* the same space and panel as the Orbit and Watchlist pages */
  --bg: #05070A;
  --surface: #10151B;
  --raised: #1A2129;
  --fg: #E6EBF0;
  --bright: #F5F8FB;
  --label: #8A96A3;
  --hair: #1C242D;
  --rule: #34414E;
  --field: #3A4757;
  --accent: #3C9DF5;
  --stage: #10151B; /* a picture's slate: the panel, as on Pictures */
  --stage-fg: #A9B6C2;
  --empty: #10161D;
  --underline: rgba(230, 235, 240, 0.35);

  /* One family for headlines and text; the mono is for data (times, files, hashes). */
  --display: "Jost", "Futura", "Century Gothic", "Helvetica Neue", Arial, sans-serif;
  --sans: var(--display);
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --pad: 24px;
  --gap: 6px;
  --nav-h: var(--nav-bar); /* assets/nav.css */
  /* the page's sides, clear of a phone's notch in landscape (viewport-fit=cover) */
  --pad-l: max(var(--pad), env(safe-area-inset-left, 0px));
  --pad-r: max(var(--pad), env(safe-area-inset-right, 0px));
}

@media (max-width: 599px) {
  :root { --pad: 16px; --gap: 4px; }
}

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

/* The hidden attribute wins over any display rule below. */
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
  scroll-padding-top: calc(var(--nav-h) + 12px); /* keyboard focus is never left under the sticky nav */
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main { flex: 1 0 auto; outline: none; }
/* while a picture or the list is loading, the page holds a screen's height, so the footer doesn't
   show and then jump away when it arrives */
body:is([data-view="detail"], [data-view="pictures"]) main { min-height: calc(100svh - var(--nav-h)); }

img { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

button, input, select, textarea { font: inherit; color: inherit; }

h1, h2, h3 { font-weight: 600; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.mono {
  font-family: var(--mono);
  font-size: 0.92em;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
}

.vh {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: absolute;
  left: var(--pad-l);
  top: -100px;
  z-index: 50;
  padding: 8px 12px;
  background: var(--fg);
  color: var(--bg);
  font-size: 14px;
}
.skip:focus { top: 8px; }

.noscript { padding: 24px var(--pad-r) 24px var(--pad-l); }

/* Shared bits */

/* Buttons, as on every page: the primary is Ink with dark words (.btn, .btn-primary),
   the secondary a raised grey fill (.btn-secondary), both 500. 44px tall on touch. */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  border: 0;
  border-radius: 0;
  padding: 0 16px;
  background: var(--fg);
  color: var(--bg);
  font: 500 16px/1.2 var(--sans);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.btn:hover { background: var(--bright); }
.btn:disabled { background: var(--label); cursor: progress; }
.btn-secondary { background: var(--raised); color: var(--fg); }
.btn-secondary:hover { background: color-mix(in srgb, var(--raised), var(--fg) 10%); }
.btn[aria-disabled="true"] { background: var(--surface); color: var(--label); cursor: default; }
@media (pointer: coarse) {
  .btn { min-height: 44px; }
}

.linkish {
  border: 0;
  padding: 0;
  background: none;
  font-size: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  cursor: pointer;
}

.text-link {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  text-decoration-color: var(--underline);
}
.text-link:hover { text-decoration-color: currentColor; }
/* a link on its own in a notice ("← All pictures" on a picture that isn't there): a full-size target on touch */
@media (pointer: coarse) {
  .notice .text-link { display: inline-flex; align-items: center; min-width: 44px; min-height: 44px; }
}

/* Header and nav */

/* The nav stays on screen on every page. */
.site-head {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--bg);
  border-bottom: 1px solid var(--hair);
}

/* Explore, the landing globe: the nav (assets/nav.css) lies over the stage, and the page
   ends with the story, so there is no footer under it. */
body[data-view="explore"] { --jy-nav: var(--nav-h); }
/* where the bar grows for the bigger logos (assets/nav.css), the globe's words and picture start under it */
@media (min-width: 1200px) and (min-height: 860px) {
  body[data-view="explore"] .jy-root { --jy-nav: var(--nav-h); }
}
body[data-view="explore"] .site-head {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  background: transparent;
  border-bottom: 0;
  pointer-events: none;
}
body[data-view="explore"] .wordmark,
body[data-view="explore"] .site-foot,
body[data-view="explore"] .name-ctl { display: none; }

.name-ctl { position: relative; }

.name-btn {
  max-width: 11em;
  overflow: hidden;
  border: 0;
  padding: 0;
  background: none;
  color: var(--label);
  font-weight: 500;
  white-space: nowrap;
  text-overflow: ellipsis;
  cursor: pointer;
}
.name-btn:hover { color: var(--fg); }
.name-btn.is-set::before { content: "Name: "; color: inherit; opacity: 0.7; }

.name-form {
  position: absolute;
  right: 0;
  top: calc(100% + 13px);
  z-index: 30;
  width: 260px;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--rule);
  color: var(--fg);
  font-size: 13px;
}
.name-form label { display: block; margin-bottom: 6px; color: var(--label); font-size: 13px; }
.name-form input {
  width: 100%;
  border: 1px solid var(--field);
  border-radius: 0;
  padding: 6px 8px;
  background: var(--bg);
}
.name-actions { display: flex; align-items: center; gap: 14px; margin-top: 10px; }

/* Filters */

.filters {
  position: sticky;
  top: calc(var(--nav-h) + 1px); /* under the sticky nav */
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 22px;
  margin: 0;
  padding: 10px var(--pad-r) 10px var(--pad-l);
  background: rgba(5, 7, 10, 0.92);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--hair);
  font-size: 13px;
}

.filter { display: inline-flex; align-items: baseline; gap: 6px; }
.filter-label { color: var(--label); font-size: 12.5px; }

.filter select {
  -webkit-appearance: none;
  appearance: none;
  field-sizing: content;
  max-width: 13em;
  margin: 0;
  border: 0;
  border-radius: 0;
  padding: 3px 17px 3px 5px;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5' viewBox='0 0 8 5'%3E%3Cpath d='M.5.5 4 4 7.5.5' fill='none' stroke='%23E6EBF0' stroke-width='1.2'/%3E%3C/svg%3E") no-repeat right 5px center / 8px 5px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.3;
  cursor: pointer;
}
.filter select option { background: var(--surface); color: var(--fg); }
.filter select:hover { text-decoration: underline; text-underline-offset: 3px; }
.filter select.is-set { color: var(--accent); }
.filter select:disabled { color: var(--label); cursor: default; text-decoration: none; }

.search {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex: 1 1 240px;
  max-width: 420px;
  min-width: 0;
}
.search input {
  flex: 1;
  min-width: 0;
  border: 0;
  border-bottom: 1px solid var(--rule);
  border-radius: 0;
  padding: 3px 0;
  background: transparent;
  font-size: 13px;
}
.search input:hover { border-bottom-color: var(--label); }
.search input::placeholder { color: var(--label); opacity: 1; }
.search input.is-set { border-bottom: 2px solid var(--accent); padding-bottom: 2px; }
.search input::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }

.filter-summary {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 0 0 0 auto;
  color: var(--label);
  font-size: 12.5px;
  white-space: nowrap;
}
.filter-summary .linkish { color: var(--fg); font-size: 12.5px; }

/* Mosaic */

.mosaic-wrap { padding: var(--gap) var(--pad-r) 56px var(--pad-l); }

.mosaic {
  display: flex;
  flex-wrap: wrap;
  column-gap: var(--gap);
  row-gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.mosaic-break { flex: 0 0 100%; height: 0; }

.tile { min-width: 0; }

.tile a { display: block; }

.frame {
  display: block;
  overflow: hidden;
  background: var(--empty);
}

.frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 120ms linear;
}

.tile a:hover .frame img { opacity: 0.8; }

.cap {
  display: block;
  padding: 7px 0 16px;
  font-size: 13px;
  line-height: 1.3;
}

.cap-title {
  display: block;
  overflow: hidden;
  font-weight: 500;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.cap-meta {
  display: block;
  color: var(--label);
  font-size: 12px;
}
.cap-meta .mono { font-size: 11.5px; }

.tile a:hover .cap-title {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.notice {
  max-width: 40em;
  margin: 0;
  padding: 40px var(--pad-r) 72px var(--pad-l);
  font-size: 16px;
}
.notice code { font-family: var(--mono); font-size: 0.9em; }
.notice .linkish { margin-left: 0.3em; }

.hidden-note { max-width: 48em; margin: 20px 0 0; color: var(--label); font-size: 13px; }
.hidden-line { display: block; }
.hidden-line + .hidden-line { margin-top: 6px; }
.hidden-note .linkish { margin-left: 0.4em; color: var(--fg); }

/* Photo details (photo-info.js): the same block on Pictures and on a picture's
   own page. A 13px muted label beside a 16px value; the data's own terms in a
   closed Technical details. */

.nobr { white-space: nowrap; }

.pi-lead > * { margin: 0; }
.pi-credit { margin-top: 4px; color: var(--label); font-size: 13px; line-height: 1.45; letter-spacing: 0.01em; }
.pi-when { margin-top: 8px; color: var(--label); }
.pi-when-line { display: block; }
.pi-when-local { color: var(--fg); }
.pi-status { max-width: 62ch; margin-top: 12px; color: var(--fg); }

.pi-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
/* why Show on the globe is greyed, in small words on a line of its own under it */
.pi-why { flex: 1 0 100%; margin: -4px 0 4px; color: var(--label); font-size: 13px; line-height: 1.45; letter-spacing: 0.01em; }

.pi-facts {
  display: grid;
  grid-template-columns: minmax(88px, max-content) minmax(0, 1fr);
  gap: 12px 20px;
  margin: 24px 0 0;
}
.pi-facts dt {
  margin: 0;
  padding-top: 2px;
  color: var(--label);
  font-size: 13px;
  line-height: 1.45;
  letter-spacing: 0.01em;
}
.pi-facts dd { min-width: 0; margin: 0; overflow-wrap: anywhere; }
.pi-value { display: block; }
.pi-second {
  display: block;
  margin-top: 2px;
  color: var(--label);
  font-size: 13px;
  line-height: 1.45;
  letter-spacing: 0.01em;
}
.pi-muted { color: var(--label); }
.pi-code { font-family: var(--mono); font-size: 14px; font-variant-numeric: normal; }
.pi-second .pi-code { font-size: 13px; }

/* People and tags (links on a picture's page, filter buttons on Pictures), and the hash's Copy */
.pi-inline-btn,
.pi-list-link {
  border: 0;
  padding: 0;
  background: none;
  color: var(--fg);
  font: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  text-decoration-color: var(--underline);
  cursor: pointer;
}
.pi-inline-btn:hover,
.pi-list-link:hover { text-decoration-color: currentColor; }
/* a larger target on touch, without spreading the lines of text around it */
@media (pointer: coarse) {
  .pi-inline-btn,
  .pi-list-link { position: relative; }
  .pi-inline-btn::after,
  .pi-list-link::after { content: ""; position: absolute; inset: -13px -6px; }
  /* the hash's Copy: a 44px box of its own, its line no taller (the margin takes the padding back) */
  .pi-copy { min-width: 44px; margin: -10px 0; padding: 10px 0; }
  .pi-copy::after { content: none; }
}

.pi-tech { margin-top: 20px; }
/* the whole row opens it */
.pi-tech > summary {
  display: flex;
  align-items: center;
  min-height: 36px;
  list-style: none;
  font-weight: 500;
  cursor: pointer;
}
.pi-tech > summary::-webkit-details-marker { display: none; }
.pi-tech > summary::before { content: "+"; display: inline-block; width: 1.1em; font-family: var(--mono); }
.pi-tech[open] > summary::before { content: "\2212"; }
.pi-tech > summary:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
@media (pointer: coarse) {
  .pi-tech > summary { min-height: 44px; }
}
.pi-tech-list { margin-top: 8px; }

.pi-notes { margin-top: 32px; }
.pi-notes-heading { margin: 0 0 8px; font-size: 20px; font-weight: 600; line-height: 1.4; }
.pi-notes-text {
  max-width: 62ch;
  margin: 0;
  white-space: pre-line;
  overflow-wrap: anywhere; /* a long link can't widen the page */
}
.pi-notes .pi-second { margin-top: 4px; }

@media (max-width: 599px) {
  .pi-facts { grid-template-columns: minmax(0, 1fr); row-gap: 0; }
  .pi-facts dt { padding-top: 12px; }
  .pi-facts dt:first-child { padding-top: 0; }
}

/* Detail */

/* Capped like the catalogue, so on a big screen the picture and its facts stay
   together instead of drifting apart. */
.detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(320px, 32vw, 480px);
  max-width: 1784px;
  min-height: calc(100vh - var(--nav-h) - 1px);
  margin: 0 auto;
  /* clear of a phone's notch in landscape */
  padding: 0 env(safe-area-inset-right, 0px) 0 env(safe-area-inset-left, 0px);
}

.stage-wrap { background: var(--stage); }

.stage {
  position: sticky;
  top: calc(var(--nav-h) + 1px); /* under the sticky nav */
  height: calc(100vh - var(--nav-h) - 1px);
  min-height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 76px;
  color: var(--stage-fg);
}

.shot {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  margin: 0;
}

/* Shown at its own size, smaller only when the stage is (detail.js sets
   max-width to the picture's width); the image keeps its shape. */
.shot img {
  width: 100%;
  height: auto;
  max-height: calc(100vh - var(--nav-h) - 150px);
  object-fit: contain;
}

.shot-fail { min-height: 240px; margin: 0; padding-top: 104px; text-align: center; }

.step {
  position: absolute;
  top: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  margin-top: -26px;
  color: var(--stage-fg);
  font-size: 24px;
  line-height: 1;
}
.step:hover { color: var(--bright); }
.step-prev { left: max(12px, calc(50% - var(--pic-w, 640px) / 2 - 64px)); }
.step-next { right: max(12px, calc(50% - var(--pic-w, 640px) / 2 - 64px)); }
.step.is-off { color: #34414E; }
.step-text { display: none; }
.step-globe { display: none; } /* phones: "Back to the globe" between Newer and Older */

.panel {
  min-width: 0;
  padding: 16px 32px 56px;
  font-size: 16px;
  line-height: 1.5;
}

.panel-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
.panel-top a:hover { text-decoration: underline; text-underline-offset: 3px; }
.panel-count { color: var(--label); }
.panel-links { display: flex; flex-wrap: wrap; gap: 4px 16px; font-weight: 500; }
@media (pointer: coarse) {
  .panel-top { align-items: center; }
  .panel-links a { display: inline-flex; align-items: center; min-height: 44px; }
}

/* "Latest picture" after a picture's name (Pictures, its details): a small framed tag. */
.pi-tag {
  display: inline-block;
  margin-left: 4px;
  padding: 0 8px;
  border: 1px solid currentColor;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0;
  vertical-align: 0.3em;
  white-space: nowrap;
}

.detail-title {
  margin: 24px 0 0;
  color: var(--fg);
  font-weight: 500;
  font-size: clamp(24px, 1rem + 1.2vw, 32px);
  line-height: 1.2;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
  outline: none;
}

.panel-section { margin-top: 32px; }

.panel-section > h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.4;
}

.section-note { margin: 8px 0 0; color: var(--label); }

.readonly { margin: 32px 0 0; color: var(--label); }
.readonly a { margin-left: 0.35em; }

/* Edit form */

.edit-form { margin-top: 12px; }

.field { margin-bottom: 16px; }
.field > label,
.field-label {
  display: block;
  margin-bottom: 4px;
  color: var(--label);
  font-size: 13px;
  line-height: 1.45;
  letter-spacing: 0.01em;
}
.field input,
.field textarea {
  display: block;
  width: 100%;
  border: 1px solid var(--field);
  border-radius: 0;
  padding: 8px 10px;
  background: var(--surface);
  font-size: 16px; /* below this, iPhones zoom the page on focus */
  line-height: 1.35;
}
.field input:hover,
.field textarea:hover { border-color: var(--label); }
.field input:focus-visible,
.field textarea:focus-visible { outline-offset: 0; border-color: var(--fg); }
.field textarea { min-height: 88px; resize: vertical; }
.field input::placeholder,
.field textarea::placeholder { color: #6B7682; opacity: 1; }
.field .hint { display: block; margin-top: 4px; color: var(--label); font-size: 13px; line-height: 1.45; letter-spacing: 0.01em; }
.field [aria-invalid="true"] { border-color: var(--fg); border-left: 3px solid var(--accent); }

.req { color: var(--fg); }

.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.overrides { margin: 4px 0 16px; }
.overrides > summary {
  padding: 8px 0;
  list-style: none;
  cursor: pointer;
  font-weight: 500;
}
.overrides > summary::-webkit-details-marker { display: none; }
.overrides > summary::before { content: "+"; display: inline-block; width: 1em; font-family: var(--mono); }
.overrides[open] > summary::before { content: "\2212"; }
.overrides > summary:hover { text-decoration: underline; text-underline-offset: 3px; }
.overrides-body { padding: 4px 0 2px; }

.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-top: 16px; }

.form-msg { margin: 0; }
.form-msg:empty { display: none; }
.form-msg.is-error { padding-left: 9px; border-left: 3px solid var(--accent); }
.form-msg.is-ok { color: var(--label); }

/* History */

.history { margin: 0; padding: 0; list-style: none; }
.history { margin-top: 8px; }
.history li { padding: 6px 0; }
.history .who { font-weight: 600; }
.history .when { display: block; color: var(--label); font-size: 13px; line-height: 1.45; letter-spacing: 0.01em; }
.history-more { margin-top: 10px; }

/* About: the page titles' 32/500, section headings at 20 */

.about {
  max-width: 42em;
  margin: 0 auto; /* a readable column, centred on wide screens */
  padding: 48px var(--pad-r) 80px var(--pad-l);
  font-size: 16px;
  line-height: 1.6;
}
.about-title {
  margin: 0 0 20px;
  color: var(--fg);
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(24px, 1rem + 1.2vw, 32px);
  line-height: 1.2;
  letter-spacing: -0.01em;
  outline: none;
}
.about h2 { margin: 40px 0 8px; color: var(--fg); font-size: 20px; font-weight: 600; line-height: 1.4; }
.about p { margin: 0 0 12px; color: var(--fg); }
.about-list { display: grid; grid-template-columns: 12em minmax(0, 1fr); margin: 0; border-top: 1px solid var(--hair); }
.about-list dt, .about-list dd { margin: 0; padding: 8px 0; border-bottom: 1px solid var(--hair); }
.about-list dt { font-weight: 500; padding-right: 16px; }
.about-list dd { color: var(--fg); }

/* "In the news" opens Credits, so it is a button; in its sentence it reads as a link */
.about-link {
  border: 0;
  padding: 0;
  background: none;
  color: var(--fg);
  font: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  text-decoration-color: var(--underline);
  cursor: pointer;
}
.about-link:hover { text-decoration-color: currentColor; }
/* 44px tall to tap, without spreading its sentence's lines (the margin takes the padding back) */
@media (pointer: coarse) {
  .about-link { margin: -10px 0; padding: 10px 0; }
}

/* Open on bigger screens, folded on phones (the script after the footer in index.html):
   About's list of files that can't be shown, and the footer's Data list */
.fold > summary { list-style: none; }
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary > h2 { margin: 0; }
.about .fold { margin-top: 40px; }
.about .fold > summary { margin-bottom: 8px; }
.site-foot .fold > summary { margin-bottom: 6px; }
@media (max-width: 599px), (max-height: 500px) {
  .fold > summary {
    display: flex;
    align-items: center;
    min-height: 44px;
    margin: 0;
    cursor: pointer;
  }
  .fold > summary::before { content: "+"; display: inline-block; flex: none; width: 1.1em; color: var(--fg); font: 500 16px/1 var(--mono); }
  .fold[open] > summary::before { content: "\2212"; }
  .fold > summary:hover > h2 { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
  .about .fold { margin-top: 28px; }
  .about .fold > summary { margin-bottom: 0; }
  .site-foot .fold > summary { margin: -12px 0 0; } /* its 44px row starts where a heading's line would */
}
.fold-n { color: var(--label); font-weight: 400; }

/* Footer */

.site-foot {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px 32px;
  padding: 28px var(--pad-r) calc(36px + env(safe-area-inset-bottom, 0px)) var(--pad-l);
  background: var(--surface);
  border-top: 1px solid var(--hair);
  color: var(--label);
  font-size: 13px;
  line-height: 1.55;
}
.site-foot .mono { font-family: inherit; font-size: inherit; }
.site-foot h2 {
  margin: 0 0 6px;
  color: var(--fg);
  font-size: 13px;
  font-weight: 600;
}
.site-foot p { margin: 0; max-width: 34em; }
.site-foot a {
  color: var(--fg);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
  text-decoration-color: var(--underline);
}
.site-foot a:hover { text-decoration-color: currentColor; }
/* Every line the same height, with a link or without: 24px apart, so no link sits closer
   than 24px to the next; on touch each line is a 44px row and its link fills the row's
   height (padding on an inline link doesn't spread the lines) */
.foot-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.foot-list li { max-width: 34em; line-height: 24px; }
@media (pointer: coarse) {
  .foot-list li { padding: 12px 0; line-height: 20px; }
  .foot-list a { padding: 13px 0; }
}

/* Views */

.view[hidden] { display: none; }

/* Medium screens */

@media (max-width: 1099px) {
  .detail { grid-template-columns: minmax(0, 60fr) minmax(300px, 40fr); }
  .panel { padding-right: 24px; padding-left: 24px; }
  .stage { padding: 40px 68px; }
}

/* Phones and narrow tablets */

@media (max-width: 799px) {
  .detail { display: block; min-height: 0; }
  .stage {
    position: static;
    height: auto;
    min-height: 0;
    flex-direction: column;
    padding: 16px 0 0;
  }
  .shot { width: 100%; }
  .shot img { width: 100%; max-height: none; }
  .stepper {
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding: 4px calc(var(--pad) - 8px) 6px; /* .detail already keeps clear of a notch */
  }
  .step {
    position: static;
    width: auto;
    height: 44px;
    margin: 0;
    padding: 0 8px;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
  }
  .step-text { display: inline; }
  .step-globe { display: flex; }
  .panel { padding: 14px var(--pad) 48px; }
  .detail-title { font-size: 24px; margin-top: 18px; }
}

/* A phone on its side: the picture takes the screen's height under the nav, with the
   arrows beside it (side by side with the facts), or Newer and Older under it */
@media (max-height: 500px) and (orientation: landscape) {
  .detail { grid-template-columns: minmax(0, 1fr) minmax(280px, 34%); min-height: 0; }
  .stage { height: calc(100svh - var(--nav-h) - 1px); min-height: 0; padding: 0 64px; }
  .shot img { max-height: calc(100svh - var(--nav-h) - 24px); }
}
@media (max-height: 500px) and (orientation: landscape) and (max-width: 799px) {
  .stage { height: auto; padding: 12px 0 0; }
  .shot img { width: auto; }
}

@media (max-width: 599px) {
  /* the edit form on a picture asks for the name itself */
  .name-ctl { display: none; }
  .name-btn { max-width: 6.5em; }
  .name-btn.is-set::before { content: none; }
  .name-form { position: fixed; left: var(--pad); right: var(--pad); top: calc(var(--nav-h) + 6px); width: auto; }

  .filters {
    position: static;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 14px;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .filter { justify-content: space-between; min-width: 0; }
  .filter select { max-width: 100%; min-width: 0; text-align: right; }
  .search { grid-column: 1 / -1; max-width: none; margin-top: 2px; }
  .filter-summary { grid-column: 1 / -1; margin: 0; justify-content: space-between; }

  .cap { padding-bottom: 12px; font-size: 12.5px; }
  .cap-meta { font-size: 11.5px; }
  .cap-meta .mono { font-size: 11px; }

  .site-foot { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .about-list { grid-template-columns: minmax(0, 1fr); }
  .about-list dt { padding-bottom: 0; border-bottom: 0; }
}

/* ?motion=reduced (app.js) keeps the pages still. The system's own reduced-motion setting doesn't:
   the owner chose to keep the site's motion (as on the home page, Orbit and Watchlist). */
html[data-motion="reduced"] * { transition: none !important; }
