@font-face {
  font-family: "Proxima Nova Bold";
  src: url("fonts/ProximaNova-Bold.ttf") format("truetype");
  font-weight: bold;
  font-style: normal;
}

@font-face {
  font-family: "Gotham-Medium";
  src: url("fonts/Gotham Pro Medium.ttf");
}

.dialog:focus {
  outline: none;
}

.dialog {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: linear-gradient(to bottom right, #1a1a1c, #201f24);
  border: 1px solid #444;
  border-radius: 5px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
  min-width: 555px;
  max-width: 555px;
  z-index: 1000;
  color: #fff;
  user-select: none;
  overflow: hidden;

  white-space: normal;
  word-wrap: break-word;
  word-break: break-word;
  
}


.dialog::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;

  background: linear-gradient(
      to bottom,
      rgba(26, 26, 28, 0.6) 0%,
      rgba(32, 31, 36, 0.1) 100%
    ),
    url("../images/background.svg");

  z-index: -1;
}

.dialog-header {
  padding: 10px 20px;
  cursor: move;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top-left-radius: 5px;
  border-top-right-radius: 5px;
}

.dialog-header::after {
  content: "";
  flex-grow: 1;
  height: 1px;
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0.25),
    rgba(255, 255, 255, 0)
  );
  align-self: center;
  display: block;
  margin-top: 10px;
  margin-left: 5px;
}

.dialog-title {
  font-weight: bold;
  font-size: 20px;
  color: #e69348;
  text-transform: uppercase;
  font-family: "Gotham-Medium", sans-serif;
  margin-top: 10px;
  letter-spacing: 0.6px;
}

.dialog-content {
  padding: 20px;
  max-height: 400px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: 0;
  margin-top: -15px;
}

.dialog-content{
  padding: 20px;
  max-height: 400px;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: 0;
  margin-top: -15px;
}

/* .dialog-content:has(.dialog-tablist),
.dialog-content:has(.dialog-list) {
  padding-bottom: 0;
  max-height: 400px;
  overflow-y: auto;
  scrollbar-width: 0;
  margin-top: -15px;
} */

.dialog-text {
    margin-bottom: -15px;
    line-height: 1.5;
    font-family: "Proxima Nova Bold";
    font-size: small;
    white-space: pre-wrap;
    tab-size: 25;
}

.dialog-list-text {
  margin-top: -5px;
  margin-bottom: 5px;
  line-height: 1.5;
  font-family: "Proxima Nova Bold";
  font-size: small;
  white-space: pre-wrap;
}

.dialog-buttons {
  display: flex;
  justify-content: space-between;
  padding: 10px 20px;
  border-bottom-left-radius: 5px;
  border-bottom-right-radius: 5px;
}

.dialog-button {
  padding: 12px 15px;
  border: none;
  border-radius: 1.5px;
  cursor: pointer;
  font-size: 12px;
  min-width: 80px;
  min-height: 40px;
  text-transform: uppercase;
  font-family: "Proxima Nova Bold";
  transition: background-color 0.2s;
  margin-bottom: 10px;
  outline: none;
}

.dialog-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background-color: #3f3f41;
}

.dialog-button-primary {
  background-image: linear-gradient(to right, #21a24d, #5fda55);
  color: white;
  flex: 1;
  margin-right: 5px;
  box-shadow: 0 1.5px 0 #2d682f;
  transition: box-shadow 0.5s ease;
}

.dialog-button-primary:hover:not(:disabled) {
  box-shadow: 0 1.5px 0 #2d682f, 0 3px 2px rgba(70, 180, 76, 0.3);
}

.dialog-button-secondary {
  background-color: #3f3f41;
  opacity: 0.7;
  color: white;
  flex: 1;
  margin-left: 5px;
  outline: 0.1px solid rgba(255, 255, 255, 0.3);
  outline-offset: 0;
  transition: outline 0.25s ease;
}

.dialog-button-secondary:hover {
  outline: 0.3px solid rgba(255, 255, 255, 0.4);
}

.dialog-button-middle {
  background-color: #2196f3;
  box-shadow: 0 1.5px 0 #092842;
  color: white;
  transition: box-shadow 0.5s ease;
  flex: 1;
  margin-left: 2px;
  margin-right: 2px;
}

.dialog-button-middle:hover {
  box-shadow: 0 1.5px 0 #092842, 0 3px 2px rgba(16, 79, 131, 0.3);
}

.timer-dialog .dialog-button-primary {
  background-color: #3f3f41;
  position: relative;
  box-shadow: none;
}

.timer-dialog .dialog-button-primary.timer-active {
  background-color: #4caf50;
}

.timer-text {
  font-size: 14px;
  font-weight: bold;
}

.dialog-input {
  width: 100%;
  max-width: 494px;
  height: 40px;
  padding: 0 10px;
  margin-top: 20px;
  margin-bottom: -15px;
  background-color: #000;
  border: 1px solid #000;
  color: gray;
  border-radius: 1px;
  font-family: "Gotham-Medium";
  line-height: 40px;
  overflow-x: hidden;
  scrollbar-width: 0;
}

.dialog-input:focus {
  outline: none;
}

.dialog-password {
  -webkit-text-security: disc;
}
.dialog-list {
  max-height: 400px;
  overflow-y: auto;    
  border-radius: 2px;
}

.dialog-tablist .row,
.dialog-list-item {
  outline: none;
  user-select: none;
}

/* Webkit Scrollbar */
.dialog-list::-webkit-scrollbar {
  width: 6px;
}
.dialog-list::-webkit-scrollbar-thumb {
  background-color: #e69348;
  border-radius: 3px;
}
.dialog-list::-webkit-scrollbar-track {
  background: transparent;
}

.dialog-list-item {
  padding: 10px 12px;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.1s;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: "Proxima Nova Bold";
  font-size: 14px;

  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 2px;
  margin-bottom: 5px;
  min-height: 25px;
}

.dialog-list-item:last-child {
  margin-bottom: 0;  /* убираем лишнее место после последнего элемента */
}

.dialog-list-item:hover {
  background-color: #444;
  /* transform: translateY(-1px); */
}

.dialog-list-item.selected {
  background-color: #e69348;
  color: #2e302b;
  box-shadow: 0 0 5px rgba(230, 147, 72, 0.5);
  color: #000 !important;
}


.dialog-tablist {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-height: 400px;
  overflow-y: overlay;
  outline: none;
}

.dialog-tablist .row {
  display: flex;
  border-radius: 2px;
  padding: 6px 8px;
  cursor: pointer;
  transition: background-color 0.2s, transform 0.1s;
  background-color: rgba(0, 0, 0, 0.5);
  min-height: 25px;
}

.dialog-tablist .row.header {
  font-weight: bold;
  color: #e69348;
  background: transparent;
  box-shadow: none;
  cursor: default;
  margin-top: -10px;
  margin-bottom: -10px;
  margin-left: -10px;
}

.dialog-tablist .cell {
  flex: 1;
  padding: 4px 6px;
  font-family: "Proxima Nova Bold";
  font-size: 14px;
}

.dialog-tablist .row.selected {
  background-color: #e69348;
  color: #2e302b;
  box-shadow: 0 0 5px rgba(230, 147, 72, 0.5);
}

.dialog-tablist tr.selected {
  background-color: #e69348;
  box-shadow: 0 0 5px rgba(230, 147, 72, 0.5);
}

.dialog-tablist tr.selected td {
  color: #2e302b;
}
.dialog-list-item {
  position: relative; /* для overlay */
}
.overlay-black {
  display: block;
  color: #000 !important;
}

.dialog-tablist::-webkit-scrollbar,
.dialog-list::-webkit-scrollbar {
  width: 6px;
}

.dialog-tablist::-webkit-scrollbar-thumb,
.dialog-list::-webkit-scrollbar-thumb {
  background-color: #e69348;
  border-radius: 3px;
  border: 2px solid #1a1a1c; /* фон контейнера создаёт отступ */
}

.dialog-tablist::-webkit-scrollbar-track,
.dialog-list::-webkit-scrollbar-track {
  background: transparent;
}

.dialog-pictures {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 15px;
  border-top: 1px solid #444;
  padding-top: 15px;
  margin-top: 25px;
}

.dialog-pictures img {
  width: 100px;
  height: 70px;
  object-fit: contain;
  border-radius: 3px;
  border: 1px solid #555;
  background-color: #222;
}
