/* ZozoDeal Listing Quality & Health Assistant */

.listing-quality-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1;
}

.listing-quality-badge.quality-good {
  background: #dcfce7;
  color: #15803d;
  border-color: #bbf7d0;
}

.listing-quality-badge.quality-good:hover {
  background: #bbf7d0;
}

.listing-quality-badge.quality-fair {
  background: #fef3c7;
  color: #b45309;
  border-color: #fde68a;
}

.listing-quality-badge.quality-fair:hover {
  background: #fde68a;
}

.listing-quality-badge.quality-bad {
  background: #fee2e2;
  color: #b91c1c;
  border-color: #fecaca;
}

.listing-quality-badge.quality-bad:hover {
  background: #fecaca;
}

.quality-score {
  font-variant-numeric: tabular-nums;
}

.quality-label {
  text-transform: uppercase;
  font-size: 0.68rem;
  letter-spacing: 0.03em;
}

/* Modal Overlay */
.quality-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(4px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  animation: quality-fade 0.2s ease-out;
}

@keyframes quality-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.quality-modal-sheet {
  background: #ffffff;
  width: 100%;
  max-width: 540px;
  max-height: 85vh;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
}

.quality-modal-header {
  padding: 1rem 1.25rem;
  background: #1e293b;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.quality-kicker {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #38bdf8;
  letter-spacing: 0.04em;
  display: block;
}

.quality-title {
  margin: 2px 0 0 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.quality-close-btn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 1.6rem;
  cursor: pointer;
  line-height: 1;
}

.quality-close-btn:hover {
  color: #ffffff;
}

.quality-modal-body {
  padding: 1.25rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

/* Meter Hero */
.quality-score-hero {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1rem;
  background: #f8fafc;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
}

.quality-meter-wrap {
  position: relative;
  width: 84px;
  height: 84px;
  flex-shrink: 0;
}

.quality-meter-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.quality-meter-bg {
  fill: none;
  stroke: #e2e8f0;
  stroke-width: 8;
}

.quality-meter-progress {
  fill: none;
  stroke-width: 8;
  stroke-linecap: round;
  stroke-dasharray: 283;
  transition: stroke-dashoffset 0.8s ease;
}

.quality-meter-value {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.meter-num {
  font-size: 1.4rem;
  font-weight: 800;
  color: #0f172a;
}

.meter-total {
  font-size: 0.65rem;
  color: #64748b;
  margin-top: 2px;
}

.quality-hero-text h3 {
  margin: 0 0 4px 0;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
}

.quality-hero-text p {
  margin: 0;
  font-size: 0.82rem;
  color: #475569;
  line-height: 1.4;
}

/* Checklist */
.quality-checklist {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.quality-checklist h4 {
  margin: 0 0 4px 0;
  font-size: 0.88rem;
  font-weight: 700;
  color: #1e293b;
}

.quality-check-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
}

.quality-check-item.passed {
  border-left: 3px solid #10b981;
}

.quality-check-item.passed .material-symbols-outlined {
  color: #10b981;
  font-size: 20px;
}

.quality-check-item.failed {
  border-left: 3px solid #ef4444;
}

.quality-check-item.failed .material-symbols-outlined {
  color: #ef4444;
  font-size: 20px;
}

.quality-check-content {
  flex: 1;
}

.quality-check-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: #1e293b;
}

.quality-pts {
  font-size: 0.78rem;
  font-weight: 600;
  color: #64748b;
}

.quality-hint {
  margin: 2px 0 0 0;
  font-size: 0.78rem;
  color: #64748b;
}

/* Actions */
.quality-actions {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}

.quality-action-btn {
  flex: 1;
  padding: 10px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.quality-action-btn.primary {
  background: #0284c7;
  color: #ffffff;
  border: none;
}

.quality-action-btn.primary:hover {
  background: #0369a1;
}

.quality-action-btn.secondary {
  background: #ffffff;
  color: #334155;
  border: 1px solid #cbd5e1;
}
