/* ===============================
   eMagin RMA Standalone Form
================================= */

.emrma-wrap {
  max-width: 1100px;
  margin: 0 auto;
  font-family: Arial, Helvetica, sans-serif;
  color: #1f2933;
}

.emrma-form {
  display: flex;
  flex-direction: column;
}

/* ===============================
   Alerts
================================= */

.emrma-alert {
  padding: 12px 16px;
  margin-bottom: 20px;
  border-radius: 6px;
  font-size: 14px;
  line-height: 1.4;
}

.emrma-alert-success {
  background: #e6f7ed;
  border: 1px solid #b7e4c7;
  color: #1b5e20;
}

.emrma-alert-error {
  background: #fdecea;
  border: 1px solid #f5c2c0;
  color: #8a1c1c;
}

/* ===============================
   Field Basics
================================= */

.emrma-field {
  margin-bottom: 14px;
}

.emrma-field label {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
  line-height: 1.2;
}

.emrma-required {
  color: #c62828;
}

.emrma-help {
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 8px;
  line-height: 1.35;
}

.emrma-field input,
.emrma-field select,
.emrma-field textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 12px;
  border: 1px solid #b8b8b8;
  border-radius: 4px;
  font-size: 15px;
  line-height: 1.4;
  background: #fff;
  color: #1f2933;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.emrma-field input:focus,
.emrma-field select:focus,
.emrma-field textarea:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
  outline: none;
}

/* ===============================
   Top 2x2 Compact Layout
   Company / Date
   Attention / Email
================================= */

.emrma-grid-2-top {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  margin-bottom: 18px;
}

.emrma-grid-2-top .emrma-field {
  margin-bottom: 0;
}

.emrma-grid-2-top input[type="date"] {
  max-width: 280px;
}

/* ===============================
   Return Shipment Details Grid
================================= */

.emrma-fieldset {
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 20px;
  margin: 0 0 24px;
}

.emrma-fieldset legend {
  font-weight: 700;
  padding: 0 8px;
  font-size: 18px;
}

.emrma-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px 24px;
}

.emrma-grid-2 .emrma-field {
  margin-bottom: 0;
}

/* ===============================
   Note Block
================================= */

.emrma-note {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  padding: 14px 16px;
  margin-bottom: 20px;
  border-radius: 6px;
  font-size: 14px;
  line-height: 1.45;
}

/* ===============================
   Handsontable Return Grid
================================= */

.emrma-grid-block {
  margin-top: 10px;
  margin-bottom: 24px;
}

.emrma-grid-heading {
  font-weight: 700;
  margin-bottom: 6px;
}

.emrma-grid-subheading {
  font-size: 13px;
  color: #6b7280;
  margin-bottom: 12px;
  line-height: 1.35;
}

#emrma-grid {
  border: 1px solid #ddd;
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
}

.emrma-grid-error {
  padding: 20px;
  text-align: center;
  color: #8a1c1c;
  background: #fdecea;
}

/* ===============================
   File Upload
================================= */

.emrma-field input[type="file"] {
  padding: 8px;
}

/* ===============================
   Submit Button
================================= */

.emrma-actions {
  margin-top: 10px;
}

.emrma-actions button {
  background: #1f2937;
  color: #fff;
  border: none;
  padding: 12px 18px;
  font-size: 15px;
  font-weight: 700;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.05s ease;
}

.emrma-actions button:hover {
  background: #111827;
}

.emrma-actions button:active {
  transform: translateY(1px);
}

/* ===============================
   Responsive
================================= */

@media (max-width: 768px) {
  .emrma-wrap {
    padding: 0 12px;
  }

  .emrma-grid-2-top,
  .emrma-grid-2 {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .emrma-grid-2-top input[type="date"] {
    max-width: 100%;
  }

  .emrma-fieldset {
    padding: 16px;
  }
}
