/* SAF Mail - Templates editor */

.saf-mail-template-detail {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.saf-mail-template-detail > .saf-mail-form__header {
  margin: 0 0 4px;
  padding-bottom: 8px;
  border-bottom: 1px solid #f0f0f1;
}
.saf-mail-template-detail [data-saf-tab][aria-pressed="true"] {
  background: #2271b110;
  border-color: #2271b1;
  color: #1a4b7a;
}

.saf-mail-template-form .saf-mail-template-body {
  width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12.5px;
  line-height: 1.5;
}

.saf-mail-template-textmanual {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #50575e;
}

.saf-mail-template-vars {
  margin-top: 8px;
  padding: 10px 12px;
  background: #fafafa;
  border-radius: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  font-size: 12px;
}
.saf-mail-template-vars strong {
  margin-right: 6px;
}
.saf-mail-template-vars code {
  background: #fff;
  border: 1px solid #dcdcde;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 11.5px;
}

.saf-mail-template-preview__bar {
  display: flex;
  align-items: end;
  gap: 10px;
  margin-bottom: 10px;
}
.saf-mail-template-preview__bar label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
}
.saf-mail-template-preview__bar input {
  width: 140px;
  padding: 6px 8px;
}

.saf-mail-template-preview__subject {
  background: #f6f7f7;
  border: 1px solid #dcdcde;
  border-radius: 4px;
  padding: 8px 10px;
  font-size: 13px;
  margin-bottom: 8px;
}

.saf-mail-template-preview__iframe {
  width: 100%;
  min-height: 480px;
  border: 1px solid #dcdcde;
  border-radius: 4px;
  background: #fff;
}

.saf-mail-template-preview__text {
  margin-top: 12px;
}
.saf-mail-template-preview__text pre {
  background: #fafafa;
  border: 1px solid #dcdcde;
  border-radius: 4px;
  padding: 10px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  white-space: pre-wrap;
  max-height: 320px;
  overflow: auto;
}
