/* Meld rich reference viewer */
.mv-mount{
  width:min(1440px,96vw);
  max-width:100%;
  min-width:0;
  color:var(--ink,#1f1f1f);
  font-family:var(--sans,'Suisse Intl',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif);
  font-synthesis:none;
  -webkit-font-smoothing:antialiased;
}
.mv-mount *{box-sizing:border-box}
.mv-mount button,
.mv-mount input,
.mv-mount textarea,
.mv-mount select{font:inherit;color:inherit}
.mv-mount button,
.mv-mount a,
.mv-mount select{touch-action:manipulation}
.mv-mount button:focus-visible,
.mv-mount a:focus-visible,
.mv-mount input:focus-visible,
.mv-mount textarea:focus-visible,
.mv-mount select:focus-visible,
.mv-mount summary:focus-visible{
  outline:2px solid currentColor;
  outline-offset:2px;
}
.mv-mount ::selection{background:rgba(31,31,31,.16)}
.mv-loading,
.mv-media-empty{
  min-height:18rem;
  display:grid;
  place-items:center;
  color:var(--ink3,#707070);
  background:var(--surface2,#eaebef);
}
.mv-viewer{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(360px,420px);
  width:100%;
  height:min(84svh,900px);
  min-height:min(620px,84svh);
  overflow:hidden;
  background:var(--surface,#fff);
}
.mv-media-pane{
  min-width:0;
  min-height:0;
  display:grid;
  grid-template-rows:auto auto minmax(0,1fr) auto;
  background:var(--surface2,#eaebef);
  border-inline-end:1px solid var(--line,rgba(20,20,20,.1));
}
.mv-media-topbar{
  min-height:52px;
  display:flex;
  align-items:center;
  gap:12px;
  padding:8px 12px;
  background:var(--surface,#fff);
  border-block-end:1px solid var(--line,rgba(20,20,20,.1));
  z-index:5;
}
.mv-media-count{
  margin-inline-end:auto;
  color:var(--ink3,#707070);
  font-size:13px;
  font-variant-numeric:tabular-nums;
  white-space:nowrap;
}
.mv-media-tools{
  min-width:0;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:0;
  font-size:13px;
  font-variant-numeric:tabular-nums;
}
.mv-media-tools button,
.mv-annotate{
  min-height:36px;
  padding:0 12px;
  border:1px solid var(--line,rgba(20,20,20,.1));
  border-radius:var(--r,8px);
  background:var(--surface,#fff);
  color:var(--ink,#1f1f1f);
  white-space:nowrap;
}
.mv-media-tools button+button,
.mv-media-tools label+span,
.mv-media-tools span+button{margin-inline-start:-1px}
.mv-media-tools button:hover:not(:disabled),
.mv-annotate:hover{background:var(--fill,rgba(20,20,20,.06))}
.mv-media-tools button[aria-pressed="true"],
.mv-annotate.is-active{
  background:var(--ink,#1f1f1f);
  border-color:var(--ink,#1f1f1f);
  color:var(--surface,#fff);
}
.mv-media-tools button:disabled{opacity:.4;cursor:not-allowed}
.mv-media-tools output{min-width:54px;text-align:center;color:var(--ink2,#525252)}
.mv-media-tools label{display:flex;align-items:center;gap:6px;padding-inline:10px}
.mv-page-input{
  width:44px;
  height:30px;
  padding-inline:5px;
  border:1px solid var(--line,rgba(20,20,20,.1));
  border-radius:var(--r,8px);
  background:var(--surface,#fff);
  text-align:center;
  font-variant-numeric:tabular-nums;
}
.mv-tool-separator{width:12px}
.mv-annotate{margin-inline-start:0;font-size:13px}
.mv-annotate-help{
  padding:8px 14px;
  background:var(--ink,#1f1f1f);
  color:var(--surface,#fff);
  font-size:13px;
  line-height:1.4;
  text-align:center;
}
.mv-stage{
  position:relative;
  min-width:0;
  min-height:0;
  display:grid;
  place-items:center;
  overflow:hidden;
  padding:24px;
  overscroll-behavior:contain;
}
.mv-stage-page{align-items:start;overflow:auto}
.mv-stage-pdf{overflow:auto;align-items:start}
.mv-stage-image.mv-fit{cursor:default}
.mv-stage-image.mv-fit:has(.is-zoomed){cursor:grab}
.mv-stage-image.mv-fit.is-panning{cursor:grabbing;user-select:none}
.mv-stage.is-annotating{cursor:crosshair}
.mv-media-frame{position:relative;isolation:isolate;max-width:100%;max-height:100%}
.mv-image-frame{
  display:inline-grid;
  place-items:center;
  transform-origin:center;
  will-change:transform;
}
.mv-image-frame>*{grid-area:1/1}
.mv-image-frame.mv-fit{
  transform:translate(var(--mv-pan-x,0),var(--mv-pan-y,0)) scale(var(--mv-image-scale,1));
}
.mv-image-frame.mv-fit img{
  width:auto;
  height:auto;
  max-width:100%;
  max-height:calc(84svh - 150px);
  object-fit:contain;
}
.mv-image-frame.mv-page{
  width:var(--mv-image-width,100%);
  max-width:none;
  max-height:none;
  align-self:start;
}
.mv-image-frame.mv-page img{width:100%;height:auto;max-width:none;max-height:none}
.mv-video-frame{display:grid;place-items:center;width:100%;height:100%}
.mv-video-frame>*{grid-area:1/1}
.mv-video-frame video{
  display:block;
  max-width:100%;
  max-height:calc(84svh - 150px);
  width:auto;
  height:auto;
  background:#0a0a0a;
}
.mv-pdf-frame{display:grid;place-items:start center;max-width:none;max-height:none;background:#fff}
.mv-pdf-frame>*{grid-area:1/1}
.mv-pdf-canvas{display:block;max-width:none;background:#fff;box-shadow:0 0 0 1px rgba(20,20,20,.12)}
.mv-pdf-status{
  align-self:center;
  justify-self:center;
  max-width:32ch;
  padding:10px 12px;
  background:var(--surface,#fff);
  color:var(--ink2,#525252);
  font-size:13px;
  line-height:1.45;
  text-align:center;
}
.mv-link-media{
  max-width:34rem;
  display:grid;
  gap:18px;
  justify-items:start;
  padding:28px;
  background:var(--surface,#fff);
  border:1px solid var(--line,rgba(20,20,20,.1));
}
.mv-link-media p{font-family:var(--serif,'Lyon Text',Georgia,serif);font-size:24px;line-height:1.15;text-wrap:balance}
.mv-link-media a{
  min-height:40px;
  display:inline-flex;
  align-items:center;
  padding-inline:14px;
  background:var(--ink,#1f1f1f);
  color:var(--surface,#fff);
  text-decoration:none;
}
.mv-pin-capture{
  position:absolute;
  inset:0;
  z-index:2;
  width:100%;
  height:100%;
  padding:0;
  border:0;
  border-radius:var(--r,8px);
  background:transparent;
  cursor:crosshair;
  pointer-events:none;
}
.mv-stage.is-annotating .mv-pin-capture{pointer-events:auto}
.mv-pin{
  position:absolute;
  z-index:3;
  width:30px;
  height:30px;
  display:grid;
  place-items:center;
  padding:0;
  border:2px solid var(--surface,#fff);
  border-radius:50%;
  background:var(--ink,#1f1f1f);
  color:var(--surface,#fff);
  box-shadow:0 2px 8px rgba(0,0,0,.28);
  transform:translate(-50%,-50%);
  font-size:12px;
  font-weight:500;
  font-variant-numeric:tabular-nums;
}
.mv-pin:hover,
.mv-pin.is-selected{background:var(--surface,#fff);color:var(--ink,#1f1f1f);border-color:var(--ink,#1f1f1f)}
.mv-thumbs{
  display:flex;
  gap:8px;
  min-height:76px;
  overflow-x:auto;
  padding:8px 12px 10px;
  background:var(--surface,#fff);
  border-block-start:1px solid var(--line,rgba(20,20,20,.1));
  scrollbar-width:thin;
  overscroll-behavior-inline:contain;
}
.mv-thumb{
  position:relative;
  flex:0 0 58px;
  width:58px;
  height:58px;
  display:grid;
  place-items:center;
  overflow:hidden;
  padding:0;
  border:1px solid transparent;
  border-radius:var(--r,8px);
  background:var(--surface2,#eaebef);
}
.mv-thumb[aria-current="true"]{border-color:var(--ink,#1f1f1f)}
.mv-thumb img{width:100%;height:100%;object-fit:cover}
.mv-thumb-kind{font-size:11px;letter-spacing:.04em;color:var(--ink3,#707070)}
.mv-thumb-index{
  position:absolute;
  inset-inline-end:2px;
  inset-block-end:2px;
  min-width:18px;
  height:18px;
  display:grid;
  place-items:center;
  padding-inline:4px;
  background:rgba(255,255,255,.94);
  color:var(--ink,#1f1f1f);
  font-size:11px;
  font-variant-numeric:tabular-nums;
}
.mv-details{display:contents}
.mv-details>summary{display:none}
.mv-sr-only{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  padding:0!important;
  margin:-1px!important;
  overflow:hidden!important;
  clip:rect(0,0,0,0)!important;
  white-space:nowrap!important;
  border:0!important;
}

@media (max-width:1000px){
  .mv-viewer{grid-template-columns:minmax(0,1fr) minmax(320px,380px)}
  .mv-media-topbar{flex-wrap:wrap}
  .mv-media-tools{order:3;width:100%;justify-content:flex-start;overflow-x:auto;padding-block-start:4px}
  .mv-stage{padding:16px}
}

@media (max-width:760px){
  .mv-mount{width:100%;max-width:100vw}
  .mv-viewer{
    display:flex;
    flex-direction:column;
    width:100%;
    height:min(760px,calc(90svh - 48px));
    min-height:0;
    max-height:calc(90svh - 48px);
  }
  .mv-media-pane{
    flex:1 1 58%;
    min-height:0;
    border-inline-end:0;
    border-block-end:1px solid var(--line,rgba(20,20,20,.1));
  }
  .mv-media-topbar{padding:8px;gap:8px}
  .mv-media-tools{scrollbar-width:none}
  .mv-media-tools::-webkit-scrollbar{display:none}
  .mv-media-tools button{min-height:40px}
  .mv-tool-separator{width:8px}
  .mv-annotate{min-height:40px}
  .mv-stage{padding:10px}
  .mv-image-frame.mv-fit img,
  .mv-video-frame video{max-height:calc(58svh - 150px)}
  .mv-thumbs{min-height:66px;padding:6px 8px 8px}
  .mv-thumb{flex-basis:50px;width:50px;height:50px}
  .mv-details{
    flex:0 1 42%;
    min-height:54px;
    max-height:72svh;
    display:flex;
    flex-direction:column;
    overflow:hidden;
    background:var(--surface,#fff);
  }
  .mv-details:not([open]){flex:0 0 54px}
  .mv-details>summary{
    min-height:54px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:0 max(16px,env(safe-area-inset-left));
    border-block-end:1px solid var(--line,rgba(20,20,20,.1));
    cursor:pointer;
    font-size:15px;
    font-weight:500;
    list-style:none;
    user-select:none;
  }
  .mv-details>summary::-webkit-details-marker{display:none}
  .mv-details[open]>summary span:last-child{transform:rotate(45deg)}
}

@media (max-width:420px){
  .mv-media-count{width:100%;margin:0}
  .mv-annotate{margin-inline-start:auto}
  .mv-media-tools{order:4}
  .mv-media-tools button{padding-inline:10px}
  .mv-media-tools label{padding-inline:6px}
}

@media (prefers-reduced-motion:reduce){
  .mv-mount *,
  .mv-mount *::before,
  .mv-mount *::after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important;animation-iteration-count:1!important}
}

@media (forced-colors:active){
  .mv-pin,
  .mv-thumb[aria-current="true"]{border:2px solid ButtonText}
}
/* Full-screen viewer in the original Meld staging visual language. */
.mv-fullscreen-layer.meld-dialog-layer{padding:0;display:block;background:var(--bg);overflow:hidden}
.mv-fullscreen-layer .meld-dialog{width:100vw;max-width:none!important;height:100dvh;max-height:none;border-radius:0;box-shadow:none;overflow:hidden}
.mv-fullscreen-layer>.meld-dialog>.dialog-header{position:absolute;inset:0 auto auto 0;padding:0;width:64px;height:64px;background:transparent;z-index:30;pointer-events:none}
.mv-fullscreen-layer>.meld-dialog>.dialog-header h2{display:none}
.mv-fullscreen-layer .dialog-close{position:absolute;top:12px;left:16px;background:var(--surface);border:0;box-shadow:none;pointer-events:auto;outline-offset:1px}
.mv-fullscreen-layer>.meld-dialog>.dialog-body{padding:0;overflow:hidden;height:100%;max-height:100%}
.mv-fullscreen-layer .mv-mount{width:100%;height:100%;max-width:none}
.mv-fullscreen-layer .mv-viewer{height:100dvh;min-height:0;grid-template-columns:minmax(0,1fr) 420px;background:var(--surface)}
.mv-fullscreen-layer .mv-media-pane{border:0;background:var(--bg);background-size:1016px}
.mv-fullscreen-layer .mv-media-topbar{min-height:64px;padding:12px 20px 12px 72px;border:0;background:transparent;gap:16px}
.mv-media-tools{gap:4px;background:var(--fill);padding:3px;border-radius:var(--pill)}
.mv-media-tools button,.mv-annotate{border:0;border-radius:var(--pill);background:var(--fill);min-height:36px;padding:0 14px;font-size:14px;font-weight:400;box-shadow:none}
.mv-media-tools button{background:transparent;padding:0 12px;min-width:32px;min-height:32px}
.mv-media-tools button+button,.mv-media-tools label+span,.mv-media-tools span+button{margin-inline-start:0}
.mv-media-tools button[aria-pressed="true"]{background:var(--surface);color:var(--ink);box-shadow:var(--sh1)}
.mv-media-tools output{min-width:48px;font-size:13px}
.mv-annotate.is-active{background:var(--ink);color:var(--surface);border:0}
.mv-fullscreen-layer .mv-stage{padding:20px 36px 28px}
.mv-fullscreen-layer .mv-image-frame.mv-fit img,.mv-fullscreen-layer .mv-video-frame video{max-height:calc(100dvh - 120px);border-radius:var(--r)}
.mv-fullscreen-layer .mv-viewer:has(.mv-thumbnails) .mv-image-frame.mv-fit img,.mv-fullscreen-layer .mv-viewer:has(.mv-thumbnails) .mv-video-frame video{max-height:calc(100dvh - 220px)}
.mv-fullscreen-layer .mv-details{height:100%;min-height:0;overflow:hidden;border:0;background:var(--surface)}.mv-annotate-help{background:var(--fill);color:var(--ink2);font-size:13px}.mv-thumbnail,.mv-thumb{border-radius:var(--r)!important}
@media(min-width:1700px){.mv-fullscreen-layer .mv-viewer{grid-template-columns:minmax(0,1fr) 460px}}
@media(max-width:1050px) and (min-width:761px){.mv-fullscreen-layer .mv-viewer{grid-template-columns:minmax(0,1fr) 370px}.mv-media-topbar{flex-wrap:wrap}.mv-media-count{display:none}}
@media(max-width:760px){.mv-fullscreen-layer .mv-viewer{display:flex;flex-direction:column;height:100dvh}.mv-fullscreen-layer .mv-media-pane{display:flex;flex-direction:column;flex:1;min-height:35dvh}.mv-fullscreen-layer .mv-media-topbar{min-height:60px;padding:10px 12px 10px 64px;flex-wrap:wrap;gap:8px}.mv-media-count{display:none}.mv-fullscreen-layer .mv-stage{padding:12px 16px;flex:1;min-height:0}.mv-fullscreen-layer .mv-image-frame.mv-fit img,.mv-fullscreen-layer .mv-video-frame video{max-height:calc(52dvh - 100px)}.mv-fullscreen-layer .mv-details{flex:0 1 45dvh;height:auto;min-height:52px;max-height:60dvh;border-radius:var(--r3) var(--r3) 0 0;box-shadow:0 -4px 24px oklch(0 0 0/.05);overflow-y:auto}.mv-fullscreen-layer .mv-details:not([open]){flex:0 0 56px}.mv-fullscreen-layer .mv-details>summary{display:flex;padding:16px 20px;min-height:52px;position:sticky;top:0;z-index:5;background:var(--surface)}.mv-fullscreen-layer .dialog-close{left:12px;top:10px}.mv-media-tools{gap:0}.mv-media-tools button{padding-inline:10px}.mv-annotate{padding-inline:12px}.mv-fullscreen-layer .mv-stage-page img{max-height:none}.mv-fullscreen-layer .mv-details:not([open])~*{display:none}}
.mv-fullscreen-layer .mv-viewer:has(.mv-thumbs) .mv-image-frame.mv-fit img,.mv-fullscreen-layer .mv-viewer:has(.mv-thumbs) .mv-video-frame video{max-height:calc(100dvh - 220px)}
@media(min-width:1051px){.mv-fullscreen-layer .mv-viewer{grid-template-columns:minmax(0,1fr) 460px}}
.mv-fullscreen-layer .mv-viewer{max-height:none}
@media(max-width:760px){
 .mv-fullscreen-layer .mv-viewer .mv-image-frame.mv-fit img,.mv-fullscreen-layer .mv-viewer .mv-video-frame video{max-height:calc(55dvh - 150px)}
 .mv-fullscreen-layer .mv-viewer:has(.mv-thumbs) .mv-image-frame.mv-fit img,.mv-fullscreen-layer .mv-viewer:has(.mv-thumbs) .mv-video-frame video{max-height:calc(55dvh - 220px)}
 .mv-fullscreen-layer .mv-viewer:has(.mv-details:not([open])) .mv-image-frame.mv-fit img,.mv-fullscreen-layer .mv-viewer:has(.mv-details:not([open])) .mv-video-frame video{max-height:calc(100dvh - 200px)}
}
