

.modal-root {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1000;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  pointer-events: auto;

  opacity: 0;
  transition: opacity 0.18s ease;
}
.modal-backdrop.is-open { opacity: 1; }

.modal-window {
  width: 100%;
  max-width: 420px;
  background: #0f0f12;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.6);

  transform: translateY(8px) scale(0.96);
  opacity: 0;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.modal-backdrop.is-open .modal-window {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.modal-title {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.modal-text {
  margin: 0 0 22px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  font-weight: 300;
}

.modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.btn--danger {
  background: #c84545;
  color: #fff;
}
.btn--danger:hover { background: #b73a3a; }

.modal-backdrop[hidden] { display: none; }

.modal-window--wide {
  max-width: 920px;
}

.modal-window--scroll {
  padding: 0;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-window__head {
  padding: 20px 24px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.modal-window__head .modal-title {
  margin: 0;
}

.modal-window__close {
  background: none;
  border: 0;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}
.modal-window__close:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.modal-window__body {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.14) transparent;
}
.modal-window__body::-webkit-scrollbar { width: 8px; }
.modal-window__body::-webkit-scrollbar-track { background: transparent; }
.modal-window__body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.14);
  border-radius: 4px;
}

.modal-window__body .admin-table {
  margin: 0;
}

.modal-window__foot {
  padding: 16px 24px 20px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
  background: #0f0f12;
}

.modal-window--sheet {
  max-width: 540px;
}

.modal-backdrop--sheet {
  
}

@media (max-width: 640px) {
  .modal-backdrop--sheet {
    align-items: flex-end;
    padding: 0;
  }
  .modal-window--sheet {
    max-width: 100%;
    border-radius: 16px 16px 0 0;
    max-height: 90vh;
    transform: translateY(20px);
  }
  .modal-backdrop--sheet.is-open .modal-window--sheet {
    transform: translateY(0);
  }
}

.contacts-list {
  list-style: none;
  margin: 0 0 22px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.contacts-list__item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.contacts-list__icon {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: rgba(218, 170, 68, 0.1);
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.contacts-list__icon svg { width: 18px; height: 18px; }
.contacts-list__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.contacts-list__label {
  font-size: 12px;
  color: var(--text-muted);
}
.contacts-list__value {
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  line-height: 1.35;
}
a.contacts-list__value { transition: color 0.18s; }
a.contacts-list__value:hover { color: var(--gold); }

.contacts-modal__call { justify-content: center; }

@media (max-width: 640px) {
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions .btn { width: 100%; justify-content: center; }
}
