/**
 * PICTOR theme — Tabler overrides & legacy component bridge
 */
:root {
  --tblr-primary: #206bc4;
  --tblr-primary-rgb: 32, 107, 196;
  --pictor-body-color: #1e293b;
  --pictor-muted: #475569;
  --pictor-page-bg: #f1f5f9;
}

body.pictor-app {
  color: var(--pictor-body-color);
  background: var(--pictor-page-bg);
}

body.pictor-app .page-body {
  background: var(--pictor-page-bg);
}

body.pictor-app .text-muted,
body.pictor-app .text-secondary {
  color: var(--pictor-muted) !important;
}

body.pictor-app .card,
body.pictor-app .customer-card,
body.pictor-app .order-card,
body.pictor-app .form-label,
body.pictor-app .page-title,
body.pictor-app h1,
body.pictor-app h2,
body.pictor-app h3,
body.pictor-app h4,
body.pictor-app h5,
body.pictor-app h6 {
  color: var(--pictor-body-color);
}

/* Colored KPI cards must keep light text */
body.pictor-app .stat-card.text-white,
body.pictor-app .stat-card.text-white h6,
body.pictor-app .stat-card.text-white p,
body.pictor-app .stat-card.text-white small,
body.pictor-app .stat-card.text-white .progress-label,
body.pictor-app .stat-card.text-white .progress-label span {
  color: #fff !important;
}

.pictor-standalone {
  min-height: 100dvh;
}

/* Auth / login */
body.pictor-auth .pictor-standalone {
  display: flex;
  min-height: 100dvh;
}

body.pictor-auth .page.page-center {
  flex: 1;
  width: 100%;
}

.pictor-auth-wide {
  max-width: 42rem;
}

.pictor-role-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem;
}

@media (max-width: 480px) {
  .pictor-role-grid {
    grid-template-columns: 1fr;
  }
}

.pictor-role-option {
  position: relative;
  cursor: pointer;
}

.pictor-role-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pictor-role-option .card {
  border: 2px solid var(--tblr-border-color);
  transition: border-color 0.15s, box-shadow 0.15s;
  height: 100%;
}

.pictor-role-option input:checked + .card,
.pictor-role-option .card:hover {
  border-color: var(--tblr-primary);
  box-shadow: 0 0 0 3px rgba(var(--tblr-primary-rgb), 0.12);
}

/* Landing */
body.pictor-landing .pictor-standalone {
  display: flex;
  min-height: 100dvh;
}

body.pictor-landing .page {
  flex: 1;
  width: 100%;
}

/* Legacy stat cards → Tabler look */
.stat-card {
  border: none !important;
  border-radius: var(--tblr-border-radius-lg) !important;
  box-shadow: var(--tblr-box-shadow-card) !important;
  padding: 1.25rem 1.5rem;
  min-height: 8.5rem;
  position: relative;
  overflow: hidden;
}

.stat-card h6 {
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
}

.stat-card .amount {
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.2;
}

.stat-card small {
  font-size: 0.8125rem;
  line-height: 1.45;
  display: block;
}

.stat-card .icon {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.75rem;
  opacity: 0.2 !important;
  pointer-events: none;
}

.stat-card .progress-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8125rem;
  margin-bottom: 0.35rem;
  gap: 0.5rem;
}

/* Order list cards */
.order-card {
  background: var(--tblr-bg-surface);
  border: 1px solid var(--tblr-border-color);
  border-radius: var(--tblr-border-radius-lg);
  padding: 1.25rem;
  margin-bottom: 1rem;
  display: grid;
  grid-template-columns: 1.2fr 1.4fr auto 1.6fr;
  gap: 1rem;
  align-items: start;
  box-shadow: var(--tblr-box-shadow-input);
}

.order-card .order-id-link {
  font-weight: 600;
  color: var(--tblr-primary);
  text-decoration: none;
}

.order-card .order-id-link:hover {
  text-decoration: underline;
}

.order-card .company-name {
  color: var(--pictor-muted);
  font-size: 0.875rem;
}

.filter-card,
.chart-card,
.table-card,
.form-card,
.customer-card {
  background: #fff;
  border: 1px solid var(--tblr-border-color);
  border-radius: var(--tblr-border-radius-lg);
  padding: 1.25rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--tblr-box-shadow-input);
}

.customer-card {
  border-left: 3px solid var(--tblr-primary) !important;
  height: 100%;
  transition: transform 0.15s, box-shadow 0.15s;
}

.customer-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--tblr-box-shadow-card);
}

.customer-card .customer-meta {
  color: var(--pictor-muted);
  font-size: 0.875rem;
  line-height: 1.5;
}

/* Customers dashboard */
body.pictor-customers-dashboard .cd-toolbar .btn-group .btn.active {
  background: #206bc4;
  color: #fff;
  border-color: #206bc4;
}

body.pictor-customers-dashboard .cd-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 1.1rem 1.15rem 1rem;
  border-left: 3px solid #206bc4 !important;
}

body.pictor-customers-dashboard .cd-card-head {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.9rem;
}

body.pictor-customers-dashboard .cd-card-title {
  min-width: 0;
  flex: 1;
}

body.pictor-customers-dashboard .cd-card-title h3 {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 0.15rem;
}

body.pictor-customers-dashboard .cd-card-title p {
  margin: 0;
  font-size: 0.75rem;
  color: var(--pictor-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.pictor-customers-dashboard .cd-badges {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
  flex-shrink: 0;
}

body.pictor-customers-dashboard .cd-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}

body.pictor-customers-dashboard .cd-metrics > div {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.45rem 0.5rem;
  min-width: 0;
}

body.pictor-customers-dashboard .cd-metrics span {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #64748b;
}

body.pictor-customers-dashboard .cd-metrics strong {
  display: block;
  font-size: 0.875rem;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.pictor-customers-dashboard .cd-facts {
  margin: 0 0 0.85rem;
}

body.pictor-customers-dashboard .cd-facts > div {
  display: grid;
  grid-template-columns: 8.5rem minmax(0, 1fr);
  gap: 0.35rem 0.6rem;
  padding: 0.28rem 0;
  border-bottom: 1px solid #f1f5f9;
  font-size: 0.8125rem;
}

body.pictor-customers-dashboard .cd-facts > div:last-child {
  border-bottom: 0;
}

body.pictor-customers-dashboard .cd-facts dt {
  margin: 0;
  color: #64748b;
  font-weight: 600;
}

body.pictor-customers-dashboard .cd-facts dt i {
  margin-right: 0.2rem;
}

body.pictor-customers-dashboard .cd-facts dd {
  margin: 0;
  color: #0f172a;
  overflow-wrap: anywhere;
}

body.pictor-customers-dashboard .cd-actions {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 0.4rem;
  margin-top: auto;
}

body.pictor-customers-dashboard .cd-table thead th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #475569;
  background: #f8fafc;
}

.cd-avatar {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: #dbeafe;
  color: #1e40af;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
  overflow: hidden;
  flex-shrink: 0;
}

.cd-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cd-avatar-sm {
  width: 2.15rem;
  height: 2.15rem;
  font-size: 0.7rem;
}

body.pictor-customers-dashboard .sd-pill {
  display: inline-flex;
  align-items: center;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.2;
  padding: 0.22em 0.55em;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
}

body.pictor-customers-dashboard .sd-pill-info {
  background: #dbeafe;
  color: #1e40af;
  border-color: #93c5fd;
}

body.pictor-customers-dashboard .sd-pill-muted {
  background: #f1f5f9;
  color: #334155;
  border-color: #cbd5e1;
}

body.pictor-customers-dashboard .sd-pill-warning {
  background: #ffedd5;
  color: #9a3412;
  border-color: #fdba74;
}

@media (max-width: 575.98px) {
  body.pictor-customers-dashboard .cd-facts > div {
    grid-template-columns: 1fr;
    gap: 0.1rem;
  }

  body.pictor-customers-dashboard .cd-actions {
    grid-template-columns: 1fr;
  }
}

.main-header {
  border-radius: var(--tblr-border-radius-lg);
  margin-bottom: 1.5rem;
  padding: 1.5rem !important;
  background: linear-gradient(135deg, #206bc4, #1a56a8) !important;
}

.main-header,
.main-header .text-muted,
.main-header h1,
.main-header h2,
.main-header p {
  color: #fff !important;
}

.main-header p {
  opacity: 0.9;
}

.details-list {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.875rem;
}

.details-list li {
  margin-bottom: 0.35rem;
}

.status-badge {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: 50rem;
}

@media (max-width: 1199px) {
  .order-card {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 767px) {
  .order-card {
    grid-template-columns: 1fr;
  }

  .page-wrapper {
    padding-bottom: env(safe-area-inset-bottom);
  }
}

/* Tables */
.table-responsive {
  border-radius: var(--tblr-border-radius-lg);
  border: 1px solid var(--tblr-border-color);
}

/* Quotation / PI line items: allow product search dropdown outside table */
.table-responsive.quote-pi-lines {
  overflow: visible !important;
}

.product-search-cell {
  overflow: visible;
}

.product-search-results {
  z-index: 10550 !important;
}

.quote-pi-search-wrap {
  position: relative;
  z-index: 1;
}

.product-search-cell {
  position: relative;
}

.quote-pi-autocomplete {
  position: absolute;
  z-index: 10050;
  max-height: 320px;
  overflow-y: auto;
  margin-top: 0;
  background: #fff;
  border: 1px solid var(--tblr-border-color, #dee2e6);
  border-radius: 0.375rem;
  box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.15);
  display: none;
}

.quote-pi-autocomplete.is-open {
  display: block !important;
}

#quotePiForm,
#quotePiForm .card-body,
#quotePiForm .row,
#quotePiForm [class*="col-"] {
  overflow: visible;
}

body.pictor-app .table {
  color: var(--pictor-body-color);
}

/* Sales dashboard orders table */
.pictor-orders-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.pictor-orders-table {
  width: 100%;
  min-width: 1100px;
  margin-bottom: 0;
  font-size: inherit;
}

.pictor-orders-table thead th {
  white-space: nowrap;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  vertical-align: middle;
  padding: 0.75rem 0.65rem;
  background: #f8fafc;
  color: var(--pictor-body-color);
  border-bottom: 2px solid #e2e8f0;
}

.pictor-orders-table tbody td {
  vertical-align: middle;
  padding: 0.75rem 0.65rem;
  line-height: 1.45;
}

.pictor-orders-table .col-order-id {
  white-space: nowrap;
  width: 5rem;
}

.pictor-orders-table .col-order-id .order-id-link {
  color: var(--tblr-primary);
  text-decoration: none;
  cursor: pointer;
}

.pictor-orders-table .col-order-id .order-id-link:hover {
  text-decoration: underline;
}

.pictor-orders-table .col-company {
  min-width: 10rem;
  max-width: 14rem;
  word-break: break-word;
}

.pictor-orders-table .col-date {
  white-space: nowrap;
  min-width: 6.5rem;
}

.pictor-orders-table .col-status {
  white-space: nowrap;
}

.pictor-orders-table .col-payment {
  min-width: 8.5rem;
}

.pictor-orders-table .col-payment .btn {
  font-size: 0.8125rem;
  padding: 0.2rem 0.45rem;
}

.pictor-orders-table .col-amount {
  white-space: nowrap;
  min-width: 5.5rem;
}

.pictor-orders-table .badge {
  font-size: 0.75rem;
  font-weight: 600;
}

.chart-card canvas {
  max-height: 280px;
}

.pictor-dashboard-header .btn-list {
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Sales dashboard layout & spacing */
body.pictor-sales-dashboard .page-body .container-xl {
  max-width: 100%;
  padding-top: 0.25rem;
}

@media (min-width: 1200px) {
  body.pictor-sales-dashboard .page-body .container-xl {
    max-width: 96%;
  }
}

body.pictor-sales-dashboard .pictor-dashboard-section {
  margin-bottom: 1.5rem;
}

body.pictor-sales-dashboard .pictor-dashboard-section:last-child {
  margin-bottom: 0;
}

body.pictor-sales-dashboard .stat-card {
  min-height: 7.75rem;
  margin-bottom: 0;
}

body.pictor-sales-dashboard .chart-card {
  min-height: 320px;
  display: flex;
  flex-direction: column;
}

body.pictor-sales-dashboard .chart-card canvas {
  flex: 1;
  min-height: 240px;
  max-height: 300px;
}

body.pictor-sales-dashboard .table-card {
  padding: 1rem 1.25rem 1.25rem;
}

body.pictor-admin-dashboard .chart-card {
  min-height: 320px;
  display: flex;
  flex-direction: column;
}

body.pictor-admin-dashboard .chart-card canvas {
  flex: 1;
  min-height: 240px;
  max-height: 300px;
}

body.pictor-admin-dashboard .table-card + .table-card {
  margin-top: 0;
}

body.pictor-admin-dashboard .filter-card {
  margin-bottom: 1.25rem;
}

body.pictor-sales-dashboard .pictor-orders-table tbody td {
  padding: 0.55rem 0.7rem;
  font-size: 0.875rem;
  line-height: 1.4;
  vertical-align: middle;
}

body.pictor-sales-dashboard .pictor-orders-table thead th {
  padding: 0.65rem 0.7rem;
}

body.pictor-sales-dashboard .pictor-orders-table .col-company {
  max-width: 12rem;
  line-height: 1.35;
}

body.pictor-sales-dashboard .pictor-orders-table {
  min-width: 1180px;
}

body.pictor-sales-dashboard .pictor-orders-table tbody tr:hover {
  background: #f8fafc;
}

body.pictor-sales-dashboard .pictor-orders-table .col-tracking {
  max-width: 9.5rem;
}

/* High-contrast status pills — Tabler badges were unreadable (dark on dark) */
body.pictor-sales-dashboard .sd-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.2;
  padding: 0.28em 0.7em;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
  vertical-align: middle;
}

body.pictor-sales-dashboard .sd-pill-success {
  background: #dcfce7;
  color: #166534;
  border-color: #86efac;
}

body.pictor-sales-dashboard .sd-pill-warning {
  background: #ffedd5;
  color: #9a3412;
  border-color: #fdba74;
}

body.pictor-sales-dashboard .sd-pill-danger {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fca5a5;
}

body.pictor-sales-dashboard .sd-pill-info {
  background: #dbeafe;
  color: #1e40af;
  border-color: #93c5fd;
}

body.pictor-sales-dashboard .sd-pill-muted {
  background: #f1f5f9;
  color: #334155;
  border-color: #cbd5e1;
}

body.pictor-sales-dashboard .sd-pill-cash {
  background: #ede9fe;
  color: #5b21b6;
  border-color: #c4b5fd;
}

body.pictor-sales-dashboard .sd-pill-wrap {
  white-space: normal;
  text-align: left;
  max-width: 16rem;
  border-radius: 0.5rem;
  line-height: 1.35;
  font-weight: 600;
}

body.pictor-sales-dashboard .sd-tracking {
  display: inline-block;
  max-width: 8.75rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.75rem;
  font-weight: 600;
  color: #0f172a;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 0.375rem;
  padding: 0.2rem 0.45rem;
  vertical-align: middle;
}

body.pictor-sales-dashboard .sd-proof-label {
  font-size: 0.75rem;
  color: #64748b;
  white-space: nowrap;
}

body.pictor-sales-dashboard .pictor-orders-table .col-payment .btn {
  min-width: 2rem;
}

/* Customer profile modal */
#clientDetailsModal .modal-body {
  max-height: min(75vh, 720px);
  overflow-y: auto;
}

/* Add Lead is taller than the viewport. Keep the header and actions visible and scroll the fields. */
#addLeadModal .modal-dialog {
  height: calc(100vh - 2rem);
  max-height: calc(100vh - 2rem);
  margin-top: 1rem;
  margin-bottom: 1rem;
}

#addLeadModal .modal-content,
#addLeadModal .modal-content > form {
  height: 100%;
  max-height: 100%;
  min-height: 0;
}

#addLeadModal .modal-header,
#addLeadModal .modal-footer {
  flex-shrink: 0;
}

#addLeadModal .modal-body {
  overflow-y: auto;
  min-height: 0;
  flex: 1 1 auto;
}

#addLeadModal .modal-header {
  align-items: flex-start;
  gap: 1rem;
  background: linear-gradient(180deg, #f4f8fd 0%, #fff 100%);
}

#addLeadModal .modal-footer {
  background: #fff;
  box-shadow: 0 -8px 24px rgba(15, 23, 42, 0.04);
}

.lead-qual-form .lead-section {
  min-width: 0;
  border: 1px solid #e2e8f0;
  border-radius: 0.9rem;
  background: #fff;
  padding: 1rem 1rem 1.15rem;
  margin: 0 0 1rem;
}

.lead-qual-form .lead-section-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  float: none;
  width: auto;
  padding: 0;
  margin: 0 0 1rem;
  font-size: 1rem;
}

.lead-qual-form .lead-section-icon {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 0.7rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
  font-size: 1.15rem;
}

.lead-qual-form .lead-section-blue .lead-section-icon { background: #206bc4; }
.lead-qual-form .lead-section-teal .lead-section-icon { background: #0ca678; }
.lead-qual-form .lead-section-purple .lead-section-icon { background: #6f42c1; }

.lead-qual-form .lead-section-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.lead-qual-form .lead-section-label {
  font-weight: 650;
  color: #0f172a;
  line-height: 1.2;
}

.lead-qual-form .lead-section-sub {
  color: #64748b;
  font-size: 0.82rem;
  font-weight: 400;
  line-height: 1.35;
}

.lead-qual-form .lead-section-blue { background: linear-gradient(180deg, #f7fbff 0%, #fff 4.5rem); }
.lead-qual-form .lead-section-teal { background: linear-gradient(180deg, #f3fbf7 0%, #fff 4.5rem); }
.lead-qual-form .lead-section-purple { background: linear-gradient(180deg, #f8f5fc 0%, #fff 4.5rem); }

.lead-qual-form .input-icon .form-select {
  padding-left: 2.5rem;
}

.lead-qual-form .lead-products {
  border: 1px solid #e2e8f0;
  border-radius: 0.8rem;
  background: #fff;
  padding: 0.85rem;
}

.lead-qual-form .lead-products-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.35rem 1rem;
  margin-bottom: 0.75rem;
}

.lead-qual-form .lead-products-title {
  font-weight: 650;
  color: #0f172a;
}

.lead-qual-form .lead-choice-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 0.55rem;
}

.lead-qual-form .lead-choice {
  position: relative;
  display: block;
  margin: 0;
  cursor: pointer;
}

.lead-qual-form .lead-choice-input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.lead-qual-form .lead-choice-body {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 2.75rem;
  padding: 0.55rem 0.7rem;
  border: 1px solid #e2e8f0;
  border-radius: 0.7rem;
  background: #f8fafc;
  color: #1e293b;
  line-height: 1.25;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.lead-qual-form .lead-choice-body .ti {
  color: #206bc4;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.lead-qual-form .lead-choice:hover .lead-choice-body {
  border-color: #b9d4f3;
  background: #fff;
}

.lead-qual-form .lead-choice-input:checked + .lead-choice-body {
  border-color: #206bc4;
  background: #eef5fc;
  box-shadow: inset 0 0 0 1px #206bc4;
}

.lead-qual-form .lead-choice-input:focus-visible + .lead-choice-body {
  outline: 2px solid #206bc4;
  outline-offset: 2px;
}

.lead-qual-form .lead-bant-card {
  height: 100%;
  border: 1px solid #e6dff3;
  border-radius: 0.8rem;
  background: #fff;
  padding: 0.85rem 0.9rem 1rem;
}

.lead-qual-form .lead-bant-head {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.75rem;
  font-weight: 650;
  color: #3b0764;
}

.lead-qual-form .lead-bant-head .ti {
  color: #6f42c1;
}

.lead-qual-form .lead-confirm {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin: 0.85rem 0 0;
  padding: 0.7rem 0.75rem;
  border: 1px dashed #d8ccee;
  border-radius: 0.7rem;
  background: #fbf9fd;
  cursor: pointer;
}

.lead-qual-form .lead-confirm-title,
.lead-qual-form .lead-confirm-sub {
  display: block;
}

.lead-qual-form .lead-confirm-title {
  font-weight: 600;
  color: #1e293b;
}

.lead-qual-form .lead-confirm-sub {
  color: #64748b;
  font-size: 0.78rem;
}

.lead-qual-form .lead-unknown {
  min-height: 1.25rem;
}

.lead-qual-form .lead-field.is-unknown .form-control {
  background: #f8fafc;
  color: #94a3b8;
}

@media (max-width: 767.98px) {
  .lead-qual-form .lead-section {
    padding: 0.85rem;
  }

  .lead-qual-form .lead-choice-grid {
    grid-template-columns: 1fr;
  }
}

.lead-score-card {
  overflow: hidden;
  border: 1px solid #e2e8f0;
}

.lead-score-head {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
}

.lead-score-head-icon {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 0.65rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #206bc4;
  color: #fff;
  flex-shrink: 0;
}

.lead-score-hero {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.lead-score-ring {
  --score: 0;
  width: 5.4rem;
  height: 5.4rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: conic-gradient(var(--ring, #206bc4) calc(var(--score) * 1%), #e8eef5 0);
  flex-shrink: 0;
  position: relative;
}

.lead-score-ring::before {
  content: "";
  position: absolute;
  inset: 0.42rem;
  border-radius: 50%;
  background: #fff;
}

.lead-score-ring-value {
  position: relative;
  font-size: 1.45rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1;
}

.lead-score-high { --ring: #0ca678; }
.lead-score-high .lead-score-head-icon,
.lead-score-high .lead-score-band { background: #0ca678; }
.lead-score-mid .lead-score-band { background: #206bc4; }
.lead-score-low { --ring: #f59f00; }
.lead-score-low .lead-score-head-icon,
.lead-score-low .lead-score-band { background: #f59f00; color: #1e293b; }
.lead-score-early { --ring: #94a3b8; }
.lead-score-early .lead-score-head-icon,
.lead-score-early .lead-score-band { background: #64748b; }

.lead-score-band {
  display: inline-flex;
  align-items: center;
  margin-bottom: 0.35rem;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: #206bc4;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 650;
}

.lead-score-formula {
  color: #64748b;
  font-size: 0.78rem;
  line-height: 1.35;
  margin-bottom: 0.55rem;
}

.lead-gst-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.28rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: #f1f5f9;
  color: #334155;
}

.lead-gst-invalid,
.lead-gst-mismatch {
  background: #fff1f2;
  color: #be123c;
}

.lead-gst-unverified {
  background: #fff7ed;
  color: #c2410c;
}

.lead-gst-verified {
  background: #ecfdf3;
  color: #067647;
}

.lead-score-meters {
  display: grid;
  gap: 0.7rem;
  margin-bottom: 1rem;
}

.lead-score-meter-top,
.lead-score-row-top {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.82rem;
  margin-bottom: 0.28rem;
}

.lead-score-meter-top strong,
.lead-score-row-points {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: #0f172a;
}

.lead-meter {
  height: 0.45rem;
  border-radius: 999px;
  background: #e8eef5;
  overflow: hidden;
}

.lead-meter > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #206bc4;
}

.lead-meter-bant > span { background: #6f42c1; }
.lead-meter-kyc > span { background: #206bc4; }
.lead-meter-sm { height: 0.28rem; }
.lead-score-group .lead-meter > span { background: #7c93ad; }

.lead-score-group {
  margin-bottom: 0.85rem;
}

.lead-score-group-title {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.55rem;
  font-weight: 650;
  color: #0f172a;
}

.lead-score-row {
  padding: 0.45rem 0;
  border-top: 1px solid #eef2f6;
}

.lead-score-row-note {
  margin-top: 0.25rem;
  color: #64748b;
  font-size: 0.75rem;
  line-height: 1.35;
}

.lead-score-note {
  margin-top: 0.35rem;
  padding-top: 0.75rem;
  border-top: 1px solid #eef2f6;
  color: #64748b;
  font-size: 0.75rem;
}

/* Hide legacy duplicate nav when using shell */
.pictor-app .pictor-nav {
  display: none !important;
}

/* ── Fulfillment dashboard ───────────────────────────────────────── */
body.pictor-fulfillment-dashboard .filter-bar {
  background: #fff;
  border: 1px solid var(--tblr-border-color);
  border-radius: var(--tblr-border-radius-lg);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--tblr-box-shadow-input);
}

body.pictor-fulfillment-dashboard .stat-card {
  min-height: auto;
  padding: 0;
  color: #fff !important;
}

body.pictor-fulfillment-dashboard .stat-card .stat-number,
body.pictor-fulfillment-dashboard .stat-card .stat-label,
body.pictor-fulfillment-dashboard .stat-card .stat-icon {
  color: #fff !important;
}

body.pictor-fulfillment-dashboard .stat-card-body {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
}

body.pictor-fulfillment-dashboard .stat-icon {
  font-size: 2rem;
  opacity: 0.85;
  flex-shrink: 0;
}

body.pictor-fulfillment-dashboard .stat-number {
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.2;
  margin: 0;
}

body.pictor-fulfillment-dashboard .stat-label {
  margin: 0;
  font-size: 0.875rem;
  opacity: 0.9;
}

body.pictor-fulfillment-dashboard .stat-card-total {
  background: linear-gradient(135deg, #206bc4, #1a56a8) !important;
}

body.pictor-fulfillment-dashboard .stat-card-delivered {
  background: linear-gradient(135deg, #2fb344, #229a36) !important;
}

body.pictor-fulfillment-dashboard .stat-card-dispatched {
  background: linear-gradient(135deg, #f59f00, #d48806) !important;
}

body.pictor-fulfillment-dashboard .stat-card-pending {
  background: linear-gradient(135deg, #64748b, #475569) !important;
}

body.pictor-fulfillment-dashboard .order-section {
  background: #fff;
  border: 1px solid var(--tblr-border-color);
  border-radius: var(--tblr-border-radius-lg);
  margin-bottom: 1.5rem;
  overflow: hidden;
  box-shadow: var(--tblr-box-shadow-input);
}

body.pictor-fulfillment-dashboard .order-section.order-section-cancelled {
  position: relative;
  opacity: 0.45;
  filter: grayscale(0.8);
  background: #f1f5f9;
  border-color: #cbd5e1;
  box-shadow: none;
}

body.pictor-fulfillment-dashboard .order-section.order-section-cancelled::before {
  content: "CANCELLED";
  position: absolute;
  top: 42%;
  left: 50%;
  z-index: 2;
  transform: translate(-50%, -50%) rotate(-14deg);
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: 0.18em;
  color: rgba(153, 27, 27, 0.22);
  pointer-events: none;
  white-space: nowrap;
}

/* Order card header */
body.pictor-fulfillment-dashboard .order-section-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
  padding: 1rem 1.25rem;
  background: #fff;
  border-bottom: 1px solid #e2e8f0;
}

@media (min-width: 1400px) {
  body.pictor-fulfillment-dashboard .order-section-header {
    grid-template-columns: minmax(0, 1fr) minmax(0, max-content);
    gap: 1rem 1.5rem;
    align-items: start;
  }
}

body.pictor-fulfillment-dashboard .order-identity {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  min-width: 0;
  width: 100%;
}

body.pictor-fulfillment-dashboard .order-identity-primary {
  display: flex;
  flex: 1 1 16rem;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 1rem;
  min-width: 0;
}

body.pictor-fulfillment-dashboard .order-renewal-flag {
  flex: 0 1 auto;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: #1e3a8a;
  background: #eff6ff;
  border: 1px solid #93c5fd;
  border-radius: 0.5rem;
  padding: 0.4rem 0.75rem;
  white-space: nowrap;
}

@media (max-width: 575.98px) {
  body.pictor-fulfillment-dashboard .order-identity {
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
  }

  body.pictor-fulfillment-dashboard .order-identity-primary {
    flex: 0 1 auto;
  }

  body.pictor-fulfillment-dashboard .order-renewal-flag {
    margin-left: 0;
    white-space: normal;
  }
}

body.pictor-fulfillment-dashboard .order-id-link {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--tblr-primary);
  text-decoration: none;
  white-space: nowrap;
}

body.pictor-fulfillment-dashboard .order-id-link:hover {
  text-decoration: underline;
}

body.pictor-fulfillment-dashboard .order-company {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--pictor-body-color);
  max-width: 100%;
}

body.pictor-fulfillment-dashboard .order-sales-person {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8125rem;
  color: var(--pictor-muted);
}

body.pictor-fulfillment-dashboard .order-toolbar {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.65rem;
  min-width: 0;
  width: 100%;
}

@media (min-width: 1400px) {
  body.pictor-fulfillment-dashboard .order-toolbar {
    align-items: flex-end;
    width: auto;
    max-width: 100%;
  }
}

body.pictor-fulfillment-dashboard .order-toolbar-time {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem;
}

body.pictor-fulfillment-dashboard .order-time-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 50rem;
  padding: 0.2rem 0.65rem;
  white-space: nowrap;
}

body.pictor-fulfillment-dashboard .order-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 0.5rem 0.65rem;
  width: 100%;
  max-width: 100%;
}

@media (min-width: 1400px) {
  body.pictor-fulfillment-dashboard .order-toolbar-actions {
    justify-content: flex-end;
  }
}

body.pictor-fulfillment-dashboard .order-toolbar-actions-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.65rem;
  width: 100%;
}

/* Accept + Schedule: Bootstrap form-switch uses negative margin-left on the input, which overlaps the Accept button */
body.pictor-fulfillment-dashboard .order-accept-schedule-group {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
  padding-right: 0.5rem;
  border-right: 1px solid #e2e8f0;
  margin-right: 0.15rem;
}

body.pictor-fulfillment-dashboard .order-accept-form {
  display: inline-flex;
  margin: 0;
  flex-shrink: 0;
}

body.pictor-fulfillment-dashboard .order-schedule-switch.form-switch {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 0.45rem;
  flex-shrink: 0;
  padding: 0 !important;
  padding-left: 0 !important;
  margin: 0 !important;
  min-height: 0;
  border: none;
  white-space: nowrap;
}

body.pictor-fulfillment-dashboard .order-schedule-switch .form-check-input {
  float: none !important;
  margin-left: 0 !important;
  margin-top: 0 !important;
  position: static !important;
  width: 2.25rem;
  height: 1.2rem;
  flex-shrink: 0;
}

body.pictor-fulfillment-dashboard .order-schedule-switch .form-check-label {
  font-size: 0.8125rem;
  font-weight: 500;
  color: #475569;
  margin: 0;
  padding: 0;
  line-height: 1.2;
}

body.pictor-fulfillment-dashboard .order-btn-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;
  max-width: 100%;
}

body.pictor-fulfillment-dashboard .order-btn-group .btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 500;
  font-size: 0.8125rem;
  padding: 0.25rem 0.55rem;
  border-radius: var(--tblr-border-radius-sm) !important;
  margin: 0 !important;
  flex-shrink: 0;
  white-space: nowrap;
}

body.pictor-fulfillment-dashboard .order-btn-group .btn-label {
  font-size: 0.8125rem;
}

body.pictor-fulfillment-dashboard .btn-whatsapp {
  background: #25d366 !important;
  border-color: #25d366 !important;
  color: #fff !important;
}

body.pictor-fulfillment-dashboard .btn-whatsapp:hover,
body.pictor-fulfillment-dashboard .btn-whatsapp:focus {
  background: #1ebe57 !important;
  border-color: #1ebe57 !important;
  color: #fff !important;
}

body.pictor-fulfillment-dashboard .btn-whatsapp .bi-whatsapp {
  color: #fff;
}

body.pictor-fulfillment-dashboard .btn-fulfillment-disabled {
  background: #f8fafc !important;
  color: #94a3b8 !important;
  border-color: #e2e8f0 !important;
  opacity: 1 !important;
  cursor: not-allowed;
}

body.pictor-fulfillment-dashboard .order-status-pills {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  flex-shrink: 0;
}

body.pictor-fulfillment-dashboard .order-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.25rem 0.55rem;
  border-radius: 50rem;
  white-space: nowrap;
}

body.pictor-fulfillment-dashboard .order-pill-warning {
  background: #fff7ed;
  color: #c2410c;
  border: 1px solid #fed7aa;
}

body.pictor-fulfillment-dashboard .order-pill-success {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

body.pictor-fulfillment-dashboard .order-pill-danger {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

body.pictor-fulfillment-dashboard .order-cancel-btn {
  flex-shrink: 0;
  margin-left: 0.15rem;
}

/* Meta chips row — single horizontal line */
body.pictor-fulfillment-dashboard .order-meta-bar {
  padding: 0.65rem 1.25rem;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

body.pictor-fulfillment-dashboard .order-meta-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

body.pictor-fulfillment-dashboard .order-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.7rem;
  font-weight: 600;
  line-height: 1.2;
  padding: 0.3rem 0.6rem;
  border-radius: 0.375rem;
  white-space: nowrap;
}

body.pictor-fulfillment-dashboard .order-chip-muted {
  background: #e2e8f0;
  color: #334155;
}

body.pictor-fulfillment-dashboard .order-chip-blue {
  background: #dbeafe;
  color: #1e40af;
}

body.pictor-fulfillment-dashboard .order-chip-brown {
  background: #e9dcc8;
  color: #5c4033;
}

body.pictor-fulfillment-dashboard .order-chip-info {
  background: #e0f2fe;
  color: #0369a1;
}

body.pictor-fulfillment-dashboard .order-chip-primary {
  background: #dbeafe;
  color: #1d4ed8;
}

body.pictor-fulfillment-dashboard .order-chip-success {
  background: #dcfce7;
  color: #15803d;
}

body.pictor-fulfillment-dashboard .order-chip-danger {
  background: #fee2e2;
  color: #b91c1c;
}

body.pictor-fulfillment-dashboard .order-chip-dark {
  background: #334155;
  color: #fff;
}

body.pictor-fulfillment-dashboard .order-chip-warning {
  background: #fff7ed;
  color: #c2410c;
}

body.pictor-fulfillment-dashboard .order-btn-group .btn-outline-primary {
  border-color: #206bc4;
  color: #206bc4;
}

body.pictor-fulfillment-dashboard .order-btn-group .btn-outline-primary:hover {
  background: #206bc4;
  color: #fff;
}

body.pictor-fulfillment-dashboard .tracking-form {
  padding: 1rem 1.25rem;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

body.pictor-fulfillment-dashboard .workflow-container {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: #f8fafc;
}

body.pictor-fulfillment-dashboard .stage-column {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: var(--tblr-border-radius);
  padding: 0.85rem;
  min-width: 0;
}

body.pictor-fulfillment-dashboard .stage-title {
  font-size: 0.8125rem;
  font-weight: 600;
  margin-bottom: 0.65rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #e2e8f0;
  color: #334155;
}

body.pictor-fulfillment-dashboard .form-stage {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

body.pictor-fulfillment-dashboard .form-stage .form-select {
  font-size: 0.8125rem;
}

body.pictor-fulfillment-dashboard .form-stage .timestamp {
  font-size: 0.7rem;
  color: var(--pictor-muted);
}

body.pictor-fulfillment-dashboard .form-stage .update-stage-btn {
  font-size: 0.75rem;
  padding: 0.25rem 0.55rem;
}

body.pictor-fulfillment-dashboard .device-config-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: var(--tblr-border-radius);
  min-width: 0;
  display: flex;
  flex-direction: column;
}

body.pictor-fulfillment-dashboard .device-config-card .card-header {
  padding: 0.75rem 0.85rem;
  background: #fff;
  border-bottom: 1px solid #e2e8f0;
}

body.pictor-fulfillment-dashboard .device-config-card .card-body {
  padding: 0.85rem;
  flex: 1;
}

body.pictor-fulfillment-dashboard .device-config-form .form-label {
  font-size: 0.75rem;
  margin-bottom: 0.2rem;
}

body.pictor-fulfillment-dashboard .bg-light-blue {
  background-color: #cfe2ff !important;
  color: #084298 !important;
}

body.pictor-fulfillment-dashboard .bg-light-brown {
  background-color: #e9dcc8 !important;
  color: #5c4033 !important;
}

/* Badge contrast — gray bg-secondary was unreadable (dark text on dark gray) */
body.pictor-fulfillment-dashboard .badge.bg-secondary,
body.pictor-fulfillment-dashboard .badge.fulfillment-badge-muted {
  background-color: #e2e8f0 !important;
  color: #1e293b !important;
  border: 1px solid #cbd5e1;
}

body.pictor-fulfillment-dashboard .badge.fulfillment-badge-pending {
  background-color: #fef3c7 !important;
  color: #92400e !important;
  border: 1px solid #fcd34d;
}

body.pictor-fulfillment-dashboard .badge.bg-dark {
  background-color: #334155 !important;
  color: #fff !important;
}

body.pictor-fulfillment-dashboard .badge.bg-success,
body.pictor-fulfillment-dashboard .badge.bg-danger,
body.pictor-fulfillment-dashboard .badge.bg-primary,
body.pictor-fulfillment-dashboard .badge.bg-info {
  color: #fff !important;
}

body.pictor-fulfillment-dashboard .badge.bg-warning:not(.text-dark) {
  color: #1e293b !important;
}

body.pictor-fulfillment-dashboard .stage-title .badge,
body.pictor-fulfillment-dashboard .device-config-card .card-header .badge {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 0.3em 0.55em;
}

body.pictor-fulfillment-dashboard .badge.fulfillment-badge-muted,
body.pictor-fulfillment-dashboard .badge.fulfillment-badge-muted i,
body.pictor-fulfillment-dashboard .badge.fulfillment-badge-pending,
body.pictor-fulfillment-dashboard .badge.fulfillment-badge-pending i {
  color: inherit;
}

@media (max-width: 1199px) {
  body.pictor-fulfillment-dashboard .workflow-container {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 991px) {
  body.pictor-fulfillment-dashboard .order-section-header {
    grid-template-columns: 1fr;
  }

  body.pictor-fulfillment-dashboard .order-toolbar {
    align-items: stretch;
    width: 100%;
  }

  body.pictor-fulfillment-dashboard .order-toolbar-time,
  body.pictor-fulfillment-dashboard .order-toolbar-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 767px) {
  body.pictor-fulfillment-dashboard .order-btn-group {
    flex-wrap: wrap;
  }

  body.pictor-fulfillment-dashboard .order-btn-group .btn-label {
    display: none;
  }

  body.pictor-fulfillment-dashboard .order-accept-schedule-group {
    border-right: none;
    padding-right: 0;
    gap: 0.75rem;
  }

  body.pictor-fulfillment-dashboard .workflow-container {
    grid-template-columns: 1fr;
  }
}

/* Place order styles: assets/css/place-order.css */

/* Thank you pages */
body.pictor-thankyou-page .page-body {
  padding-bottom: 2rem;
}

.pictor-thankyou {
  max-width: 960px;
  margin: 0 auto;
}

.pictor-thankyou-hero {
  text-align: center;
  padding: 2.5rem 1.5rem 2rem;
  border: none;
  background: linear-gradient(160deg, #ecfdf5 0%, #ffffff 45%, #eff6ff 100%);
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
  overflow: hidden;
  position: relative;
}

.pictor-thankyou-hero::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -15%;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.08);
  pointer-events: none;
}

.pictor-thankyou-hero__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 4.5rem;
  height: 4.5rem;
  margin-bottom: 1rem;
  border-radius: 50%;
  background: #22c55e;
  color: #fff;
  font-size: 2.25rem;
  box-shadow: 0 8px 24px rgba(34, 197, 94, 0.35);
  animation: pictor-thankyou-pop 0.5s ease-out;
}

.pictor-thankyou-hero__title {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--pictor-body-color);
}

.pictor-thankyou-hero__subtitle {
  font-size: 1rem;
  color: var(--pictor-muted);
  margin-bottom: 1.25rem;
  max-width: 28rem;
  margin-left: auto;
  margin-right: auto;
}

.pictor-thankyou-hero__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.pictor-thankyou-stat .card-body {
  padding: 1.15rem 1.25rem;
}

.pictor-thankyou-stat__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.5rem;
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.pictor-thankyou-dl dt {
  font-weight: 500;
  color: var(--pictor-muted);
  font-size: 0.875rem;
}

.pictor-thankyou-dl dd {
  font-size: 0.9375rem;
  margin-bottom: 0.65rem;
}

.pictor-thankyou-dl dd:last-child,
.pictor-thankyou-dl dt:last-of-type {
  margin-bottom: 0;
}

.pictor-thankyou-actions {
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
}

.pictor-thankyou-actions .btn-list {
  gap: 0.5rem;
}

@keyframes pictor-thankyou-pop {
  0% {
    transform: scale(0.6);
    opacity: 0;
  }
  70% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@media (max-width: 575px) {
  .pictor-thankyou-hero {
    padding: 2rem 1rem 1.5rem;
  }

  .pictor-thankyou-hero__title {
    font-size: 1.4rem;
  }

  .pictor-thankyou-actions .btn-list .btn {
    width: 100%;
  }
}

.pictor-guide-i {
  width: 1.75rem;
  height: 1.75rem;
  padding: 0;
  color: var(--tblr-primary);
  border: 0;
  background: transparent;
  line-height: 1;
}
.pictor-guide-i:hover,
.pictor-guide-i:focus {
  color: var(--tblr-primary);
  background: rgba(32, 107, 196, 0.08);
}
.pictor-guide-i .ti {
  font-size: 1.1rem;
}
.popover.pictor-guide-popover {
  max-width: 22rem;
}
.popover.pictor-guide-popover .popover-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-right: 0.7rem;
  margin-bottom: 0;
}
.popover.pictor-guide-popover .pictor-guide-close {
  width: 0.8rem;
  height: 0.8rem;
  padding: 0;
  margin: 0;
  flex-shrink: 0;
  opacity: 0.65;
}
.popover.pictor-guide-popover .pictor-guide-close:hover {
  opacity: 1;
}
body.pictor-app .input-icon textarea.form-control {
  padding-left: 2.5rem;
}

/* Customer Intelligence */
.ci-queue-card .card-header {
  align-items: center;
}
.ci-queue-item {
  display: block;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid #e2e8f0;
}
.ci-queue-item:last-child {
  border-bottom: 0;
}
.ci-queue-item:hover {
  background: rgba(32, 107, 196, 0.06);
}
.ci-score {
  font-weight: 700;
}
.ci-nba-card {
  border-left: 4px solid var(--tblr-primary);
}
body.pictor-ci-dashboard .progress-sm {
  height: 0.45rem;
}

/* Live inventory health bar with available quantity */
.inv-health {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 11rem;
}
.inv-health-track {
  flex: 1 1 auto;
  height: 10px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}
.inv-health-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: hsl(var(--inv-hue, 0), 72%, 42%);
  min-width: 0;
}
.inv-health-qty {
  flex: 0 0 auto;
  font-size: 0.8125rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: #0f172a;
  white-space: nowrap;
  min-width: 1.25rem;
}
.inv-health-label {
  flex: 0 0 auto;
  font-size: 0.75rem;
  font-weight: 600;
  color: #475569;
  white-space: nowrap;
}
.inv-health-inline {
  display: inline-flex;
  vertical-align: middle;
  min-width: 13rem;
}

.inv-name {
  font-weight: 650;
  letter-spacing: -0.01em;
  color: #0f172a;
  line-height: 1.3;
}
.inv-model {
  font-size: 0.75rem;
  margin-top: 0.15rem;
}
.inv-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-top: 0.35rem;
}
.inv-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.08rem 0.45rem;
  border-radius: 999px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  color: #334155;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.pictor-notify-bar {
  display: flex;
  align-items: center;
  width: 100%;
  flex: 0 0 auto;
}

@media (max-width: 991.98px) {
  .pictor-notify-bar {
    width: auto;
    flex: 1 1 auto;
    min-width: 0;
  }
}

.pictor-notify-toggle {
  position: relative;
}

.pictor-notify-badge {
  position: absolute;
  top: 0.1rem;
  right: 0.1rem;
}

.pictor-notify-menu {
  width: 22rem;
  max-width: calc(100vw - 1.5rem);
}

.pictor-notify-menu [data-notify-list] {
  max-height: 22rem;
  overflow-y: auto;
}
