/* Universal modal styles for the DPI child theme. */
.dpi-modal[hidden] { display: none; }

.dpi-modal {
  position: fixed;
  inset: 0;
  z-index: 1050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.dpi-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}

.dpi-modal__dialog {
  position: relative;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2.5rem 2rem 2rem;
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.dpi-modal__dialog--small  { max-width: 400px; }
.dpi-modal__dialog--medium { max-width: 600px; }
.dpi-modal__dialog--large  { max-width: 900px; }

.dpi-modal__close {
  position: absolute;
  top: 0.5rem;
  right: 0.75rem;
  padding: 0;
  border: 0;
  outline: none;
  background: none;
  font-size: 1.75rem;
  line-height: 1;
  color: inherit;
  cursor: pointer;
}
.dpi-modal__close:focus { outline: none; }
.dpi-modal__close:hover { opacity: 0.7; }

.dpi-modal__title { margin-top: 0; }
body.dpi-modal-open { overflow: hidden; }