/* ============ ManageShop — Kairalmas ============ */
:root {
  --brand: #0d9488;
  --brand-dark: #0f766e;
  --brand-darker: #134e4a;
  --sidebar-bg: #0f172a;
  --sidebar-hover: #1e293b;
  --body-bg: #f1f5f9;
}

body { background: var(--body-bg); font-family: "Segoe UI", system-ui, -apple-system, sans-serif; min-height: 100vh; }

/* ---------- Topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 1030;
  background: linear-gradient(90deg, var(--brand-darker), var(--brand-dark));
  min-height: 56px; padding: .35rem 1rem;
}
.topbar-brand { color: #fff; font-weight: 700; letter-spacing: .3px; }

/* ---------- Sidebar layout ---------- */
.app-wrapper { display: flex; min-height: calc(100vh - 56px); }
.app-sidebar {
  width: 250px; flex-shrink: 0; background: var(--sidebar-bg);
  padding: 1rem .75rem;
}
.app-content { flex-grow: 1; padding: 1.25rem 1.5rem 2.5rem; min-width: 0; }
@media (max-width: 991.98px) {
  .app-content { padding: 1rem .75rem 2rem; }
  .d-lg-none .collapse.show .sidebar-inner { padding: .5rem; }
}

.sidebar-inner .nav-link {
  color: #cbd5e1; border-radius: .5rem; padding: .55rem .75rem;
  margin-bottom: .15rem; display: flex; align-items: center; gap: .6rem;
  font-size: .925rem; text-decoration: none;
}
.sidebar-inner .nav-link i { font-size: 1.05rem; width: 1.25rem; text-align: center; }
.sidebar-inner .nav-link:hover { background: var(--sidebar-hover); color: #fff; }
.sidebar-inner .nav-link.active { background: var(--brand); color: #fff; font-weight: 600; }
.sidebar-sep { border-color: #334155; opacity: .6; margin: .75rem .25rem; }

.sidebar-shop-badge {
  display: flex; gap: .6rem; align-items: center;
  background: var(--sidebar-hover); border-radius: .6rem;
  padding: .6rem .7rem; margin-bottom: .9rem; color: #e2e8f0;
}
.sidebar-shop-badge i { font-size: 1.5rem; color: var(--brand); }
.sidebar-shop-badge small { color: #94a3b8; display: block; }
.shop-switcher select { min-width: 220px; }

/* ---------- Cards / stats ---------- */
.card { border: none; box-shadow: 0 1px 3px rgba(15, 23, 42, .08); border-radius: .75rem; }
.stat-card { display: flex; align-items: center; gap: 1rem; padding: 1.1rem 1.25rem; }
.stat-card .stat-icon {
  width: 52px; height: 52px; border-radius: .75rem;
  display: flex; align-items: center; justify-content: center; font-size: 1.5rem; color: #fff;
}
.stat-card .stat-value { font-size: 1.45rem; font-weight: 700; line-height: 1.1; }
.stat-card .stat-label { color: #64748b; font-size: .82rem; }
.bg-brand { background: var(--brand) !important; }
.page-title { font-weight: 700; margin-bottom: 1.1rem; display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.page-title .bi { color: var(--brand-dark); }

.table th { font-size: .78rem; text-transform: uppercase; letter-spacing: .4px; color: #64748b; }
.table td { vertical-align: middle; }

.badge-soft-success { background: #dcfce7; color: #166534; }
.badge-soft-danger  { background: #fee2e2; color: #991b1b; }
.badge-soft-warning { background: #fef9c3; color: #854d0e; }
.badge-soft-info    { background: #e0f2fe; color: #075985; }
.badge-soft-brand   { background: #ccfbf1; color: #115e59; }

.app-footer { text-align: center; color: #94a3b8; font-size: .8rem; padding: 1rem 0 1.5rem; }

/* ---------- Landing page ---------- */
.hero {
  background: linear-gradient(135deg, var(--brand-darker) 0%, var(--brand-dark) 55%, var(--brand) 100%);
  color: #fff; padding: 4.5rem 1rem 5rem;
}
.hero h1 { font-weight: 800; font-size: clamp(1.9rem, 4vw, 3rem); }
.feature-icon {
  width: 46px; height: 46px; border-radius: .65rem; background: #ccfbf1; color: var(--brand-dark);
  display: flex; align-items: center; justify-content: center; font-size: 1.3rem; margin-bottom: .8rem;
}
.login-wrap { max-width: 420px; margin: 3rem auto; }

/* ---------- POS ---------- */
.pos-product {
  cursor: pointer; transition: transform .06s ease, box-shadow .06s ease;
}
.pos-product:hover { transform: translateY(-2px); box-shadow: 0 4px 14px rgba(15,23,42,.14); }
.pos-product.out-of-stock { opacity: .45; cursor: not-allowed; }
#cartTable input.qty-input { width: 74px; }
.invoice-print { background: #fff; max-width: 820px; margin: 1rem auto; padding: 2rem; border-radius: .5rem; box-shadow: 0 2px 10px rgba(0,0,0,.08); }
@media print {
  .topbar, .app-sidebar, .app-footer, .no-print, .btn, .alert { display: none !important; }
  .app-wrapper { display: block !important; }
  .app-content { padding: 0 !important; }
  .invoice-print { box-shadow: none; margin: 0; max-width: 100%; padding: 0; }
  body { background: #fff !important; }
}

/* ---------- Attribute chips ---------- */
.attr-chip {
  display: inline-block; background: #f1f5f9; border: 1px solid #e2e8f0;
  border-radius: 2rem; padding: .12rem .6rem; font-size: .76rem; color: #334155; margin: .1rem .15rem .1rem 0;
}

/* mini bar chart */
.mini-bars { display: flex; align-items: flex-end; gap: 6px; height: 140px; padding-top: .5rem; }
.mini-bars .bar-col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; }
.mini-bars .bar { width: 100%; background: var(--brand); border-radius: 4px 4px 0 0; min-height: 2px; }
.mini-bars .bar-label { font-size: .62rem; color: #64748b; margin-top: .3rem; white-space: nowrap; }

.product-thumb {
  width: 46px; height: 46px; border-radius: .45rem; object-fit: cover; background: #e2e8f0;
  display: flex; align-items: center; justify-content: center; color: #94a3b8; overflow: hidden; flex-shrink: 0;
}
