/* ============================================================
   ALENA POS — Design System
   Built by Alena Technologies
   ============================================================ */

:root {
  --primary:         #1D4ED8;
  --primary-light:   #2563EB;
  --primary-lighter: #3B82F6;
  --accent:          #2563EB;
  --accent-dark:     #1D4ED8;
  --success:         #10B981;
  --success-bg:      #D1FAE5;
  --warning:         #F59E0B;
  --warning-bg:      #FEF3C7;
  --danger:          #EF4444;
  --danger-bg:       #FEE2E2;
  --info:            #06B6D4;
  --info-bg:         #CFFAFE;
  --bg:              #F8FAFC;
  --surface:         #FFFFFF;
  --border:          #E2E8F0;
  --border-light:    #F1F5F9;
  --text-primary:    #0F172A;
  --text-secondary:  #475569;
  --text-muted:      #94A3B8;
  --shadow-sm:       0 1px 3px rgba(29,78,216,.08), 0 1px 2px rgba(29,78,216,.05);
  --shadow-md:       0 4px 6px -1px rgba(29,78,216,.1), 0 2px 4px -1px rgba(29,78,216,.06);
  --shadow-lg:       0 10px 15px -3px rgba(29,78,216,.12), 0 4px 6px -2px rgba(29,78,216,.06);
  --shadow-xl:       0 20px 25px -5px rgba(29,78,216,.12), 0 10px 10px -5px rgba(29,78,216,.05);
  --radius-sm:       0.375rem;
  --radius:          0.5rem;
  --radius-lg:       0.75rem;
  --radius-xl:       1rem;
  --transition:      all 0.2s ease;
}

/* ── Base ── */
*, *::before, *::after { box-sizing: border-box; }

body {
    background-color: var(--bg);
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--text-primary);
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* ── Cards ── */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-md);
}

.card-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.25rem;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0 !important;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-header h6,
.card-header .m-0 {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    letter-spacing: 0.01em;
}

.card-body {
    padding: 1.25rem;
}

/* ── Navbar ── */
.navbar {
    padding: 0 1.5rem;
    height: 64px;
    box-shadow: 0 2px 8px rgba(29,78,216,.4);
    background: var(--primary) !important;
    position: sticky;
    top: 0;
    z-index: 1030;
}

.navbar-brand {
    font-size: 1rem;
    padding: 0;
    text-decoration: none;
}

.navbar-nav .nav-item {
    position: relative;
    margin: 0 1px;
}

.navbar-nav .nav-link {
    padding: 0.5rem 0.85rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    font-size: 0.875rem;
    font-weight: 500;
    color: rgba(255,255,255,.75) !important;
    letter-spacing: 0.01em;
}

.navbar-nav .nav-link:hover {
    background: rgba(255,255,255,.1);
    color: #fff !important;
}

.navbar-nav .nav-link.active {
    background: rgba(59,130,246,.25);
    color: #fff !important;
    font-weight: 600;
}

.navbar-nav .nav-link i {
    opacity: .8;
}

/* Dropdown */
.navbar-nav .nav-item.dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown-menu {
    border: 1px solid var(--border);
    box-shadow: var(--shadow-xl);
    border-radius: var(--radius-lg);
    margin-top: 0;
    padding: 6px;
    min-width: 200px;
    animation: dropIn 0.15s ease;
}

@keyframes dropIn {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.dropdown-item {
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition);
}

.dropdown-item:hover {
    background: var(--border-light);
    color: var(--text-primary);
}

.dropdown-item i {
    width: 18px;
    text-align: center;
    margin-right: 8px;
    color: var(--accent);
    font-size: 0.875rem;
}

.dropdown-divider {
    border-color: var(--border);
    margin: 4px 8px;
}

/* Logo */
.logo-container {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    box-shadow: 0 0 0 3px rgba(59,130,246,.25);
    flex-shrink: 0;
}

/* Low stock notification badge */
.nav-alert-badge {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.nav-alert-badge .badge-dot {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 8px;
    height: 8px;
    background: var(--danger);
    border-radius: 50%;
    border: 2px solid #fff;
    animation: pulse-dot 1.5s infinite;
}

@keyframes pulse-dot {
    0%, 100% { transform: scale(1); opacity: 1; }
    50%       { transform: scale(1.3); opacity: 0.7; }
}

/* ── Page Header ── */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.75rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.page-header h1,
.page-header .h3 {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    letter-spacing: -0.02em;
}

/* ── Buttons ── */
.btn {
    font-weight: 500;
    font-size: 0.875rem;
    border-radius: var(--radius);
    padding: 0.5rem 1.125rem;
    transition: var(--transition);
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    letter-spacing: 0.01em;
}

.btn:focus { box-shadow: 0 0 0 3px rgba(59,130,246,.3); outline: none; }

.btn-primary {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 1px 3px rgba(59,130,246,.4);
}
.btn-primary:hover {
    background: var(--accent-dark);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59,130,246,.4);
}

.btn-success {
    background: var(--success);
    color: #fff;
    box-shadow: 0 1px 3px rgba(16,185,129,.4);
}
.btn-success:hover {
    background: #059669;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16,185,129,.35);
}

.btn-danger {
    background: var(--danger);
    color: #fff;
    box-shadow: 0 1px 3px rgba(239,68,68,.3);
}
.btn-danger:hover {
    background: #DC2626;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(239,68,68,.35);
}

.btn-warning {
    background: var(--warning);
    color: #fff;
    box-shadow: 0 1px 3px rgba(245,158,11,.3);
}
.btn-warning:hover {
    background: #D97706;
    color: #fff;
    transform: translateY(-1px);
}

.btn-info {
    background: var(--info);
    color: #fff;
}
.btn-info:hover {
    background: #0891B2;
    color: #fff;
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--border-light);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}
.btn-secondary:hover {
    background: var(--border);
    color: var(--text-primary);
    transform: translateY(-1px);
}

.btn-outline-secondary {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}
.btn-outline-secondary:hover {
    background: var(--border-light);
    color: var(--text-primary);
    border-color: var(--border);
}

.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.8rem;
    border-radius: var(--radius-sm);
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    border-radius: var(--radius);
}

/* ── Tables ── */
.table {
    color: var(--text-primary);
    font-size: 0.875rem;
    border-collapse: separate;
    border-spacing: 0;
    width: 100%;
}

.table thead th {
    background: var(--primary);
    color: rgba(255,255,255,.85);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.875rem 1rem;
    border: none;
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 2;
}

.table thead th:first-child { border-radius: var(--radius-sm) 0 0 0; }
.table thead th:last-child  { border-radius: 0 var(--radius-sm) 0 0; }

.table tbody tr td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-light);
    vertical-align: middle;
    transition: background 0.15s;
}

.table tbody tr:nth-child(even) td {
    background: #FAFBFC;
}

.table tbody tr:hover td {
    background: #EFF6FF;
}

.table tbody tr:last-child td {
    border-bottom: none;
}

.table-bordered {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.table-bordered thead th,
.table-bordered tbody td {
    border: 1px solid var(--border-light) !important;
}

/* DataTables overrides */
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0.35rem 0.75rem;
    font-size: 0.875rem;
    color: var(--text-primary);
    background: var(--surface);
}

.dataTables_wrapper .dataTables_filter input:focus,
.dataTables_wrapper .dataTables_length select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(59,130,246,.15);
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    border-radius: var(--radius-sm) !important;
    font-size: 0.825rem !important;
    padding: 4px 10px !important;
    color: var(--text-secondary) !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: var(--accent) !important;
    color: #fff !important;
    border: 1px solid var(--accent) !important;
}

.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: var(--border-light) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border) !important;
}

/* ── Badges ── */
.badge {
    font-weight: 600;
    font-size: 0.725rem;
    padding: 0.3em 0.7em;
    border-radius: 99px;
    letter-spacing: 0.03em;
}

.badge.bg-success  { background: var(--success-bg) !important; color: #065F46 !important; }
.badge.bg-danger   { background: var(--danger-bg)  !important; color: #991B1B !important; }
.badge.bg-warning  { background: var(--warning-bg) !important; color: #92400E !important; }
.badge.bg-info     { background: var(--info-bg)    !important; color: #164E63 !important; }
.badge.bg-primary  { background: #DBEAFE !important;           color: #1E40AF !important; }
.badge.bg-secondary{ background: var(--border-light)!important;color: var(--text-secondary)!important; }

/* ── KPI / Dashboard Cards ── */
.kpi-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.375rem 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.kpi-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.kpi-card.kpi-primary::before  { background: var(--accent); }
.kpi-card.kpi-success::before  { background: var(--success); }
.kpi-card.kpi-warning::before  { background: var(--warning); }
.kpi-card.kpi-danger::before   { background: var(--danger); }
.kpi-card.kpi-info::before     { background: var(--info); }

.kpi-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.kpi-label {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.kpi-value {
    font-size: 1.875rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: 0.25rem;
}

.kpi-sub {
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.kpi-trend-up   { color: var(--success); font-weight: 600; }
.kpi-trend-down { color: var(--danger);  font-weight: 600; }

.kpi-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.375rem;
    flex-shrink: 0;
}

.kpi-icon.icon-primary  { background: #DBEAFE; color: var(--accent); }
.kpi-icon.icon-success  { background: var(--success-bg); color: var(--success); }
.kpi-icon.icon-warning  { background: var(--warning-bg); color: var(--warning); }
.kpi-icon.icon-danger   { background: var(--danger-bg); color: var(--danger); }
.kpi-icon.icon-info     { background: var(--info-bg); color: var(--info); }

/* Legacy dashboard stats — keep working */
.dashboard-stats .card { transition: var(--transition); }
.dashboard-stats .card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }

.stats-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

/* ── Forms ── */
.form-control,
.form-select {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.5rem 0.875rem;
    font-size: 0.875rem;
    color: var(--text-primary);
    background: var(--surface);
    transition: var(--transition);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(59,130,246,.15);
    outline: none;
}

.form-control::placeholder { color: var(--text-muted); }

.form-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.375rem;
}

.input-group-text {
    background: var(--border-light);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* ── Modals ── */
.modal-content {
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
}

.modal-header {
    background: var(--primary);
    color: #fff;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    padding: 1.125rem 1.5rem;
    border-bottom: none;
}

.modal-header .modal-title { font-weight: 700; font-size: 1rem; }
.modal-header .btn-close { filter: invert(1) brightness(2); }

.modal-body {
    padding: 1.5rem;
    background: var(--surface);
}

.modal-footer {
    background: var(--border-light);
    border-top: 1px solid var(--border);
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
    padding: 1rem 1.5rem;
}

/* ── Alerts ── */
.alert {
    border-radius: var(--radius);
    border: none;
    font-size: 0.875rem;
    padding: 0.875rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.alert-success { background: var(--success-bg); color: #065F46; border-left: 4px solid var(--success); }
.alert-danger  { background: var(--danger-bg);  color: #991B1B; border-left: 4px solid var(--danger); }
.alert-warning { background: var(--warning-bg); color: #92400E; border-left: 4px solid var(--warning); }
.alert-info    { background: var(--info-bg);    color: #164E63; border-left: 4px solid var(--info); }

/* ── POS Screen ── */
.pos-container {
    display: grid;
    grid-template-columns: 1fr 460px;
    gap: 1.25rem;
    height: calc(100vh - 160px);
    min-height: 560px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
    gap: 0.875rem;
    overflow-y: auto;
    padding: 0.25rem;
    height: 100%;
    align-content: start;
}

.product-item {
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem 0.75rem;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    height: 195px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.product-item:hover {
    border-color: var(--accent);
    box-shadow: var(--shadow-md), 0 0 0 3px rgba(59,130,246,.12);
    transform: translateY(-2px);
}

.product-item:active {
    transform: translateY(0);
    background: #EFF6FF;
}

.product-image {
    height: 75px;
    width: 100%;
    object-fit: contain;
    margin-bottom: 0.4rem;
    border-radius: var(--radius-sm);
}

.product-name {
    font-weight: 600;
    margin-bottom: 0.2rem;
    font-size: 0.85rem;
    color: var(--text-primary);
    height: 2.6rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.3;
}

.product-price {
    color: var(--success);
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: -0.01em;
}

.product-stock {
    font-size: 0.72rem;
    color: var(--text-muted);
}

/* Cart */
.cart-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
    overflow: hidden;
}

.cart-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    background: var(--primary);
    color: #fff;
}

.cart-header h5 { color: #fff; font-weight: 700; font-size: 1rem; margin-bottom: 0.75rem; }

.cart-header .form-label { color: rgba(255,255,255,.7); font-size: 0.8rem; }
.cart-header .form-select {
    background: rgba(255,255,255,.1);
    border-color: rgba(255,255,255,.2);
    color: #fff;
    font-size: 0.875rem;
}
.cart-header .form-select option { background: var(--primary); color: #fff; }

.cart-items {
    flex-grow: 1;
    overflow-y: auto;
    padding: 0.875rem;
    background: var(--bg);
}

.cart-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.75rem;
    margin-bottom: 0.625rem;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 0.5rem;
    align-items: center;
    transition: var(--transition);
}

.cart-item:hover { border-color: var(--accent); }

.cart-item-name  { font-weight: 600; font-size: 0.85rem; color: var(--text-primary); }
.cart-item-price { font-size: 0.78rem; color: var(--text-muted); }

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.cart-item-quantity .btn { padding: 0.25rem 0.5rem; min-width: 28px; justify-content: center; }

.cart-item-quantity input {
    width: 42px;
    text-align: center;
    padding: 0.25rem;
    font-size: 0.875rem;
    border-radius: var(--radius-sm);
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.cart-item-subtotal {
    font-weight: 700;
    color: var(--success);
    font-size: 0.9rem;
    white-space: nowrap;
}

.cart-footer {
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--border);
    background: var(--surface);
    flex-shrink: 0;
}

.cart-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    background: var(--primary);
    border-radius: var(--radius);
    color: #fff;
}

.cart-total-label { font-size: 0.85rem; font-weight: 600; opacity: .8; }

.cart-total {
    font-size: 1.5rem;
    font-weight: 900;
    color: #fff;
    letter-spacing: -0.02em;
}

#btn-checkout {
    width: 100%;
    padding: 0.875rem;
    font-size: 1rem;
    font-weight: 700;
    background: var(--success);
    border: none;
    border-radius: var(--radius);
    color: #fff;
    box-shadow: 0 2px 8px rgba(16,185,129,.4);
    margin-bottom: 0.625rem;
    transition: var(--transition);
}

#btn-checkout:hover {
    background: #059669;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(16,185,129,.4);
}

#btn-clear-cart {
    width: 100%;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    border-radius: var(--radius);
    padding: 0.625rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: var(--transition);
}

#btn-clear-cart:hover {
    background: var(--danger-bg);
    border-color: var(--danger);
    color: var(--danger);
}

/* ── Login Page ── */
.login-container {
    max-width: 420px;
    width: 100%;
    padding: 1rem;
}

.login-logo { text-align: center; margin-bottom: 1.5rem; }
.login-logo i { font-size: 3.5rem; }

/* ── Products page thumbnail ── */
.product-image-thumbnail {
    width: 48px;
    height: 48px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    padding: 2px;
}

/* ── Inventory ── */
.low-stock { color: var(--danger); font-weight: 700; }

/* ── List group ── */
.list-group-item {
    border-color: var(--border-light);
    font-size: 0.875rem;
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    transition: background 0.15s;
}

.list-group-item:hover { background: var(--border-light); }
.list-group-flush .list-group-item:first-child { border-top: 0; }
.list-group-flush .list-group-item:last-child { border-bottom: 0; }

/* ── Custom Scrollbar ── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ── Footer ── */
footer.site-footer {
    background: var(--primary);
    color: rgba(255,255,255,.6);
    text-align: center;
    padding: 1.25rem 1rem;
    font-size: 0.8rem;
    margin-top: 3rem;
    border-top: 1px solid rgba(255,255,255,.06);
}

footer.site-footer a {
    color: rgba(255,255,255,.5);
    text-decoration: none;
    font-weight: 600;
}

footer.site-footer a:hover { color: var(--accent); }

/* ── Print: Receipt ── */
@media print {
    .no-print { display: none !important; }

    .receipt {
        width: 80mm;
        font-size: 12px;
        margin: 0;
        padding: 0;
    }
    .receipt-header  { text-align: center; margin-bottom: 10px; }
    .receipt-items   { border-top: 1px dashed #000; border-bottom: 1px dashed #000; margin: 10px 0; padding: 10px 0; }
    .receipt-item    { display: flex; justify-content: space-between; margin-bottom: 5px; }
    .receipt-total   { font-weight: bold; text-align: right; margin-top: 10px; }
    .receipt-footer  { text-align: center; margin-top: 10px; font-size: 10px; }
}

/* ── Print: Supplier Price List ── */
.price-list-print-wrapper {
    max-width: 900px;
    margin: 0 auto;
}

@media print {
    .price-list-print-wrapper .navbar,
    .price-list-print-wrapper .no-print,
    .price-list-print-wrapper footer { display: none !important; }

    .price-list-print-wrapper .card {
        border: none;
        box-shadow: none;
    }

    .price-list-print-table thead th {
        background: #000 !important;
        color: #fff !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .price-list-print-table tbody tr:nth-child(even) td {
        background: #f5f5f5 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .page-break-before { page-break-before: always; }
}

/* ── Responsive ── */
@media (max-width: 1200px) {
    .pos-container { grid-template-columns: 1fr 420px; }
}

@media (max-width: 992px) {
    .pos-container {
        grid-template-columns: 1fr;
        height: auto;
        min-height: auto;
    }
    .product-grid, .cart-container { height: 520px; min-height: 420px; }
    .navbar { height: auto; min-height: 60px; }
    .navbar-nav { padding: 0.5rem 0 1rem; }
    .navbar-nav .nav-link { padding: 0.5rem 0.75rem; }
}

@media (max-width: 768px) {
    .pos-container { gap: 1rem; }
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 0.75rem;
    }
    .product-item { height: 175px; padding: 0.625rem; }
    .product-image { height: 65px; }
    .product-name { font-size: 0.82rem; }
    .kpi-value { font-size: 1.5rem; }
    .modal-dialog { margin: 0.75rem; }
    .card-body { padding: 1rem; }
}

@media (max-width: 576px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(115px, 1fr));
        gap: 0.5rem;
    }
    .product-item { height: 155px; padding: 0.5rem; }
    .product-image { height: 56px; }
    .cart-item { grid-template-columns: 1fr; gap: 0.4rem; }
    .kpi-value { font-size: 1.25rem; }
    .page-header { flex-direction: column; align-items: flex-start; gap: 0.75rem; }
    h1, .h3 { font-size: 1.2rem; }
}

@media (max-width: 400px) {
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); }
    .product-item { height: 148px; }
    .product-image { height: 50px; }
}

@media (max-width: 992px) and (orientation: landscape) {
    .pos-container {
        height: calc(100vh - 110px);
    }
}

/* ── Global print hide ── */
@media print {
    .navbar, .no-print, footer, .btn { display: none !important; }
    body { padding: 0; margin: 0; }
    .container-fluid { padding: 0; }
    .card { border: none; box-shadow: none; margin: 0; }
} 