/* Container */
#auction-filter-container {
  margin-bottom: 20px;
  overflow-x: auto;
}

/* Table */
.won-lost-table {
  width: 100%;
  font-family: 'Montserrat', sans-serif;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  border-radius: 2px;
  border: 1px solid #e2e2e2;
  border-spacing: 0;
}

/* Table Header */
.won-lost-table thead th {
  background: #130100;
  color: #fff;
  font-weight: bold;
  padding: 12px 15px;
  text-align: left;
  font-size: 14px;
  border-bottom: 1px solid #ccc;
}

/* Table Body */
.won-lost-table tbody td {
  padding: 12px 15px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
  font-size: 13px;
  color: #333;
  position: relative;
}

/* Last row border removal */
.won-lost-table tbody tr:last-child td {
  border-bottom: none;
}

/* Hover effect */
.won-lost-table tbody tr:hover {
  background: #f9f9f9;
}

/* Product cell with image and title */
.won-lost-table tbody td:first-child {
  display: flex;
  align-items: center;
  gap: 10px; /* space between image and title */
}

/* Product image */
.won-lost-table .product-img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 5px;
  flex-shrink: 0;
}

/* Product link/title */
.won-lost-table td:first-child a {
  display: inline-block;
  max-width: 250px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #0073aa;
  text-decoration: none;
}

.won-lost-table td:first-child a:hover {
  text-decoration: underline;
}

/* Padding adjustment for header */
table.won-lost-table tr th {
  padding-left: 14px !important;
}

/* Responsive */
@media screen and (max-width: 768px) {
  #auction-filter-container {
    overflow-x: auto;
  }

  .won-lost-table tbody td {
    display: block;
    width: 100%;
    padding-left: 50%;
    box-sizing: border-box;
    text-align: left;
  }

  /* Show label on left */
  .won-lost-table tbody td:before {
    content: attr(data-label);
    position: absolute;
    left: 15px;
    font-weight: bold;
    color: #130100;
    white-space: nowrap;
  }

  /* Product cell image + title inline */
  .won-lost-table tbody td:first-child {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-left: 15px !important;
  }

  .won-lost-table td:first-child a {
    max-width: calc(100% - 60px);
  }
}

@media screen and (max-width: 480px) {
  .won-lost-table td:first-child a {
    max-width: calc(100% - 55px);
    font-size: 12px;
  }

  .won-lost-table tbody td {
    padding: 10px 10px;
    font-size: 12px;
  }

  .won-lost-table thead th {
    font-size: 12px;
    padding: 8px 10px;
  }
}
