:root {
  --navy-950: #071529;
  --navy-900: #0b1f3a;
  --navy-800: #132c4f;
  --teal-600: #0d9488;
  --teal-700: #0f766e;
  --teal-50: #f0fdfa;
  --teal-100: #ccfbf1;
  --blue-600: #2563eb;
  --blue-50: #eff6ff;
  --amber-600: #d97706;
  --amber-50: #fffbeb;
  --amber-200: #fde68a;
  --danger: #dc2626;
  --danger-hover: #b91c1c;
  --danger-bg: #fef2f2;
  --bg: #f1f5f9;
  --surface: #ffffff;
  --surface-subtle: #f8fafc;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --text-900: #0f172a;
  --text-700: #334155;
  --text-500: #64748b;
  --text-400: #94a3b8;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 999px;
  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 12px 28px rgba(15, 23, 42, 0.12);
  --shadow-lg: 0 22px 54px rgba(7, 21, 41, 0.25);
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text-900);
  line-height: 1.5;
  min-height: 100vh;
}

body.no-scroll { overflow: hidden; }
button, input, select { font-family: inherit; }
.hidden { display: none !important; }

/* ========================
   LOGIN SCREEN
   ======================== */
.login-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: linear-gradient(135deg, var(--navy-950) 0%, var(--navy-800) 60%, #114454 100%);
}

.login-card {
  width: 100%;
  max-width: 410px;
  background: var(--surface);
  border-radius: 20px;
  padding: 30px 28px 24px;
  box-shadow: var(--shadow-lg);
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.login-brand h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--navy-900);
  line-height: 1.2;
}

.login-brand p {
  margin: 2px 0 0;
  font-size: 0.84rem;
  color: var(--text-500);
}

.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--teal-600), var(--navy-900));
  color: #fff;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.brand-mark.small {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.password-wrap {
  position: relative;
  display: flex;
}

.password-wrap input {
  width: 100%;
  padding-right: 54px;
}

.toggle-pass-btn {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  color: var(--text-500);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
}

.toggle-pass-btn:hover { background: var(--bg); color: var(--navy-900); }

.login-footer {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  text-align: center;
}

.text-link {
  color: var(--teal-700);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
}
.text-link:hover { text-decoration: underline; }

/* ========================
   HEADER
   ======================== */
.admin-container {
  width: 100%;
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 18px;
}

.admin-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--navy-900);
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 16px rgba(7, 21, 41, 0.16);
}

.header-inner {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding-top: 8px;
  padding-bottom: 8px;
}

.header-left, .header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #fff;
}

.brand-title {
  display: flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.02rem;
  line-height: 1.15;
}

.badge-admin {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: rgba(13, 148, 136, 0.25);
  color: #5eead4;
  border: 1px solid rgba(94, 234, 212, 0.35);
  padding: 2px 7px;
  border-radius: var(--radius-pill);
}

.brand-sub {
  display: block;
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.68);
}

.mode-pill {
  font-size: 0.74rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.1);
  color: #e2e8f0;
  white-space: nowrap;
}

.mode-pill.server {
  background: rgba(16, 185, 129, 0.18);
  color: #6ee7b7;
  border: 1px solid rgba(110, 231, 183, 0.3);
}

.mode-pill.static {
  background: rgba(245, 158, 11, 0.2);
  color: #fcd34d;
  border: 1px solid rgba(252, 211, 77, 0.3);
}

.profile-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 11px 4px 5px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.1);
  font-size: 0.8rem;
  font-weight: 600;
}

.profile-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--teal-600);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
}

/* ========================
   MAIN & STATS
   ======================== */
.admin-main {
  padding-top: 20px;
  padding-bottom: 48px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.banner-warn {
  background: var(--amber-50);
  border: 1px solid var(--amber-200);
  color: #78350f;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  font-size: 0.86rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

@media (min-width: 768px) {
  .stats-grid { grid-template-columns: repeat(5, 1fr); }
}

.stat-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  text-align: left;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: var(--shadow-sm);
}

.stat-card:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.stat-card.active { border-color: var(--navy-900); box-shadow: 0 0 0 2px rgba(11, 31, 58, 0.1); }

.stat-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-500);
  margin-bottom: 4px;
}

.stat-value {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 800;
  color: var(--navy-900);
}

.text-teal { color: var(--teal-700); }
.text-muted { color: var(--text-500); }
.text-blue { color: var(--blue-600); }
.text-amber { color: var(--amber-600); }

/* ========================
   TOOLBAR
   ======================== */
.toolbar-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.toolbar-top {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.search-box {
  position: relative;
  flex: 1;
  min-width: 240px;
}

.search-icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-400);
  pointer-events: none;
}

.search-box input {
  width: 100%;
  padding: 10px 14px 10px 40px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  background: var(--surface-subtle);
  color: var(--text-900);
  outline: none;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.search-box input:focus {
  border-color: var(--teal-600);
  background: #fff;
}

.toolbar-filters {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.toolbar-filters select {
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border);
  background: #fff;
  color: var(--text-700);
  font-size: 0.85rem;
  font-weight: 500;
  outline: none;
  cursor: pointer;
}

.toolbar-filters select:focus { border-color: var(--teal-600); }

.results-meta {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.84rem;
  color: var(--text-500);
  font-weight: 500;
}

.link-btn {
  border: none;
  background: none;
  color: var(--teal-700);
  font-weight: 600;
  font-size: 0.83rem;
  cursor: pointer;
  padding: 0;
}
.link-btn:hover { text-decoration: underline; }

/* ========================
   TABLE
   ======================== */
.table-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

.products-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.products-table th {
  text-align: left;
  padding: 12px 14px;
  background: var(--surface-subtle);
  color: var(--text-500);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.products-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.products-table tbody tr:hover { background: #f8fafc; }
.products-table tbody tr.is-hidden-row { opacity: 0.62; }

.col-id { width: 58px; color: var(--text-400); font-weight: 600; font-size: 0.8rem; }
.col-img { width: 64px; }
.col-num { text-align: right; white-space: nowrap; }
.products-table th.col-num { text-align: right; }
.col-status { width: 100px; text-align: center; }
.products-table th.col-status { text-align: center; }
.col-actions { width: 165px; text-align: right; white-space: nowrap; }
.products-table th.col-actions { text-align: right; }

.thumb {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #fff;
  display: grid;
  place-items: center;
  overflow: hidden;
  flex-shrink: 0;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2px;
}

.thumb-icon {
  font-size: 1.35rem;
}

.prod-title {
  font-weight: 700;
  color: var(--text-900);
  line-height: 1.25;
}

.prod-meta {
  font-size: 0.78rem;
  color: var(--text-500);
  margin-top: 2px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.cat-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-700);
  white-space: nowrap;
}

.frozen-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 7px;
  border-radius: var(--radius-pill);
  background: var(--blue-50);
  color: var(--blue-600);
  font-size: 0.72rem;
  font-weight: 700;
}

.price-cell {
  font-family: var(--font-display);
  font-weight: 800;
  color: var(--navy-900);
  font-size: 0.95rem;
}

.margin-sub {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--teal-700);
}

.cost-cell {
  color: var(--text-500);
  font-weight: 500;
}

/* Toggle Switch */
.switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 24px;
}

.switch input { opacity: 0; width: 0; height: 0; }

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #cbd5e1;
  border-radius: 999px;
  transition: 0.18s;
}

.slider::before {
  content: '';
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: #fff;
  border-radius: 50%;
  transition: 0.18s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.switch input:checked + .slider { background: var(--teal-600); }
.switch input:checked + .slider::before { transform: translateX(18px); }

.row-actions {
  display: inline-flex;
  gap: 6px;
}

.empty-table {
  padding: 40px 20px;
  text-align: center;
  color: var(--text-500);
}

/* ========================
   BUTTONS
   ======================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 15px;
  border-radius: var(--radius-sm);
  border: 1.5px solid transparent;
  font-size: 0.87rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-sm { padding: 6px 11px; font-size: 0.8rem; }
.btn-lg { padding: 12px 18px; font-size: 0.94rem; }
.btn-block { width: 100%; }

.btn-primary { background: var(--teal-600); color: #fff; }
.btn-primary:hover { background: var(--teal-700); }

.btn-secondary { background: var(--surface); color: var(--text-700); border-color: var(--border-strong); }
.btn-secondary:hover { background: var(--surface-subtle); color: var(--navy-900); }

.btn-ghost { background: rgba(255, 255, 255, 0.1); color: #fff; border-color: rgba(255, 255, 255, 0.16); }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.18); }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: var(--danger-hover); }

.btn-danger-outline { background: #fff; color: var(--danger); border-color: #fecaca; }
.btn-danger-outline:hover { background: var(--danger-bg); border-color: var(--danger); }

.btn-danger-ghost { background: rgba(220, 38, 38, 0.18); color: #fecaca; border-color: rgba(254, 202, 202, 0.25); }
.btn-danger-ghost:hover { background: rgba(220, 38, 38, 0.32); color: #fff; }

.btn:disabled { opacity: 0.55; cursor: not-allowed; }

/* ========================
   MODALS & FORMS
   ======================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(7, 21, 41, 0.62);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  overflow-y: auto;
}

.modal-card {
  width: 100%;
  background: var(--surface);
  border-radius: 18px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  max-height: calc(100vh - 32px);
  display: flex;
  flex-direction: column;
}

.modal-sm { max-width: 440px; }
.modal-md { max-width: 580px; }
.modal-lg { max-width: 780px; }

.modal-header {
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.modal-header h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--navy-900);
}

.modal-sub {
  margin: 2px 0 0;
  font-size: 0.82rem;
  color: var(--text-500);
}

.close-btn {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
  color: var(--text-700);
  font-size: 1rem;
  cursor: pointer;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.close-btn:hover { background: var(--bg); color: var(--navy-900); }

.modal-body {
  padding: 20px 22px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-footer {
  padding-top: 12px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 4px;
}

.form-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 720px) {
  .form-layout { grid-template-columns: 220px 1fr; }
}

.fields-col {
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.section-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-500);
  margin-bottom: 6px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.field label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-700);
}

.field .opt {
  font-weight: 400;
  color: var(--text-400);
}

.field input[type="text"],
.field input[type="password"],
.field input[type="number"],
.field select {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  color: var(--text-900);
  background: #fff;
  outline: none;
  transition: border-color 0.15s ease;
}

.field input:focus, .field select:focus { border-color: var(--teal-600); }

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.field-row.three { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.field-xs { max-width: 110px; }

.input-with-btn {
  display: flex;
  gap: 6px;
}

.input-with-btn input { flex: 1; }

.price-box {
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.price-hint {
  font-size: 0.8rem;
  color: var(--teal-700);
  font-weight: 600;
}

.toggles-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (max-width: 520px) {
  .field-row, .field-row.three, .toggles-row { grid-template-columns: 1fr; }
}

.check-card {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  background: #fff;
}

.check-card:hover { border-color: var(--border-strong); }
.check-card input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--teal-600); }
.check-card strong { display: block; font-size: 0.84rem; color: var(--text-900); }
.check-card span { display: block; font-size: 0.74rem; color: var(--text-500); }

/* Photo Uploader */
.photo-dropzone {
  border: 1.5px dashed var(--border-strong);
  border-radius: var(--radius-md);
  padding: 14px;
  background: var(--surface-subtle);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.photo-dropzone.dragover {
  border-color: var(--teal-600);
  background: var(--teal-50);
}

.photo-preview {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #fff;
  border-radius: 10px;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  color: var(--text-400);
  font-size: 0.82rem;
  overflow: hidden;
}

.photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
}

.photo-placeholder-icon { font-size: 2rem; }
.photo-actions { display: flex; gap: 8px; }
.help-text { font-size: 0.76rem; color: var(--text-500); }

.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 4px 0;
}

.form-error {
  margin: 0;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--danger-bg);
  color: var(--danger);
  font-size: 0.84rem;
  font-weight: 600;
}

/* Delete Preview */
.delete-warn-text { margin: 0; font-size: 0.9rem; color: var(--text-700); }

.delete-preview {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
  border: 1px solid var(--border);
}

/* Toasts */
.toast-container {
  position: fixed;
  top: 76px;
  right: 16px;
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  background: var(--navy-900);
  color: #fff;
  padding: 10px 15px;
  border-radius: 10px;
  font-size: 0.84rem;
  font-weight: 600;
  box-shadow: var(--shadow-md);
}

.toast.error { background: var(--danger); }

/* ========================
   TABS & VENTAS
   ======================== */
.admin-tabs { display: flex; gap: 8px; }
.admin-tab {
  border: 1.5px solid var(--border); background: var(--surface); color: var(--text-700);
  padding: 9px 18px; border-radius: var(--radius-pill); font-weight: 700; font-size: 0.9rem;
  cursor: pointer; display: inline-flex; align-items: center; gap: 7px;
}
.admin-tab.active { background: var(--navy-900); color: #fff; border-color: var(--navy-900); }
.tab-badge {
  background: var(--amber-600); color: #fff; font-size: 0.72rem; padding: 1px 7px;
  border-radius: var(--radius-pill);
}
#productsView, .sales-view { display: flex; flex-direction: column; gap: 16px; }
.stat-static { cursor: default; }
.stat-static:hover { transform: none; }
.sales-list { display: flex; flex-direction: column; gap: 12px; }
.sale-card {
  background: var(--surface); border: 1px solid var(--border); border-left: 5px solid var(--amber-600);
  border-radius: var(--radius-lg); padding: 14px 16px; box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column; gap: 10px;
}
.sale-card.status-won { border-left-color: var(--teal-600); }
.sale-card.status-lost { border-left-color: var(--text-400); opacity: 0.8; }
.sale-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.sale-order { font-family: var(--font-display); font-weight: 800; font-size: 1.02rem; color: var(--navy-900); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.sale-total { font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; color: var(--navy-900); text-align: right; }
.sale-total span { display: block; font-family: var(--font-sans); font-size: 0.75rem; color: var(--text-500); font-weight: 600; }
.status-pill { font-family: var(--font-sans); font-size: 0.72rem; font-weight: 700; padding: 2px 9px; border-radius: var(--radius-pill); background: var(--amber-50); color: var(--amber-600); }
.status-pill.won { background: var(--teal-50); color: var(--teal-700); }
.status-pill.lost { background: var(--bg); color: var(--text-500); }
.sale-info { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 0.85rem; color: var(--text-700); }
.sale-items { width: 100%; border-collapse: collapse; font-size: 0.86rem; background: var(--surface-subtle); border-radius: var(--radius-sm); }
.sale-items td { padding: 6px 10px; border-bottom: 1px solid var(--border); }
.sale-items tr:last-child td { border-bottom: none; }
.sku-code { font-weight: 800; color: var(--navy-900); background: #fff; border: 1px solid var(--border-strong); padding: 2px 6px; border-radius: 6px; font-size: 0.8rem; white-space: nowrap; }
.qty-cell { font-weight: 800; white-space: nowrap; width: 48px; }
.sale-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.sale-note { flex: 1; min-width: 200px; padding: 7px 10px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-size: 0.85rem; }
.sale-note:focus { outline: none; border-color: var(--teal-600); }
.btn-won { background: var(--teal-600); color: #fff; }
.btn-won:hover { background: var(--teal-700); }
.btn-lost { background: #fff; color: var(--text-700); border-color: var(--border-strong); }
.btn-lost:hover { background: var(--bg); }

/* Verificación de precios de cada venta */
.price-check { margin: 10px 0 4px; padding: 8px 12px; border-radius: 10px; font-size: 0.85rem; line-height: 1.4; }
.price-check.ok { background: var(--teal-50); color: var(--teal-700); }
.price-check.bad { background: #fdecec; color: #b42318; border: 1px solid #f5c2c0; }
.price-diff { display: block; font-size: 0.72rem; color: #b42318; font-weight: 600; }
