/* Daltom Wholesale B2B - Professional Minimalist Styling */
:root {
  --daltom-red: #D71920;
  --daltom-red-dark: #B91C1C;
  --daltom-red-light: #FEE2E2;
  --daltom-black: #0F172A;
  --daltom-gray: #475569;
  --daltom-border: #E2E8F0;
  --daltom-bg: #F8FAFC;
  --surface: #FFFFFF;
}

* {
  box-sizing: border-box;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--daltom-bg);
  color: #1E293B;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Minimalist Editorial Cards */
.daltom-card {
  background: var(--surface);
  border: 1px solid var(--daltom-border);
  border-radius: 1rem;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.daltom-card:hover {
  border-color: #CBD5E1;
  box-shadow: 0 4px 12px -2px rgba(15, 23, 42, 0.06);
}

/* Red brand accents */
.bg-daltom-red {
  background-color: var(--daltom-red);
}
.text-daltom-red {
  color: var(--daltom-red);
}
.border-daltom-red {
  border-color: var(--daltom-red);
}

/* Product preview */
.product-image-container {
  position: relative;
  overflow: hidden;
  border-radius: 0.75rem;
  background: #F8FAFC;
}

.product-img {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.product-image-container:hover .product-img {
  transform: scale(1.04);
}

/* Matrix Quantity Input */
.qty-input-box {
  width: 48px;
  height: 36px;
  text-align: center;
  font-weight: 700;
  border: 1px solid #CBD5E1;
  border-radius: 0.375rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9rem;
  transition: all 0.15s ease;
}

.qty-input-box:focus {
  outline: none;
  border-color: var(--daltom-red);
  box-shadow: 0 0 0 2px rgba(215, 25, 32, 0.15);
  background-color: #FFFFFF;
}

.qty-input-box.has-value {
  background-color: #FFF1F2;
  border-color: var(--daltom-red);
  color: var(--daltom-red-dark);
}

/* Swatch Pill */
.swatch-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.55rem;
  border-radius: 0.375rem;
  border: 1px solid #E2E8F0;
  font-size: 0.75rem;
  font-weight: 600;
  background: #FFFFFF;
  cursor: pointer;
  transition: all 0.15s ease;
}

.swatch-pill:hover {
  border-color: #94A3B8;
  background-color: #F8FAFC;
}

.swatch-pill.active {
  border-color: var(--daltom-red);
  background-color: #FFF1F2;
  color: var(--daltom-red);
}

.color-dot {
  width: 14px;
  height: 14px;
  border-radius: 9999px;
  border: 1px solid rgba(0, 0, 0, 0.15);
  display: inline-block;
  flex-shrink: 0;
}

/* Mobile responsive drawer */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.drawer-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.drawer-content {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 540px;
  background: #FFFFFF;
  z-index: 51;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.drawer-backdrop.open .drawer-content {
  transform: translateX(0);
}

/* Custom scrollbars */
.scrollbar-thin::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.scrollbar-thin::-webkit-scrollbar-track {
  background: #F1F5F9;
}
.scrollbar-thin::-webkit-scrollbar-thumb {
  background: #CBD5E1;
  border-radius: 4px;
}
.scrollbar-thin::-webkit-scrollbar-thumb:hover {
  background: #94A3B8;
}

/* Horizontal Matrix Table Rows */
.matrix-table-row {
  transition: all 0.15s cubic-bezier(0.16, 1, 0.3, 1);
  border-left: 3px solid transparent;
}
.matrix-table-row:hover {
  background-color: #F8FAFC;
  border-left-color: #CBD5E1;
}
.matrix-table-row.ring-1 {
  border-left-color: var(--daltom-red) !important;
}

/* Mobile Sticky Bottom Bar */
@media (max-width: 640px) {
  .qty-input-box {
    width: 44px;
    height: 32px;
    font-size: 0.85rem;
  }
}

/* PRINT FORMAT - A4 HANDOVER NOTE */
@media print {
  @page {
    size: A4 portrait;
    margin: 12mm 15mm 15mm 15mm;
  }

  body {
    background: #FFFFFF !important;
    color: #000000 !important;
    font-size: 11pt !important;
    font-family: 'Times New Roman', Times, serif !important;
  }

  .no-print {
    display: none !important;
  }

  .print-only {
    display: block !important;
  }

  .a4-document {
    box-shadow: none !important;
    border: none !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  .a4-document table {
    width: 100% !important;
    border-collapse: collapse !important;
  }

  .a4-document table th,
  .a4-document table td {
    border: 1px solid #000000 !important;
    padding: 6px 8px !important;
    font-size: 10pt !important;
  }

  .a4-document th {
    background-color: #F5F5F5 !important;
    font-weight: bold !important;
  }
}
