.amw-email-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.48);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 9999;
}

.amw-email-modal-backdrop.amw-hidden {
  display: none;
}

.amw-email-modal {
  width: min(580px, 100%);
  background: #fff;
  border-radius: 26px;
  box-shadow: 0 28px 90px rgba(0,0,0,0.22);
  padding: 26px;
  position: relative;
  border: 1px solid #e5e5e5;
}

.amw-email-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 0;
  background: #f2f2f2;
  font-size: 22px;
  font-weight: 900;
  cursor: pointer;
}

.amw-email-close:hover {
  background: #fff3e6;
  color: #ff8000;
}

.amw-email-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
  padding-right: 40px;
}

.amw-email-icon {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: #fff3e6;
  color: #ff8000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  flex: 0 0 auto;
}

.amw-email-title {
  margin: 0;
  font-size: 25px;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.amw-email-subtitle {
  margin: 5px 0 0;
  color: #666;
  font-size: 14px;
}

.amw-email-attachment {
  display: flex;
  gap: 12px;
  align-items: center;
  background: #fff8f0;
  border: 1px solid rgba(255,128,0,0.28);
  border-radius: 18px;
  padding: 14px;
  margin-bottom: 18px;
}

.amw-email-attachment-badge {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: #ff8000;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 900;
  flex: 0 0 auto;
}

.amw-email-attachment-label {
  color: #777;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 3px;
}

.amw-email-attachment-name {
  font-size: 14px;
  font-weight: 900;
  color: #111;
  word-break: break-word;
}

.amw-email-form {
  display: grid;
  gap: 13px;
}

.amw-email-field label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 900;
  color: #111;
}

.amw-email-field input,
.amw-email-field textarea {
  width: 100%;
  border: 1px solid #d8d8d8;
  border-radius: 15px;
  padding: 13px 14px;
  font-family: inherit;
  font-size: 14px;
  outline: none;
}

.amw-email-field input:focus,
.amw-email-field textarea:focus {
  border-color: #ff8000;
  box-shadow: 0 0 0 4px rgba(255,128,0,0.13);
}

.amw-email-field textarea {
  min-height: 120px;
  resize: vertical;
}

.amw-email-feedback {
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 13px;
  font-weight: 800;
}

.amw-email-feedback.amw-hidden {
  display: none;
}

.amw-email-feedback.success {
  background: #eaf8ee;
  color: #176b2c;
  border: 1px solid #b7e3c5;
}

.amw-email-feedback.error {
  background: #fdecec;
  color: #9c1f1f;
  border: 1px solid #f2baba;
}

.amw-email-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
  flex-wrap: wrap;
}

.amw-email-cancel,
.amw-email-submit {
  border: 0;
  border-radius: 16px;
  padding: 13px 18px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}

.amw-email-cancel {
  background: #f2f2f2;
  color: #111;
}

.amw-email-submit {
  background: #ff8000;
  color: #fff;
  min-width: 170px;
}

.amw-email-submit:hover {
  background: #000;
}

.amw-email-cancel:disabled,
.amw-email-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}
