:root {
  --bordersize: 5px;

  --labelPadding: 5px;
  --leftLabelPadding: 5px;
  --rightLabelPadding: 5px;
  --topLabelPadding: 5px;
  --bottomLabelPadding: 5px;

  --leftImagePadding: 150px;
  --leftScrollSize: 15px;
  --ishaveLeftScroll: 0;

  --globalPadding:1px;
}

html, body {
  margin: var(--globalPadding);
  padding: var(--globalPadding);
  width:  calc(100% - var(--globalPadding));
  height: calc(100% - var(--globalPadding));
}

.labelLT {
  top: var(--topLabelPadding);
  left: var(--leftLabelPadding);
}

.labelRT {
  top: var(--topLabelPadding);
  right: var(--rightLabelPadding);
  text-align: right;
}

.labelLB {
  left: var(--leftLabelPadding);
  bottom: var(--bottomLabelPadding);
}

.labelRB {
  right: var(--rightLabelPadding);
  bottom: var(--bottomLabelPadding);
  text-align: right;
}

.labelMT {
  top: var(--topLabelPadding);
  left: 50%;
}

.labelMB {
  bottom: var(--bottomLabelPadding);
  left: 50%;
}

.labelLM {
  left: var(--leftLabelPadding);
  top: 50%;
}

.labelRM {
  right: var(--rightLabelPadding);
  text-align: right;
  top: 50%;
}

.labelXY {
  left: var(--leftLabelPadding);
  bottom: var(--bottomLabelPadding);
}

.labelWC {
  left: var(--leftLabelPadding);
  bottom: calc(var(--bottomLabelPadding) + 1em);
}

body,
html {
  /*margin: 0;
    padding: 0;*/
  overflow: hidden;
}

#form-group {
  flex-grow: 1;
}

.container {
  height: calc(100vh - 50px);
  position: relative;
  overflow-y: hidden;
}

#pages {
  width: 100%;
  height: 100%;
}

.DicomViewport {
  position: relative;
  float: left;
  /*left: 100px;*/
  overflow: hidden;
  border: var(--bordersize)#D3D9FF groove;
  margin: 0px;
}

.SelectedViewport {
  background-color: rgb(10, 6, 6);
  border: var(--bordersize) #FFC3FF groove;
}

.page {
  width: calc(100% - var(--leftImagePadding) - var(--bordersize) * 1 - var(--leftScrollSize)*var(--ishaveLeftScroll));
  left: calc(var(--leftImagePadding) + var(--bordersize) * 1 + var(--leftScrollSize)*var(--ishaveLeftScroll));
  height: 100%;
  position: relative;
  overflow: hidden;
  /* display: flex;
   overflow-y: hidden;*/
}

#LeftPicture {
  width: calc(var(--leftImagePadding) + var(--leftScrollSize)*var(--ishaveLeftScroll));
  height: 100%;
  overflow-y: auto;
}

select,
button,
input {
  background-color: #404048;
  color: #fff;
  border-radius: 4px;
  border: none;
  padding: 4px;
  border: 2px solid #555;
}

button:hover {
  filter: invert(80%);
}

.img {
  flex: 0 0 4.0%;
  max-width: calc(min(4.0%, 50px));
  min-width: 35px;
  width: 100%;
  height: 100%;
}

.img:active:hover {
  filter: invert(80%);
}

.img:hover {
  filter: invert(80%);
}

#WindowRevision {
  max-width: calc(min(4.0%, 38px));
  min-width: 27px;
  width: 100%;
  height: 100%;
}

#WindowRevisionOption {
  max-width: calc(min(1.0%, 13px));
  min-width: 9px;
  width: 100%;
  height: 100%;
}

.cropimg:active:hover {
  filter: invert(80%);
}

.cropimg:hover {
  filter: invert(80%);
}

.innerimg:active:hover {
  filter: invert(80%);
}

.innerimg:hover {
  filter: invert(80%);
}

.innerLabel {
  font-size: calc(0.4rem + 0.1*((5vw)));
}

.DicomCanvas {
  top: 50%;
  left: 50%;
  z-index: 6;
}

.MarkCanvas {
  top: 50%;
  left: 50%;
  z-index: 8;
  pointer-events: none;
}

.leftRule {
  top: 50%;
  transform: translateY(-50%);
}

.downRule {
  left: 50%;
  transform: translateX(-50%);
}

.WindowSelect {
  background-color: rgb(105, 105, 105);
  display: flex;
  justify-content: center;
  align-content: center;
  flex-wrap: wrap;
  color: white;
  width: 150px;
  height: 30px;

  border-color: rgb(55, 55, 55);
  border-width: 2px;
  border-style: solid;
}

.WindowSelect:hover {
  background-color: rgb(190, 175, 175);
  color: rgb(40, 25, 25);
}

#WindowRevisionParent {
  width: 50px;
  overflow: hidden;
}

.activeImg {
  border: dashed white;
}

.activeImg:hover {
  border: dashed black;
}


/*=====*/

#LeftPicture {
  display: flex;
  flex-direction: column;
  position: absolute;
  z-index: 9;
}

.filpx {
  transform: scaleX(-1);
}


/*from script*/
:root {
  --bordersize: 5px;
}

.OutLeftImg {
  border: var(--bordersize) #FFA3FF groove;
  padding: 1px 1px 1px 1px;
}

.LeftCanvas {
  width: calc(var(--leftImagePadding) - var(--bordersize) * 5);
  height: calc(var(--leftImagePadding) - var(--bordersize) * 5);
}

.LeftImgAndMark {
  /*width: calc(var(--leftImagePadding)/2);
  height: calc(var(--leftImagePadding)/2);
  border: var(--bordersize) #D3D9FF groove;
  /*touch-action: none;*/
}

.LeftImgDiv {
  /*width: calc(var(--leftImagePadding) - var(--bordersize) * 2);
  height: calc(var(--leftImagePadding) - var(--bordersize) * 2);*/
  position: relative;
}

.LeftImgCountLabel {
  position: absolute;
  color: white;
  bottom: 1px;
  right: 1px;
  background-color: black;
}

.LeftShadowLabel {
  text-shadow: 0px 0px 10px #fff, 0px 0px 10px #fff, 0px 0px 10px #fff, 0px 0px 10px #fff, 0px 0px 10px #fff, 0px 0px 10px #fff, 0px 0px 10px #fff;
}

.innerLabel {
  position: absolute;
  color: white;
  z-index: 10;
  -webkit-user-select: none;
}

/*
.labelWC {
  left: 115px;
  bottom: 30px;
}

.labelLT {
  left: 115px;
  top: 10px;
}

.labelRT {
  right: 20px;
  top: 10px;
  text-align: right;
}

.labelRB {
  right: 20px;
  bottom: 20px;
  text-align: right;
}

.labelXY {
  left: 115px;
  bottom: 10px;
}
*/
.leftRule {
  z-index: 30;
  position: absolute;
  left: 15px;
}

.downRule {
  z-index: 30;
  position: absolute;
  bottom: 15px;
}

.PDFView {
  width: 100%;
  height: 100%;
  left: 0px;
  position: absolute;
}

#EcgView {
  width: calc(100% - var(--bordersize)*2);
  height: calc(100% - 25px - var(--bordersize)*2);
  left: 0px;
  position: absolute;
  border: var(--bordersize) #FFC3FF groove;
  overflow: scroll;
}

#tooltiptext_img {
  color: white;
  position: absolute;
}

.DicomTable {
  border: 2;
  border-collapse: collapse;
  color: #ffffff;
  position: absolute;
  background-color: black;
  /*right : 0px;*/
  z-index: 105;
}

.DicomTableDIV {
  width: 100%;
  height: 100%;
  position: absolute;
  overflow-y: scroll;
}

#EcgCanvas {
  /*object-fit: scale-down;
  height: 100%;
  width: 100%;
  image-rendering: pixelated;*/
}

#ECGOptionsDIV {
  background-color: #00306044;
  color: #ffffff;
  height: 25px;
}