/* Страница сканера штрихкодов */
.session-container {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background-color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 16px;
}

.scanner-container {
  height: 80hv !important;
  position: relative !important;
  overflow: visible !important;
  width: 100%;
  max-width: 640px;
}

[ data-controller="scanner" ] .reader {
  position: relative;
  width: 100%;
  background: #000;
  overflow: hidden;
}

.reader::before {
  content: '';
  display: block;
  padding-bottom: 75%;
}

#barcode-reader {
  position: relative !important;
  width: 100%;
  height: 100%;
  overflow: visible !important;
  cursor: pointer;
}

#barcode-reader video {
  z-index: 1 !important;
}

.barcode-reader video {
  z-index: 1 !important;
}
#barcode-reader canvas {
  z-index: 25 !important;
}
#barcode-reader::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 15;
  background: rgba(0,0,0,0.1);
  pointer-events: none;
}

.scanner-instruction {
  position: relative;
  margin-top: 32px;
  background-color: transparent;
  z-index: 10;
  padding: 0 16px;
  text-align: center;
}

.scanner-instruction p {
  font-size: 18px;
  color: #000;
  font-weight: 500;
  margin: 0;
}

.scanner-reload-button {
  margin-top: 16px;
  padding: 8px 16px;
  background-color: #4318FF;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  padding: 8px;
}

.show_login_page_text {
  padding: 8px;
  color: white;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none !important;
  display: inline-block;
}

.show_login_page_button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  cursor: pointer;
  border-radius: 5px;
  background-color: #4318FF;  
  text-decoration: none;
  transition: background-color 0.2s;
}

/* Адаптивность для экранов 700px и меньше */
@media (max-width: 700px) {
  .session-container {
    padding: 8px;
  }
  
  .scanner-container {
    max-width: 100%;
  }
  
  .scanner-instruction {
    margin-top: 16px;
    padding: 0 8px;
  }
  
  .scanner-instruction p {
    font-size: 14px;
  }
  
  .scanner-reload-button {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: 6px;
  }
  
  .show_login_page_text {
    padding: 6px;
    font-size: 12px;
  }
  
  .show_login_page_button {
    padding: 6px;
  }
}