/* ============================================================
   テーブル一元管理（logikan方式）
   ・table-layout: fixed + colgroup で列幅を厳密制御
   ・各テーブルに .tbl-XXX クラスで全幅 + col:nth-child(N) で各列幅
   ============================================================ */

.table-area { display: inline-block; min-width: 0; }
.table-wrap { overflow-x: auto; }
.pagination-row {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 16px;
}
.pagination-row .pagination { padding: 0; }

table.fixed-table { table-layout: fixed; border-collapse: collapse; }
table.fixed-table thead { background: var(--gray-50); }
table.fixed-table th {
  padding: 8px 6px;
  font-weight: 600; font-size: 12px;
  color: var(--gray-600); letter-spacing: .3px;
  border-bottom: 1px solid var(--gray-200);
  border-right: 1px solid var(--gray-100);
  text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
table.fixed-table td {
  padding: 6px 6px;
  border-bottom: 1px solid var(--gray-100);
  border-right: 1px solid var(--gray-100);
  text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  vertical-align: middle;
  position: relative;
}
table.fixed-table th:last-child, table.fixed-table td:last-child { border-right: none; }
table.fixed-table tr:hover td { background: var(--gray-50); }
table.fixed-table tr.row-clickable { cursor: pointer; }
table.fixed-table tr.row-clickable:hover td { background: var(--primary-light); }

table.fixed-table td.text-left, table.fixed-table th.text-left { text-align: left; }
table.fixed-table td.text-right, table.fixed-table th.text-right { text-align: right; }

table.fixed-table .badge { vertical-align: middle; }
.fixed-table .btn-sm { padding: 4px 8px; font-size: 12px; }


/* ===== 商品管理 (products.html) =====
   チェック36 + Item_id110 + Brand110 + Name160 + Color200 + 在庫90 = 706
   ※ ダブルクリックで編集（操作列なし、Color_codeはテーブル非表示） */
.tbl-products { width: 706px; }
.tbl-products col:nth-child(1) { width:  36px; } /* チェック */
.tbl-products col:nth-child(2) { width: 110px; } /* Item_id */
.tbl-products col:nth-child(3) { width: 110px; } /* Brand */
.tbl-products col:nth-child(4) { width: 160px; } /* Name */
.tbl-products col:nth-child(5) { width: 200px; } /* Color */
.tbl-products col:nth-child(6) { width:  90px; } /* 在庫合計 */

/* ===== ラックマスタ詳細 (右側パネル) =====
   Item_id110 + Brand110 + Name240 + Color110 + Num90 = 660 */
.tbl-rack-detail { width: 660px; }
.tbl-rack-detail col:nth-child(1) { width: 110px; } /* Item_id */
.tbl-rack-detail col:nth-child(2) { width: 110px; } /* Brand */
.tbl-rack-detail col:nth-child(3) { width: 240px; } /* Name */
.tbl-rack-detail col:nth-child(4) { width: 110px; } /* Color */
.tbl-rack-detail col:nth-child(5) { width:  90px; } /* Num */


/* ===== FBA予定 (fba.html) =====
   ID60 + Task160 + Rack_id100 + Item_id110 + Name240 + Num90 + Box_num80 + Status100 = 940 */
.tbl-fba-plan { width: 940px; }
.tbl-fba-plan col:nth-child(1) { width:  60px; }
.tbl-fba-plan col:nth-child(2) { width: 160px; } /* Task */
.tbl-fba-plan col:nth-child(3) { width: 100px; } /* Rack_id */
.tbl-fba-plan col:nth-child(4) { width: 110px; } /* Item_id */
.tbl-fba-plan col:nth-child(5) { width: 240px; } /* 商品名 */
.tbl-fba-plan col:nth-child(6) { width:  90px; } /* Num */
.tbl-fba-plan col:nth-child(7) { width:  80px; } /* Box_num */
.tbl-fba-plan col:nth-child(8) { width: 100px; } /* Status */

/* ===== FBA実績 =====
   ID60 + Datetime160 + User100 + task160 + Rack_id100 + Item_id110 + Name240 + Num90 + Elapsed110 = 1130 */
.tbl-fba-record { width: 1130px; }
.tbl-fba-record col:nth-child(1) { width:  60px; }
.tbl-fba-record col:nth-child(2) { width: 160px; } /* Datetime */
.tbl-fba-record col:nth-child(3) { width: 100px; } /* User */
.tbl-fba-record col:nth-child(4) { width: 160px; } /* task */
.tbl-fba-record col:nth-child(5) { width: 100px; } /* Rack_id */
.tbl-fba-record col:nth-child(6) { width: 110px; } /* Item_id */
.tbl-fba-record col:nth-child(7) { width: 240px; } /* 商品名 */
.tbl-fba-record col:nth-child(8) { width:  90px; } /* Num */
.tbl-fba-record col:nth-child(9) { width: 110px; } /* Elapsedtime */


/* ===== 棚卸し予定 =====
   ID60 + Rack_id100 + Status100 + 作成日時160 = 420 */
.tbl-stocktaking-plan { width: 420px; }
.tbl-stocktaking-plan col:nth-child(1) { width:  60px; }
.tbl-stocktaking-plan col:nth-child(2) { width: 100px; } /* Rack_id */
.tbl-stocktaking-plan col:nth-child(3) { width: 100px; } /* Status */
.tbl-stocktaking-plan col:nth-child(4) { width: 160px; } /* 作成日時 */

/* ===== 棚卸し実績 =====
   ID60 + Datetime160 + User100 + Rack_id100 + Item_id110 + Name240 + Original90 + Fixed90 + 差異90 = 1080 */
.tbl-stocktaking-record { width: 1080px; }
.tbl-stocktaking-record col:nth-child(1) { width:  60px; }
.tbl-stocktaking-record col:nth-child(2) { width: 160px; } /* Datetime */
.tbl-stocktaking-record col:nth-child(3) { width: 100px; } /* User */
.tbl-stocktaking-record col:nth-child(4) { width: 100px; } /* Rack_id */
.tbl-stocktaking-record col:nth-child(5) { width: 110px; } /* Item_id */
.tbl-stocktaking-record col:nth-child(6) { width: 240px; } /* 商品名 */
.tbl-stocktaking-record col:nth-child(7) { width:  90px; } /* Original_num */
.tbl-stocktaking-record col:nth-child(8) { width:  90px; } /* Fixed_num */
.tbl-stocktaking-record col:nth-child(9) { width:  90px; } /* 差異 */


/* ===== ラック間移動 予定 =====
   ID60 + Rack_id100 + Moved110 + Item_id110 + Name240 + Num90 + Box80 + Status100 = 890 */
.tbl-rackmove-plan { width: 890px; }
.tbl-rackmove-plan col:nth-child(1) { width:  60px; }
.tbl-rackmove-plan col:nth-child(2) { width: 100px; } /* Rack_id */
.tbl-rackmove-plan col:nth-child(3) { width: 110px; } /* Moved_rack_id */
.tbl-rackmove-plan col:nth-child(4) { width: 110px; } /* Item_id */
.tbl-rackmove-plan col:nth-child(5) { width: 240px; } /* 商品名 */
.tbl-rackmove-plan col:nth-child(6) { width:  90px; } /* Num */
.tbl-rackmove-plan col:nth-child(7) { width:  80px; } /* Box_num */
.tbl-rackmove-plan col:nth-child(8) { width: 100px; } /* Status */

/* ===== ラック間移動 実績 =====
   ID60 + Datetime160 + User100 + Rack_id100 + Moved110 + Item_id110 + Name240 + Num90 = 970 */
.tbl-rackmove-record { width: 970px; }
.tbl-rackmove-record col:nth-child(1) { width:  60px; }
.tbl-rackmove-record col:nth-child(2) { width: 160px; } /* Datetime */
.tbl-rackmove-record col:nth-child(3) { width: 100px; } /* User */
.tbl-rackmove-record col:nth-child(4) { width: 100px; } /* Rack_id */
.tbl-rackmove-record col:nth-child(5) { width: 110px; } /* Moved_rack_id */
.tbl-rackmove-record col:nth-child(6) { width: 110px; } /* Item_id */
.tbl-rackmove-record col:nth-child(7) { width: 240px; } /* 商品名 */
.tbl-rackmove-record col:nth-child(8) { width:  90px; } /* Num */


/* ===== 納品 / 町田搬送 予定 =====
   ID60 + Rack_id100 + Item_id110 + Name240 + Num90 + Status100 = 700 */
.tbl-simple-plan { width: 700px; }
.tbl-simple-plan col:nth-child(1) { width:  60px; }
.tbl-simple-plan col:nth-child(2) { width: 100px; } /* Rack_id */
.tbl-simple-plan col:nth-child(3) { width: 110px; } /* Item_id */
.tbl-simple-plan col:nth-child(4) { width: 240px; } /* 商品名 */
.tbl-simple-plan col:nth-child(5) { width:  90px; } /* Num */
.tbl-simple-plan col:nth-child(6) { width: 100px; } /* Status */

/* ===== 納品 / 町田搬送 実績 =====
   ID60 + Datetime160 + User100 + Rack_id100 + Item_id110 + Name240 + Num90 = 860 */
.tbl-simple-record { width: 860px; }
.tbl-simple-record col:nth-child(1) { width:  60px; }
.tbl-simple-record col:nth-child(2) { width: 160px; } /* Datetime */
.tbl-simple-record col:nth-child(3) { width: 100px; } /* User */
.tbl-simple-record col:nth-child(4) { width: 100px; } /* Rack_id */
.tbl-simple-record col:nth-child(5) { width: 110px; } /* Item_id */
.tbl-simple-record col:nth-child(6) { width: 240px; } /* 商品名 */
.tbl-simple-record col:nth-child(7) { width:  90px; } /* Num */


/* ===== レポート FBA集計 =====
   Task160 + 件数90 + 合計Num90 + 合計時間110 + 平均時間110 = 560 */
.tbl-reports-fba { width: 560px; }
.tbl-reports-fba col:nth-child(1) { width: 160px; } /* Task */
.tbl-reports-fba col:nth-child(2) { width:  90px; } /* 件数 */
.tbl-reports-fba col:nth-child(3) { width:  90px; } /* 合計Num */
.tbl-reports-fba col:nth-child(4) { width: 110px; } /* 合計時間 */
.tbl-reports-fba col:nth-child(5) { width: 110px; } /* 平均時間 */


/* ===== 設定 ユーザー管理 =====
   ID60 + ユーザー名220 + ロール130 + 登録日160 = 570 */
.tbl-settings-users { width: 570px; }
.tbl-settings-users col:nth-child(1) { width:  60px; } /* ID */
.tbl-settings-users col:nth-child(2) { width: 220px; } /* ユーザー名 */
.tbl-settings-users col:nth-child(3) { width: 130px; } /* ロール */
.tbl-settings-users col:nth-child(4) { width: 160px; } /* 登録日 */
