/* Pages PDF : feuille, couche de texte sélectionnable (pdf.js), surlignages. */

.feuille {
  position: relative;
  background: #fff;
  box-shadow: 0 1px 0 var(--trait), 0 10px 28px rgba(20, 30, 50, .12);
  border-radius: 3px;
  overflow: hidden;
  margin: 0 auto;
  max-width: 100%;
}
.feuille canvas { display: block; width: 100%; height: auto; }
.feuille-attente { display: grid; place-items: center; color: var(--texte-discret); font-size: 15px; min-height: 300px; }

.surligne { position: absolute; mix-blend-mode: multiply; border-radius: 2px; z-index: 3; pointer-events: none; }
.surligne-actif { outline: 2px solid var(--accent); outline-offset: 1px; }

.textLayer {
  position: absolute; text-align: initial; inset: 0; overflow: clip; opacity: 1; line-height: 1;
  letter-spacing: normal; word-spacing: normal; -webkit-text-size-adjust: none; text-size-adjust: none;
  forced-color-adjust: none; transform-origin: 0 0; z-index: 2;
  --min-font-size: 1; --text-scale-factor: calc(var(--total-scale-factor) * var(--min-font-size)); --min-font-size-inv: calc(1 / var(--min-font-size));
}
.textLayer :is(span, br) { color: transparent; position: absolute; white-space: pre; cursor: text; transform-origin: 0% 0%; }
.textLayer > :not(.markedContent), .textLayer .markedContent span:not(.markedContent) {
  z-index: 1; --font-height: 0; font-size: calc(var(--text-scale-factor) * var(--font-height));
  --scale-x: 1; --rotate: 0deg; transform: rotate(var(--rotate)) scaleX(var(--scale-x)) scale(var(--min-font-size-inv));
}
.textLayer .markedContent { display: contents; }
.textLayer ::selection { background: rgba(0, 90, 255, .25); color: transparent; }
