.form-upload {
  padding: 5px;
  /*border: 1px solid #ccc;*/
  border-radius: 10px;
  /*background-color: #f9f9f9;*/
}
.form-upload label {
  display: block;
  cursor: default;
}
.form-upload input,
.form-upload textarea,
.form-upload select,
.form-upload button {
  margin-bottom: 15px;
  padding: 10px;
  font-size: 16px;
}

#upload-progress {
  position: relative;
  width: 100%;
  height: 25px;
  background-color: #e0e0e0;
  border: 1px solid #ccc;
  border-radius: 5px;
  overflow: hidden;
}

#upload-progress .progress-bar {
  width: 0%;
  height: 100%;
  background-color: #4caf50;
  transition: width 0.3s ease;
}

#upload-progress .progress-text {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  font-size: 14px;
  font-weight: bold;
  color: #fff;
  line-height: 25px;
}

.upload-progress-container {
  position: relative;
  width: 100%;
  height: 25px;
  background-color: #e0e0e0;
  border-radius: 5px;
  overflow: hidden;
  margin-bottom: 10px;
}

.upload-progress-container .progress-bar {
  width: 0%;
  height: 100%;
  background-color: #4caf50;
  transition: width 0.3s ease;
}

.upload-progress-container .progress-text {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  font-size: 14px;
  font-weight: bold;
  color: #000;
}

.img-preview {
  position: relative;
  display: inline-block;
  margin: 5px;
  width: auto;
  max-height: 80px;
  text-align: center;
}

.img-preview img {
  max-width: 100%;
  border: 1px solid #ddd;
  border-radius: 5px;
}

.img-preview .remove-image {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: red;
  color: #fff;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
  padding: 2px 5px;
  border-radius: 50%;
}

.sortable-placeholder {
  width: 120px;
  height: auto;
  background-color: #f0f0f0;
  border: 2px dashed #ccc;
  margin: 5px;
}

#loading-spinner {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 10px;
}

.spinner {
  border: 4px solid #f3f3f3; /* Light grey */
  border-top: 4px solid #3498db; /* Blue */
  border-radius: 50%;
  width: 16px;
  height: 16px;
  animation: spin 1s linear infinite;
  display: inline-block;
  margin-left: 8px;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.upload-button {
  display: inline-block;
  background: linear-gradient(135deg, #5b92af, #3d5f73);
  color: #fff;
  text-align: center;
  padding: 10px 20px;
  font-size: 16px ; /* Cỡ chữ */
  font-weight: normal; /* Chữ không đậm */
  text-transform: uppercase; /* Viết hoa */
  border-radius: 6px; /* Góc bo tròn hơn */
  cursor: pointer;
  margin-top: 5px;
  margin-bottom: 10px;
  box-shadow:
    inset 0 4px 6px rgba(255, 255, 255, 0.3),
    /* Hiệu ứng sáng bên trong */ 0 2px 4px rgba(0, 0, 0, 0.3); /* Bóng bên ngoài */
  transition:
    background 0.3s ease,
    transform 0.2s ease,
    box-shadow 0.3s ease;
  width: 120px; /* Kích thước rộng hơn một chút */
  position: relative;
  overflow: hidden;
}

/* Hiệu ứng ánh sáng bóng loáng */
.upload-button::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 135%;
  height: 100%;
  background: rgba(255, 255, 255, 0.2);
  transform: skewX(-30deg);
  transition: all 0.5s ease-in-out;
}

/* Hover tạo hiệu ứng ánh sáng và phản chiếu */
.upload-button:hover {
  background: linear-gradient(135deg, #6aa5c5, #4a6f84);
  box-shadow:
    inset 0 6px 10px rgba(255, 255, 255, 0.4),
    /* Sáng hơn khi hover */ 0 4px 6px rgba(0, 0, 0, 0.4);
  transform: translateY(-2px); /* Hiệu ứng nâng nút */
}

.upload-button:hover::after {
  left: 100%;
}

.upload-button:active {
  transform: translateY(1px); /* Hiệu ứng khi nhấn */
  box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.1);
}

/* Áp dụng chung cho tất cả các loại input */
input[type="email"],
input[type="number"],
input[type="search"],
input[type="text"],
input[type="tel"],
input[type="url"],
input[type="password"] {
  border: 1px solid #cccccc; /* Viền nhẹ, màu xám nhạt */
  border-radius: 4px; /* Góc bo tròn */
  padding: 8px 10px; /* Khoảng cách bên trong */
  font-size: 14px; /* Cỡ chữ */
  box-shadow: none; /* Bỏ bóng viền */
  outline: none; /* Bỏ đường viền khi focus */
  transition:
    border-color 0.3s ease,
    box-shadow 0.3s ease; /* Hiệu ứng mượt */
  font-family: Helvetica, Arial, sans-serif;
}

/* Áp dụng hiệu ứng khi focus */
input:focus {
  border-color: #66afe9; /* Viền màu xanh khi focus */
  box-shadow: 0 0 5px rgba(102, 175, 233, 0.5); /* Ánh sáng mờ xanh */
}

/* Áp dụng style cho placeholder */
input::placeholder {
  color: #aaaaaa; /* Màu placeholder nhạt */
  font-style: italic; /* Chữ nghiêng */
}

#model-description {
  height: calc(50px + 50px);
  font-size: 14px;
  border: 1px solid #cccccc;
  border-radius: 4px;
  box-shadow: none;
  outline: none;
  resize: vertical;
  font-family: Helvetica, Arial, sans-serif;
  overflow-y: auto;
  line-height: 1.8;
}

/* Xóa viền đen của nút Browse và Submit */
input[type="file"],
button,
input[type="submit"] {
  border: none; /* Xóa viền */
  outline: none; /* Xóa đường viền khi nhấn vào */
  box-shadow: none; /* Xóa bóng viền */
}

/* Thêm một số style tùy chỉnh để nút đẹp hơn */
button,
input[type="submit"] {
  background-color: #007bff; /* Màu nền */
  color: #ffffff; /* Màu chữ */
  padding: 10px 15px; /* Khoảng cách bên trong */
  border-radius: 4px; /* Bo tròn góc */
  font-size: 16px; /* Cỡ chữ */
  cursor: pointer; /* Hiệu ứng con trỏ chuột */
  transition: background-color 0.3s ease; /* Hiệu ứng khi di chuột */
}

/* Hiệu ứng hover cho nút */
button:hover,
input[type="submit"]:hover {
  background-color: #0056b3; /* Màu nền khi hover */
}

/* Hiệu ứng khi bấm vào nút */
button:active,
input[type="submit"]:active {
  background-color: #004085; /* Màu nền khi nhấn */
}

.error-message {
  color: red;
  font-size: 12px;
  margin-left: 10px;
}

/* General Form Styles */
.form-section {
  margin-bottom: 20px;
}

/*
label {
    display: block;
    font-weight: 400;
    margin-bottom: 5px;
    font-size: 14px;
}
*/

input[type="text"],
select {
  width: 100%;
  padding: 8px;

  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 14px;
}

/* Dropdown styling */
select {
  appearance: none;
  background: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAiIGhlaWdodD0iNiIgZmlsbD0ibm9uZSIgdmlld0JveD0iMCAwIDEwIDYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGc+PHBhdGggZD0iTTEgMUw1IDVNNSA1TDkgMSIgIHN0cm9rZT0iIzAwMDAwMCIgc3Ryb2tlLXdpZHRoPSIxLjUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgLz48L2c+PC9zdmc+")
    no-repeat right 10px center;
  background-size: 10px 6px;
  padding-right: 30px;
}

 
/* Checkbox styling */
.upload-model-version-3dsmax input[type="checkbox"],
.upload-model-formats input[type="checkbox"],
.upload-model-renders input[type="checkbox"],
.upload-model-style input[type="checkbox"],
.upload-model-material input[type="checkbox"],
.upload-model-optional-standard input[type="checkbox"],
.upload-to-maxve-sub input[type="checkbox"] {
  margin-right: 5px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid #ccc;
  appearance: none; /* Loại bỏ giao diện mặc định */
  background-color: white;
  cursor: pointer;
  position: relative;
}

/* Grid for checkboxes and radios */
.upload-model-version-3dsmax,
.upload-model-formats,
.upload-model-renders,
.upload-model-style,
.upload-model-material,
.upload-model-colorchoise,
.upload-model-optional-standard,
.upload-to-maxve-sub {
  display: grid;
  grid-template-columns: repeat(4, 1fr); 
  gap: 5px; /* Khoảng cách giữa các mục */
  margin-bottom: 20px;
  align-items: center; /* Căn chỉnh tất cả mục giữa theo chiều dọc */
}

@media (max-width: 899px) {
  .upload-model-version-3dsmax,
  .upload-model-formats,
  .upload-model-renders,
  .upload-model-style,
  .upload-model-material,
  .upload-model-colorchoise,
  .upload-model-optional-standard,
  .upload-to-maxve-sub {
    grid-template-columns: repeat(3, 1fr);  
  }
}
/* Checkbox và Radio cùng sử dụng cấu trúc thẳng hàng */
.upload-model-version-3dsmax label,
.upload-model-formats label,
.upload-model-renders label,
.upload-model-style label,
.upload-model-material label,
.upload-model-colorchoise label,
.upload-model-optional-standard label {
  display: flex;
  align-items: center; /* Đảm bảo thẳng hàng giữa checkbox/radio và nhãn */
  gap: 8px; /* Khoảng cách giữa checkbox/radio và văn bản */
  font-size: 14px; /* Kích thước văn bản đồng đều */
  cursor: pointer;
  margin-bottom: 5px; /* Khoảng cách giữa các dòng */
}

/* Căn chỉnh chung cho checkbox và radio */
.custom-checkbox,
.upload-model-formats input[type="checkbox"],
.upload-model-renders input[type="checkbox"],
.upload-model-material input[type="checkbox"],
.upload-model-colorchoise input[type="checkbox"],
.upload-model-optional-standard input[type="checkbox"],
.upload-model-version-3dsmax input[type="radio"],
.upload-model-style input[type="radio"],
.upload-to-maxve-sub input[type="radio"] {
  width: 20px;
  height: 20px;
  margin: 0; /* Loại bỏ margin mặc định */
  flex-shrink: 0; /* Đảm bảo kích thước không bị thay đổi */
  border-radius: 50%; /* Làm tròn checkbox và radio */
  border: 1px solid #ccc;
  appearance: none; /* Loại bỏ giao diện mặc định */
  background-color: white;
  cursor: pointer;
  position: relative;
}

/* Trạng thái khi được chọn (checkbox và radio) */
.custom-checkbox:checked,
.upload-model-formats input[type="checkbox"]:checked,
.upload-model-renders input[type="checkbox"]:checked,
.upload-model-material input[type="checkbox"]:checked,
.upload-model-colorchoise input[type="checkbox"]:checked,
.upload-model-optional-standard input[type="checkbox"]:checked,
.upload-model-version-3dsmax input[type="radio"]:checked,
.upload-model-style input[type="radio"]:checked,
.upload-to-maxve-sub input[type="radio"]:checked {
  background-color: rgb(59, 121, 127);
  border-color: #888;
}

/* Biểu tượng hiển thị khi checkbox được chọn */
.custom-checkbox:checked::after,
.upload-model-formats input[type="checkbox"]:checked::after,
.upload-model-renders input[type="checkbox"]:checked::after,
.upload-model-material input[type="checkbox"]:checked::after,
.upload-model-colorchoise input[type="checkbox"]:checked::after,
.upload-model-optional-standard input[type="checkbox"]:checked::after,
.upload-model-version-3dsmax input[type="radio"]:checked::after,
.upload-model-style input[type="radio"]:checked::after,
.upload-to-maxve-sub input[type="radio"]:checked::after {
  content: "\2714"; /* Dấu tích */
  color: white;
  font-size: 14px;
  position: absolute;
  top: 0px;
  left: 5px;
}

 

.colorChoise {
  position: relative;
  width: 30px;
  height: 30px;
}

.colorChoise input[type="checkbox"] {
  display: none; /* Ẩn checkbox */
}

.hex-wrapper {
  width: 25px;
  height: 25px;
  clip-path: polygon(
    25% 6.7%,
    75% 6.7%,
    100% 50%,
    75% 93.3%,
    25% 93.3%,
    0% 50%
  );
  background-color: black; /* Viền đen */
  display: flex;
  align-items: center;
  justify-content: center;
}

.colorCircle1 {
  width: 25px;
  height: 25px;
  clip-path: polygon(
    25% 6.7%,
    75% 6.7%,
    100% 50%,
    75% 93.3%,
    25% 93.3%,
    0% 50%
  );
  transition: transform 0.2s ease;
  cursor: pointer;
}

/* Khi checkbox được chọn */
.colorChoise input[type="checkbox"]:checked + .hex-wrapper .colorCircle1 {
  transform: scale(1.1);
  border: 2px solid white;
}

.colorChoise
  input[type="checkbox"]:checked
  + .hex-wrapper
  .colorCircle1::after {
  content: "✔";
  position: absolute;
  color: #777070;
  font-size: 16px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

/* Căn chỉnh container chung */
.upload-container {
  display: flex;
  align-items: center;
  gap: 10px; /* Khoảng cách giữa nút Browse và Drop Zone */
  margin-bottom: 15px; /* Khoảng cách giữa các mục */
}



/* Drop Zone */
.drop-zone {
  flex: 1; /* Drop Zone chiếm toàn bộ không gian còn lại */
  border: 2px dashed #ccc;
  padding: 7px;
  text-align: center;
  cursor: pointer;
  color: #888;
  transition: border-color 0.3s ease-in-out;
  font-size: 14px;
}

/* Hiệu ứng khi kéo tệp vào Drop Zone */
.drop-zone.drag-over {
  border-color: #4caf50;
  color: #4caf50;
}

/* Preview Box */
.file-preview {
  margin-top: 10px;
  font-size: 14px;
}

.custom-alert {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  padding: 15px 20px;
  background-color: #f44336; /* Màu nền đỏ */
  color: white;
  border-radius: 5px;
  font-size: 14px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  animation: fadeInOut 4s;
}

@keyframes fadeInOut {
  0% {
    opacity: 0;
    transform: translateY(-10px);
  }
  10%,
  90% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-10px);
  }
}

/* CSS for custom checkbox */
.checkbox-container {
  display: flex;
}

.checkbox-container label {
  font-size: 14px;
  color: #333;
  cursor: pointer;
}

.categories-dropdown-bulk {
  position: relative;
  display: inline-block;
  width: 100%;
}

.bulk-upload-row {
  display: flex;
  justify-content: space-between;
  gap: 20px; /* Khoảng cách giữa các cột */
}

.bulk-upload-column {
  flex: 1; /* Cột có kích thước bằng nhau */
  display: flex;
  flex-direction: column; /* Sắp xếp tiêu đề và input theo chiều dọc */
}

.bulk-upload-column label {
  margin-bottom: 5px; /* Khoảng cách giữa label và input */
}

.bulk-upload-column input {
  width: 100%; /* Input chiếm toàn bộ chiều rộng cột */
  padding: 8px; /* Khoảng cách bên trong input */
  box-sizing: border-box; /* Đảm bảo padding không làm thay đổi kích thước input */
}

#images-preview .ui-sortable-placeholder {
  background-color: #f8f8f8; /* Màu nền placeholder */
  border: 2px dashed #007bff; /* Viền dashed màu xanh */
  width: 80px; /* Đảm bảo placeholder có cùng chiều rộng với ảnh */
  height: 80px; /* Đảm bảo chiều cao tối đa của placeholder */
  margin: 5px; /* Khoảng cách giữa các ảnh */
  display: inline-block; /* Đảm bảo placeholder nằm ngang */
  transition: all 0.3s ease; /* Hiệu ứng mượt khi di chuyển placeholder */
}

#images-preview .ui-sortable-helper {
  transform: scale(1.1); /* Phóng to ảnh khi kéo */
  box-shadow: 0px 8px 15px rgba(0, 0, 0, 0.2); /* Thêm bóng mờ */
  opacity: 0.9; /* Làm mờ ảnh phía sau */
  cursor: move; /* Hiển thị con trỏ di chuyển */
  transition: transform 0.2s ease; /* Hiệu ứng phóng to mượt */
}

#images-preview img {
  max-height: 80px; /* Chiều cao tối đa cho ảnh */
  width: auto; /* Tự động điều chỉnh chiều rộng theo tỷ lệ */
  border-radius: 5px; /* Thêm góc bo tròn */
  display: inline-block;
}

#images-preview {
  display: flex; /* Căn ảnh theo hàng ngang */
  flex-wrap: wrap; /* Tự động xuống dòng nếu không đủ chỗ */
  gap: 5px; /* Giảm khoảng cách giữa các ảnh */
  justify-content: flex-start !important; /* Căn tất cả ảnh sang bên trái */
  align-items: flex-start; /* Căn chỉnh ảnh theo trục trên cùng */
  position: relative; /* Đảm bảo lớp phủ hiển thị chính xác */
  padding: 5px; /* Thêm khoảng cách nhỏ bên trong khung chứa */
}

@keyframes move-arrows {
  0% {
    transform: translateX(-10px);
  }
  50% {
    transform: translateX(10px);
  }
  100% {
    transform: translateX(-10px);
  }
}

.upload-single-3dmodel-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
}
@media (max-width: 899px) {
  .upload-single-3dmodel-row {
    flex-direction: column;
  }
}  
.column-product-link,
.column-price,
.column-tags {
  flex: 1; /* Makes each column take equal space */
  padding: 0 10px; /* Adds spacing between columns */
}

.column-polygons,
.column-vertices,
.column-dimensions {
  flex: 1; /* Each column takes equal space */
}

input#product-link,
input#price,
input#tags,
input#wetransfer-link,
input#version,
textarea#model-description{
  width: 98% !important;
    color: #000;  
}

input#model-name {
  width: 100% !important;
    color: #000;  
}

input#dimensions {
  width: 95% !important;
}

.error-message-upload  
{
  margin-top: 20px;
  padding: 10px;
  border: 1px solid #f44336;
  background-color: #ffebee;
  color: #f44336;
  font-size: 16px;
  text-align: center;
  border-radius: 5px;
} 

.custom-confirm-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.custom-confirm-box {
  background: #fff;
  padding: 20px;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  max-width: 400px;
  width: 90%;
}

.custom-confirm-message {
  font-size: 16px;
  margin-bottom: 20px;
}

.confirm-yes,
.confirm-no {
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  color: white;
}

.confirm-yes {
  background: #4caf50;
  margin-right: 10px;
}

.confirm-no {
  background: #f44336;
}
pre#bulk-upload-log {
    background: #ffffff00;
}

#bulk-upload-popup {
  position: fixed;
  top: 100px;
  left: 100px;
  width: 600px;
  height: 400px;
  background: #1e1e1e;
  color: white;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0,0,0,0.5);
  box-sizing: border-box;
  overflow: hidden;
  resize: none;
  z-index: 9999;
}

.popup-header {
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #222;
  padding: 0 10px;
  cursor: move;
  user-select: none;
}

.popup-controls button {
  background: none;
  border: none;
  color: white;
  font-size: 18px;
  margin-left: 8px;
  cursor: pointer;
}

 
#bulk-upload-log {
  height: calc(100% - 70px);
  overflow: auto;
  padding: 10px;
  white-space: pre-wrap;
}

 
#bulk-upload-popup.minimized {
  width: 230px !important;
  height: 50px !important;
  left: 20px !important;
  bottom: 20px !important;
  top: auto !important;
  right: auto !important;
  padding: 0;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

#bulk-upload-popup.minimized .popup-note,
#bulk-upload-popup.minimized pre
 {
  display: none !important;
}

#bulk-upload-popup.minimized .popup-header {
  height: 30px !important;
  padding: 0 8px;
  background: #1e1e1e;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ✅ Kéo 4 cạnh và 4 góc */
#bulk-upload-popup::before,
#bulk-upload-popup::after,
#bulk-upload-popup .resize-handle {
  content: "";
  position: absolute;
  z-index: 10000;
}

#bulk-upload-popup .resize-handle {
  background: transparent;
}

/* 4 góc */
.resize-nw, .resize-ne, .resize-sw, .resize-se {
  width: 15px;
  height: 15px;
}

.resize-nw { top: 0; left: 0; cursor: nw-resize; }
.resize-ne { top: 0; right: 0; cursor: ne-resize; }
.resize-sw { bottom: 0; left: 0; cursor: sw-resize; }
.resize-se { bottom: 0; right: 0; cursor: se-resize; }

/* 4 cạnh */
.resize-n, .resize-s {
  height: 5px;
  left: 0;
  right: 0;
}

.resize-n { top: 0; cursor: n-resize; }
.resize-s { bottom: 0; cursor: s-resize; }

.resize-e, .resize-w {
  width: 5px;
  top: 0;
  bottom: 0;
}

.resize-e { right: 0; cursor: e-resize; }
.resize-w { left: 0; cursor: w-resize; }