/* ===== Estimate form (Step 2) table alignment fix ===== */
.estimate-items,
.items-table,
#itemsTable {
  width: 100%;
}

.items-table table,
#itemsTable table,
table.items {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed; /* КЛЮЧ: фіксована ширина колонок */
}

.items-table th,
.items-table td,
#itemsTable th,
#itemsTable td,
table.items th,
table.items td {
  padding: 8px 10px;
  vertical-align: middle;
}

/* Всі інпути/селекти в таблиці — на 100% комірки */
.items-table td input,
.items-table td select,
#itemsTable td input,
#itemsTable td select,
table.items td input,
table.items td select {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  height: 36px;
  padding: 6px 10px;
  border-radius: 10px;
}

/* Якщо десь є number поля — щоб цифри гарно виглядали */
.items-table input[type="number"],
#itemsTable input[type="number"],
table.items input[type="number"] {
  text-align: right;
}

/* Колонки: піджати дрібні, розширити “Товар” */
.items-table th:nth-child(1),
.items-table td:nth-child(1),
#itemsTable th:nth-child(1),
#itemsTable td:nth-child(1),
table.items th:nth-child(1),
table.items td:nth-child(1) {
  width: 30%;
}

.items-table th:nth-child(2),
.items-table td:nth-child(2) { width: 8%; }   /* К-сть */

.items-table th:nth-child(3),
.items-table td:nth-child(3) { width: 10%; }  /* Ціна */

.items-table th:nth-child(4),
.items-table td:nth-child(4) { width: 10%; }  /* Ціна закуп */

.items-table th:nth-child(5),
.items-table td:nth-child(5) { width: 10%; }  /* Сума закуп */

.items-table th:nth-child(6),
.items-table td:nth-child(6) { width: 10%; }  /* Сума грн */

.items-table th:nth-child(7),
.items-table td:nth-child(7) { width: 22%; }  /* Фото URL */

/* Фото URL: щоб не роздувало рядок і не їхало */
.items-table td:nth-child(7) input,
#itemsTable td:nth-child(7) input,
table.items td:nth-child(7) input {
  font-size: 12px;
}

/* Прибрати “дивні” глобальні box-sizing із тем */
.items-table *,
#itemsTable *,
table.items * {
  box-sizing: border-box;
}
