* {
  box-sizing: border-box;
}

:root {
  /* Backgrounds */
  --bg-primary: #f8f9fa;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-input: #ffffff;
  --bg-input-disabled: #e4e4e6;

  /* Borders */
  --border: #c5c9d1;
  --border-subtle: #d8dbe0;
  --border-input: #b8bcc4;

  /* Text Colors */
  --text-primary: #111827;
  --text-secondary: #4b5563;
  --text-muted: #6b7280;

  /* Accent Colors */
  --accent-blue: #0080c2;
  --accent-blue-light: rgba(0, 128, 194, 0.1);
  --accent-green: #059669;
  --accent-green-light: rgba(5, 150, 105, 0.12);
  --accent-amber: #b45309;
  --accent-amber-light: rgba(180, 83, 9, 0.1);
  --accent-red: #dc2626;
  --accent-red-light: rgba(220, 38, 38, 0.1);
  --accent-purple: #7c3aed;

  /* Layout */
  --page-width: 1280px;
  --base-border-radius: 8px;
  --base-line-height: 1.5;

  /* Font Sizes */
  --font-14: 14px;
  --font-13: 13px;
  --font-12: 12px;
  --font-11: 11px;
}

/* Colors */

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  /* Prevent horizontal overflow */
}

*,
*::before,
*::after {
  box-sizing: border-box;
  /* Include padding and border in the element's total width and height */
}

.container-fluid {
  max-height: 100vh;
  /* 100% of the viewport height */
}

@media (max-width:1440px) {
  .container-fluid {
    max-width: 1380px;
  }
}

body {
  font-family: 'DM Sans', -apple-system, sans-serif;
  font-size: var(--font-14);
  color: var(--text-primary);
  margin: 0;
  padding: 0;
  line-height: var(--base-line-height);
}

/* Monospace utility for numeric data */
.mono {
  font-family: 'JetBrains Mono', monospace;
}


h1,
h2,
h3,
h4,
h5 {
  color: var(--text-primary);
}

h1 {
  font-size: 30px;
  line-height: 38px;
  font-weight: 600;
}

h2 {
  font-size: 20px;
  margin-bottom: 6px;
}

p {
  line-height: var(--base-line-height);
  margin-top: 4px;
  margin-bottom: 4px;
}

.text-muted {
  color: var(--text-muted);
}

.font-14 {
  font-size: 14px;
}

.font-13 {
  font-size: 13px;
}

.font-12 {
  font-size: 12px;
}

.font-11 {
  font-size: 11px;
}

.font-10 {
  font-size: 10px;
}

a {
  display: inline-block;
  color: inherit;
}

.button>a,
.nav-items>a {
  text-decoration: none;
}

a[type="button"] {
  text-decoration: none;
}

a[type=button] {
  text-align: center;
}

a:hover {
  cursor: pointer;
}

.page-width {
  max-width: var(--page-width);
}

/* NAVBAR  */


.header-nav {
  border-bottom: 1px solid #ededed;
}

.navigation {
  display: flex;
  align-items: center;
  padding: 10px 0px;
}

.mobile-menu {
  display: none;
}

/* ========================================
   Navigation Styles
   ======================================== */

/* Navigation Container */
.nav-container {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.nav-inner {
  max-width: 1800px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

/* Logo */
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 18px;
  flex-shrink: 0;
}

.nav-logo:hover {
  color: var(--text-primary);
  text-decoration: none;
}

.nav-logo-icon {
  width: 32px;
  height: 32px;
  background: var(--accent-blue);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.nav-logo-icon svg {
  width: 18px;
  height: 18px;
}

/* Main Navigation */
.nav-main {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: 32px;
}

.nav-item {
  position: relative;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
  background: transparent;
  font-family: inherit;
}

.nav-link:hover {
  color: var(--text-primary);
  background: var(--bg-primary);
  text-decoration: none;
}

.nav-link.active {
  color: var(--accent-blue);
  background: var(--accent-blue-light);
}

.nav-link svg {
  width: 16px;
  height: 16px;
  transition: transform 0.2s;
}

.nav-item.open .nav-link svg {
  transform: rotate(180deg);
}

/* Dropdown */
.nav-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 240px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.2s ease;
  z-index: 100;
  padding: 8px;
}

.nav-item.open .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-section {
  padding: 4px 0;
}

.dropdown-section:not(:last-child) {
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 4px;
  padding-bottom: 8px;
}

.dropdown-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  padding: 8px 12px 4px;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.15s;
}

.dropdown-item:hover {
  color: var(--text-primary);
  background: var(--bg-primary);
  text-decoration: none;
}

.dropdown-item.highlighted {
  color: var(--accent-blue);
}

.dropdown-item.highlighted:hover {
  background: var(--accent-blue-light);
}

.dropdown-item svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.dropdown-item:hover svg {
  color: var(--text-secondary);
}

.dropdown-item.highlighted svg {
  color: var(--accent-blue);
}

.dropdown-item-text {
  flex: 1;
}

.dropdown-item-desc {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 400;
}

.dropdown-kbd {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  padding: 2px 6px;
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-muted);
}

/* Right side nav */
.nav-right {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav-icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
}

.nav-icon-btn:hover {
  color: var(--text-primary);
  background: var(--bg-primary);
}

.nav-icon-btn svg {
  width: 20px;
  height: 20px;
}

.nav-icon-btn .badge {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  background: var(--accent-blue);
  border-radius: 50%;
  border: 2px solid var(--bg-secondary);
}

.nav-divider {
  width: 1px;
  height: 24px;
  background: var(--border-subtle);
  margin: 0 8px;
}

.nav-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 6px 6px;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

.nav-user:hover {
  background: var(--bg-primary);
  text-decoration: none;
}

.nav-avatar {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--accent-blue), #00a3cc);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  font-size: 13px;
}

.nav-user-info {
  text-align: left;
}

.nav-user-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.2;
}

.nav-user-role {
  font-size: 11px;
  color: var(--text-muted);
}

.nav-user svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  margin-left: 4px;
}

/* Mobile Menu Button */
.nav-mobile-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.nav-mobile-toggle:hover {
  color: var(--text-primary);
  background: var(--bg-primary);
}

.nav-mobile-toggle svg {
  width: 24px;
  height: 24px;
}

/* Mobile Styles */
@media (max-width: 1024px) {
  .nav-main {
    display: none;
  }

  .nav-right .nav-link {
    display: none;
  }

  .nav-mobile-toggle {
    display: flex;
  }

  .nav-user-info {
    display: none;
  }

  .nav-user {
    padding: 6px;
  }
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  z-index: 1001;
}

.mobile-menu-overlay.open {
  opacity: 1;
  visibility: visible;
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 300px;
  max-width: 85vw;
  height: 100vh;
  background: var(--bg-secondary);
  transform: translateX(-100%);
  transition: transform 0.3s ease;
  z-index: 1002;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.mobile-menu.open {
  transform: translateX(0);
}

.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-menu-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: var(--text-secondary);
  background: var(--bg-primary);
  border: none;
  border-radius: 8px;
  cursor: pointer;
}

.mobile-menu-close svg {
  width: 20px;
  height: 20px;
}

.mobile-menu-body {
  flex: 1;
  padding: 12px;
  overflow-y: auto;
}

.mobile-nav-item {
  margin-bottom: 4px;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 10px;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
  background: transparent;
  width: 100%;
  font-family: inherit;
}

.mobile-nav-link:hover {
  color: var(--text-primary);
  background: var(--bg-primary);
}

.mobile-nav-link.active {
  color: var(--accent-blue);
  background: var(--accent-blue-light);
}

.mobile-nav-link svg {
  width: 18px;
  height: 18px;
  transition: transform 0.2s;
}

.mobile-nav-item.open .mobile-nav-link svg {
  transform: rotate(180deg);
}

.mobile-submenu {
  display: none;
  padding: 4px 0 4px 16px;
}

.mobile-nav-item.open .mobile-submenu {
  display: block;
}

.mobile-submenu-item {
  display: block;
  padding: 10px 14px;
  font-size: 14px;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 8px;
  transition: all 0.15s;
}

.mobile-submenu-item:hover {
  color: var(--text-primary);
  background: var(--bg-primary);
}

.mobile-menu-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border-subtle);
}

.mobile-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

.mobile-user-info {
  flex: 1;
}

.mobile-user-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.mobile-user-role {
  font-size: 12px;
  color: var(--text-muted);
}

/* Legacy navbar support - remove container-fluid padding when inside nav */
.nav-container + .container-fluid {
  padding-top: 0;
}


/* Containers, rows and columns */

@media (min-width: 1650px) {
  .container-xxl {
    max-width: 1570px;
  }
}

@media (min-width: 1500px) {
  .container-xxl {
    max-width: 1420px;
  }
}

.header-row {
  padding-top: 30px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--border-subtle);
}

.filter-bar,
.header-row {
  padding-top: 20px;
  padding-bottom: 20px;
}


td>.form-control,
.grouped-cell-inputs>.form-control {
  /* font-size: 12px; */
  min-height: auto;
}

td>.form-control {
  font-size: var(--small-font);
}



#searchbar {
  background: url('/search.svg') no-repeat 10px center / 16px 16px;
  padding-left: 30px;
  /* Adjust padding to ensure text does not overlay the image */
}


/* Remove spinners */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}



@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.hide-menu {
  opacity: 0;
  visibility: hidden;
  /* transition: opacity 0.4s ease-out, visibility 0.4s ease-out 0.4s; */
}

@keyframes fadeOut {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}

.container {
  max-width: var(--page-width);
  margin: auto;
}

.shimmer {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 4px;
  min-width: 50px;
  display: inline-block;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

.hidden {
  display: none !important;
}

.visible {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s linear;
}


/* Header content */





/* Borders */


/* BUTTONS & LINKS  */

button,
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  border-radius: 6px;
  padding: 8px 14px;
  font-family: 'DM Sans', sans-serif;
  font-size: var(--font-13);
  background: var(--bg-secondary);
  font-weight: 500;
  transition: all 0.2s;
  cursor: pointer;
}

button:hover,
.btn:hover {
  border-color: var(--border);
  background: var(--bg-primary);
}

.primary-btn,
.btn-primary {
  background: var(--accent-blue);
  color: white;
  border: none;
}

.primary-btn:hover,
.btn-primary:hover {
  background: #006da6;
  color: white;
}

.btn-secondary {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--bg-primary);
}

.btn-danger {
  background: var(--accent-red-light);
  color: var(--accent-red);
  border: 1px solid var(--accent-red);
}

.btn-danger:hover {
  background: var(--accent-red);
  color: white;
}

.sky-blue-button {
  background: var(--accent-blue-light);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
}

.sky-blue-button:hover {
  background: var(--accent-blue);
  color: white;
}

/* Action buttons for icon-only buttons in tables */
.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.2s;
  text-decoration: none;
  padding: 0;
}

.action-btn:hover {
  background: var(--bg-secondary);
  border-color: var(--border);
  color: var(--accent-blue);
}

.action-btn i {
  font-size: 14px;
}

.action-btn.danger:hover {
  color: var(--accent-red);
  border-color: var(--accent-red);
}

hr {
  border-top: 1px solid var(--grey);
}

.separator {
  border-top: 1px solid #aaa;
}

.scroll-container {
  overflow: auto;
}

.box-shadow {
  box-shadow: var(--base-box-shadow);
}

/* Login */
.login-box {
  border: var(--base-border);
  box-shadow: var(--base-box-shadow);
  border-radius: var(--base-border-radius);
}


.lowest-price {
  font-size: var(--small-font);
}

/* Tables */
.price-actions>i:hover {
  cursor: pointer;
}

/* Tables */
table {
  text-align: left;
  border-radius: var(--base-border-radius);
  font-size: var(--font-13);
  border-collapse: collapse;
  width: 100%;
  background: var(--bg-secondary);
  border-spacing: 0;
}


#pricing-table {
  max-height: 63vh;
  border: 1px solid var(--border-subtle);
}

#pricing-table tr {
  border: 1px solid var(--border-subtle);
  background: var(--bg-secondary);
}

#pricing-table tr:hover {
  background: rgba(0, 128, 194, 0.02);
}


th,
td {
  border-left: 1px solid var(--border-subtle);
  padding: 10px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  align-content: center;
}

.price-table .sticky-column,
.price-table .sticky-column td {
  min-width: 280px;
  max-width: 100%;
}

.price-table th,
.price-table td {
  white-space: wrap;
  overflow: hidden;
  font-size: 12px;
  max-width: 150px;
}

td>.form-control {
  width: 80px;
}

thead {
  background: var(--bg-primary);
  border-radius: 4px 4px 4px 4px;
}

.no-bottom-border {
  border-bottom: none !important;
  /* !important may be needed to override other styles */
}



@media (min-width: 1200px) {
  .sticky-column {
    position: -webkit-sticky;
    position: sticky;
    left: -1px;
    z-index: 10;
    background: var(--bg-secondary);
  }

  thead th {
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 2;
    top: -2px;
    background: var(--bg-primary) !important;
  }

  thead .sticky-column {
    z-index: 11;
    background: var(--bg-primary) !important;
  }
}

.archive-row,
.archive-row input[readonly] {
  background-color: #e3e3e3;
}



th {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 500;
  color: var(--text-muted);
  font-size: var(--font-11);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

thead th:first-child {
  left: 0;
  z-index: 3;
}

.table-container {
  border-radius: var(--base-border-radius);
  border: 1px solid var(--border-subtle);
  min-width: 100%;
  overflow-x: auto;
  padding-bottom: 2px;
  background: var(--bg-secondary);
}

thead tr {
  border-top: 0px;
  background-color: var(--bg-primary);
}

tr {
  height: 48px;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

thead>tr:first-child:hover {
  background-color: inherit;
  cursor: inherit;
}

tr:last-child {
  border-bottom: 0px;
}

.table-product-image-container {
  height: 36px;
  width: 36px;
  border: 1px solid var(--border-subtle);
  border-radius: 50%;
  padding: 4px;
}

.table-product-image-container>img {
  max-width: 100%;
  max-height: 100%;
  object-fit: cover;
}

td {
  font-size: var(--font-13);
  font-weight: 400;
  color: var(--text-primary);
}


/* Forms */

form {
  margin-bottom: 0;
}


.form-label {
  margin-bottom: 0.5rem;
  font-weight: 500;
  font-size: var(--font-14);
}

input,
select,
option,
span,
label,
.form-select {
  font-size: var(--font-14);
}



.form-control,
.form-select {
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  background: var(--bg-input);
  color: var(--text-primary);
  font-size: var(--font-14);
  padding: 8px 12px;
  box-shadow: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 3px var(--accent-blue-light);
  outline: none;
}

.form-control:disabled,
.form-select:disabled {
  background: var(--bg-input-disabled);
  cursor: not-allowed;
}

.price-input {
  width: 100px;
  font-size: var(--font-13);
  font-family: 'JetBrains Mono', monospace;
  text-align: right;
  padding: 6px 8px;
}

.unstyled {
  border: none !important;
  outline: none;
  padding: 0px;
}


.login-form {
  background: #fff;
  padding: 20px;
  border: var(--base-border);
  border-radius: var(--base-border-radius);
  max-width: 450px;
  margin: auto;
}

@media screen and (max-width:900px) {

  input,
  td>.form-control {
    font-size: 16px;
  }

  .form-control {
    font-size: 16px;
  }

  td {
    font-size: 12px;
  }
}


/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4px;
  margin-top: 20px;
  border: none;
}

.pagination a,
.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: var(--font-13);
  background: var(--bg-secondary);
  transition: all 0.2s;
}

.pagination a:hover,
.page-btn:hover {
  border-color: var(--border);
  background: var(--bg-primary);
  color: var(--text-primary);
}

.pagination a.active,
.page-btn.active {
  background-color: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
}

.pagination a.disabled,
.page-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* Bootstrap pagination override */
.pagination .page-item .page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 10px;
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  text-decoration: none;
  color: var(--text-secondary);
  font-size: var(--font-13);
  background: var(--bg-secondary);
  transition: all 0.2s;
  margin: 0 2px;
}

.pagination .page-item .page-link:hover {
  border-color: var(--border);
  background: var(--bg-primary);
  color: var(--text-primary);
}

.pagination .page-item.active .page-link {
  background-color: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
}


/* Buttons and links */

button {
  white-space: nowrap;
}

.badge {
  padding: 4px 6px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 500;
  color: white;
  background-color: var(--base-color);
}

.badge-blue {
  background-color: var(--skyblue-400);
  color: white;
}

.badge-success {
  background-color: #befbdf;
  color: #024802;
}

.active-dot {
  display: inline-block;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background-color: green;
}

/* Schedule indicator next to price inputs */
.schedule-indicator {
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s;
}

.schedule-indicator:hover {
  transform: scale(1.1);
}

/* Confirm updates */
#confirmUpdatesBtn {
  position: fixed;
  bottom: 0px;
  width: 100%;
  background: red;
  border-radius: 0px;
  height: 100px;
  color: white;
  margin: auto;
  left: 0;
  z-index: 100;
  /* border-radius: 30px; */
  /* left: 50%; */
  /* transform: translateX(-50%); */
}

#showStagedChanges {
  padding: 10px;
  display: flex;
  gap: 2;
}

/* Overlays and modals */
.modal-content {
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  overflow: hidden;
}

.modal-header {
  padding: 20px 24px;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-subtle);
  border-radius: 12px 12px 0 0;
}

.modal-header .modal-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

.modal-header .btn-close {
  opacity: 0.6;
}

.modal-header .btn-close:hover {
  opacity: 1;
}

.modal-body {
  padding: 24px;
  background: var(--bg-secondary);
}

.modal-footer {
  padding: 16px 24px;
  background: var(--bg-primary);
  border-top: 1px solid var(--border-subtle);
  border-radius: 0 0 12px 12px;
}

/* Alerts */
.alert {
  padding: 16px;
  border-radius: var(--base-border-radius);
  border: var(--base-border);
  box-shadow: var(--base-box-shadow);
  background-color: #fff;
  color: var(--base-color);
}


/* Filters */
.filter-pill,
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: var(--font-13);
  background-color: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.filter-pill:hover,
.filter-chip:hover {
  border-color: var(--border);
  background-color: var(--bg-secondary);
}

.filter-pill.active,
.filter-chip.active {
  background-color: var(--accent-blue-light);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
}


@media (max-width:996px) {

  .filters>.form-control,
  .form-select {
    width: 100%;
  }
}


/* Images */
.img {
  max-width: 100%;
}

.table-product-image-container {
  height: 36px;
  width: 36px;
  border: 1px solid #ededed;
  border-radius: 50%;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.table-product-image-container>img {
  max-width: 100%;
  max-height: 100%;
  object-fit: cover;
}

/* Flash */
.flash-messages-container {
  padding: 16px;
  border-radius: var(--base-border-radius);
  border: var(--base-border);
  border-color: #e7e7e7;
  box-shadow: var(--base-box-shadow);
  width: 320px;
  max-width: 100%;
  position: absolute;
  right: 16px;
  top: 10%;
  color: #fff;
  background-color: #000;
  z-index: 100;
}

/* Checkboxes */

.product_price_checkbox {
  width: 22px;
  height: 22px;
  border: 1px solid #8f8f8f;
}

/* Readoly inputs */

.disabled-input {
  background-color: var(--bg-input-disabled);
  cursor: not-allowed;
}

/* Performance Chart Styles */
.chart-container {
  position: relative;
  height: 400px;
  width: 100%;
  margin-bottom: 20px;
}

/* Toggle button styles */

/* Filter controls */
.filter-controls {
  margin-bottom: 20px;
}

/* Loading and no data states */
#chartLoading,
#noChartData {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: rgba(255, 255, 255, 0.8);
}

/* Responsiveness adjustments */
@media (max-width: 768px) {
  #performanceChartModal .modal-body {
    padding: 10px;
  }

  .chart-container {
    height: 300px;
  }
}

/* cards */
.card-title {
  font-size: 18px;
}

.table .dropdown {
  position: static;
  /* Override Bootstrap's default relative position */
}

/* ========================================
   Purchase Orders Page Styles
   ======================================== */

.po-view {
  max-width: 1600px;
  margin: 0 auto;
  padding: 24px 32px;
}

/* Page Header */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.page-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
}

.page-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 4px;
}

.page-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Filters Bar */
.filters-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  padding: 14px 18px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
}

.filter-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.filter-tab {
  padding: 8px 16px;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.filter-tab:hover {
  background: var(--bg-primary);
  color: var(--text-primary);
}

.filter-tab.active {
  background: var(--accent-blue-light);
  color: var(--accent-blue);
  border-color: var(--accent-blue);
}

.filter-tab .count {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  margin-left: 6px;
  padding: 2px 6px;
  background: var(--bg-primary);
  border-radius: 8px;
}

.filter-tab.active .count {
  background: var(--accent-blue);
  color: white;
}

/* Search Box */
.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  background: var(--bg-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  min-width: 280px;
  transition: border-color 0.2s;
}

.search-box:focus-within {
  border-color: var(--accent-blue);
}

.search-box i {
  color: var(--text-muted);
  font-size: 14px;
}

.search-box input {
  flex: 1;
  border: none;
  background: transparent;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  color: var(--text-primary);
  outline: none;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

/* PO Table Specific Styles */
.po-table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
}

.po-table th {
  padding: 14px 16px;
  text-align: left;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 10;
  white-space: nowrap;
}

.po-table th:first-child {
  padding-left: 24px;
}

.po-table td {
  padding: 16px;
  border-bottom: 1px solid var(--border-subtle);
  vertical-align: middle;
  font-size: 14px;
}

.po-table td:first-child {
  padding-left: 24px;
}

.po-table tbody tr {
  transition: background 0.15s;
}

.po-table tbody tr:hover {
  background: rgba(0, 128, 194, 0.02);
}

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

/* PO Number Cell */
.po-number-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.po-number {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.po-source {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  padding: 4px 8px;
  border-radius: 4px;
}

.po-source.linnworks {
  background: var(--text-secondary);
  color: white;
}

.po-source.app {
  background: var(--accent-green);
  color: white;
}

/* Supplier Cell */
.supplier-name {
  font-weight: 500;
  color: var(--text-primary);
}

/* Date Cell */
.date-cell {
  font-family: 'JetBrains Mono', monospace;
  font-size: 13px;
  color: var(--text-secondary);
}

/* Items Cell */
.items-cell {
  font-size: 13px;
  color: var(--text-secondary);
}

.items-cell strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* Value & Status Cell */
.value-status-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}

.po-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

/* Status Badges */
.status-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.status-badge.pending {
  background: var(--accent-amber-light);
  color: var(--accent-amber);
}

.status-badge.open {
  background: var(--accent-blue-light);
  color: var(--accent-blue);
}

.status-badge.partial {
  background: var(--accent-blue-light);
  color: var(--accent-blue);
}

.status-badge.delivered {
  background: var(--accent-green-light);
  color: var(--accent-green);
}

.status-badge.cancelled {
  background: var(--accent-red-light);
  color: var(--accent-red);
}

/* Actions Cell */
.actions-cell {
  display: flex;
  align-items: center;
  gap: 8px;
}

.action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 14px;
  font-family: 'DM Sans', sans-serif;
  font-size: 12px;
  font-weight: 500;
  background: var(--bg-primary);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

.action-link:hover {
  background: var(--bg-secondary);
  border-color: var(--border);
  color: var(--text-primary);
}

.action-link i {
  font-size: 14px;
}

.action-link.primary {
  background: var(--accent-blue);
  color: white;
  border-color: var(--accent-blue);
}

.action-link.primary:hover {
  background: #006da6;
  color: white;
}

/* Table Footer */
.table-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: var(--bg-primary);
  border-top: 1px solid var(--border-subtle);
}

.results-info {
  font-size: 13px;
  color: var(--text-secondary);
}

.results-info strong {
  color: var(--text-primary);
  font-weight: 600;
}

/* Summary Cards */
.summary-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.summary-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 20px;
}

.summary-card-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.summary-card-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
}

.summary-card-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Mini chart container for dashboard cards */
.mini-chart-container {
  height: 60px;
  margin-top: 12px;
}