/* A quiet route through the story, with Founding Members outside the chapter rail. */
.chapter-nav {
  align-items:center;
  justify-content:space-between;
  gap:24px;
  padding:0 var(--gutter);
  overflow:visible;
}
.chapter-links {
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex:1 1 auto;
  min-width:0;
  gap:clamp(24px,3.8vw,70px);
  overflow-x:auto;
  padding:17px 3px;
  overscroll-behavior-x:contain;
  scrollbar-width:none;
}
.chapter-links::-webkit-scrollbar {display:none}
.chapter-links a {flex-shrink:0}
.chapter-links a:focus-visible {outline-offset:3px}
.chapter-nav .chapter-join {
  flex-shrink:0;
  padding:6px 0 6px 24px;
  border-left:1px solid var(--mise-site-rule);
  font-size:16px;
  font-weight:600;
}
.chapter-nav .chapter-join span {margin:0 0 0 9px;font-size:16px}

/* Every capture opens complete. Magnification is a deliberate, reversible action. */
.image-dialog {
  width:1100px;
  height:min(960px,calc(100dvh - 32px));
  max-height:calc(100dvh - 32px);
  overflow:hidden;
}
.image-dialog[open] {display:flex;flex-direction:column}
.image-dialog.phone {width:570px}
.image-dialog .dialog-top {flex:0 0 auto;margin-bottom:12px}
.image-dialog .dialog-top p {font-size:16px;line-height:1.4}
.image-tools {display:flex;align-items:center;flex-wrap:wrap;gap:8px 16px;margin:0 0 12px;flex:0 0 auto}
.image-tools button {
  border:1px solid var(--mise-site-ink);
  background:transparent;
  padding:8px 11px;
  min-height:36px;
  font-size:16px;
  line-height:1.4;
}
.image-tools button:hover {text-decoration:underline;text-underline-offset:3px}
.image-tools button:disabled {opacity:1;cursor:not-allowed;border-style:dashed;background:var(--mise-site-linen)}
.image-tools #image-zoom[aria-pressed="true"] {background:var(--mise-site-ink);border-color:var(--mise-site-ink);color:var(--mise-site-paper)}
.image-pan {display:flex;gap:6px}
.image-pan[hidden] {display:none}
.image-pan button {width:38px;padding:6px;font-size:18px}
#image-view-help {font-size:16px;line-height:1.5;flex:1 1 220px;color:var(--mise-site-ink)}
.image-dialog .image-scroll,
.image-dialog.phone .image-scroll {
  flex:1 1 auto;
  min-height:0;
  min-width:0;
  height:100%;
  max-height:none;
  overflow:auto;
  overscroll-behavior:contain;
  touch-action:pan-x pan-y pinch-zoom;
  background:var(--mise-site-linen);
  scrollbar-width:thin;
  scrollbar-color:var(--mise-site-ink) var(--mise-site-linen);
}
.image-dialog .image-scroll:focus-visible {outline:3px solid var(--mise-site-focus);outline-offset:3px}
.image-dialog .image-scroll img,
.image-dialog.phone .image-scroll img,
.image-dialog.wide .image-scroll img {
  display:block;
  width:100%;
  height:100%;
  min-width:0;
  max-width:100%;
  max-height:100%;
  object-fit:contain;
  margin:0 auto;
}
.image-dialog.is-zoomed .image-scroll img {
  width:var(--image-zoom-width,1100px);
  height:auto;
  min-width:0;
  max-width:none;
  max-height:none;
  object-fit:contain;
}
.image-dialog .image-tip {flex:0 0 auto;margin-top:10px;line-height:1.3}
@media(max-width:760px) {
  .chapter-nav {padding:0 16px;gap:12px;font-size:16px}
  .chapter-links {gap:24px;padding:15px 2px}
  .chapter-nav .chapter-join {font-size:16px;padding-left:13px}
  .chapter-nav .chapter-join span {font-size:16px;margin-left:5px}
  .image-dialog {height:calc(100dvh - 20px);max-height:calc(100dvh - 20px);padding:14px}
  .image-tools {gap:7px 10px;margin-bottom:10px}
  #image-view-help {flex-basis:100%;font-size:16px}
  .image-dialog .dialog-top p {font-size:16px}
}
@media(max-width:370px) {
  .chapter-nav {padding:0 12px;gap:9px}
  .chapter-nav .chapter-join {padding-left:10px;font-size:16px}
  .chapter-nav .chapter-join span {display:none}
  .chapter-links {gap:21px}
}
