* { box-sizing: border-box; margin: 0; padding: 0; }

.btn-icon { background: none; border: 1px solid #e5e5e5; border-radius: 8px; padding: 8px; cursor: pointer; color: #555; display: flex; align-items: center; justify-content: center; }
.btn-icon:hover { background: #f5f5f5; color: #000; }

.settings-panel { background: #fff; width: 360px; height: 100vh; margin-left: auto; padding: 28px 24px; display: flex; flex-direction: column; gap: 24px; overflow-y: auto; }
.settings-header { display: flex; justify-content: space-between; align-items: center; }
.settings-header h2 { margin: 0; font-size: 1.1rem; color: #1a1a1a; }
.settings-section { display: flex; flex-direction: column; gap: 12px; }
.settings-label { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: #999; }
.copy-row { display: flex; gap: 8px; }
.copy-row input { flex: 1; font-size: 0.82rem; color: #555; background: #f8f8f8; border: 1px solid #e5e5e5; border-radius: 6px; padding: 8px 10px; }
.color-row { display: flex; align-items: center; justify-content: space-between; font-size: 0.9rem; color: #444; }
.color-row input[type="color"] { width: 40px; height: 32px; border: 1px solid #e5e5e5; border-radius: 6px; cursor: pointer; padding: 2px; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: #f5f5f5;
  color: #1a1a1a;
  line-height: 1.5;
}

.container {
  max-width: 900px;
  margin: 40px auto;
  padding: 0 20px;
}

.container.narrow {
  max-width: 400px;
  margin-top: 100px;
}

h1 { font-size: 1.8rem; margin-bottom: 24px; }
h2 { font-size: 1.1rem; margin-bottom: 16px; color: #444; }
h3 { font-size: 1rem; }

.section {
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 20px;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 6px;
  color: #333;
}

.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 0.95rem;
  font-family: inherit;
  background: #fff;
  transition: border-color 0.15s;
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: #000;
}

.field input[type="file"] {
  padding: 8px;
  background: #f9f9f9;
}

.product-card {
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 16px;
}

.product-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.submit-row {
  margin-top: 24px;
}

.btn-primary {
  background: #000;
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.15s;
}

.btn-primary:hover { opacity: 0.85; }
.btn-primary.full-width { width: 100%; }

.btn-secondary {
  background: #fff;
  color: #000;
  border: 1px solid #ddd;
  padding: 10px 18px;
  border-radius: 6px;
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  transition: background 0.15s;
}

.btn-secondary:hover { background: #f5f5f5; }
.btn-secondary.small { padding: 6px 14px; font-size: 0.8rem; }

.btn-remove {
  background: none;
  border: none;
  color: #999;
  font-size: 0.875rem;
  cursor: pointer;
  padding: 4px 8px;
}

.btn-remove:hover { color: #e00; }

.variants-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.variant-row { display: flex; gap: 8px; align-items: center; }
.variant-row input[data-variant-size] { flex: 1; }
.variant-row input[data-variant-qty] { width: 80px; }
.btn-add-variant { background: none; border: 1px dashed #ccc; color: #555; padding: 6px 14px; border-radius: 6px; cursor: pointer; font-size: 0.85rem; }
.btn-add-variant:hover { border-color: #999; color: #222; }
.btn-remove-variant { background: none; border: none; color: #bbb; font-size: 1.1rem; cursor: pointer; padding: 0 4px; line-height: 1; }
.btn-remove-variant:hover { color: #e00; }

.btn-approve {
  background: #16a34a;
  color: #fff;
  border: none;
  padding: 12px 24px;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  margin-right: 12px;
  transition: opacity 0.15s;
}

.btn-approve:hover { opacity: 0.85; }
.btn-approve.small { padding: 5px 10px; font-size: 0.78rem; margin-right: 4px; }

.btn-reject {
  background: #fff;
  color: #dc2626;
  border: 1px solid #dc2626;
  padding: 12px 24px;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-reject:hover { background: #fef2f2; }
.btn-reject.small { padding: 5px 10px; font-size: 0.78rem; }

.action-cell { display: flex; align-items: center; gap: 4px; flex-wrap: nowrap; }

.alert {
  padding: 14px 18px;
  border-radius: 6px;
  margin-bottom: 24px;
  font-size: 0.9rem;
}

.alert.success { background: #f0fdf4; color: #16a34a; border: 1px solid #bbf7d0; }
.alert.error { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; }

.header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
}

.subtitle {
  color: #666;
  font-size: 0.875rem;
  margin-top: 4px;
}

.tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 24px;
  border-bottom: 1px solid #e5e5e5;
}

.tab {
  padding: 10px 18px;
  text-decoration: none;
  color: #666;
  font-size: 0.9rem;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s;
  background: none;
  cursor: pointer;
  font-family: inherit;
}

.tab:hover { color: #000; }
.tab.active { color: #000; font-weight: 500; border-bottom-color: #000; }

.sub-tabs {
  display: flex;
  gap: 2px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #f0f0f0;
}

.sub-tab {
  padding: 6px 14px;
  font-size: 0.82rem;
  border: 1px solid #e5e5e5;
  border-radius: 20px;
  background: #fff;
  color: #666;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s;
}

.sub-tab:hover { border-color: #999; color: #000; }
.sub-tab.active { background: #000; color: #fff; border-color: #000; }

.table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  overflow: hidden;
}

.table th {
  text-align: left;
  padding: 12px 16px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #666;
  background: #f9f9f9;
  border-bottom: 1px solid #e5e5e5;
}

.table td {
  padding: 14px 16px;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.9rem;
}

.table tr:last-child td { border-bottom: none; }

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 500;
  text-transform: capitalize;
}

.badge.pending { background: #fef9c3; color: #854d0e; }
.badge.approved { background: #f0fdf4; color: #16a34a; }
.badge.rejected { background: #fef2f2; color: #dc2626; }

.stats-row {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  flex: 1;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 10px;
  padding: 16px 20px;
  text-align: center;
}

.stat-num {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #999;
  font-weight: 600;
}

.pending-stat { border-top: 3px solid #f59e0b; }
.pending-stat .stat-num { color: #b45309; }
.approved-stat { border-top: 3px solid #16a34a; }
.approved-stat .stat-num { color: #16a34a; }
.rejected-stat { border-top: 3px solid #dc2626; }
.rejected-stat .stat-num { color: #dc2626; }

.brand-accordion {
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 10px;
  margin-bottom: 10px;
  overflow: hidden;
}

.brand-accordion-header-row { display: flex; align-items: center; }

.brand-accordion-header {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  text-align: left;
  min-width: 0;
}

.brand-accordion-header:hover { background: #fafafa; }

.brand-remove-btn { background: none; border: none; cursor: pointer; padding: 10px 14px; color: #ccc; flex-shrink: 0; line-height: 1; }
.brand-remove-btn:hover { color: #ef4444; }

.brand-accordion-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-accordion-arrow { font-size: 0.65rem; color: #aaa; }
.brand-accordion-name { font-size: 0.95rem; font-weight: 700; color: #1a1a1a; }
.brand-accordion-body { padding: 0 20px 16px; }

.product-count-badge {
  background: #f0f0f0;
  color: #555;
  border-radius: 20px;
  padding: 2px 10px;
  font-size: 0.78rem;
  font-weight: 600;
}

.empty {
  color: #999;
  text-align: center;
  padding: 60px 0;
  font-size: 0.95rem;
}

.back-link {
  display: inline-block;
  color: #666;
  text-decoration: none;
  font-size: 0.875rem;
  margin-bottom: 24px;
}

.back-link:hover { color: #000; }

.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.product-card .product-image {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 6px 6px 0 0;
  display: block;
}

.product-image-placeholder {
  width: 100%;
  height: 180px;
  background: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  font-size: 0.85rem;
  border-radius: 6px 6px 0 0;
}

.product-info {
  padding: 14px;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.product-info h3 { margin-bottom: 6px; }

.price {
  font-weight: 600;
  color: #000;
  margin-bottom: 6px;
}

.description {
  font-size: 0.85rem;
  color: #666;
  margin-top: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.image-count {
  font-size: 0.78rem;
  color: #999;
  margin-top: 6px;
}

.meta {
  font-size: 0.82rem;
  color: #555;
  margin-top: 4px;
}

.variants-display {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.variant-tag {
  background: #f0f0f0;
  border-radius: 4px;
  padding: 3px 8px;
  font-size: 0.78rem;
  color: #444;
  font-weight: 600;
}

.variant-row-display { padding: 3px 0; }
.variant-size-label { font-size: 0.88rem; font-weight: 600; color: #1a1a1a; }
.variant-qty-label { font-size: 0.88rem; color: #888; margin-left: 8px; }

.actions {
  padding: 24px 0;
  border-top: 1px solid #e5e5e5;
}

.radio-group {
  display: flex;
  gap: 24px;
  margin-top: 4px;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  cursor: pointer;
}

.radio-label input[type="radio"] {
  width: auto;
  margin: 0;
}

.store-type-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.store-tab {
  padding: 10px 20px;
  border: 1px solid #ddd;
  border-radius: 6px;
  background: #fff;
  font-size: 0.9rem;
  cursor: pointer;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  color: #555;
  transition: all 0.15s;
}

.store-tab:hover { border-color: #000; color: #000; }
.store-tab.active { background: #000; color: #fff; border-color: #000; }

.badge.store-badge.online { background: #eff6ff; color: #1d4ed8; }
.badge.store-badge.physical { background: #fdf4ff; color: #7e22ce; }

/* Image upload grid */
.img-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.img-slot {
  position: relative;
  aspect-ratio: 1;
  border-radius: 8px;
  overflow: hidden;
  background: #f0f0f0;
}

.img-slot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.img-hero-tag {
  position: absolute;
  bottom: 6px;
  left: 6px;
  background: rgba(0,0,0,0.55);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.03em;
}

.img-remove-btn {
  position: absolute;
  top: 5px;
  right: 5px;
  background: rgba(0,0,0,0.5);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 15px;
  line-height: 1;
  opacity: 0;
  transition: opacity 0.15s;
}

.img-slot:hover .img-remove-btn { opacity: 1; }

.img-slot-add {
  border: 1.5px dashed #ccc;
  background: #fafafa;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #aaa;
  transition: border-color 0.15s, color 0.15s;
}

.img-slot-add:hover { border-color: #888; color: #555; }

/* Submission review — additional images strip */
.product-images-strip {
  display: flex;
  gap: 4px;
  padding: 4px;
  background: #f9f9f9;
  flex-wrap: wrap;
}

.product-image-thumb {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 4px;
  display: block;
}
