.dsgt-buy {
  max-width: 480px;
  margin: 1em auto;
  padding: 20px;
  background: #ffffff;
  border-radius: 15px;
  border: 1px solid #e2eefe;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  font-size: 16px;
  color: #111111;
}

.dsgt-buy__title {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 600;
}

.dsgt-buy__subtitle {
  margin: 0 0 16px;
  padding: 10px 12px;
  background: #fff8e1;
  border-radius: 8px;
  font-size: 13px;
  color: #5d4d00;
  line-height: 1.4;
}
.dsgt-buy__subtitle[hidden] {
  display: none;
}

.dsgt-buy__subtitle-item {
  display: block;
  margin: 0 0 6px;
}
.dsgt-buy__subtitle-item:last-child {
  margin-bottom: 0;
}
.dsgt-buy__subtitle-item strong {
  font-weight: 600;
}

.dsgt-buy__notice {
  margin: 0 0 16px;
  padding: 10px 12px;
  background: #fff8e1;
  border-radius: 8px;
  font-size: 13px;
  color: #5d4d00;
  line-height: 1.4;
}

.dsgt-buy__packages {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.dsgt-buy__pkg {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: #f7f7f7;
  border: 2px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s;
  user-select: none;
}

.dsgt-buy__pkg:hover {
  background: #eef4ff;
}

.dsgt-buy__pkg.is-selected {
  background: #e2eefe;
  border-color: #1f6feb;
}

.dsgt-buy__pkg-label {
  font-weight: 600;
}

.dsgt-buy__pkg-discount {
  color: #1a7f37;
  font-weight: 600;
}

.dsgt-buy__pkg-tag {
  color: #1f1f1f;
  font-weight: 400;
}

.dsgt-buy__pkg-price {
  font-weight: 600;
  color: #1f1f1f;
}

.dsgt-buy__paypal {
  min-height: 50px;
  margin-bottom: 8px;
}

.dsgt-buy__status {
  font-size: 14px;
  min-height: 1.2em;
}

.dsgt-buy__status.is-success {
  color: #1a7f37;
  padding: 14px 16px;
  background: #eafbf0;
  border: 1px solid #b6e6c4;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.45;
  margin-top: 8px;
}

.dsgt-buy__status.is-error { color: #d1242f; }

.dsgt-buy.is-purchased .dsgt-buy__notice,
.dsgt-buy.is-purchased .dsgt-buy__subtitle,
.dsgt-buy.is-purchased .dsgt-buy__packages,
.dsgt-buy.is-purchased .dsgt-buy__paypal {
  display: none;
}

.dsgt-buy.is-purchased .dsgt-buy__status {
  margin-top: 12px;
}

.dsgt-buy--gated {
  padding: 12px;
  background: #fff3cd;
  border-radius: 6px;
  font-size: 13px;
}

/* Modal / Lightbox */
.dsgt-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.dsgt-modal[hidden] { display: none; }

.dsgt-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.dsgt-modal__inner {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}

.dsgt-modal__inner .dsgt-buy,
.dsgt-modal__inner .dsgt-support {
  max-width: none;
  margin: 0;
  border: none;
  box-shadow: none;
  background: transparent;
  padding: 28px 22px 22px;
}

.dsgt-modal__close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 36px;
  height: 36px;
  background: transparent;
  border: none;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  color: #555;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  z-index: 2;
}

.dsgt-modal__close:hover { background: #f0f0f0; color: #000; }

body.dsgt-modal-open { overflow: hidden; }

/* Buy-Button (Link, der die Lightbox öffnet) */
.dsgt-buy-button {
  display: inline-block;
  padding: 10px 18px;
  background: #1f6feb;
  color: #fff !important;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none !important;
  border: none;
  cursor: pointer;
  transition: background-color 0.15s;
  font-size: 15px;
  line-height: 1.2;
}

.dsgt-buy-button:hover { background: #1858c4; color: #fff !important; }

.dsgt-quota-cta {
  margin: 16px 0;
  padding: 14px 16px;
  background: #fff8e1;
  border: 1px solid #f0d97a;
  border-radius: 10px;
  font-size: 14px;
}

.dsgt-quota-cta p { margin: 0 0 8px; }
.dsgt-quota-cta p:last-child { margin-bottom: 0; }

.dsgt-balance {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: #e2eefe;
  border-radius: 999px;
  font-size: 13px;
}

.dsgt-balance strong {
  font-weight: 700;
}

/* Footer-Variante: keine Pille, kein eigener BG — erbt das Aussehen von .aipkit_chat_footer */
.dsgt-footer-balance {
  display: inline;
  padding: 0;
  background: none;
  border: none;
  border-radius: 0;
  font-size: inherit;
  color: inherit;
}

.dsgt-footer-balance strong {
  font-weight: 600;
}

/* --- Support panel inside the Lightbox --- */
.dsgt-support[hidden] {
  display: none;
}
.dsgt-support .dsgt-buy__title {
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #e6e8ee;
}
.dsgt-support__form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.dsgt-support__label {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 13px;
  font-weight: 600;
  color: #222;
}
.dsgt-support__label input,
.dsgt-support__label textarea {
  font: inherit;
  font-weight: 400;
  padding: 10px 12px;
  border: 1px solid #d6dbe2;
  border-radius: 8px;
  background: #ffffff;
  color: #111;
  width: 100%;
  box-sizing: border-box;
  line-height: 1.4;
}
.dsgt-support__label input:focus,
.dsgt-support__label textarea:focus {
  outline: none;
  border-color: #4380f5;
  box-shadow: 0 0 0 3px rgba(67, 128, 245, 0.18);
}
.dsgt-support__label textarea {
  resize: vertical;
  min-height: 110px;
}
.dsgt-support__actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
  flex-wrap: wrap;
}
.dsgt-support__back {
  font-size: 13px;
  color: #4d6bfe;
  text-decoration: underline;
}
.dsgt-support__back:hover {
  text-decoration: underline;
  opacity: 0.85;
}
.dsgt-support__submit {
  font: inherit;
  font-weight: 600;
  background: #4d6bfe;
  color: #ffffff;
  border: 0;
  border-radius: 8px;
  padding: 10px 22px;
  cursor: pointer;
}
.dsgt-support__submit:hover:not(:disabled) {
  background: #3b56e0;
}
.dsgt-support__submit:disabled {
  opacity: 0.6;
  cursor: default;
}
.dsgt-support__status {
  margin-top: 4px;
  font-size: 13px;
  min-height: 1em;
}
.dsgt-support__status.is-success {
  color: #166534;
}
.dsgt-support__status.is-error {
  color: #b91c1c;
}
