/* ========================================
   Kindlco WMS - Color Theme & Variables
   ======================================== */
:root {
  /* Kindlco Brand Colors */
  --kindlco-primary: #F7941D;      /* Bright orange from logo */
  --kindlco-primary-dark: #d67b15;  /* Darker shade for hover */
  --kindlco-secondary: #2D2D2D;     /* Dark gray/charcoal */
  --kindlco-accent: #86BC25;        /* Green accent */
  --kindlco-light-bg: #F8F9FA;      /* Light background */
  --kindlco-border: #E0E0E0;        /* Light border color */
  --kindlco-text: #333333;          /* Main text color */
  --kindlco-text-muted: #6C757D;    /* Muted text */
  --kindlco-white: #FFFFFF;
  --kindlco-success: #28A745;
  --kindlco-warning: #FFC107;
  --kindlco-danger: #DC3545;
}

/* ========================================
   Base Typography & Layout
   ======================================== */
html {
  font-size: 14px;
  position: relative;
  min-height: 100%;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--kindlco-text);
  background-color: var(--kindlco-light-bg);
  margin-bottom: 60px;
  line-height: 1.6;
}

/* ========================================
   Navigation Bar
   ======================================== */
.navbar {
  background-color: var(--kindlco-white) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  padding: 1rem 0;
  border-bottom: 3px solid var(--kindlco-primary);
}

.navbar-logo {
  max-height: 50px;
  width: auto;
  margin-right: 1rem;
  transition: transform 0.3s ease;
}

.navbar-logo:hover {
  transform: scale(1.05);
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--kindlco-secondary) !important;
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
}

.navbar-brand:hover {
  color: var(--kindlco-primary) !important;
}

.nav-link {
  color: var(--kindlco-text) !important;
  font-weight: 500;
  padding: 0.5rem 1rem !important;
  transition: all 0.3s ease;
  position: relative;
}

.nav-link:hover {
  color: var(--kindlco-primary) !important;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 3px;
  background-color: var(--kindlco-primary);
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 80%;
}

/* User dropdown styling */
.dropdown-toggle::after {
  margin-left: 0.5rem;
}

.dropdown-menu {
  border: 1px solid var(--kindlco-border);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  margin-top: 0.5rem;
}

.dropdown-item {
  padding: 0.75rem 1.25rem;
  transition: all 0.2s ease;
}

.dropdown-item:hover {
  background-color: var(--kindlco-primary);
  color: var(--kindlco-white);
}

/* ========================================
   Buttons
   ======================================== */
.btn-primary {
  background-color: var(--kindlco-primary);
  border-color: var(--kindlco-primary);
  color: var(--kindlco-white);
  font-weight: 600;
  padding: 0.625rem 1.5rem;
  border-radius: 6px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(134, 188, 37, 0.2);
}

.btn-primary:hover {
  background-color: var(--kindlco-primary-dark);
  border-color: var(--kindlco-primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(134, 188, 37, 0.3);
}

.btn-primary:active, .btn-primary:focus {
  background-color: var(--kindlco-primary-dark);
  border-color: var(--kindlco-primary-dark);
  box-shadow: 0 0 0 0.2rem rgba(134, 188, 37, 0.25);
}

.btn-secondary {
  background-color: var(--kindlco-secondary);
  border-color: var(--kindlco-secondary);
  color: var(--kindlco-white);
  font-weight: 600;
  padding: 0.625rem 1.5rem;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background-color: #1a1a1a;
  border-color: #1a1a1a;
  transform: translateY(-1px);
}

.btn-outline-primary {
  border-color: var(--kindlco-primary);
  color: var(--kindlco-primary);
  font-weight: 600;
  padding: 0.625rem 1.5rem;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.btn-outline-primary:hover {
  background-color: var(--kindlco-primary);
  border-color: var(--kindlco-primary);
  color: var(--kindlco-white);
  transform: translateY(-1px);
}

/* ========================================
   Cards & Containers
   ======================================== */
.card {
  border: 1px solid var(--kindlco-border);
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
  background-color: var(--kindlco-white);
  cursor: default;
}

.card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.card-header {
  background-color: var(--kindlco-light-bg);
  border-bottom: 2px solid var(--kindlco-primary);
  font-weight: 600;
  color: var(--kindlco-secondary);
  padding: 1rem 1.25rem;
}

/* ========================================
   Tables
   ======================================== */
.table {
  background-color: var(--kindlco-white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.table thead th {
  background-color: var(--kindlco-secondary);
  color: var(--kindlco-white);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 0.5px;
  border: none;
  padding: 1rem;
}

.table tbody tr {
  transition: all 0.2s ease;
}

.table tbody tr:hover {
  background-color: rgba(134, 188, 37, 0.05);
}

.table tbody td {
  padding: 1rem;
  vertical-align: middle;
  border-bottom: 1px solid var(--kindlco-border);
}

.table-striped tbody tr:nth-of-type(odd) {
  background-color: rgba(248, 249, 250, 0.5);
}

/* ========================================
   Forms
   ======================================== */
.form-label {
  font-weight: 600;
  color: var(--kindlco-secondary);
  margin-bottom: 0.5rem;
}

.form-control {
  border: 2px solid var(--kindlco-border);
  border-radius: 6px;
  padding: 0.625rem 1rem;
  transition: all 0.3s ease;
  font-size: 1rem;
  color: var(--kindlco-text);
}

.form-control:hover {
  border-color: var(--kindlco-primary);
  color: var(--kindlco-text);
}

.form-control:focus {
  border-color: var(--kindlco-primary);
  box-shadow: 0 0 0 0.2rem rgba(134, 188, 37, 0.15);
  outline: none;
  color: var(--kindlco-text);
}

.form-control::placeholder {
  color: var(--kindlco-text-muted);
  opacity: 0.6;
}

.form-select {
  border: 2px solid var(--kindlco-border);
  border-radius: 6px;
  padding: 0.625rem 1rem;
  transition: all 0.3s ease;
}

.form-select:focus {
  border-color: var(--kindlco-primary);
  box-shadow: 0 0 0 0.2rem rgba(247, 148, 29, 0.15);
}

.form-check-input:checked {
  background-color: var(--kindlco-primary);
  border-color: var(--kindlco-primary);
}

.form-check-input:focus {
  border-color: var(--kindlco-primary);
  box-shadow: 0 0 0 0.2rem rgba(134, 188, 37, 0.15);
}

/* Validation styling */
.invalid-feedback {
  color: var(--kindlco-danger);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

span.text-danger {
  pointer-events: none;
}

.is-invalid {
  border-color: var(--kindlco-danger) !important;
}

/* ========================================
   Page Headers & Content
   ======================================== */
h1, h2, h3, h4, h5, h6 {
  color: var(--kindlco-secondary);
  font-weight: 700;
}

h1 {
  font-size: 2.25rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 3px solid var(--kindlco-primary);
}

h2 {
  font-size: 1.875rem;
  margin-bottom: 1.25rem;
}

h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.page-header {
  background: linear-gradient(135deg, var(--kindlco-primary) 0%, var(--kindlco-primary-dark) 100%);
  color: var(--kindlco-white);
  padding: 2rem 0;
  margin-bottom: 2rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.page-header h1 {
  color: var(--kindlco-white);
  border: none;
  margin: 0;
  padding: 0;
}

/* ========================================
   Footer
   ======================================== */
.footer {
  background-color: var(--kindlco-secondary);
  color: var(--kindlco-white);
  padding: 1.5rem 0;
  margin-top: 3rem;
  border-top: 3px solid var(--kindlco-primary);
}

.footer a {
  color: var(--kindlco-primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer a:hover {
  color: var(--kindlco-white);
  text-decoration: underline;
}

/* ========================================
   Badges & Status Indicators
   ======================================== */
.badge {
  font-weight: 600;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  font-size: 0.875rem;
}

.badge-active {
  background-color: var(--kindlco-success);
  color: var(--kindlco-white);
}

.badge-inactive {
  background-color: var(--kindlco-text-muted);
  color: var(--kindlco-white);
}

/* ========================================
   Alerts
   ======================================== */
.alert {
  border-radius: 8px;
  border: none;
  padding: 1rem 1.25rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.alert-success {
  background-color: rgba(134, 188, 37, 0.1);
  color: var(--kindlco-primary-dark);
  border-left: 4px solid var(--kindlco-primary);
}

.alert-danger {
  background-color: rgba(220, 53, 69, 0.1);
  color: #b02a37;
  border-left: 4px solid var(--kindlco-danger);
}

.alert-warning {
  background-color: rgba(255, 193, 7, 0.1);
  color: #997404;
  border-left: 4px solid var(--kindlco-warning);
}

.alert-info {
  background-color: rgba(13, 202, 240, 0.1);
  color: #055160;
  border-left: 4px solid #0dcaf0;
}

/* ========================================
   Utility Classes
   ======================================== */
.text-primary {
  color: var(--kindlco-primary) !important;
}

.bg-primary {
  background-color: var(--kindlco-primary) !important;
}

.border-primary {
  border-color: var(--kindlco-primary) !important;
}

.container-main {
  background-color: var(--kindlco-white);
  border-radius: 10px;
  padding: 2rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  margin-top: 2rem;
  margin-bottom: 2rem;
}

/* ========================================
   Responsive Adjustments
   ======================================== */
@media (max-width: 768px) {
  .navbar-brand {
    font-size: 1.25rem;
  }

  h1 {
    font-size: 1.75rem;
  }

  .container-main {
    padding: 1rem;
  }

  .page-header {
    padding: 1.5rem 0;
  }
}

/* ========================================
   Loading & Animations
   ======================================== */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.5s ease-in-out;
}

/* Smooth transitions for interactive elements */
a, button, .btn, .nav-link, .card, .form-control {
  transition: all 0.3s ease;
}

/* CRITICAL FIX: Disable ALL cursor transitions globally */
* {
  transition-property: background-color, border-color, box-shadow, transform, opacity, color !important;
}

/* Override transition for quantity input to fix cursor visibility */
input#receivedQuantityInput {
  transition: none !important;
  cursor: text !important;
  caret-color: black !important;
  color: #333333 !important;
  opacity: 1 !important;
  visibility: visible !important;
  position: relative !important;
  z-index: 9999 !important;
  pointer-events: auto !important;
}

/* Ensure parent doesn't interfere with cursor */
.col-md-4.mb-3, .card-body, .container-main, .card, form, .row {
  cursor: default !important;
}

/* Focus visible for accessibility */
:focus-visible {
  outline: 2px solid var(--kindlco-primary);
  outline-offset: 2px;
}