/* cards.css - Persistent Sold Overlay (Always Visible) */

.card-container {
  background: #1e2937;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
}

.card-container:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.5);
}

.card-image {
  position: relative;
  padding-top: 145%;
  overflow: hidden;
}

.card-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* SOLD OVERLAY - ALWAYS VISIBLE */
.card-image.sold::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('images/sold.png') center/contain no-repeat;
  background-color: rgba(0, 0, 0, 0.75);
  z-index: 10;
  pointer-events: none;
  opacity: 1 !important;
}

/* Hover Name */
.card-image::after {
  content: attr(data-name);
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
  color: white;
  padding: 1.2rem 0.8rem 0.8rem;
  text-align: center;
  font-weight: 700;
  font-size: 1.1rem;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  z-index: 3;
}

.card-container:hover .card-image::after {
  opacity: 1;
}

.card-info {
  padding: 1rem;
  background: #111827;
}

/* Action Buttons */
.card-actions {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  gap: 6px;
  opacity: 0;
  transition: opacity 0.2s;
  z-index: 20;
}

.card-container:hover .card-actions {
  opacity: 1;
}

.card-actions button {
  width: 34px;
  height: 34px;
  border: none;
  border-radius: 50%;
  color: white;
  font-size: 1.2rem;
  cursor: pointer;
}

.btn-sold { background: #22c55e; }
.btn-copy { background: #3b82f6; }
.btn-delete { background: #ef4444; }

/* Info Rows */
.card-details {
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
  padding: 10px 12px;
  flex-wrap: wrap;
  gap: 8px;
}

.card-psa {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  padding: 8px 12px;
  color: #94a3b8;
  flex-wrap: wrap;
  gap: 8px;
  border-top: 1px solid #334155;
}

.sold-price {
  margin-top: 8px;
  padding: 8px;
  background: #166534;
  color: #86efac;
  font-weight: 600;
  text-align: center;
  border-radius: 6px;
}

/* Mass Refresh Button */
.mass-refresh-btn {
  padding: 10px 18px;
  background: #eab308;
  color: black;
  font-weight: bold;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.mass-refresh-btn:hover {
  background: #facc15;
  transform: translateY(-2px);
}

.mass-refresh-btn:disabled {
  background: #64748b;
  color: white;
  cursor: not-allowed;
  transform: none;
}

/* Archive Button */
.archive-btn {
  padding: 10px 18px;
  background: #ef4444;
  color: white;
  font-weight: bold;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.archive-btn:hover {
  background: #f87171;
  transform: translateY(-2px);
}

.archive-btn:active {
  transform: translateY(1px);
}

/* Action Buttons Layout */
.search-section {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.search-section input[type="search"] {
  flex: 1;
  min-width: 250px;
}

@media (max-width: 768px) {
  .search-section {
    flex-direction: column;
    align-items: stretch;
  }
}