/* === Общие контейнеры === */
.iarc-orders, 
.iarc-order-add {
  font-family: "Segoe UI", sans-serif;
  background: #fff;
  padding: 20px 25px;
  border: 1px solid #dcdcdc;
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
  max-width: 1200px;
  margin: 25px auto;
}

.iarc-orders h3,
.iarc-order-add h4 {
  margin-bottom: 20px;
  color: #1f2937;
  border-bottom: 2px solid #3b82f6;
  padding-bottom: 6px;
  font-weight: 600;
}

/* === Фильтры === */
.filters {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
  flex-wrap: wrap;
}

.filters input,
.filters select {
  padding: 8px 12px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 14px;
  transition: border 0.2s ease;
}

.filters input:focus,
.filters select:focus {
  border-color: #3b82f6;
  outline: none;
}

/* === Таблица === */
.order-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.order-table th {
  background-color: #f1f5f9;
  color: #374151;
  font-weight: 600;
  text-align: left;
  padding: 10px 12px;
  border-bottom: 2px solid #d1d5db;
}

.order-table td {
  padding: 9px 12px;
  border-bottom: 1px solid #e5e7eb;
  vertical-align: middle;
}

.order-table tr:hover {
  background-color: #eef6ff;
}

.order-table a {
  color: #2563eb;
  text-decoration: none;
  font-weight: 500;
}

.order-table a:hover {
  text-decoration: underline;
}

/* === Кнопки === */
.order-table button,
#order_add_form button,
#order_edit_form button {
  cursor: pointer;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 13px;
  transition: background 0.2s ease;
}

.order-table button:hover,
#order_add_form button:hover,
#order_edit_form button:hover {
  background-color: #1e40af;
}

.order-table .order-delete {
  background-color: #dc2626;
}
.order-table .order-delete:hover {
  background-color: #b91c1c;
}

/* === Форма добавления === */
.iarc-order-add form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.iarc-order-add form p {
  margin: 0;
}

.iarc-order-add input[type="text"],
.iarc-order-add input[type="date"],
.iarc-order-add select {
  width: 100%;
  padding: 7px 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  transition: border-color 0.2s ease;
}

.iarc-order-add input:focus,
.iarc-order-add select:focus {
  border-color: #3b82f6;
  outline: none;
}

.iarc-order-add hr {
  margin: 15px 0;
  border: none;
  border-top: 1px solid #e5e7eb;
}

#order_dynamic_table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

#order_dynamic_table th {
  background: #f3f4f6;
  padding: 8px;
  text-align: left;
  border-bottom: 1px solid #d1d5db;
  font-weight: 600;
}

#order_dynamic_table td {
  padding: 6px 8px;
  border-bottom: 1px solid #e5e7eb;
}

#order_row_add {
  background: #10b981;
  margin-top: 10px;
}
#order_row_add:hover {
  background: #059669;
}

.order_row_delete {
  background: #dc2626 !important;
}
.order_row_delete:hover {
  background: #b91c1c !important;
}

/* === Модалка редактирования === */
#order_modal {
  position: fixed;
  inset: 0;
  background-color: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

#order_modal .modal-content {
  background: #fff;
  border-radius: 10px;
  padding: 25px;
  max-width: 600px;
  width: 90%;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

#order_modal h4 {
  margin-bottom: 15px;
  color: #1f2937;
  border-bottom: 2px solid #3b82f6;
  padding-bottom: 6px;
}

#order_modal form p {
  margin-bottom: 10px;
}

#order_modal select,
#order_modal input[type="text"],
#order_modal input[type="date"],
#order_modal input[type="file"] {
  width: 100%;
  padding: 6px 8px;
  border-radius: 6px;
  border: 1px solid #ccc;
  transition: border-color 0.2s ease;
}

#order_modal select:focus,
#order_modal input:focus {
  border-color: #3b82f6;
  outline: none;
}

#order_modal button[type="submit"] {
  background: #2563eb;
  margin-right: 8px;
}
#order_modal button#order_modal_close {
  background: #6b7280;
}
#order_modal button#order_modal_close:hover {
  background: #4b5563;
}
