.flip-card {
    background-color: transparent;
    width: 100%;
    height: auto;
    perspective: 1000px; /* Tạo hiệu ứng 3D */
  }
  
  .flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.6s;
    transform-style: preserve-3d;
  }
  
  .flip-card-front,
  .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 10px;
  }
  
  .flip-card-front {
    background-color: #fff;
  }
  
  .flip-card-back {
    /* background-color: #106eea;
    color: white; */
    transform: rotateY(180deg); /* Đặt mặt sau lật 180 độ */
  }
  
  .flipped .flip-card-inner {
    transform: rotateY(180deg); /* Lật thẻ khi được nhấp */
  }

  .wtg-contact {
    position: fixed; /* Giữ cho nó luôn ở bên phải */
    right: 20px; /* Cách lề phải 20px */
    top: 68%; /* Định vị ở giữa theo chiều dọc */
    /* transform: translateY(-60%); Đẩy nó lên 50% chiều cao của chính nó để căn giữa */
    display: flex;
    flex-direction: column; /* Đặt các phần tử thành cột */
    align-items: center; /* Căn giữa theo chiều ngang */
  }
  
  .wtg-contact-list {
    display: flex;
    flex-direction: column; /* Đặt các phần tử trong danh sách thành cột */
    align-items: center; /* Căn giữa theo chiều ngang */
  }
  
  .wtg-contact-list-item {
    margin-bottom: 15px; /* Khoảng cách giữa các phần tử */
  }
  
  .wtg-contact-list-item img {
    display: block; /* Đảm bảo hình ảnh căn giữa trong phần tử cha */
  }
  

  button {
    background-color: #F15E22; /* Màu nền */
    color: white; /* Màu chữ */
    border: none; /* Bỏ viền */
    padding: 10px 20px; /* Padding */
    text-align: center; /* Căn giữa chữ */
    text-decoration: none; /* Bỏ gạch chân */
    display: inline-block; /* Hiển thị inline-block */
    font-size: 16px; /* Kích thước chữ */
    margin: 4px 2px; /* Margin */
    cursor: pointer; /* Con trỏ chuột */
    border-radius: 5px; /* Bo góc */
    transition: all 0.3s;
}

button:hover {
  box-shadow: 
    0 0 0 2px currentColor, /* Border ngoài */
    inset 0 0 0 1px white; /* Border trong (tuỳ chọn) */
    filter: brightness(1.1); /* Làm nhạt màu tổng thể */
}

.dynamic-contrast {
  mix-blend-mode: difference;
  color: white;
  padding: 10px;
}


/* Đặt nền trắng khi được bấm vào */
.nav-link.active-phung {
  background-color: #ffffff;
  color: #0dcaf0; /* Màu chữ khi tab được chọn */
  padding: 0; 
  display: flex; 
  justify-content: center; 
  align-items: center; 
  height: 100%;
}

.form-group {
  display: flex; /* Hiển thị dạng hàng ngang */
  align-items: center; /* Căn giữa theo chiều dọc */
}

label {
  margin-right: 10px; /* Khoảng cách giữa nhãn và dropdown */
  white-space: nowrap; /* Giữ nhãn trên một dòng */
}

select {
  flex: 1; /* Chiếm phần còn lại của không gian nếu cần */
  width: auto; /* Đặt chiều rộng tự động */
  min-width: 200px; /* Đảm bảo dropdown không quá nhỏ */
  padding: 5px; /* Khoảng đệm bên trong */
}



/* PHẦN NÀY CHO PORTFORLIO */
body {
      background-color: #E6ECF5;
      color: #0A3161;
      font-family: 'Roboto', sans-serif;
      margin: 0;
    }
    .container {
      width: 100%;
      padding: 0 0.25rem;
    }
    .tab-contents {
      display: none;
    }
    .tab-contents.active {
      display: block;
    }
    .popup {
      display: none;
      position: fixed;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      background-color: #FFFFFF;
      color: #0A3161;
      max-height: 90vh;
      overflow-y: auto;
      border: 1px solid #0A3161;
      border-radius: 8px;
      box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
      z-index: 1000;
      width: 95%;
      max-width: 600px;
      padding: 1rem;
    }
    .popup.active {
      display: block;
    }
    .overlay {
      display: none;
      position: fixed;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      background: rgba(0, 0, 0, 0.5);
      z-index: 999;
    }
    .overlay.active {
      display: block;
    }
    .table-wrapper {
      overflow-x: auto;
    }
    table {
      background-color: #FFFFFF;
      color: #0A3161;
      table-layout: fixed;
      width: 100%;
      min-width: 500px;
      margin: 0 auto;
      border-collapse: collapse;
    }
    th, td {
      border: 1px solid #0A3161;
      padding: 6px;
      text-align: left;
      font-size: clamp(0.75rem, 1vw, 0.9rem);
    }
    th {
      background-color: #0A3161;
      color: #FFFFFF;
      font-weight: 700;
      font-size: clamp(0.8rem, 1.1vw, 1rem);
    }
    .image-cell {
      /* display: flex; cần bật để align hoạt động */
      justify-content: center; /* căn giữa theo chiều ngang */
      align-items: center;     /* căn giữa theo chiều dọc */
      text-align: center;
      height: 100%;
      padding: 2px;
      max-width: 8vw;
      /* border: none; */
    }

    .table-img {
      max-width: 60px;
      max-height: 60px;
      object-fit: contain;
      border: none;
      border-radius: 4px;
    }
    .popup-img {
      width: 100%;
      /* max-height: 300px; */
      object-fit: contain;
      margin: 0 auto;
      display: block;
    }
    .hover\:bg-red-700:hover {
      background-color: #F15E22;
      color: #FFFFFF;
    }
    .pagination {
      display: flex;
      justify-content: center;
      align-items: center;
      gap: 0.5rem;
      margin-top: 1rem;
      flex-wrap: wrap;
    }
    .pagination button, .pagination select {
      padding: 0.25rem 0.5rem;
      border: 1px solid #FCDFD4;
      border-radius: 4px;
      background-color: #F15E22;
      color: white;
      cursor: pointer;
      font-size: clamp(0.75rem, 0.9vw, 0.85rem);
    }
    .pagination button.active {
      background-color: #0A3161;
      /* color: white; */
    }
    .pagination button:disabled {
      opacity: 0.5;
      cursor: not-allowed;
      background-color: #F9B79D;
    }
    .error-message {
      color: #F15E22;
      text-align: center;
      margin: 1rem 0;
      font-weight: bold;
      font-size: clamp(0.8rem, 1vw, 0.9rem);
    }
    .rating-display {
      display: flex;
      align-items: center;
      gap: 0.5rem;
      margin-bottom: 0.5rem;
      font-size: clamp(0.75rem, 0.9vw, 0.85rem);
    }
    .rating-star {
      font-size: clamp(0.8rem, 1vw, 0.9rem);
      color: #f59e0b;
    }
    .origin-filter-row {
      display: flex;
      flex-direction: column;
      gap: 0.5rem;
      margin-bottom: 0.75rem;
    }
    .origin-all {
      width: 100%;
      padding: 0.5rem;
      background-color: #0A3161;
      color: white;
      border: none;
      border-radius: 4px;
      font-weight: 600;
      text-align: center;
      font-size: clamp(0.8rem, 1vw, 0.9rem);
    }
    .origin-options {
      display: flex;
      flex-wrap: wrap;
      gap: 0.5rem;
    }
    .origin-option {
      flex: 1;
      min-width: 100px;
      padding: 0.4rem;
      background-color: #A3C4F3;
      color: #0A3161;
      border: none;
      border-radius: 4px;
      font-weight: 500;
      text-align: center;
      font-size: clamp(0.75rem, 0.9vw, 0.85rem);
    }
    .origin-option.active {
      background-color: #0A3161;
      color: white;
    }
    .category-filter-row {
      display: flex;
      flex-direction: column;
      gap: 0.5rem;
      margin-bottom: 0.75rem;
    }
    .category-all {
      width: 100%;
      padding: 0.5rem;
      background-color: #F15E22;
      color: white;
      border: none;
      border-radius: 4px;
      font-weight: 600;
      text-align: center;
      font-size: clamp(0.8rem, 1vw, 0.9rem);
    }
    .category-options {
      display: flex;
      flex-wrap: wrap;
      gap: 0.5rem;
    }
    .category-option {
      flex: 1;
      min-width: 100px;
      padding: 0.4rem;
      background-color: #FCDFD4;
      color: #F15E22;
      border: none;
      border-radius: 4px;
      font-weight: 500;
      text-align: center;
      font-size: clamp(0.75rem, 0.9vw, 0.85rem);
    }
    .category-option.active {
      background-color: #F15E22;
      color: white;
    }
    .search-container {
      display: flex;
      gap: 0.5rem;
      margin-bottom: 0.75rem;
    }
    .search-input {
      flex: 1;
      padding: 0.4rem;
      border: 1px solid #0A3161;
      border-radius: 4px;
      font-size: clamp(0.75rem, 0.9vw, 0.85rem);
    }
    .search-button {
      padding: 0.4rem 0.8rem;
      background-color: #0A3161;
      color: white;
      border: none;
      border-radius: 4px;
      cursor: pointer;
      font-size: clamp(0.75rem, 0.9vw, 0.85rem);
    }
    .barcode-container {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 0.25rem;
    }
    .barcode-svg {
      /* height: 28px;
      max-width: 150px; */
      width: 100%;
      /* min-width: 150px; */
    }
    #popup-barcode {
      transform: scale(1.5);
      transform-origin: top left;
    }
    .barcode-number {
      white-space: nowrap;
      font-size: clamp(0.75rem, 1vw, 0.95rem);
    }
    .barcode-number-large {
      white-space: nowrap;
      font-size: clamp(0.8rem, 1vw, 0.9rem);
    }
    #popup-details table {
      table-layout: auto;
      width: 100%;
      margin: 0 auto;
    }
    #popup-details td:first-child {
      width: auto;
      white-space: nowrap;
      font-weight: 500;
    }
    #popup-details td:nth-child(2) {
      padding: 0.5rem;
      word-break: break-word;
      width: 100%;
    }
    @media (max-width: 768px) {
      .origin-option, .category-option {
        flex: 1 0 calc(50% - 0.5rem);
      }
      th, td {
        padding: 4px;
      }
      .table-img {
        max-width: 50px;
        max-height: 50px;
      }
      /* .barcode-svg {
        height: 24px;
      } */
      th:nth-child(8), td:nth-child(8),
      th:nth-child(9), td:nth-child(9),
      th:nth-child(10), td:nth-child(10) {
        display: none;
      }
      table {
        min-width: 500px;
      }
    }
    @media (max-width: 480px) {
      .origin-option, .category-option {
        flex: 1 0 100%;
      }
      .search-container {
        flex-direction: column;
      }
      .search-button {
        width: 100%;
      }
      .popup {
        padding: 0.75rem;
        width: 98%;
      }
      /* .popup-img {
        max-height: 200px;
      } */
      h1 {
        font-size: clamp(1.2rem, 3vw, 1.5rem);
      }
    }
    @media (max-width: 320px) {
      .pagination button, .pagination select {
        padding: 0.2rem 0.4rem;
      }
    }
