.nerdagent-popup {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.nerdagent-popup.is-open {
  display: flex;
}

.nerdagent-popup__backdrop {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.8);
}

.nerdagent-popup__modal {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1000px;
  max-height: calc(100vh - 40px);
  overflow: auto;
  pointer-events: all;
}

.nerdagent-popup .dialog-widget-content {
  position: relative;
  animation-duration: 0.3s;
  background-color: transparent;
  background-image: linear-gradient(110deg, #191c22 1.69%, #0f1014 103.78%);
  border-radius: 20px;
  box-shadow: 0 1px 1px 0 rgba(21, 25, 19, 0.46) inset;
}

.nerdagent-popup .dialog-message {
  width: 100%;
  height: auto;
  padding: 30px;
}

.nerdagent-popup .dialog-close-button {
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.nerdagent-popup .dialog-close-button:hover {
  opacity: 0.85;
}

.nerdagent-popup.is-open .nerdagent-popup-content {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.nerdagent-form-status {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: 8px;
  font-family: Inter, sans-serif;
  font-size: 14px;
}

.nerdagent-form-status.is-success {
  background: rgba(46, 204, 113, 0.15);
  color: #b8f0c8;
  border: 1px solid rgba(46, 204, 113, 0.35);
}

.nerdagent-form-status.is-error {
  background: rgba(255, 77, 77, 0.12);
  color: #ffb3b3;
  border: 1px solid rgba(255, 77, 77, 0.35);
}

.nerdagent-form-status.is-info {
  background: rgba(99, 102, 241, 0.15);
  color: #c7cbff;
  border: 1px solid rgba(99, 102, 241, 0.35);
}

#nerdagent-contact-form .mf-input.mf-invalid {
  border: 1px solid #f00;
}

.nerdagent-youtube-embed__frame {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 15px;
}

.nerdagent-youtube-embed__frame iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #000;
}

body.nerdagent-popup-open {
  overflow: hidden;
}

.nerdagent-inline-form {
  display: block;
  width: 100%;
}

.nerdagent-inline-form .metform-form-main-wrapper,
.nerdagent-popup .metform-form-main-wrapper {
  display: block;
}

.nerdagent-inline-form .mf-input-wrapper,
.nerdagent-popup .mf-input-wrapper {
  display: block;
}

@media (max-width: 767px) {
  .nerdagent-popup .dialog-message {
    padding: 20px;
  }

  .nerdagent-popup .dialog-widget-content {
    margin: 0;
  }
}
