:root {
  --bg: #f4f7fb;
  --sidebar: #101828;
  --sidebar-light: #1d2939;
  --primary: #2563eb;
  --primary-soft: #dbeafe;
  --success: #16a34a;
  --success-soft: #dcfce7;
  --warning: #f59e0b;
  --warning-soft: #fef3c7;
  --danger: #dc2626;
  --danger-soft: #fee2e2;
  --purple: #7c3aed;
  --purple-soft: #ede9fe;
  --text: #111827;
  --muted: #667085;
  --card: #ffffff;
  --border: #e5e7eb;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
  --radius: 22px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
}

body {
  background: var(--bg);
  color: var(--text);
}

.app {
  display: flex;
  min-height: 100vh;
}

/* SIDEBAR */

.sidebar {
  width: 280px;
  background: linear-gradient(180deg, var(--sidebar), #0b1220);
  color: #ffffff;
  padding: 24px;
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: 0 auto 0 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 36px;
}

.brand-icon {
  width: 48px;
  height: 48px;
  background: var(--primary);
  border-radius: 16px;
  display: grid;
  place-items: center;
  font-size: 22px;
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.35);
}

.brand h1 {
  font-size: 22px;
  line-height: 1.1;
}

.brand p {
  font-size: 12px;
  color: #98a2b3;
  margin-top: 4px;
}

.nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nav-link {
  color: #cbd5e1;
  text-decoration: none;
  padding: 14px 16px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 13px;
  transition: 0.25s ease;
  font-size: 15px;
}

.nav-link i {
  width: 20px;
}

.nav-link:hover,
.nav-link.active {
  background: var(--sidebar-light);
  color: #ffffff;
}

.sidebar-footer {
  margin-top: auto;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 18px;
  border-radius: 18px;
}

.sidebar-footer p {
  color: #98a2b3;
  font-size: 13px;
  margin-bottom: 6px;
}

/* MAIN */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 20px;
}

.topbar h2 {
  font-size: 30px;
  letter-spacing: -0.6px;
}

.topbar p {
  color: var(--muted);
  margin-top: 5px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.role-select {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 10px 14px;
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.role-select label {
  font-size: 12px;
  color: var(--muted);
  display: block;
  margin-bottom: 4px;
}

.role-select select {
  border: none;
  outline: none;
  font-size: 14px;
  font-weight: 700;
  background: transparent;
}

.notification-btn {
  width: 48px;
  height: 48px;
  border: none;
  background: var(--card);
  border-radius: 50%;
  box-shadow: var(--shadow);
  position: relative;
  cursor: pointer;
  font-size: 18px;
}

.notification-btn span {
  width: 9px;
  height: 9px;
  background: var(--danger);
  border: 2px solid white;
  border-radius: 50%;
  position: absolute;
  top: 12px;
  right: 13px;
}

.profile {
  background: var(--card);
  padding: 9px 14px 9px 9px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow);
}

.profile-avatar {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--primary);
  color: white;
  display: grid;
  place-items: center;
  font-weight: 800;
}

.profile p {
  margin: 2px 0 0;
  font-size: 12px;
}

/* DASHBOARD SECTIONS */

.dashboard-section {
  display: none;
}

.dashboard-section.active {
  display: block;
}

/* STATS */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-bottom: 24px;
}

.manager-grid {
  grid-template-columns: repeat(4, 1fr);
}

.employee-grid {
  grid-template-columns: repeat(3, 1fr);
}

.stat-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 18px;
}

.stat-icon {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-size: 23px;
  flex-shrink: 0;
}

.stat-icon.sales {
  color: var(--primary);
  background: var(--primary-soft);
}

.stat-icon.month {
  color: var(--purple);
  background: var(--purple-soft);
}

.stat-icon.profit,
.stat-icon.net {
  color: var(--success);
  background: var(--success-soft);
}

.stat-icon.expense {
  color: var(--danger);
  background: var(--danger-soft);
}

.stat-icon.stock {
  color: var(--warning);
  background: var(--warning-soft);
}

.stat-card p {
  color: var(--muted);
  font-size: 14px;
}

.stat-card h3 {
  font-size: 25px;
  margin: 6px 0;
  letter-spacing: -0.5px;
}

.stat-card span {
  font-size: 13px;
  color: var(--muted);
}

.stat-card .positive {
  color: var(--success);
}

.stat-card .negative {
  color: var(--danger);
}

/* PANELS */

.content-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 22px;
}

.panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.panel.large {
  min-height: 320px;
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.panel-header h3 {
  font-size: 19px;
  margin-bottom: 5px;
}

.panel-header p {
  color: var(--muted);
  font-size: 14px;
}

.panel-header button {
  border: none;
  background: var(--primary);
  color: white;
  padding: 11px 16px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 700;
}

/* BAR LIST */

.bar-list {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.bar-item > div:first-child {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.bar-item span {
  color: var(--muted);
  font-size: 14px;
}

.bar {
  height: 11px;
  background: #eef2f7;
  border-radius: 999px;
  overflow: hidden;
}

.bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--primary), #60a5fa);
  border-radius: 999px;
}

/* PRODUCT LIST */

.product-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.product {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid var(--border);
}

.product strong {
  font-size: 14px;
}

.product p {
  color: var(--muted);
  font-size: 12px;
  margin-top: 4px;
}

.product span {
  font-size: 13px;
  font-weight: 800;
  padding: 7px 10px;
  border-radius: 999px;
}

.product.warning span {
  color: #92400e;
  background: var(--warning-soft);
}

.product.danger span {
  color: var(--danger);
  background: var(--danger-soft);
}

/* RANKING */

.ranking-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ranking-list div {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 8px;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}

.ranking-list div:last-child {
  border-bottom: none;
}

.ranking-list span {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 800;
}

.ranking-list p {
  grid-column: 2;
  color: var(--muted);
  font-size: 13px;
}

/* TABLE */

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  text-align: left;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  padding: 14px 10px;
  background: #f9fafb;
}

td {
  padding: 15px 10px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

tr:last-child td {
  border-bottom: none;
}

.badge {
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.badge.success {
  color: var(--success);
  background: var(--success-soft);
}

.badge.pending {
  color: #92400e;
  background: var(--warning-soft);
}

/* SUMMARY */

.summary-box {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.summary-box div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f9fafb;
  padding: 15px;
  border-radius: 14px;
}

.summary-box span {
  color: var(--muted);
  font-size: 14px;
}

.summary-box strong {
  font-size: 15px;
}

/* SEARCH */

.search-box {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #f9fafb;
  border: 1px solid var(--border);
  padding: 14px 16px;
  border-radius: 16px;
  margin-bottom: 18px;
}

.search-box i {
  color: var(--muted);
}

.search-box input {
  border: none;
  outline: none;
  background: transparent;
  width: 100%;
  font-size: 15px;
}

.full-btn {
  width: 100%;
  margin-top: 20px;
  border: none;
  background: var(--sidebar);
  color: white;
  padding: 15px;
  border-radius: 16px;
  font-weight: 800;
  cursor: pointer;
}

.full-btn i {
  margin-right: 8px;
}

/* RESPONSIVE */

@media (max-width: 1200px) {
  .stats-grid,
  .manager-grid,
  .employee-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .content-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 850px) {
  .sidebar {
    position: static;
    width: 100%;
    min-height: auto;
  }

  .app {
    flex-direction: column;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .topbar-actions {
    width: 100%;
    flex-wrap: wrap;
  }

  .stats-grid,
  .manager-grid,
  .employee-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .profile {
    width: 100%;
  }

  table {
    min-width: 620px;
  }

  .panel {
    overflow-x: auto;
  }
}

/* PAGE SWITCHING */

.page-section {
  display: none;
}

.page-section.active {
  display: block;
}

body.show-sales .dashboard-section {
  display: none !important;
}

body.show-dashboard .page-section {
  display: none !important;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.page-header h2 {
  font-size: 30px;
  letter-spacing: -0.6px;
}

.page-header p {
  color: var(--muted);
  margin-top: 5px;
}

.secondary-btn {
  border: none;
  background: var(--primary);
  color: white;
  padding: 13px 18px;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
}

.secondary-btn i {
  margin-right: 8px;
}

/* POS LAYOUT */

.pos-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr;
  gap: 24px;
  align-items: start;
}

.pos-products-panel,
.pos-cart-panel,
.held-sales-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.product-results {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 18px;
}

.pos-product-card {
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 16px;
  cursor: pointer;
  transition: 0.2s ease;
  background: #ffffff;
}

.pos-product-card:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.1);
}

.pos-product-card.disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.pos-product-card h4 {
  font-size: 16px;
  margin-bottom: 8px;
}

.pos-product-card p {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
}

.pos-product-card strong {
  display: block;
  font-size: 17px;
  margin-bottom: 8px;
}

.stock-pill {
  display: inline-block;
  padding: 6px 9px;
  border-radius: 999px;
  background: var(--success-soft);
  color: var(--success);
  font-size: 12px;
  font-weight: 800;
}

.stock-pill.low {
  background: var(--danger-soft);
  color: var(--danger);
}

/* CART */

.cart-items {
  min-height: 230px;
  margin-bottom: 20px;
}

.cart-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.cart-row:last-child {
  border-bottom: none;
}

.cart-row h4 {
  font-size: 15px;
  margin-bottom: 4px;
}

.cart-row p {
  color: var(--muted);
  font-size: 13px;
}

.cart-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.qty-btn,
.remove-btn {
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  cursor: pointer;
  font-weight: 800;
}

.qty-btn {
  background: var(--primary-soft);
  color: var(--primary);
}

.remove-btn {
  background: var(--danger-soft);
  color: var(--danger);
}

.cart-summary {
  border-top: 1px solid var(--border);
  padding-top: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cart-summary > div {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-summary span {
  color: var(--muted);
}

.cart-summary strong {
  font-size: 18px;
}

.discount-control {
  display: flex;
  align-items: center;
  gap: 8px;
}

.discount-control input,
.payment-box select,
.split-payment-box input {
  border: 1px solid var(--border);
  padding: 11px;
  border-radius: 12px;
  outline: none;
  background: #ffffff;
}

.discount-control input {
  width: 100px;
}

.payment-box {
  margin-top: 18px;
}

.payment-box label,
.split-payment-box label {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 7px;
}

.payment-box select {
  width: 100%;
}

.split-payment-box {
  display: none;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 14px;
}

.split-payment-box.active {
  display: grid;
}

.split-payment-box input {
  width: 100%;
}

/* POS ACTIONS */

.pos-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 18px;
}

.pos-actions button {
  border: none;
  padding: 14px;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
}

.hold-btn {
  background: var(--warning-soft);
  color: #92400e;
}

.cancel-btn {
  background: var(--danger-soft);
  color: var(--danger);
}

.complete-btn {
  grid-column: span 2;
  background: var(--success);
  color: white;
}

.held-sales-panel {
  margin-top: 24px;
}

.held-sale-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--border);
  padding: 14px;
  border-radius: 14px;
  margin-bottom: 12px;
}

.held-sale-card p {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px;
}

.held-sale-card button {
  border: none;
  background: var(--primary);
  color: white;
  padding: 10px 14px;
  border-radius: 12px;
  cursor: pointer;
  font-weight: 700;
}

/* RESPONSIVE POS */

@media (max-width: 1100px) {
  .pos-layout {
    grid-template-columns: 1fr;
  }

  .product-results {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .page-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .pos-actions {
    grid-template-columns: 1fr;
  }

  .complete-btn {
    grid-column: span 1;
  }
}

/* RECEIPT DESIGN SECTION */

.receipt-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: start;
}

.receipt-settings-panel,
.receipt-preview-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group.full {
  grid-column: span 2;
}

.form-group label {
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
}

.form-group input,
.form-group textarea,
.form-group select {
  border: 1px solid var(--border);
  padding: 13px 14px;
  border-radius: 14px;
  outline: none;
  font-size: 14px;
  background: #ffffff;
}

.form-group textarea {
  resize: vertical;
}

.form-group small {
  color: var(--muted);
  font-size: 12px;
}

.checkbox-group {
  justify-content: center;
}

.checkbox-group label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.checkbox-group input {
  width: 17px;
  height: 17px;
}

.receipt-actions {
  display: flex;
  gap: 12px;
  margin-top: 22px;
}

.dark-btn {
  border: none;
  background: var(--sidebar);
  color: white;
  padding: 13px 18px;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
}

.dark-btn i {
  margin-right: 8px;
}

/* THERMAL RECEIPT PREVIEW */

.thermal-preview-wrapper {
  background: #f8fafc;
  padding: 22px;
  border-radius: 20px;
  display: flex;
  justify-content: center;
  overflow-x: auto;
}

.thermal-receipt-preview {
  width: 300px;
  background: white;
  color: #111827;
  padding: 18px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 12px 35px rgba(15, 23, 42, 0.08);
  font-family: "Courier New", monospace;
  font-size: 12px;
}

.thermal-receipt-preview h3,
.thermal-receipt-preview p {
  text-align: center;
  margin: 4px 0;
}

.thermal-receipt-preview hr {
  border: none;
  border-top: 1px dashed #9ca3af;
  margin: 10px 0;
}

.receipt-logo-preview {
  width: 80px;
  height: 80px;
  margin: 0 auto 10px;
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: #94a3b8;
  font-size: 11px;
}

.receipt-logo-preview img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.receipt-line {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 5px 0;
}

.total-line {
  font-size: 14px;
  font-weight: 900;
}

.receipt-preview-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.receipt-preview-table th,
.receipt-preview-table td {
  padding: 5px 2px;
  border-bottom: 1px dashed #d1d5db;
  text-align: left;
}

.preview-qr-box {
  width: 96px;
  height: 96px;
  margin: 10px auto;
  border: 1px solid #d1d5db;
  display: grid;
  place-items: center;
  text-align: center;
  font-size: 10px;
  color: #64748b;
}

.receipt-small-text {
  font-size: 10px;
  line-height: 1.4;
}

/* PRINT RECEIPT */

@media print {
  body {
    background: white;
  }
}

@media (max-width: 1100px) {
  .receipt-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .form-grid {
    grid-template-columns: 1fr;
  }

  .form-group.full {
    grid-column: span 1;
  }

  .receipt-actions {
    flex-direction: column;
  }
}

.inventory-layout {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 24px;
  align-items: start;
}

.inventory-form-panel,
.inventory-alert-panel,
.inventory-actions-panel,
.inventory-transfer-panel,
.inventory-products-panel,
.inventory-history-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.outlet-checkboxes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.outlet-checkboxes label {
  background: #f9fafb;
  border: 1px solid var(--border);
  padding: 12px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.inventory-form-actions {
  display: flex;
  gap: 12px;
  margin-top: 22px;
}

.stock-action-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 18px;
}

.stock-action-grid .full {
  grid-column: span 4;
}

.inventory-search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #f9fafb;
  border: 1px solid var(--border);
  padding: 11px 14px;
  border-radius: 14px;
  min-width: 320px;
}

.inventory-search-box input {
  border: none;
  outline: none;
  background: transparent;
  width: 100%;
}

.inventory-table-wrapper {
  width: 100%;
  overflow-x: auto;
}

.product-thumb {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid var(--border);
  background: #f9fafb;
}

.no-thumb {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: #f9fafb;
  border: 1px solid var(--border);
  color: var(--muted);
}

.inventory-actions {
  display: flex;
  gap: 8px;
}

.icon-action {
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 800;
}

.icon-action.edit {
  background: var(--primary-soft);
  color: var(--primary);
}

.icon-action.delete {
  background: var(--danger-soft);
  color: var(--danger);
}

.stock-status {
  display: inline-block;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.stock-status.ok {
  background: var(--success-soft);
  color: var(--success);
}

.stock-status.low {
  background: var(--warning-soft);
  color: #92400e;
}

.stock-status.out {
  background: var(--danger-soft);
  color: var(--danger);
}

.notification-item {
  padding: 14px;
  border-radius: 16px;
  border: 1px solid var(--border);
  margin-bottom: 12px;
  background: #ffffff;
}

.notification-item strong {
  display: block;
  margin-bottom: 5px;
}

.notification-item p {
  color: var(--muted);
  font-size: 13px;
}

.notification-item.low {
  border-left: 5px solid var(--warning);
}

.notification-item.damaged,
.notification-item.expired {
  border-left: 5px solid var(--danger);
}

.notification-item.transfer {
  border-left: 5px solid var(--primary);
}

.notification-item.stock {
  border-left: 5px solid var(--success);
}

@media (max-width: 1200px) {
  .inventory-layout {
    grid-template-columns: 1fr;
  }

  .stock-action-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stock-action-grid .full {
    grid-column: span 2;
  }
}

@media (max-width: 650px) {
  .outlet-checkboxes,
  .stock-action-grid {
    grid-template-columns: 1fr;
  }

  .stock-action-grid .full {
    grid-column: span 1;
  }

  .inventory-form-actions {
    flex-direction: column;
  }

  .inventory-search-box {
    min-width: 100%;
  }
}

/* PURCHASES SECTION */

.purchases-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: start;
}

.purchase-panel,
.purchase-order-panel,
.purchase-history-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.supplier-form-grid {
  grid-template-columns: repeat(2, 1fr);
}

.purchase-actions {
  display: flex;
  gap: 12px;
  margin-top: 22px;
  flex-wrap: wrap;
}

.supplier-list-box {
  margin-top: 24px;
}

.supplier-list-box h4 {
  margin-bottom: 14px;
}

.supplier-card {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  margin-bottom: 12px;
  background: #ffffff;
}

.supplier-card p {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px;
}

.supplier-card-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.purchase-summary-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.purchase-summary-card {
  background: #f9fafb;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
}

.purchase-summary-card span {
  display: block;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 8px;
}

.purchase-summary-card strong {
  font-size: 22px;
}

.purchase-items-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 24px 0 14px;
  gap: 16px;
}

.purchase-items-header p {
  color: var(--muted);
  font-size: 14px;
  margin-top: 4px;
}

.purchase-items-table-wrapper {
  width: 100%;
  overflow-x: auto;
}

.purchase-item-product,
.purchase-item-input {
  width: 100%;
  min-width: 150px;
  border: 1px solid var(--border);
  padding: 10px;
  border-radius: 12px;
  outline: none;
}

.purchase-remove-btn {
  border: none;
  background: var(--danger-soft);
  color: var(--danger);
  width: 36px;
  height: 36px;
  border-radius: 10px;
  cursor: pointer;
}

.purchase-total-box {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.purchase-total-box div {
  background: #f9fafb;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.purchase-total-box span {
  color: var(--muted);
}

.purchase-total-box strong {
  font-size: 18px;
}

.purchase-status {
  display: inline-block;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.purchase-status.ordered {
  background: var(--warning-soft);
  color: #92400e;
}

.purchase-status.received {
  background: var(--success-soft);
  color: var(--success);
}

.purchase-status.cancelled {
  background: var(--danger-soft);
  color: var(--danger);
}

.payment-status {
  display: inline-block;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.payment-status.paid {
  background: var(--success-soft);
  color: var(--success);
}

.payment-status.partial {
  background: var(--warning-soft);
  color: #92400e;
}

.payment-status.unpaid {
  background: var(--danger-soft);
  color: var(--danger);
}

.purchase-history-actions {
  display: flex;
  gap: 8px;
}

@media (max-width: 1100px) {
  .purchases-layout {
    grid-template-columns: 1fr;
  }

  .purchase-total-box {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .supplier-form-grid {
    grid-template-columns: 1fr;
  }

  .purchase-items-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* REPORTS SECTION */

.reports-filter-panel,
.report-output-panel {
  margin-bottom: 24px;
}

.report-filter-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  align-items: end;
}

.report-filter-actions {
  justify-content: flex-end;
}

.reports-link-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 24px;
}

.report-link-card {
  border: 1px solid var(--border);
  background: var(--card);
  border-radius: 18px;
  padding: 20px;
  box-shadow: var(--shadow);
  cursor: pointer;
  text-align: left;
  transition: 0.2s ease;
}

.report-link-card:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
}

.report-link-card i {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 20px;
  margin-bottom: 14px;
}

.report-link-card strong {
  display: block;
  margin-bottom: 6px;
  color: var(--text);
}

.report-link-card span {
  color: var(--muted);
  font-size: 13px;
}

.reports-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  margin-bottom: 24px;
}

.report-table-wrapper {
  width: 100%;
  overflow-x: auto;
}

.report-mini-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 22px;
}

.report-mini-card {
  background: #f9fafb;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
}

.report-mini-card span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 7px;
}

.report-mini-card strong {
  font-size: 20px;
}

.report-badge {
  display: inline-block;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.report-badge.good {
  background: var(--success-soft);
  color: var(--success);
}

.report-badge.warning {
  background: var(--warning-soft);
  color: #92400e;
}

.report-badge.danger {
  background: var(--danger-soft);
  color: var(--danger);
}

@media (max-width: 1200px) {
  .reports-summary-grid,
  .reports-link-grid,
  .report-filter-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .report-mini-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .reports-summary-grid,
  .reports-link-grid,
  .report-filter-grid {
    grid-template-columns: 1fr;
  }
}

/* EMPLOYEES SECTION */

.employees-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: start;
}

.employee-form-panel,
.employee-attendance-panel,
.employee-list-panel,
.employee-shift-history-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.employee-photo-area {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 22px;
  padding: 16px;
  background: #f9fafb;
  border: 1px solid var(--border);
  border-radius: 18px;
}

.employee-photo-preview {
  width: 96px;
  height: 96px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--muted);
  font-size: 34px;
  flex-shrink: 0;
}

.employee-photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--primary);
  color: white !important;
  padding: 12px 16px;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
  margin-bottom: 8px;
}

.employee-photo-area p {
  color: var(--muted);
  font-size: 13px;
}

.employee-actions,
.attendance-actions {
  display: flex;
  gap: 12px;
  margin-top: 22px;
  flex-wrap: wrap;
}

.complete-btn.single,
.cancel-btn.single {
  grid-column: auto;
  border: none;
  padding: 14px 18px;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
}

.active-shift-box {
  margin-top: 26px;
}

.active-shift-box h4 {
  margin-bottom: 14px;
}

.active-employee-card {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 12px;
  background: #ffffff;
}

.active-employee-card img,
.employee-table-photo {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  object-fit: cover;
  border: 1px solid var(--border);
}

.employee-photo-placeholder {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #f9fafb;
  color: var(--muted);
  border: 1px solid var(--border);
}

.active-employee-card p {
  color: var(--muted);
  font-size: 13px;
  margin-top: 4px;
}

.employee-status {
  display: inline-block;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.employee-status.active {
  background: var(--success-soft);
  color: var(--success);
}

.employee-status.inactive {
  background: var(--warning-soft);
  color: #92400e;
}

.employee-status.suspended {
  background: var(--danger-soft);
  color: var(--danger);
}

.shift-status {
  display: inline-block;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.shift-status.open {
  background: var(--success-soft);
  color: var(--success);
}

.shift-status.closed {
  background: #eef2f7;
  color: var(--muted);
}

@media (max-width: 1100px) {
  .employees-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  .employee-photo-area {
    flex-direction: column;
    align-items: flex-start;
  }
}

.settings-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: start;
}

.settings-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.settings-checkbox-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.settings-checkbox-list label,
.settings-panel .form-group.full label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.settings-checkbox-list input,
.settings-panel input[type="checkbox"] {
  width: 17px;
  height: 17px;
}

.settings-note {
  margin-top: 18px;
  padding: 14px;
  border-radius: 14px;
  background: var(--primary-soft);
  color: var(--primary);
  font-size: 14px;
  line-height: 1.5;
}

.settings-warning {
  margin-top: 18px;
  padding: 14px;
  border-radius: 14px;
  background: var(--warning-soft);
  color: #92400e;
  font-weight: 700;
  font-size: 14px;
  line-height: 1.5;
}

.settings-danger-box {
  margin-top: 24px;
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--danger-soft);
  background: #fff7f7;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}

.settings-danger-box p {
  color: var(--muted);
  font-size: 14px;
  margin-top: 5px;
}

.danger-btn {
  border: none;
  background: var(--danger);
  color: white;
  padding: 13px 18px;
  border-radius: 14px;
  font-weight: 800;
  cursor: pointer;
}

.danger-btn i {
  margin-right: 8px;
}

.settings-inline-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.permissions-table-wrapper {
  width: 100%;
  overflow-x: auto;
}

.permissions-table-wrapper input[type="checkbox"] {
  width: 18px;
  height: 18px;
}

.settings-save-permissions {
  margin-top: 18px;
}

@media (max-width: 1100px) {
  .settings-layout {
    grid-template-columns: 1fr;
  }

  .settings-danger-box {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* MAIN POS SECURITY SCREEN */

.security-screen {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, 0.22), transparent 35%),
    linear-gradient(135deg, #020617, #0f172a);
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.security-screen.active {
  display: flex;
}

.security-card {
  width: 100%;
  max-width: 460px;
  background: #ffffff;
  border-radius: 28px;
  padding: 34px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}

.security-logo {
  width: 76px;
  height: 76px;
  border-radius: 24px;
  background: var(--primary-soft);
  color: var(--primary);
  display: grid;
  place-items: center;
  font-size: 32px;
  margin: 0 auto 18px;
}

.security-card h1 {
  text-align: center;
  font-size: 28px;
  margin-bottom: 8px;
  color: var(--text);
}

.security-card > p {
  text-align: center;
  color: var(--muted);
  margin-bottom: 22px;
}

.security-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #f1f5f9;
  padding: 6px;
  border-radius: 18px;
  margin-bottom: 22px;
}

.security-tab {
  border: none;
  background: transparent;
  padding: 12px;
  border-radius: 14px;
  font-weight: 900;
  cursor: pointer;
  color: var(--muted);
}

.security-tab.active {
  background: var(--primary);
  color: white;
}

.security-form {
  display: none;
}

.security-form.active {
  display: block;
}

.security-login-btn {
  width: 100%;
  border: none;
  background: var(--primary);
  color: white;
  padding: 15px;
  border-radius: 16px;
  font-weight: 900;
  cursor: pointer;
  margin-top: 10px;
}

.security-login-btn i {
  margin-right: 8px;
}

.security-error {
  color: var(--danger) !important;
  font-weight: 800;
  margin-top: 14px;
  min-height: 20px;
}

.security-note {
  margin-top: 18px;
  padding: 13px;
  border-radius: 14px;
  background: #f8fafc;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.shift-correct-btn {
  display: block;
  margin-top: 7px;
  border: 0;
  border-radius: 8px;
  padding: 6px 9px;
  background: #dbeafe;
  color: #1d4ed8;
  font-weight: 800;
  cursor: pointer;
}

.shift-correct-btn:hover {
  background: #bfdbfe;
}

/* LOCKED POS STATE */

/* SMARTPOS DASHBOARD LIVE SALES FIX */

.ranking-item {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--border);
}

.ranking-item:last-child {
  border-bottom: 0;
}

.rank-number {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 900;
}

.ranking-info {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.ranking-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ranking-info small {
  color: var(--muted);
}

.ranking-value {
  color: var(--primary);
  font-weight: 900;
  white-space: nowrap;
}

body.pos-locked .sidebar,
body.pos-locked .logout-btn {
  border: none;
  background: var(--danger-soft);
  color: var(--danger);
  padding: 11px 14px;
  border-radius: 14px;
  font-weight: 900;
  cursor: pointer;
}

.logout-btn i {
  margin-right: 7px;
}

.logout-btn {
  border: none;
  background: var(--danger-soft);
  color: var(--danger);
  padding: 11px 15px;
  border-radius: 14px;
  font-weight: 900;
  cursor: pointer;
}

.logout-btn i {
  margin-right: 7px;
}

.logout-btn:hover {
  opacity: 0.85;
}

body.employee-session #roleSelector,
body.employee-session .role-selector-box,
body.employee-session .view-as-box {
  display: none !important;
}

.forgot-pin-btn {
  width: 100%;
  border: none;
  background: transparent;
  color: var(--primary);
  font-weight: 900;
  cursor: pointer;
  margin-top: 14px;
  padding: 10px;
}

.forgot-pin-btn:hover {
  text-decoration: underline;
}

.pin-reset-panel {
  display: none;
  margin-top: 18px;
}

.pin-reset-panel.active {
  display: block;
}

.security-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.security-divider::before,
.security-divider::after {
  content: "";
  height: 1px;
  background: var(--border);
  flex: 1;
}

.pin-reset-help {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px !important;
}

/* PRODUCTS SECTION */

.products-list-panel,
.products-stock-panel,
.stock-taking-panel,
.stock-taking-history-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.stock-taking-controls {
  display: grid;
  grid-template-columns: 0.8fr 1.4fr 0.8fr;
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
}

.stock-taking-action-box {
  justify-content: end;
}

.stock-taking-table-wrapper {
  margin-top: 18px;
}

.stock-taking-input {
  width: 100%;
  min-width: 120px;
  border: 1px solid var(--border);
  padding: 10px;
  border-radius: 12px;
  outline: none;
}

.stock-difference {
  display: inline-block;
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.stock-difference.equal {
  background: var(--success-soft);
  color: var(--success);
}

.stock-difference.shortage {
  background: var(--danger-soft);
  color: var(--danger);
}

.stock-difference.excess {
  background: var(--warning-soft);
  color: #92400e;
}

.stock-taking-footer {
  margin-top: 18px;
  padding: 18px;
  background: #f9fafb;
  border: 1px solid var(--border);
  border-radius: 18px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}

.stock-taking-footer p {
  color: var(--muted);
  margin-top: 5px;
  font-size: 14px;
}

.stock-taking-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

@media (max-width: 1000px) {
  .stock-taking-controls {
    grid-template-columns: 1fr;
  }

  .stock-taking-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}
.notification-item.employee {
  border-left: 4px solid var(--primary);
}

/* EXPENSES SECTION */

.expense-form-panel,
.expense-tools-panel,
.expense-breakdown-panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  margin-bottom: 24px;
}

.expense-filter-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr;
  gap: 18px;
  margin-bottom: 20px;
  align-items: end;
}

.expense-receipt-thumb {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--border);
}

.no-expense-receipt {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: var(--muted);
  background: #f8fafc;
  border: 1px solid var(--border);
}

.expense-actions {
  display: flex;
  gap: 8px;
}

@media (max-width: 1000px) {
  .expense-filter-grid {
    grid-template-columns: 1fr;
  }
}

.password-field {
  position: relative;
}

.password-field input {
  padding-right: 48px;
}

.view-password-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: #f1f5f9;
  color: var(--muted);
  width: 34px;
  height: 34px;
  border-radius: 10px;
  cursor: pointer;
}

.view-password-btn:hover {
  color: var(--primary);
}

.small-action-btn {
  border: none;
  background: var(--primary-soft);
  color: var(--primary);
  padding: 8px 10px;
  border-radius: 10px;
  font-weight: 900;
  cursor: pointer;
}

.small-action-btn:hover {
  opacity: 0.85;
}

.outlet-form-box {
  display: none;
  margin-bottom: 18px;
}

.outlet-form-box.active {
  display: block;
}

/* PAYMENT POPUP */

.payment-popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  z-index: 999998;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.payment-popup-overlay.active {
  display: flex;
}

.payment-popup-card {
  width: 100%;
  max-width: 620px;
  background: #ffffff;
  border-radius: 28px;
  padding: 26px;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.35);
}

.payment-popup-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 18px;
}

.payment-popup-header h2 {
  margin-bottom: 6px;
  color: var(--text);
}

.payment-popup-header p {
  color: var(--muted);
  font-size: 14px;
}

.payment-close-btn {
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 12px;
  background: #f1f5f9;
  color: var(--text);
  cursor: pointer;
}

.payment-total-box {
  background: var(--primary-soft);
  color: var(--primary);
  padding: 18px;
  border-radius: 18px;
  margin-bottom: 18px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}

.payment-total-box span {
  font-weight: 800;
}

.payment-total-box strong {
  font-size: 24px;
}

.payment-method-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.payment-method-card {
  border: 1px solid var(--border);
  background: #ffffff;
  border-radius: 18px;
  padding: 18px;
  cursor: pointer;
  text-align: left;
  transition: 0.2s ease;
}

.payment-method-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}

.payment-method-card i {
  font-size: 26px;
  color: var(--primary);
  margin-bottom: 12px;
}

.payment-method-card strong {
  display: block;
  color: var(--text);
  margin-bottom: 6px;
}

.payment-method-card span {
  color: var(--muted);
  font-size: 13px;
}

.payment-extra-panel {
  display: none;
  margin-top: 18px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #f9fafb;
}

.payment-extra-panel.active {
  display: block;
}

.payment-status-text {
  margin-top: 12px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

@media (max-width: 800px) {
  .payment-method-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   SALES SECTION ONLY: RETURN / DELETE SALE
   This styles only .sale-return-panel and its children.
   It will not affect other POS sections.
   ========================================================= */

.sale-return-panel {
  margin-top: 18px;
}

.sale-return-panel .form-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 14px;
  align-items: end;
}

.sale-return-panel .form-group {
  margin: 0;
}

.sale-return-panel .form-group label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 900;
  color: var(--text);
}

.sale-return-panel input {
  width: 100%;
  height: 46px;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0 14px;
  outline: none;
  font-size: 14px;
  background: #ffffff;
}

.sale-return-panel input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.sale-return-panel #searchSaleReturnBtn {
  width: 100%;
  height: 46px;
  border-radius: 14px;
  padding: 0 16px;
}

.sale-return-panel #saleReturnResult {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.sale-return-panel .return-sale-card {
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #ffffff;
  padding: 16px;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.sale-return-panel .return-sale-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}

.sale-return-panel .return-sale-card h4 {
  font-size: 16px;
  margin-bottom: 8px;
  color: var(--text);
}

.sale-return-panel .return-sale-card p {
  margin: 5px 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.sale-return-panel .return-sale-card strong {
  color: var(--text);
}

.sale-return-panel .return-sale-card .report-badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 5px 11px;
  font-size: 12px;
}

.sale-return-panel .return-sale-card .secondary-btn {
  flex-shrink: 0;
  min-width: 110px;
  height: 42px;
  border-radius: 13px;
  padding: 0 14px;
  font-size: 13px;
}

.sale-return-panel .table-empty {
  grid-column: 1 / -1;
  padding: 18px;
  border: 1px dashed var(--border);
  border-radius: 16px;
  background: #f9fafb;
  color: var(--muted);
  text-align: center;
  font-weight: 700;
}

/* Sale action popup table and buttons */
#saleActionPopupOverlay .payment-popup-card {
  max-width: 760px;
}

#saleActionPopupOverlay p {
  margin: 6px 0;
  color: var(--muted);
  font-size: 14px;
}

#saleActionPopupOverlay .inventory-table-wrapper {
  max-height: 280px;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 16px;
}

#saleActionPopupOverlay table {
  width: 100%;
  border-collapse: collapse;
}

#saleActionPopupOverlay th {
  padding: 12px 10px;
  background: #f9fafb;
  color: var(--muted);
  font-size: 13px;
}

#saleActionPopupOverlay td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

#saleActionPopupOverlay .form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

#saleActionPopupOverlay .form-actions button {
  min-height: 42px;
}

/* Responsive only for this return/delete section */
@media (max-width: 900px) {
  .sale-return-panel .form-grid {
    grid-template-columns: 1fr;
  }

  .sale-return-panel #saleReturnResult {
    grid-template-columns: 1fr;
  }

  .sale-return-panel .return-sale-header {
    flex-direction: column;
  }

  .sale-return-panel .return-sale-card .secondary-btn {
    width: 100%;
  }
}

/* =========================================================
   SALES SECTION ONLY: BULK RETURN / DELETE
   Scoped to .sale-return-panel only.
   ========================================================= */

.sale-return-panel .sale-bulk-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  margin: 14px 0 4px;
}

.sale-return-panel .sale-bulk-actions button {
  min-height: 42px;
}

.sale-return-panel .sale-select-box {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 900;
  color: var(--text);
  background: #f9fafb;
  border: 1px solid var(--border);
  padding: 8px 10px;
  border-radius: 12px;
  cursor: pointer;
}

.sale-return-panel .sale-select-box input {
  width: 16px;
  height: 16px;
  box-shadow: none;
}

.sale-return-panel .return-sale-body {
  margin-top: 12px;
}

.sale-return-panel .return-sale-header {
  align-items: center;
}

/* =========================================================
   AI STOCK PREDICTION SECTION ONLY
   Scoped to #aiSection.
   ========================================================= */

#aiSection .ai-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

#aiSection .ai-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  align-items: start;
}

#aiSection .ai-panel {
  overflow-x: auto;
}

#aiSection .ai-notes-box {
  display: grid;
  gap: 10px;
}

#aiSection .ai-note-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 13px;
  border-radius: 14px;
  background: #f9fafb;
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 14px;
  line-height: 1.45;
}

#aiSection .ai-note-item i {
  color: var(--success);
  margin-top: 2px;
}

@media (max-width: 1200px) {
  #aiSection .ai-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #aiSection .ai-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  #aiSection .ai-summary-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   OFFLINE SYNC STATUS ONLY
   Scoped to .sync-status-pill.
   ========================================================= */

.sync-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #ffffff;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  box-shadow: var(--shadow);
}

.sync-status-pill.online {
  background: var(--success-soft);
  color: var(--success);
  border-color: var(--success-soft);
}

.sync-status-pill.offline {
  background: var(--warning-soft);
  color: #92400e;
  border-color: var(--warning-soft);
}

.sync-status-pill.syncing {
  background: var(--primary-soft);
  color: var(--primary);
  border-color: var(--primary-soft);
}

.sync-status-pill.conflict {
  background: var(--danger-soft);
  color: var(--danger);
  border-color: var(--danger-soft);
}

@media (max-width: 650px) {
  .sync-status-pill {
    width: 100%;
    justify-content: center;
  }
}

/* =========================================================
   AUDIT LOGS SECTION ONLY
   Scoped to #auditSection.
   ========================================================= */

#auditSection .audit-filter-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr) minmax(0, 0.8fr);
  gap: 14px;
  align-items: end;
}

#auditSection .audit-filter-panel,
#auditSection .audit-table-panel {
  margin-bottom: 18px;
}

#auditSection #auditLogsTable td {
  vertical-align: top;
}

#auditSection #auditLogsTable td:nth-child(5) {
  min-width: 260px;
}

#auditSection #auditLogsTable td:nth-child(6) {
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 900px) {
  #auditSection .audit-filter-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   RETURN FRAUD PROTECTION ONLY
   Scoped to return popup and settings panel.
   ========================================================= */

#saleActionPopupOverlay .return-protection-box {
  margin-top: 16px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #f9fafb;
}

#saleActionPopupOverlay .return-protection-box h4 {
  margin-bottom: 10px;
  color: var(--text);
}

#saleActionPopupOverlay .return-protection-box textarea,
#saleActionPopupOverlay .return-protection-box input[type="file"] {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px;
  background: #ffffff;
  outline: none;
}

#saleActionPopupOverlay .return-protection-box textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

#saleActionPopupOverlay .return-history-box {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}

#saleActionPopupOverlay .return-history-item {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid var(--border);
  font-size: 13px;
}

#saleActionPopupOverlay .return-history-item span {
  color: var(--muted);
}

.return-protection-settings-panel {
  margin-top: 18px;
}

/* =========================================================
   FIX RETURN / DELETE SALE POPUP VISIBILITY ONLY
   Scoped only to #saleActionPopupOverlay.
   ========================================================= */

#saleActionPopupOverlay {
  position: fixed;
  inset: 0;
  padding: 24px;
  overflow-y: auto;
  align-items: flex-start;
  justify-content: center;
}

#saleActionPopupOverlay.active {
  display: flex;
}

#saleActionPopupOverlay .payment-popup-card {
  width: min(900px, 100%);
  max-width: 900px;
  max-height: none;
  margin: 20px auto;
  overflow: visible;
}

#saleActionPopupOverlay .payment-popup-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: #ffffff;
  padding-bottom: 12px;
}

#saleActionPopupOverlay .payment-total-box {
  position: sticky;
  top: 74px;
  z-index: 4;
}

#saleActionPopupOverlay .return-protection-box {
  max-height: none;
  overflow: visible;
}

#saleActionPopupOverlay .inventory-table-wrapper {
  max-height: none;
  overflow-x: auto;
  overflow-y: visible;
}

#saleActionPopupOverlay .form-actions {
  position: sticky;
  bottom: 0;
  z-index: 6;
  background: #ffffff;
  padding: 14px 0 0;
  border-top: 1px solid var(--border);
}

@media (max-width: 700px) {
  #saleActionPopupOverlay {
    padding: 12px;
  }

  #saleActionPopupOverlay .payment-popup-card {
    margin: 10px auto;
    border-radius: 18px;
  }

  #saleActionPopupOverlay .payment-popup-header {
    top: 0;
  }

  #saleActionPopupOverlay .payment-total-box {
    top: 70px;
  }

  #saleActionPopupOverlay .form-actions {
    flex-direction: column;
  }

  #saleActionPopupOverlay .form-actions button {
    width: 100%;
  }
}

/* =========================================================
   DAILY CLOSING SECTION ONLY
   Scoped only to #closingSection.
   ========================================================= */

#closingSection .closing-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

#closingSection .closing-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(320px, 0.7fr);
  gap: 18px;
  align-items: start;
}

#closingSection .closing-panel {
  margin-bottom: 18px;
}

#closingSection textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 14px;
  outline: none;
  resize: vertical;
  font-size: 14px;
}

#closingSection textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

#closingSection .closing-calculation-box {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #f9fafb;
}

#closingSection .closing-calculation-box div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

#closingSection .closing-calculation-box div:last-child {
  border-bottom: none;
}

#closingSection .closing-calculation-box span {
  color: var(--muted);
  font-weight: 800;
}

#closingSection .closing-calculation-box strong {
  color: var(--text);
}

#closingSection .closing-total-row {
  font-size: 16px;
}

#closingSection .closing-approval-box {
  min-height: 170px;
}

#closingSection .closing-approval-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #f9fafb;
}

#closingSection .closing-approval-card h4 {
  color: var(--text);
  margin-bottom: 4px;
}

#closingSection .closing-approval-card p {
  color: var(--muted);
  margin: 0;
}

#closingSection #closingHistoryTable tr {
  cursor: pointer;
}

#closingSection #closingHistoryTable tr:hover {
  background: #f9fafb;
}

#closingSection .closing-short {
  color: var(--danger);
  font-weight: 900;
}

#closingSection .closing-excess {
  color: var(--success);
  font-weight: 900;
}

#closingSection .closing-balanced {
  color: var(--primary);
  font-weight: 900;
}

@media (max-width: 1200px) {
  #closingSection .closing-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #closingSection .closing-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  #closingSection .closing-summary-grid {
    grid-template-columns: 1fr;
  }

  #closingSection .closing-calculation-box div {
    flex-direction: column;
  }
}

/* =========================================================
   EMPLOYEE SHIFT + DAILY REPORT ONLY
   Scoped to employee dashboard and popup.
   ========================================================= */

.employee-shift-card {
  margin-bottom: 18px;
}

.employee-shift-card .employee-shift-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.employee-shift-status {
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #f9fafb;
  color: var(--muted);
  font-weight: 800;
}

.employee-daily-report-popup {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  padding: 24px;
  background: rgba(15, 23, 42, 0.55);
  overflow-y: auto;
}

.employee-daily-report-popup.active {
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.employee-daily-report-card {
  width: min(900px, 100%);
  margin: 20px auto;
  padding: 22px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.25);
}

.employee-daily-report-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 18px;
}

.employee-daily-report-header h2 {
  margin: 0;
  color: var(--text);
}

.employee-daily-report-header p {
  margin: 6px 0 0;
  color: var(--muted);
}

.employee-daily-report-header button {
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 14px;
  background: #f3f4f6;
  cursor: pointer;
}

.employee-report-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.employee-report-grid div {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #f9fafb;
}

.employee-report-grid span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 6px;
}

.employee-report-grid strong {
  color: var(--text);
  font-size: 16px;
}

@media (max-width: 900px) {
  .employee-shift-card .employee-shift-grid {
    grid-template-columns: 1fr;
  }

  .employee-report-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .employee-daily-report-popup {
    padding: 12px;
  }

  .employee-daily-report-card {
    padding: 16px;
    border-radius: 18px;
  }

  .employee-report-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   EMPLOYEE SHIFT OPENING CARD ONLY
   Scoped to .employee-shift-card.
   ========================================================= */

.employee-shift-card {
  padding: 22px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid var(--border);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.employee-shift-card .card-header {
  margin-bottom: 18px;
}

.employee-shift-card .card-header h3 {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 900;
  color: var(--text);
}

.employee-shift-card .card-header p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.employee-shift-card .employee-shift-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.employee-shift-card .form-group {
  margin: 0;
}

.employee-shift-card .form-group label {
  display: block;
  margin-bottom: 8px;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.employee-shift-card input {
  width: 100%;
  height: 52px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: #ffffff;
  padding: 0 16px;
  font-size: 15px;
  outline: none;
}

.employee-shift-card input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.employee-shift-card .form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.employee-shift-card .form-actions button {
  min-height: 48px;
  border-radius: 16px;
  padding: 0 18px;
  font-weight: 900;
  border: none;
  cursor: pointer;
}

.employee-shift-card #saveEmployeeShiftBtn {
  background: var(--primary);
  color: #ffffff;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.22);
}

.employee-shift-card #saveEmployeeShiftBtn:hover {
  transform: translateY(-1px);
}

.employee-shift-card #employeeDailyReportBtn {
  background: #111827;
  color: #ffffff;
}

.employee-shift-status {
  margin-top: 18px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #f9fafb;
  color: var(--muted);
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.employee-shift-status .report-badge {
  min-height: 32px;
  padding: 7px 13px;
  border-radius: 999px;
}

.employee-shift-status strong {
  color: var(--text);
}

@media (max-width: 800px) {
  .employee-shift-card {
    padding: 18px;
  }

  .employee-shift-card .employee-shift-grid {
    grid-template-columns: 1fr;
  }

  .employee-shift-card .form-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .employee-shift-card .form-actions button {
    width: 100%;
  }

  .employee-shift-status {
    align-items: flex-start;
  }
}

/* =========================================================
   MULTI-DEVICE SUPPORT SECTION ONLY
   Scoped to #devicesSection.
   ========================================================= */

#devicesSection .devices-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

#devicesSection .devices-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 18px;
  align-items: start;
}

#devicesSection .device-register-panel,
#devicesSection .devices-table-panel {
  margin-bottom: 18px;
}

#devicesSection .device-id-box {
  margin-top: 16px;
  padding: 14px;
  border: 1px dashed var(--border);
  border-radius: 16px;
  background: #f9fafb;
  display: grid;
  gap: 5px;
}

#devicesSection .device-id-box span {
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
}

#devicesSection .device-id-box strong {
  color: var(--text);
  word-break: break-all;
}

#devicesSection .device-notes-box {
  display: grid;
  gap: 12px;
}

#devicesSection .device-notes-box div {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 13px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #f9fafb;
  color: var(--text);
  line-height: 1.45;
}

#devicesSection .device-notes-box i {
  color: var(--primary);
  margin-top: 3px;
}

#devicesSection #registeredDevicesTable small {
  color: var(--muted);
  word-break: break-all;
}

@media (max-width: 1200px) {
  #devicesSection .devices-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #devicesSection .devices-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 650px) {
  #devicesSection .devices-summary-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   SIDEBAR VISIBILITY FIX ONLY
   Keeps all service buttons reachable.
   ========================================================= */

.sidebar {
  height: 100vh;
  max-height: 100vh;
  overflow: hidden;
}

.sidebar .logo {
  flex-shrink: 0;
}

.sidebar-menu,
.sidebar nav,
.nav-menu {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 6px;
  scrollbar-width: thin;
}

.sidebar-menu::-webkit-scrollbar,
.sidebar nav::-webkit-scrollbar,
.nav-menu::-webkit-scrollbar {
  width: 6px;
}

.sidebar-menu::-webkit-scrollbar-track,
.sidebar nav::-webkit-scrollbar-track,
.nav-menu::-webkit-scrollbar-track {
  background: transparent;
}

.sidebar-menu::-webkit-scrollbar-thumb,
.sidebar nav::-webkit-scrollbar-thumb,
.nav-menu::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.55);
  border-radius: 999px;
}

.sidebar .nav-link {
  min-height: 42px;
  padding: 10px 14px;
  margin-bottom: 5px;
  font-size: 14px;
  flex-shrink: 0;
}

.sidebar .nav-link i {
  width: 18px;
  font-size: 15px;
}

.sidebar-footer,
.sidebar-role-box,
.sidebar-user {
  flex-shrink: 0;
}

/* Compact sidebar on shorter screens */
@media (max-height: 780px) {
  .sidebar .logo {
    padding-bottom: 10px;
    margin-bottom: 8px;
  }

  .sidebar .logo h2,
  .sidebar .logo-title,
  .sidebar-brand h2 {
    font-size: 18px;
  }

  .sidebar .nav-link {
    min-height: 38px;
    padding: 8px 12px;
    margin-bottom: 4px;
    font-size: 13px;
  }

  .sidebar .nav-link i {
    font-size: 14px;
  }

  .sidebar-footer,
  .sidebar-role-box,
  .sidebar-user {
    padding-top: 8px;
    padding-bottom: 8px;
  }
}

/* Phone layout: sidebar can scroll if menu is open */
@media (max-width: 900px) {
  .sidebar {
    overflow-y: auto;
  }

  .sidebar-menu,
  .sidebar nav,
  .nav-menu {
    max-height: none;
    overflow-y: visible;
  }
}

/* =========================================================
   DEVICE REGISTRATION WARNING ONLY
   Scoped to .device-warning-box.
   ========================================================= */

.device-warning-box {
  display: none;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--warning-soft);
  background: var(--warning-soft);
  color: #92400e;
  font-size: 14px;
  font-weight: 900;
}

.device-warning-box i {
  font-size: 18px;
}

/* =========================================================
   RECEIPT SHARING ONLY
   Does not affect other POS sections.
   ========================================================= */

.receipt-customer-box {
  margin: 16px 0;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: #f9fafb;
}

.receipt-customer-box h4 {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}

.receipt-customer-box p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.receipt-customer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.receipt-customer-box .form-group {
  margin: 0;
}

.receipt-customer-box label {
  display: block;
  margin-bottom: 7px;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.receipt-customer-box input {
  width: 100%;
  height: 44px;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 0 13px;
  outline: none;
  background: #ffffff;
}

.receipt-customer-box input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.receipt-share-popup {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  padding: 24px;
  background: rgba(15, 23, 42, 0.55);
  overflow-y: auto;
}

.receipt-share-popup.active {
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.receipt-share-card {
  width: min(760px, 100%);
  margin: 20px auto;
  padding: 22px;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 30px 80px rgba(15, 23, 42, 0.25);
}

.receipt-share-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.receipt-share-header h2 {
  margin: 0;
  color: var(--text);
}

.receipt-share-header p {
  margin: 5px 0 0;
  color: var(--muted);
}

.receipt-share-header button {
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 14px;
  background: #f3f4f6;
  cursor: pointer;
}

.receipt-share-customer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}

.receipt-share-customer div {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #f9fafb;
}

.receipt-share-customer span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 5px;
}

.receipt-share-customer strong {
  color: var(--text);
  word-break: break-all;
}

.receipt-share-preview {
  max-height: 360px;
  overflow-y: auto;
  padding: 14px;
  border: 1px dashed var(--border);
  border-radius: 18px;
  background: #f9fafb;
}

.receipt-share-preview pre {
  white-space: pre-wrap;
  margin: 0;
  color: var(--text);
  font-family: Arial, sans-serif;
  font-size: 14px;
  line-height: 1.45;
}

.receipt-share-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.receipt-share-actions button {
  min-height: 44px;
  border-radius: 14px;
  padding: 0 15px;
  font-weight: 900;
}

.receipt-share-actions .success-btn {
  border: none;
  background: #16a34a;
  color: #ffffff;
}

.receipt-share-btn {
  min-height: 40px;
  border-radius: 14px;
  font-weight: 900;
}

@media (max-width: 700px) {
  .receipt-customer-grid,
  .receipt-share-customer {
    grid-template-columns: 1fr;
  }

  .receipt-share-popup {
    padding: 12px;
  }

  .receipt-share-card {
    padding: 16px;
    border-radius: 18px;
  }

  .receipt-share-actions {
    flex-direction: column;
  }

  .receipt-share-actions button {
    width: 100%;
  }
}

/* ===============================
   EMPLOYEE SHIFT OPENING - MODERN
================================ */

.employee-shift-card-modern {
  max-width: 920px;
  padding: 24px;
  border-radius: 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e5eaf2;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
}

.employee-shift-header h3 {
  margin-bottom: 6px;
  font-size: 26px;
  font-weight: 900;
  color: #071225;
}

.employee-shift-header p {
  margin: 0;
  font-size: 15px;
  color: #64748b;
}

.employee-shift-grid-modern {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 22px;
}

.shift-money-group label {
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
}

.shift-money-field {
  display: flex;
  align-items: center;
  max-width: 340px;
  height: 48px;
  border: 1px solid #dbe3ef;
  border-radius: 16px;
  background: #ffffff;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.shift-money-field:focus-within {
  border-color: #2563eb;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.14);
}

.shift-money-field span {
  padding: 0 14px;
  height: 100%;
  display: flex;
  align-items: center;
  background: #f1f5f9;
  color: #475569;
  font-size: 13px;
  font-weight: 900;
  border-right: 1px solid #e2e8f0;
}

.shift-money-input {
  width: 100%;
  height: 100%;
  padding: 0 14px;
  border: none;
  outline: none;
  background: transparent;
  color: #020617;
  font-size: 17px;
  font-weight: 800;
}

.shift-money-input::placeholder {
  color: #94a3b8;
}

.employee-shift-actions {
  margin-top: 22px;
  gap: 12px;
}

.employee-shift-actions .primary-btn,
.employee-shift-actions .secondary-btn {
  min-height: 46px;
  padding: 0 22px;
  border-radius: 16px;
  font-size: 14px;
  font-weight: 900;
}

.employee-shift-status-modern {
  margin-top: 22px;
  padding: 16px 18px;
  border-radius: 18px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  font-size: 15px;
  font-weight: 800;
  color: #64748b;
}

@media (max-width: 800px) {
  .employee-shift-grid-modern {
    grid-template-columns: 1fr;
  }

  .shift-money-field {
    max-width: 100%;
  }
}

/* ===============================
   FAST NON-BLOCKING NOTICE
================================ */

.smartpos-fast-notice {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 999999;
  background: #0f172a;
  color: #ffffff;
  padding: 14px 18px;
  border-radius: 14px;
  font-weight: 800;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.25);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: 0.2s ease;
}

.smartpos-fast-notice.active {
  opacity: 1;
  transform: translateY(0);
}

/* ===============================
   SMARTPOS REFRESH BUTTON
================================ */

.refresh-btn {
  min-height: 42px;
  padding: 0 16px;
  border: none;
  border-radius: 14px;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: 0.2s ease;
}

.refresh-btn:hover {
  background: #bae6fd;
  transform: translateY(-1px);
}

.refresh-btn.is-refreshing {
  opacity: 0.7;
  pointer-events: none;
}

.refresh-btn.is-refreshing i {
  animation: smartposSpin 0.8s linear infinite;
}

@keyframes smartposSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* =========================================================
   TERRENCE SOFTWARES WELCOME
========================================================= */

.smartpos-welcome-overlay {
  position: fixed;
  inset: 0;
  z-index: 1500000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(2, 6, 23, 0.68);
  backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transition: 0.3s ease;
}

.smartpos-welcome-overlay.active {
  opacity: 1;
  visibility: visible;
}

.smartpos-welcome-card {
  position: relative;
  width: min(520px, 100%);
  overflow: hidden;
  padding: 42px 34px 32px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 30px;
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.3), transparent 34%),
    linear-gradient(145deg, #ffffff, #f8fafc);
  text-align: center;
  box-shadow: 0 40px 110px rgba(2, 6, 23, 0.48);
  transform: translateY(24px) scale(0.94);
  transition: 0.35s ease;
}

.smartpos-welcome-overlay.active .smartpos-welcome-card {
  transform: translateY(0) scale(1);
}

.smartpos-welcome-card.admin {
  border-top: 6px solid #2563eb;
}

.smartpos-welcome-card.manager {
  border-top: 6px solid #7c3aed;
}

.smartpos-welcome-card.employee {
  border-top: 6px solid #16a34a;
}

.smartpos-welcome-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 3;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 13px;
  background: #eef2f7;
  color: #475569;
  cursor: pointer;
}

.smartpos-welcome-decoration {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.smartpos-welcome-decoration.decoration-one {
  top: -70px;
  left: -70px;
  width: 180px;
  height: 180px;
  background: rgba(37, 99, 235, 0.1);
}

.smartpos-welcome-decoration.decoration-two {
  right: -45px;
  bottom: -70px;
  width: 160px;
  height: 160px;
  background: rgba(22, 163, 74, 0.09);
}

.smartpos-welcome-icon {
  position: relative;
  z-index: 2;
  width: 86px;
  height: 86px;
  margin: 0 auto 20px;
  border-radius: 27px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 36px;
  background: linear-gradient(145deg, #2563eb, #1d4ed8);
  box-shadow: 0 18px 36px rgba(37, 99, 235, 0.3);
}

.smartpos-welcome-card.manager .smartpos-welcome-icon {
  background: linear-gradient(145deg, #8b5cf6, #6d28d9);
  box-shadow: 0 18px 36px rgba(124, 58, 237, 0.28);
}

.smartpos-welcome-card.employee .smartpos-welcome-icon {
  background: linear-gradient(145deg, #22c55e, #15803d);
  box-shadow: 0 18px 36px rgba(22, 163, 74, 0.28);
}

.smartpos-welcome-small-title {
  position: relative;
  z-index: 2;
  margin-bottom: 5px;
  color: #64748b;
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.smartpos-welcome-card h1 {
  position: relative;
  z-index: 2;
  margin: 0;
  color: #0f172a;
  font-size: clamp(29px, 5vw, 40px);
  font-weight: 950;
  letter-spacing: -1.2px;
}

.smartpos-welcome-divider {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 30px 1fr;
  align-items: center;
  gap: 10px;
  margin: 22px 0;
}

.smartpos-welcome-divider span {
  height: 1px;
  background: linear-gradient(90deg, transparent, #cbd5e1);
}

.smartpos-welcome-divider span:last-child {
  background: linear-gradient(90deg, #cbd5e1, transparent);
}

.smartpos-welcome-divider i {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #16a34a;
  background: #dcfce7;
}

.smartpos-welcome-card h2 {
  position: relative;
  z-index: 2;
  margin: 0 0 12px;
  color: #1e293b;
  font-size: 21px;
}

.smartpos-welcome-user {
  position: relative;
  z-index: 2;
  margin: 0 0 8px;
  color: #475569;
  font-size: 17px;
}

.smartpos-welcome-user strong {
  color: #0f172a;
}

.smartpos-welcome-message {
  position: relative;
  z-index: 2;
  max-width: 380px;
  margin: 0 auto;
  color: #64748b;
  font-size: 14px;
  line-height: 1.55;
}

.smartpos-welcome-role-badge {
  position: relative;
  z-index: 2;
  width: max-content;
  margin: 22px auto 0;
  padding: 9px 15px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #1d4ed8;
  background: #dbeafe;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.7px;
}

.smartpos-welcome-card.manager .smartpos-welcome-role-badge {
  color: #6d28d9;
  background: #ede9fe;
}

.smartpos-welcome-card.employee .smartpos-welcome-role-badge {
  color: #15803d;
  background: #dcfce7;
}

.smartpos-welcome-progress {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 5px;
  background: #2563eb;
  transform-origin: left;
  animation: smartposWelcomeProgress 4.3s linear forwards;
}

.smartpos-welcome-card.manager .smartpos-welcome-progress {
  background: #7c3aed;
}

.smartpos-welcome-card.employee .smartpos-welcome-progress {
  background: #16a34a;
}

@keyframes smartposWelcomeProgress {
  from {
    transform: scaleX(1);
  }

  to {
    transform: scaleX(0);
  }
}

/* =========================================================
   ADMIN SALES ACTIVITY TABLE
========================================================= */

.admin-sales-activity-panel {
  margin-top: 28px;
  overflow: hidden;
  border: 1px solid #dbe3ef;
  border-radius: 26px;
  background: #ffffff;
  box-shadow: 0 22px 55px rgba(15, 23, 42, 0.09);
}

.admin-sales-activity-panel[hidden] {
  display: none !important;
}

.admin-sales-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 25px;
  color: #ffffff;
  background:
    radial-gradient(circle at 82% 20%, rgba(96, 165, 250, 0.34), transparent 28%),
    linear-gradient(135deg, #0f172a, #1e3a8a);
}

.admin-sales-heading {
  display: flex;
  align-items: center;
  gap: 17px;
}

.admin-sales-heading-icon {
  width: 58px;
  height: 58px;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 18px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.12);
  font-size: 24px;
}

.admin-only-label {
  display: block;
  margin-bottom: 5px;
  color: #bfdbfe;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1.3px;
  text-transform: uppercase;
}

.admin-sales-header h2 {
  margin: 0;
  font-size: 27px;
  letter-spacing: -0.5px;
}

.admin-sales-header p {
  max-width: 680px;
  margin: 6px 0 0;
  color: #dbeafe;
  font-size: 13px;
  line-height: 1.5;
}

.admin-sales-refresh-btn {
  min-height: 45px;
  flex-shrink: 0;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 14px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.13);
  font-weight: 900;
  cursor: pointer;
}

.admin-sales-refresh-btn i {
  margin-right: 7px;
}

.admin-sales-refresh-btn:hover {
  background: rgba(255, 255, 255, 0.22);
}

.admin-sales-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  padding: 22px 22px 0;
}

.admin-sales-summary-card {
  min-height: 116px;
  padding: 18px;
  border: 1px solid #e2e8f0;
  border-radius: 19px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}

.admin-sales-summary-card span {
  display: block;
  margin-bottom: 7px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.admin-sales-summary-card strong {
  display: block;
  color: #0f172a;
  font-size: 21px;
}

.admin-sales-summary-card strong.negative {
  color: #dc2626;
}

.admin-sales-summary-card small {
  display: block;
  margin-top: 6px;
  color: #94a3b8;
  font-size: 11px;
}

.admin-sales-summary-card > i {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  border-radius: 15px;
  display: grid;
  place-items: center;
  font-size: 20px;
}

.admin-sales-summary-card.sales-value {
  background: linear-gradient(145deg, #eff6ff, #ffffff);
}

.admin-sales-summary-card.sales-value > i {
  color: #2563eb;
  background: #dbeafe;
}

.admin-sales-summary-card.profit-value {
  background: linear-gradient(145deg, #f0fdf4, #ffffff);
}

.admin-sales-summary-card.profit-value > i {
  color: #16a34a;
  background: #dcfce7;
}

.admin-sales-summary-card.item-value {
  background: linear-gradient(145deg, #fff7ed, #ffffff);
}

.admin-sales-summary-card.item-value > i {
  color: #ea580c;
  background: #ffedd5;
}

.admin-sales-summary-card.receipt-value {
  background: linear-gradient(145deg, #faf5ff, #ffffff);
}

.admin-sales-summary-card.receipt-value > i {
  color: #7c3aed;
  background: #ede9fe;
}

.admin-sales-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 22px;
}

.admin-sales-search {
  width: min(570px, 100%);
  min-height: 48px;
  padding: 0 16px;
  border: 1px solid #dbe3ef;
  border-radius: 15px;
  display: flex;
  align-items: center;
  gap: 11px;
  background: #f8fafc;
}

.admin-sales-search i {
  color: #64748b;
}

.admin-sales-search input {
  width: 100%;
  border: none;
  outline: none;
  color: #0f172a;
  background: transparent;
  font-size: 14px;
}

.admin-sales-live-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #15803d;
  font-size: 13px;
  font-weight: 900;
}

.admin-sales-live-indicator span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 5px rgba(34, 197, 94, 0.13);
  animation: adminSalesLivePulse 1.8s infinite;
}

@keyframes adminSalesLivePulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(0.72);
  }
}

.admin-sales-table-wrapper {
  width: calc(100% - 44px);
  margin: 0 22px;
  overflow: auto;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
}

.admin-sales-table {
  width: 100%;
  min-width: 1220px;
  border-collapse: separate;
  border-spacing: 0;
}

.admin-sales-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 15px 13px;
  border-bottom: 1px solid #dbe3ef;
  color: #475569;
  background: #f1f5f9;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 0.55px;
  text-transform: uppercase;
  white-space: nowrap;
}

.admin-sales-table tbody td {
  padding: 15px 13px;
  border-bottom: 1px solid #edf2f7;
  color: #334155;
  font-size: 13px;
  vertical-align: middle;
}

.admin-sales-table tbody tr {
  transition: 0.18s ease;
}

.admin-sales-table tbody tr:nth-child(even) {
  background: #fbfdff;
}

.admin-sales-table tbody tr:hover {
  background: #eff6ff;
}

.admin-sale-time {
  min-width: 135px;
  display: flex;
  align-items: flex-start;
  gap: 7px;
  color: #64748b;
  line-height: 1.35;
}

.admin-sale-time i {
  margin-top: 2px;
  color: #2563eb;
}

.admin-sale-receipt {
  color: #1d4ed8;
  font-family: "Segoe UI", sans-serif;
}

.admin-sale-product {
  min-width: 190px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.admin-sale-product-icon {
  width: 39px;
  height: 39px;
  flex-shrink: 0;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: #dbeafe;
}

.admin-sale-product strong {
  display: block;
  color: #0f172a;
  margin-bottom: 4px;
}

.admin-sale-product span {
  color: #94a3b8;
  font-size: 11px;
}

.admin-sale-quantity {
  min-width: 32px;
  min-height: 32px;
  padding: 0 9px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #1e40af;
  background: #dbeafe;
  font-weight: 950;
}

.admin-sale-profit,
.admin-payment-badge,
.admin-sale-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 950;
  white-space: nowrap;
}

.admin-sale-profit.positive {
  color: #15803d;
  background: #dcfce7;
}

.admin-sale-profit.negative {
  color: #b91c1c;
  background: #fee2e2;
}

.admin-sale-profit.neutral {
  color: #475569;
  background: #e2e8f0;
}

.admin-sale-cashier {
  min-width: 125px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-sale-cashier i {
  color: #7c3aed;
}

.admin-payment-badge.cash {
  color: #15803d;
  background: #dcfce7;
}

.admin-payment-badge.mobile {
  color: #047857;
  background: #d1fae5;
}

.admin-payment-badge.card {
  color: #1d4ed8;
  background: #dbeafe;
}

.admin-payment-badge.split {
  color: #7c2d12;
  background: #ffedd5;
}

.admin-sale-status.completed {
  color: #15803d;
  background: #dcfce7;
}

.admin-sale-status.returned {
  color: #b45309;
  background: #fef3c7;
}

.admin-sale-status.deleted {
  color: #b91c1c;
  background: #fee2e2;
}

.admin-sales-empty {
  min-height: 190px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #64748b;
  text-align: center;
}

.admin-sales-empty i {
  font-size: 30px;
  color: #94a3b8;
}

.admin-sales-empty strong {
  color: #0f172a;
  font-size: 15px;
}

.admin-sales-empty span {
  font-size: 13px;
}

.admin-sales-footer {
  margin: 20px 22px 22px;
  padding: 13px 15px;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: #64748b;
  background: #f8fafc;
  font-size: 12px;
  font-weight: 800;
}

.admin-sales-footer i {
  color: #2563eb;
}

/* =========================================================
   WINDOWS HELLO / BIOMETRIC LOGIN
========================================================= */

.security-biometric-login-btn {
  width: 100%;
  min-height: 50px;
  margin-top: 11px;
  border: 1px solid #cbd5e1;
  border-radius: 16px;
  color: #0f172a;
  background: linear-gradient(145deg, #ffffff, #f1f5f9);
  display: none;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 950;
  cursor: pointer;
}

.security-biometric-login-btn i {
  color: #2563eb;
  font-size: 20px;
}

.security-biometric-login-btn:hover {
  border-color: #2563eb;
  background: #eff6ff;
}

.admin-biometric-settings-panel {
  grid-column: 1 / -1;
}

.admin-biometric-header {
  display: flex;
  align-items: center;
  gap: 17px;
  padding: 19px;
  border-radius: 20px;
  color: #ffffff;
  background:
    radial-gradient(circle at top right, rgba(96, 165, 250, 0.35), transparent 34%),
    linear-gradient(135deg, #0f172a, #1e40af);
}

.admin-biometric-icon {
  width: 62px;
  height: 62px;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 20px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.14);
  font-size: 27px;
}

.admin-biometric-header span {
  color: #bfdbfe;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.admin-biometric-header h3 {
  margin: 4px 0 6px;
  font-size: 22px;
}

.admin-biometric-header p {
  max-width: 750px;
  margin: 0;
  color: #dbeafe;
  font-size: 13px;
  line-height: 1.5;
}

.admin-biometric-status {
  margin-top: 17px;
  padding: 15px;
  border: 1px solid #dbe3ef;
  border-radius: 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #f8fafc;
}

.admin-biometric-status > i {
  margin-top: 2px;
  font-size: 20px;
}

.admin-biometric-status div {
  display: grid;
  gap: 4px;
}

.admin-biometric-status strong {
  color: #0f172a;
  font-size: 14px;
}

.admin-biometric-status span {
  color: #64748b;
  font-size: 13px;
  line-height: 1.45;
}

.admin-biometric-status.available {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.admin-biometric-status.available > i {
  color: #2563eb;
}

.admin-biometric-status.registered {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.admin-biometric-status.registered > i {
  color: #16a34a;
}

.admin-biometric-status.unavailable {
  border-color: #fde68a;
  background: #fffbeb;
}

.admin-biometric-status.unavailable > i {
  color: #d97706;
}

.admin-biometric-information {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.admin-biometric-information div {
  min-height: 90px;
  padding: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 15px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: #475569;
  background: #f8fafc;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.admin-biometric-information i {
  margin-top: 2px;
  color: #2563eb;
  font-size: 17px;
}

.admin-biometric-actions {
  display: flex;
  gap: 11px;
  flex-wrap: wrap;
  margin-top: 17px;
}

.admin-biometric-actions button {
  min-height: 45px;
}

@media (max-width: 1100px) {
  .admin-sales-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-biometric-information {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 750px) {
  .smartpos-welcome-overlay {
    padding: 13px;
  }

  .smartpos-welcome-card {
    padding: 38px 20px 27px;
    border-radius: 23px;
  }

  .admin-sales-header,
  .admin-sales-heading,
  .admin-sales-toolbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-sales-refresh-btn,
  .admin-sales-search {
    width: 100%;
  }

  .admin-sales-summary-grid {
    grid-template-columns: 1fr;
  }

  .admin-sales-live-indicator {
    align-self: flex-start;
  }

  .admin-biometric-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-biometric-actions {
    flex-direction: column;
  }

  .admin-biometric-actions button {
    width: 100%;
  }
}

/* =========================================================
   DATABASE-BACKED EMPLOYEE PIN RECOVERY
========================================================= */

.pin-reset-panel {
  display: none;
  margin-top: 18px;
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: #f8fafc;
}

.pin-reset-panel.active {
  display: block;
}

.pin-reset-panel .form-group {
  margin-bottom: 15px;
}

.pin-reset-panel .form-group label {
  display: block;
  margin-bottom: 7px;
  color: var(--text);
  font-size: 14px;
  font-weight: 900;
}

.pin-reset-panel .form-group input,
.pin-reset-panel .form-group select {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--border);
  border-radius: 15px;
  padding: 0 15px;
  outline: none;
  background: #ffffff;
  color: var(--text);
  font-size: 15px;
}

.pin-reset-panel .form-group input:focus,
.pin-reset-panel .form-group select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.pin-reset-panel .form-group small {
  display: block;
  min-height: 18px;
  margin-top: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.pin-recovery-action-btn {
  width: 100%;
  margin-top: 4px;
}

.pin-recovery-separator {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0 17px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.pin-recovery-separator::before,
.pin-recovery-separator::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--border);
}

.admin-pin-reset-btn {
  width: 100%;
  min-height: 50px;
  border: none;
  border-radius: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, #0f172a, #334155);
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
}

.admin-pin-reset-btn i {
  margin-right: 8px;
}

.admin-pin-reset-btn:hover {
  background: linear-gradient(135deg, #020617, #1e293b);
}

.pin-recovery-message {
  display: none;
  margin-top: 16px;
  padding: 13px 15px;
  border: 1px solid var(--border);
  border-radius: 14px;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.5;
}

.pin-recovery-message:not(:empty) {
  display: block;
}

.pin-recovery-message.info {
  color: #1d4ed8;
  border-color: #bfdbfe;
  background: #eff6ff;
}

.pin-recovery-message.success {
  color: #15803d;
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.pin-recovery-message.error {
  color: #b91c1c;
  border-color: #fecaca;
  background: #fef2f2;
}

.pin-reset-panel button:disabled {
  opacity: 0.58;
  cursor: not-allowed;
}

/* ADMIN LOGIN WINDOWS HELLO BUTTON */

.security-biometric-login-btn {
  width: 100%;
  min-height: 50px;
  margin-top: 11px;
  border: 1px solid #cbd5e1;
  border-radius: 16px;
  color: #0f172a;
  background: linear-gradient(145deg, #ffffff, #f1f5f9);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 900;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    transform 0.2s ease;
}

.security-biometric-login-btn i {
  color: #2563eb;
  font-size: 20px;
}

.security-biometric-login-btn:hover {
  border-color: #2563eb;
  background: #eff6ff;
  transform: translateY(-1px);
}

@media (max-width: 600px) {
  .pin-reset-panel {
    padding: 16px;
    border-radius: 17px;
  }
}

/* TEMPORARY LOGIN RECOVERY */
#employeePinResetPanel {
  display: none;
}

#employeePinResetPanel.active {
  display: block;
}

/* =========================================================
   COMPACT STOCK COUNT BY OUTLET
========================================================= */

.smartpos-compact-stock-panel {
  padding: 15px 16px !important;
  border-radius: 18px !important;
}

.smartpos-compact-stock-panel h2,
.smartpos-compact-stock-panel h3,
.smartpos-compact-stock-panel h4 {
  margin-top: 0 !important;
  margin-bottom: 3px !important;
  font-size: 18px !important;
  line-height: 1.25 !important;
}

.smartpos-current-outlet-note {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  margin: 3px 0 11px;
  padding: 5px 10px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 800;
}

.smartpos-current-outlet-note i {
  font-size: 10px;
}

.smartpos-compact-stock-scroll {
  width: 100%;
  max-height: 310px;
  overflow: auto;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  background: #ffffff;
  scrollbar-width: thin;
  scrollbar-color: #94a3b8 #f1f5f9;
}

.smartpos-compact-stock-scroll::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.smartpos-compact-stock-scroll::-webkit-scrollbar-track {
  background: #f1f5f9;
}

.smartpos-compact-stock-scroll::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: #94a3b8;
}

.smartpos-compact-stock-table {
  width: 100%;
  min-width: 560px;
  margin: 0 !important;
  border-spacing: 0;
  border-collapse: separate;
  font-size: 12px;
}

.smartpos-compact-stock-table th {
  position: sticky;
  top: 0;
  z-index: 5;
  padding: 9px 10px !important;
  border-bottom: 1px solid #cbd5e1;
  background: #f8fafc;
  color: #334155;
  font-size: 11px !important;
  font-weight: 800;
  letter-spacing: 0.25px;
  white-space: nowrap;
}

.smartpos-compact-stock-table td {
  height: 42px;
  padding: 7px 10px !important;
  border-bottom: 1px solid #eef2f7;
  background: #ffffff;
  color: #334155;
  white-space: nowrap;
}

.smartpos-compact-stock-table tbody tr:hover td {
  background: #f8fafc;
}

.smartpos-compact-stock-table th:first-child,
.smartpos-compact-stock-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 4;
  min-width: 190px;
  max-width: 240px;
  background: #ffffff;
  box-shadow: 5px 0 8px -8px rgba(15, 23, 42, 0.35);
}

.smartpos-compact-stock-table th:first-child {
  z-index: 8;
  background: #f8fafc;
}

.smartpos-compact-stock-table th:last-child,
.smartpos-compact-stock-table td:last-child {
  position: sticky;
  right: 0;
  z-index: 4;
  background: #f8fafc;
  box-shadow: -5px 0 8px -8px rgba(15, 23, 42, 0.35);
}

.smartpos-compact-stock-table th:last-child {
  z-index: 8;
}

.smartpos-product-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.smartpos-product-cell strong {
  max-width: 210px;
  overflow: hidden;
  color: #0f172a;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.smartpos-product-cell small {
  color: #64748b;
  font-size: 10px;
}

.smartpos-outlet-heading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.smartpos-current-outlet-badge {
  display: inline-flex;
  padding: 2px 6px;
  border-radius: 999px;
  background: #2563eb;
  color: #ffffff;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.smartpos-current-outlet-column {
  background: #eff6ff !important;
}

.smartpos-compact-stock-table tbody tr:hover .smartpos-current-outlet-column {
  background: #dbeafe !important;
}

.smartpos-stock-number {
  display: inline-flex;
  min-width: 38px;
  height: 27px;
  align-items: center;
  justify-content: center;
  padding: 3px 8px;
  border-radius: 8px;
  background: #ecfdf5;
  color: #047857;
  font-size: 11px;
  font-weight: 900;
}

.smartpos-stock-number.low {
  background: #fff7ed;
  color: #c2410c;
}

.smartpos-stock-number.zero {
  background: #fef2f2;
  color: #dc2626;
}

.smartpos-total-stock-number {
  display: inline-flex;
  min-width: 42px;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 8px;
  background: #e0e7ff;
  color: #3730a3;
  font-size: 11px;
  font-weight: 900;
}

/* =========================================================
   COMPACT MY SHIFT OPENING
========================================================= */

.smartpos-compact-shift-panel {
  width: 100% !important;
  max-width: 700px !important;
  margin-top: 12px !important;
  margin-bottom: 12px !important;
  padding: 14px 16px !important;
  border-radius: 17px !important;
}

.smartpos-compact-shift-panel h2,
.smartpos-compact-shift-panel h3,
.smartpos-compact-shift-panel h4 {
  margin: 0 0 4px !important;
  font-size: 17px !important;
  line-height: 1.25 !important;
}

.smartpos-compact-shift-panel p {
  margin-top: 3px !important;
  margin-bottom: 8px !important;
  font-size: 12px !important;
  line-height: 1.45 !important;
}

.smartpos-compact-shift-panel .form-grid,
.smartpos-compact-shift-panel .settings-grid,
.smartpos-compact-shift-panel .employee-shift-grid,
.smartpos-compact-shift-panel .input-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 10px !important;
}

.smartpos-compact-shift-panel .form-group {
  margin-bottom: 9px !important;
}

.smartpos-compact-shift-panel label {
  margin-bottom: 5px !important;
  font-size: 11px !important;
  font-weight: 800 !important;
}

.smartpos-compact-shift-panel #employeeOpeningCash,
.smartpos-compact-shift-panel #employeeOpeningMpesa {
  width: 100% !important;
  min-height: 40px !important;
  padding: 8px 11px !important;
  border-radius: 10px !important;
  font-size: 13px !important;
}

.smartpos-compact-shift-panel #employeeShiftStatus {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  margin: 7px 0 9px !important;
  padding: 7px 10px !important;
  border-radius: 10px !important;
  background: #f8fafc;
  font-size: 11px !important;
}

.smartpos-compact-shift-panel #employeeShiftStatus .report-badge {
  padding: 3px 7px !important;
  font-size: 9px !important;
}

.smartpos-compact-shift-panel #saveEmployeeShiftBtn,
.smartpos-compact-shift-panel #employeeDailyReportBtn {
  min-height: 39px !important;
  padding: 8px 13px !important;
  border-radius: 10px !important;
  font-size: 11px !important;
}

.smartpos-compact-shift-panel .form-actions {
  gap: 8px !important;
  margin-top: 8px !important;
}

@media (max-width: 700px) {
  .smartpos-compact-stock-scroll {
    max-height: 270px;
  }

  .smartpos-compact-stock-table th:first-child,
  .smartpos-compact-stock-table td:first-child {
    min-width: 155px;
    max-width: 175px;
  }

  .smartpos-product-cell strong {
    max-width: 145px;
  }

  .smartpos-compact-shift-panel {
    max-width: none !important;
    padding: 12px !important;
  }

  .smartpos-compact-shift-panel .form-grid,
  .smartpos-compact-shift-panel .settings-grid,
  .smartpos-compact-shift-panel .employee-shift-grid,
  .smartpos-compact-shift-panel .input-grid {
    grid-template-columns: 1fr !important;
  }
}

.employee-product-card {
  background: #111;

  border: 1px solid #c9a227;

  border-radius: 18px;

  padding: 12px;

  display: flex;

  align-items: center;

  gap: 15px;

  margin-bottom: 12px;

  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
}

.employee-product-image {
  width: 70px;

  height: 70px;

  object-fit: cover;

  border-radius: 12px;
}

.employee-product-image-placeholder {
  width: 70px;

  height: 70px;

  background: #222;

  border-radius: 12px;

  display: flex;

  align-items: center;

  justify-content: center;

  color: #c9a227;

  font-size: 25px;
}

.employee-product-info h4 {
  color: #ffffff;

  margin: 0;

  font-size: 16px;
}

.employee-product-info p {
  color: #aaa;

  margin: 5px 0;
}

.employee-product-info strong {
  color: #d4af37;

  font-size: 18px;
}

.employee-product-empty {
  padding: 30px;

  text-align: center;

  color: #999;
}

/* =====================================
   EMPLOYEE DASHBOARD PRODUCT CARDS
===================================== */

.employee-products-grid {
  display: grid;

  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));

  gap: 16px;

  padding: 15px;
}

.employee-product-card {
  background: linear-gradient(145deg, #111111, #1c1c1c);

  border: 1px solid #d4af37;

  border-radius: 16px;

  overflow: hidden;

  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);

  transition: 0.25s ease;
}

.employee-product-card:hover {
  transform: translateY(-4px);

  box-shadow: 0 12px 30px rgba(212, 175, 55, 0.25);
}

.employee-product-image {
  width: 100%;

  height: 120px;

  object-fit: cover;

  display: block;
}

.employee-product-placeholder {
  width: 100%;

  height: 120px;

  display: flex;

  justify-content: center;

  align-items: center;

  background: #222;

  color: #d4af37;

  font-size: 35px;
}

.employee-product-details {
  padding: 14px;

  color: white;
}

.employee-product-details h3 {
  margin: 0;

  font-size: 16px;

  color: #ffffff;
}

.employee-product-details p {
  margin: 7px 0;

  color: #aaaaaa;

  font-size: 13px;
}

.employee-product-details strong {
  color: #d4af37;

  font-size: 18px;
}

.employee-empty-products {
  padding: 40px;

  text-align: center;

  color: #999;

  font-size: 18px;
}

/* Employee Dashboard Compact Product Cards */

.employee-products-grid {
  display: grid;

  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));

  gap: 14px;
}

.employee-product-card {
  min-height: 220px;
}

.employee-product-image,
.employee-product-placeholder {
  height: 100px;
}

.employee-product-details h3 {
  font-size: 14px;
}

.employee-product-details strong {
  font-size: 16px;
}

/* =====================================
   EMPLOYEE PRODUCT CARD POS VIEW
===================================== */

.employee-search-area {
  margin-bottom: 20px;
}

#employeeProductSearch {
  width: 100%;
  padding: 16px 20px;

  border-radius: 16px;

  border: 1px solid var(--border);

  font-size: 16px;

  outline: none;

  background: white;
}

.employee-product-grid {
  display: grid;

  grid-template-columns: repeat(4, 1fr);

  gap: 18px;
}

.employee-product-card {
  background: white;

  border-radius: 20px;

  overflow: hidden;

  border: 1px solid var(--border);

  transition: 0.3s ease;

  animation: employeeCardIn 0.4s ease;
}

.employee-product-card:hover {
  transform: translateY(-6px);

  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.12);
}

.employee-product-image {
  width: 100%;

  height: 180px;

  object-fit: cover;

  background: #f3f4f6;
}

.employee-product-body {
  padding: 15px;
}

.employee-product-body h3 {
  font-size: 17px;

  margin-bottom: 8px;
}

.employee-product-price {
  font-size: 20px;

  font-weight: 800;

  color: var(--primary);

  margin-bottom: 12px;
}

.employee-add-cart-btn {
  width: 100%;

  padding: 12px;

  border: none;

  border-radius: 12px;

  background: var(--primary);

  color: white;

  font-weight: 700;

  cursor: pointer;
}

.employee-add-cart-btn:hover {
  opacity: 0.85;
}

@keyframes employeeCardIn {
  from {
    opacity: 0;

    transform: translateY(20px);
  }

  to {
    opacity: 1;

    transform: none;
  }
}

@media (max-width: 1200px) {
  .employee-product-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 800px) {
  .employee-product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* EMPLOYEE PRODUCT CARDS FINAL */

.employee-product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 20px;
}

.employee-product-card {
  background: white;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--border);
  transition: 0.3s ease;
  animation: employeeCardAppear 0.35s ease;
}

.employee-product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.employee-product-image {
  width: 100%;
  height: 190px;
  object-fit: cover;
  background: #f3f4f6;
}

.employee-product-body {
  padding: 16px;
}

.employee-product-body h3 {
  font-size: 17px;
  margin-bottom: 10px;
}

.employee-product-price {
  font-size: 20px;
  font-weight: 800;
  color: #2563eb;
  margin-bottom: 15px;
}

.employee-add-cart-btn {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 12px;
  background: #2563eb;
  color: white;
  font-weight: 700;
  cursor: pointer;
}

.employee-add-cart-btn:hover {
  opacity: 0.85;
}

@keyframes employeeCardAppear {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 1200px) {
  .employee-product-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 800px) {
  .employee-product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.employee-product-card {
  animation: employeeCardAppear 0.35s ease forwards;
}

.employee-product-card:hover {
  transform: translateY(-8px);
}

.employee-image-wrapper {
  height: 220px;

  overflow: hidden;
}

.employee-product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.employee-category {
  font-size: 13px;
  color: #777;
}

@keyframes employeeCardAppear {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}


/* =========================================================
   SMARTPOS v1.0.19 DASHBOARD POLISH
   Best-selling table integrity + one-screen employee summary
========================================================= */

#adminBestSellingProducts.ranking-list {
  display: block;
  width: 100%;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  background: #ffffff;
}

#adminBestSellingProducts .ranking-table-head {
  display: grid;
  grid-template-columns: 52px minmax(180px, 1fr) 110px 150px;
  gap: 12px;
  padding: 10px 16px;
  border: 0;
  background: #f8fafc;
  color: #64748b;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

#adminBestSellingProducts .ranking-table-head span {
  display: block;
  width: auto;
  height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  font: inherit;
}

#adminBestSellingProducts.ranking-list > .ranking-item {
  display: grid !important;
  grid-template-columns: 52px minmax(180px, 1fr) 110px 150px !important;
  align-items: center !important;
  gap: 12px !important;
  min-height: 68px;
  padding: 10px 16px !important;
  border: 0 !important;
  border-top: 1px solid #eef2f7 !important;
  background: #ffffff;
}

#adminBestSellingProducts.ranking-list > .ranking-item:hover {
  background: #f8fbff;
}

#adminBestSellingProducts .ranking-item > div,
#adminBestSellingProducts .ranking-info {
  display: flex !important;
  min-width: 0;
  flex-direction: column !important;
  align-items: flex-start !important;
  gap: 3px !important;
  padding: 0 !important;
  border: 0 !important;
}

#adminBestSellingProducts .ranking-info strong {
  display: block;
  width: 100%;
  overflow: visible;
  color: #0f172a;
  font-size: 14px;
  line-height: 1.3;
  text-overflow: clip;
  white-space: normal;
  word-break: break-word;
}

#adminBestSellingProducts .ranking-info small {
  color: #64748b;
  font-size: 11px;
}

#adminBestSellingProducts .rank-number {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: #dbeafe;
  color: #1d4ed8;
  font-size: 13px;
}

#adminBestSellingProducts .ranking-units,
#adminBestSellingProducts .ranking-value {
  display: flex !important;
  width: auto !important;
  height: auto !important;
  min-width: 0;
  flex-direction: column;
  align-items: flex-start;
  padding: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #0f172a !important;
  line-height: 1.25;
}

#adminBestSellingProducts .ranking-units strong,
#adminBestSellingProducts .ranking-value strong {
  font-size: 14px;
  font-weight: 900;
  white-space: nowrap;
}

#adminBestSellingProducts .ranking-units small,
#adminBestSellingProducts .ranking-value small {
  color: #64748b;
  font-size: 10px;
  white-space: nowrap;
}

#employeeDashboard {
  --employee-compact-gap: 12px;
}

#employeeDashboard .employee-shift-card-modern {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.9fr);
  gap: 12px 18px;
  width: 100%;
  max-width: none;
  margin-bottom: var(--employee-compact-gap);
  padding: 16px 18px;
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
}

#employeeDashboard .employee-shift-header {
  grid-column: 1 / -1;
}

#employeeDashboard .employee-shift-header h3 {
  margin: 0 0 2px;
  font-size: 20px;
}

#employeeDashboard .employee-shift-header p {
  font-size: 12px;
}

#employeeDashboard .employee-shift-grid-modern {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 2px;
}

#employeeDashboard .shift-money-group {
  margin: 0;
}

#employeeDashboard .shift-money-group label {
  margin-bottom: 5px;
  font-size: 11px;
}

#employeeDashboard .shift-money-field {
  width: 100%;
  max-width: none;
  height: 40px;
  border-radius: 11px;
  box-shadow: none;
}

#employeeDashboard .shift-money-field span {
  padding: 0 11px;
  font-size: 11px;
}

#employeeDashboard .shift-money-input {
  padding: 0 11px;
  font-size: 14px;
}

#employeeDashboard .employee-shift-actions {
  align-self: end;
  gap: 8px;
  margin: 0;
}

#employeeDashboard .employee-shift-actions .primary-btn,
#employeeDashboard .employee-shift-actions .secondary-btn {
  min-height: 40px;
  padding: 0 14px;
  border-radius: 11px;
  font-size: 11px;
}

#employeeDashboard .employee-shift-status-modern {
  grid-column: 1 / -1;
  min-height: 38px;
  margin: 0;
  padding: 9px 12px;
  border-radius: 11px;
  font-size: 11px;
}

#employeeDashboard .employee-grid {
  gap: var(--employee-compact-gap);
  margin-bottom: var(--employee-compact-gap);
}

#employeeDashboard .employee-grid .stat-card {
  min-height: 112px;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 18px;
}

#employeeDashboard .employee-grid .stat-icon {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  font-size: 19px;
}

#employeeDashboard .employee-grid .stat-card p {
  font-size: 11px;
}

#employeeDashboard .employee-grid .stat-card h3 {
  margin: 3px 0;
  font-size: 19px;
}

#employeeDashboard .employee-grid .stat-card span {
  font-size: 10px;
}

#employeeDashboard > .panel {
  padding: 15px 18px;
  border-radius: 18px;
}

#employeeDashboard > .panel .panel-header {
  margin-bottom: 10px;
}

#employeeDashboard > .panel .panel-header h3 {
  font-size: 16px;
}

#employeeDashboard > .panel .panel-header p {
  font-size: 11px;
}

#employeeDashboard > .panel .summary-box {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

#employeeDashboard > .panel .summary-box div {
  min-width: 0;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 11px;
}

#employeeDashboard > .panel .summary-box span {
  font-size: 10px;
}

#employeeDashboard > .panel .summary-box strong {
  font-size: 13px;
}

#employeeDashboard > .panel .full-btn {
  min-height: 38px;
  margin-top: 10px;
  padding: 8px 12px;
  border-radius: 11px;
  font-size: 11px;
}

@media (max-width: 900px) {
  #adminBestSellingProducts.ranking-list {
    overflow-x: auto;
  }

  #adminBestSellingProducts .ranking-table-head,
  #adminBestSellingProducts.ranking-list > .ranking-item {
    min-width: 620px;
  }

  #employeeDashboard .employee-shift-card-modern {
    grid-template-columns: 1fr;
  }

  #employeeDashboard .employee-shift-header,
  #employeeDashboard .employee-shift-status-modern {
    grid-column: 1;
  }
}

@media (max-width: 650px) {
  #employeeDashboard .employee-shift-grid-modern,
  #employeeDashboard > .panel .summary-box {
    grid-template-columns: 1fr 1fr;
  }

  #employeeDashboard .employee-shift-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  #employeeDashboard .employee-shift-actions button {
    width: 100%;
  }
}
