:root {
  --navy: #0f1a2e;
  --navy-light: #1a2d4a;
  --navy-lighter: #243b5e;
  --gold: #f5a623;
  --gold-dark: #d4891a;
  --gold-light: #ffd180;
  --bg: #f0f4f9;
  --bg-card: #ffffff;
  --text: #1a2332;
  --text-light: #6b7a8f;
  --text-lighter: #9aa8b9;
  --border: #e8edf3;
  --shadow: 0 2px 12px rgba(15, 26, 46, 0.08);
  --shadow-lg: 0 8px 40px rgba(15, 26, 46, 0.12);
  --radius: 12px;
  --radius-sm: 8px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Inter', -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* ===== SPLIT LAYOUT (Login / Register) ===== */

.split-layout {
  display: flex;
  min-height: 100vh;
}

.split-brand {
  flex: 1;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 50%, var(--navy-lighter) 100%);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px;
  overflow: hidden;
}

.brand-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(245, 166, 35, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(255, 255, 255, 0.03) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(245, 166, 35, 0.06) 0%, transparent 50%);
}

.brand-content {
  position: relative;
  z-index: 1;
  max-width: 480px;
  text-align: center;
  animation: fadeInUp 0.8s ease;
}

.brand-logo {
  width: 120px;
  height: 120px;
  margin: 0 auto 28px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.brand-logo img {
  width: 76px;
  height: 76px;
  object-fit: contain;
}

.brand-title {
  font-size: 36px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.5px;
  margin-bottom: 4px;
}

.brand-subtitle {
  font-size: 14px;
  font-weight: 600;
  color: var(--gold-light);
  text-transform: uppercase;
  letter-spacing: 6px;
  margin-bottom: 20px;
}

.brand-desc {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.7;
  margin-bottom: 40px;
}

.brand-stats {
  display: flex;
  justify-content: center;
  gap: 40px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-number {
  font-size: 28px;
  font-weight: 800;
  color: var(--gold);
  line-height: 1;
}

.stat-label {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 6px;
}

.split-form {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  padding: 60px;
}

.form-container {
  max-width: 420px;
  width: 100%;
  animation: fadeInUp 0.8s ease 0.2s both;
}

.form-header {
  margin-bottom: 32px;
}

.form-header h2 {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}

.form-header p {
  font-size: 15px;
  color: var(--text-light);
}

.alert-premium {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  margin-bottom: 24px;
  font-size: 14px;
  font-weight: 500;
  animation: shake 0.4s ease;
}

.alert-premium-danger {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
}

.alert-premium i { font-size: 18px; }

.input-field {
  margin-bottom: 22px;
}

.input-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.input-wrapper {
  display: flex;
  align-items: center;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.input-wrapper:focus-within {
  border-color: var(--gold);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(245, 166, 35, 0.1);
}

.input-wrapper i {
  padding: 0 0 0 16px;
  color: var(--text-lighter);
  font-size: 15px;
  transition: var(--transition);
}

.input-wrapper:focus-within i { color: var(--gold); }

.input-wrapper input {
  flex: 1;
  padding: 14px 16px;
  border: none;
  background: transparent;
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  outline: none;
}

.input-wrapper input::placeholder { color: var(--text-lighter); }

.btn-premium {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

.btn-premium-primary {
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: #fff;
  box-shadow: 0 4px 16px rgba(245, 166, 35, 0.35);
}

.btn-premium-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(245, 166, 35, 0.45);
  color: #fff;
}

.btn-premium-outline {
  background: #fff;
  color: var(--text);
  border: 2px solid var(--border);
}

.btn-premium-outline:hover {
  border-color: var(--gold);
  color: var(--gold-dark);
}

.form-footer {
  text-align: center;
  margin-top: 28px;
  font-size: 14px;
  color: var(--text-light);
}

.form-footer a {
  color: var(--gold-dark);
  font-weight: 600;
  text-decoration: none;
}

.form-footer a:hover { color: var(--navy); text-decoration: underline; }

/* ===== DASHBOARD LAYOUT ===== */

.dashboard-layout {
  display: flex;
  min-height: 100vh;
}

/* ---- Sidebar ---- */

.sidebar {
  width: 280px;
  background: var(--navy);
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 1000;
  transition: var(--transition);
  overflow-y: auto;
}

.sidebar.collapsed { width: 72px; }

.sidebar::-webkit-scrollbar { width: 4px; }
.sidebar::-webkit-scrollbar-thumb { background: var(--navy-lighter); border-radius: 4px; }

.sidebar-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.sidebar-logo {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sidebar-logo img { width: 26px; height: 26px; object-fit: contain; }

.sidebar-brand { flex: 1; min-width: 0; }
.sidebar-brand h5 { font-size: 14px; font-weight: 700; color: #fff; margin: 0; line-height: 1.2; }
.sidebar-brand span { font-size: 10px; color: rgba(255, 255, 255, 0.4); text-transform: uppercase; letter-spacing: 2px; }

.sidebar-toggle {
  width: 32px; height: 32px;
  background: rgba(255, 255, 255, 0.06);
  border: none;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  flex-shrink: 0;
}

.sidebar-toggle:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.user-avatar {
  width: 40px; height: 40px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.user-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.user-name { font-size: 13px; font-weight: 600; color: #fff; }
.user-role { font-size: 11px; color: rgba(255, 255, 255, 0.4); }

.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
}

.nav-label {
  display: block;
  font-size: 10px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.25);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 16px 12px 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: var(--transition);
  margin-bottom: 2px;
}

.nav-item i { width: 20px; text-align: center; font-size: 15px; }

.nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.85);
}

.nav-item.active {
  background: rgba(245, 166, 35, 0.12);
  color: var(--gold);
}

.nav-logout {
  margin-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 16px;
}

.nav-logout:hover { color: #ef4444 !important; background: rgba(239, 68, 68, 0.08) !important; }

/* Collapsed sidebar */
.sidebar.collapsed .sidebar-brand,
.sidebar.collapsed .sidebar-user .user-info,
.sidebar.collapsed .sidebar-nav .nav-item span,
.sidebar.collapsed .sidebar-nav .nav-label { display: none; }

.sidebar.collapsed .sidebar-user { justify-content: center; padding: 16px; }
.sidebar.collapsed .nav-item { justify-content: center; padding: 12px; }
.sidebar.collapsed .nav-item i { width: auto; font-size: 18px; }

/* ---- Main Content ---- */

.main-content {
  flex: 1;
  margin-left: 280px;
  transition: var(--transition);
}

.sidebar.collapsed + .main-content { margin-left: 72px; }

/* ---- Topbar ---- */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.topbar-toggle {
  display: none;
  width: 36px; height: 36px;
  background: var(--bg);
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.topbar-search {
  display: flex;
  align-items: center;
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 0 16px;
  width: 320px;
  transition: var(--transition);
}

.topbar-search:focus-within {
  background: #fff;
  box-shadow: 0 0 0 2px var(--gold);
}

.topbar-search i { color: var(--text-lighter); font-size: 15px; }

.topbar-search input {
  flex: 1;
  padding: 10px 12px;
  border: none;
  background: transparent;
  font-size: 13px;
  font-family: inherit;
  color: var(--text);
  outline: none;
}

.topbar-search input::placeholder { color: var(--text-lighter); }

.topbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.topbar-btn {
  width: 38px; height: 38px;
  background: var(--bg);
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text-light);
  cursor: pointer;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.topbar-btn:hover { background: var(--border); color: var(--text); }

.topbar-btn .badge {
  position: absolute;
  top: -4px; right: -4px;
  width: 18px; height: 18px;
  background: #ef4444;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.topbar-divider {
  width: 1px;
  height: 28px;
  background: var(--border);
  margin: 0 8px;
}

.topbar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.topbar-user:hover { background: var(--bg); }

.user-avatar-sm {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
}

.user-info-sm { line-height: 1.2; }
.user-info-sm span { display: block; font-size: 13px; font-weight: 600; color: var(--text); }
.user-info-sm small { font-size: 11px; color: var(--text-light); }

/* ---- Content Area ---- */

.content-area {
  padding: 28px 32px;
}

/* ---- Page Header ---- */

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 20px;
}

.page-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}

.page-desc {
  font-size: 14px;
  color: var(--text-light);
  margin: 4px 0 0;
}

.page-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

/* ---- Stat Cards ---- */

.stat-card {
  background: #fff;
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  align-items: flex-start;
  gap: 20px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 4px;
  height: 100%;
  border-radius: 0 4px 4px 0;
}

.stat-card-blue::before { background: #3b82f6; }
.stat-card-green::before { background: #10b981; }
.stat-card-orange::before { background: #f59e0b; }
.stat-card-red::before { background: #ef4444; }

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.stat-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.stat-card-blue .stat-icon { background: #eff6ff; color: #3b82f6; }
.stat-card-green .stat-icon { background: #ecfdf5; color: #10b981; }
.stat-card-orange .stat-icon { background: #fffbeb; color: #f59e0b; }
.stat-card-red .stat-icon { background: #fef2f2; color: #ef4444; }

.stat-body h3 {
  font-size: 28px;
  font-weight: 700;
  margin: 0;
  line-height: 1;
}

.stat-body p {
  font-size: 13px;
  color: var(--text-light);
  margin: 4px 0 8px;
}

.stat-trend {
  font-size: 12px;
  font-weight: 600;
}

.stat-trend.up { color: #10b981; }
.stat-trend.down { color: #ef4444; }

.stat-trend i { font-size: 10px; margin-right: 2px; }

/* ---- Premium Cards ---- */

.card-premium {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card-premium-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
}

.card-premium-header h5 {
  font-size: 15px;
  font-weight: 600;
  margin: 0;
}

.card-link {
  font-size: 13px;
  color: var(--gold-dark);
  text-decoration: none;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
}

.card-link:hover { color: var(--navy); }

.card-premium-body {
  padding: 20px 24px;
}

/* ---- Premium Table ---- */

.table-premium {
  width: 100%;
  border-collapse: collapse;
  display: table;
}

.table-premium th {
  padding: 14px 24px;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-lighter);
  text-transform: uppercase;
  letter-spacing: 1px;
  text-align: left;
  background: var(--bg);
}

.table-premium td {
  padding: 14px 24px;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
}

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

.table-premium tr:hover td { background: rgba(245, 166, 35, 0.03); }

.project-name {
  font-weight: 600;
}

/* Status badges */
.status-badge {
  display: inline-flex;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.status-in-progress { background: #eff6ff; color: #3b82f6; }
.status-completed { background: #ecfdf5; color: #10b981; }
.status-pending { background: #fef3c7; color: #d97706; }
.status-review { background: #fdf2f8; color: #e11d48; }

/* Progress bar */
.progress-bar-container {
  display: flex;
  align-items: center;
  gap: 10px;
}

.progress-bar-container > span {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-light);
  width: 32px;
  text-align: right;
}

.progress-bar-fill {
  flex: 1;
  height: 6px;
  background: var(--bg);
  border-radius: 4px;
  position: relative;
  overflow: hidden;
}

.progress-bar-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  background: #3b82f6;
  border-radius: 4px;
  width: var(--width, 0%);
}

.progress-bar-fill.completed::after { background: #10b981; }

/* ---- Task List ---- */

.task-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.task-item:last-child { border-bottom: none; }

.task-check input { display: none; }

.task-check label {
  width: 22px; height: 22px;
  border: 2px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.task-check input:checked + label {
  background: #10b981;
  border-color: #10b981;
}

.task-check input:checked + label::after {
  content: '\f00c';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  font-size: 11px;
  color: #fff;
}

.task-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.task-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

.task-meta {
  font-size: 11px;
  color: var(--text-light);
  margin-top: 2px;
}

.task-priority {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 3px 10px;
  border-radius: 4px;
  flex-shrink: 0;
}

.task-priority.high { background: #fef2f2; color: #ef4444; }
.task-priority.medium { background: #fffbeb; color: #d97706; }
.task-priority.low { background: #f0fdf4; color: #16a34a; }

.fw-600 { font-weight: 600; }

/* ---- Stock Icons ---- */

.stock-icon {
  width: 38px; height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

.stock-danger { background: #fef2f2; color: #ef4444; }
.stock-warning { background: #fffbeb; color: #f59e0b; }
.stock-info { background: #eff6ff; color: #3b82f6; }

/* ---- Alert Success ---- */

.alert-premium-success {
  background: #ecfdf5;
  color: #16a34a;
  border: 1px solid #bbf7d0;
}

/* ---- Badge Count ---- */

.badge-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-light);
  background: var(--bg);
  padding: 4px 12px;
  border-radius: 20px;
}

/* ---- Empty State ---- */

.empty-state {
  text-align: center;
  padding: 60px 24px;
}

.empty-state i {
  font-size: 48px;
  color: var(--text-lighter);
  margin-bottom: 16px;
}

.empty-state h5 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.empty-state p {
  font-size: 14px;
  color: var(--text-light);
  margin-bottom: 24px;
}

/* ---- Action Buttons ---- */

.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  font-size: 14px;
}

.action-ledger {
  background: #fffbeb;
  color: #f5a623;
  margin-right: 6px;
  font-size: 11px;
  font-weight: 600;
  padding: 6px 10px;
  gap: 4px;
  white-space: nowrap;
  width: auto;
  height: auto;
}

.action-ledger:hover { background: #fef3c7; color: #d4891a; }

.action-edit {
  background: #eff6ff;
  color: #3b82f6;
  margin-right: 6px;
}

.action-edit:hover { background: #dbeafe; color: #2563eb; }

.action-delete {
  background: #fef2f2;
  color: #ef4444;
}

.action-delete:hover { background: #fecaca; color: #dc2626; }

/* ---- Sticky Sidebar ---- */

.sticky-sidebar { position: sticky; top: 90px; }

/* ---- Preview Card ---- */

.preview-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: linear-gradient(135deg, var(--navy), var(--navy-light));
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
}

.preview-avatar {
  width: 56px; height: 56px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: var(--gold);
  flex-shrink: 0;
}

.preview-info h5 {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin: 0;
  line-height: 1.2;
}

.preview-info span {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
}

.preview-details {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.preview-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--text);
}

.preview-row i { width: 16px; text-align: center; font-size: 14px; }

.preview-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #ecfdf5;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: #16a34a;
}

/* ---- Customer Table ---- */

.table-customers { min-width: 900px; }

.table-customers th {
  padding: 12px 16px;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-lighter);
  text-transform: uppercase;
  letter-spacing: 1px;
  background: var(--bg);
  border-bottom: 2px solid var(--border);
}

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

.customer-row { transition: var(--transition); }
.customer-row:hover td { background: rgba(245, 166, 35, 0.04); }
.customer-row:last-child td { border-bottom: none; }

.customer-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}

.customer-avatar {
  width: 38px; height: 38px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.customer-cell > div { display: flex; flex-direction: column; min-width: 0; }

.customer-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.customer-contact {
  font-size: 11px;
  color: var(--text-light);
  margin-top: 1px;
}

.contact-cell {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.contact-email, .contact-phone {
  font-size: 12px;
  color: var(--text);
}

.contact-email i, .contact-phone i {
  width: 14px;
  font-size: 11px;
  color: var(--text-lighter);
  margin-right: 4px;
}

.material-tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.3px;
}
.mat-generic { background: #f0f4f9; color: var(--text-light); }
.mat-cement { background: #e0e7ff; color: #4338ca; }
.mat-steel { background: #f3e8ff; color: #7c3aed; }
.mat-sand { background: #fef3c7; color: #b45309; }
.mat-brick { background: #fee2e2; color: #dc2626; }
.mat-aggregate { background: #e0f2fe; color: #0369a1; }
.mat-wood { background: #ffedd5; color: #c2410c; }

.location-cell {
  display: flex;
  flex-direction: column;
  gap: 1px;
  font-size: 12px;
  color: var(--text);
}
.location-cell i { color: var(--text-lighter); width: 14px; margin-right: 4px; }
.location-cell small { font-size: 10px; line-height: 1.3; }

.reg-date {
  font-size: 11px;
  color: var(--text-light);
  white-space: nowrap;
}
.reg-date i { font-size: 10px; }

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

.customer-row .status-badge i { font-size: 6px; margin-right: 5px; vertical-align: middle; }

/* ---- Stat Cards ---- */

.stat-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  transition: var(--transition);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }

.stat-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}
.stat-card-total .stat-icon { background: #eff6ff; color: #3b82f6; }
.stat-card-active .stat-icon { background: #ecfdf5; color: #16a34a; }
.stat-card-inactive .stat-icon { background: #fef2f2; color: #ef4444; }

.stat-info { display: flex; flex-direction: column; }
.stat-value { font-size: 28px; font-weight: 800; color: var(--text); line-height: 1.1; }
.stat-label { font-size: 12px; color: var(--text-light); margin-top: 2px; }

/* ---- Search ---- */

.search-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}
.search-wrapper i {
  position: absolute;
  left: 12px;
  font-size: 12px;
  color: var(--text-lighter);
  pointer-events: none;
}
.search-input {
  width: 200px;
  padding: 8px 12px 8px 32px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 12px;
  background: var(--bg);
  color: var(--text);
  outline: none;
  transition: var(--transition);
}
.search-input:focus {
  border-color: var(--gold);
  background: var(--bg-card);
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.1);
}

.status-active {
  background: #ecfdf5;
  color: #16a34a;
}

.status-active i { font-size: 7px; }

.status-inactive {
  background: #fef2f2;
  color: #ef4444;
}

.status-inactive i { font-size: 7px; }

.action-group {
  display: flex;
  gap: 4px;
  justify-content: flex-end;
}

.header-right { display: flex; align-items: center; gap: 12px; }

.btn-lg { padding: 14px 32px; font-size: 15px; }

/* ---- Purchase Table ---- */

.table-purchases { min-width: 1000px; }

.table-purchases th {
  padding: 12px 16px;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-lighter);
  text-transform: uppercase;
  letter-spacing: 1px;
  background: var(--bg);
  border-bottom: 2px solid var(--border);
}

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

.purchase-row { transition: var(--transition); }
.purchase-row:hover td { background: rgba(245, 166, 35, 0.04); }
.purchase-row:last-child td { border-bottom: none; }

.invoice-no {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-light);
  font-family: 'Courier New', monospace;
  letter-spacing: 0.5px;
}

/* ---- Purchase Summary ---- */

.purchase-preview { display: flex; flex-direction: column; gap: 4px; }

.calc-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 13px;
  color: var(--text);
}

.calc-value { font-weight: 600; color: var(--text); }

.calc-divider {
  height: 1px;
  background: var(--border);
  margin: 4px 0;
}

.calc-total { padding: 12px 0; }

.calc-total span:first-child {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}

.calc-total .calc-value {
  font-size: 16px;
  font-weight: 800;
  color: var(--gold-dark);
}



/* ---- Entry Type Guide ---- */

.entry-type-guide {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.type-box {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
}

.type-debit {
  background: #fef2f2;
  border: 1px solid #fecaca;
}

.type-debit i { font-size: 20px; color: #dc2626; }

.type-credit {
  background: #ecfdf5;
  border: 1px solid #bbf7d0;
}

.type-credit i { font-size: 20px; color: #16a34a; }

.type-box div { display: flex; flex-direction: column; }
.type-box strong { font-size: 13px; }
.type-box small { font-size: 11px; color: var(--text-light); margin-top: 2px; }

.type-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  background: #fffbeb;
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--text);
  line-height: 1.5;
}

.type-note i { color: #f59e0b; font-size: 16px; margin-top: 1px; }

/* ---- Form Select Premium ---- */

.form-select-premium {
  flex: 1;
  padding: 14px 16px;
  border: none;
  background: transparent;
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  outline: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%239aa8b9' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.input-wrapper:has(.form-select-premium) { padding-right: 0; }

/* ---- Form Check Premium ---- */

.form-check-premium {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 2px solid var(--border);
  cursor: pointer;
  transition: var(--transition);
}

.form-check-premium:hover { border-color: var(--gold); }

.form-check-premium input[type="checkbox"] {
  width: 20px; height: 20px;
  accent-color: var(--gold);
  cursor: pointer;
}

.form-check-premium label {
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  margin: 0;
}

/* ---- Form Actions ---- */

.form-actions {
  display: flex;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

/* ---- Tips List ---- */

.tips-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tip-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text);
}

.tip-item i { font-size: 16px; flex-shrink: 0; }

/* ---- Detail Row ---- */

.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.detail-row:last-child { border-bottom: none; }

.detail-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.detail-value {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}

/* ===== ANIMATIONS ===== */

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

/* ===== RESPONSIVE ===== */

@media (max-width: 992px) {
  .split-layout { flex-direction: column; }
  .split-brand { padding: 40px 24px; min-height: 300px; }
  .split-form { padding: 40px 24px; }

  .brand-stats { gap: 24px; }
  .stat-number { font-size: 22px; }

  .sidebar { transform: translateX(-100%); }
  .sidebar.mobile-open { transform: translateX(0); }
  .sidebar.collapsed { width: 280px; transform: translateX(-100%); }
  .sidebar.collapsed .sidebar-brand,
  .sidebar.collapsed .sidebar-user .user-info,
  .sidebar.collapsed .sidebar-nav .nav-item span,
  .sidebar.collapsed .sidebar-nav .nav-label { display: block; }
  .sidebar.collapsed .sidebar-user { justify-content: flex-start; padding: 16px 20px; }
  .sidebar.collapsed .nav-item { justify-content: flex-start; padding: 10px 12px; }
  .sidebar.collapsed .nav-item i { width: 20px; font-size: 15px; }
  .sidebar.collapsed.mobile-open { transform: translateX(0); }

  .main-content { margin-left: 0 !important; }

  .topbar-toggle { display: flex; }
  .topbar { padding: 12px 16px; }
  .topbar-search { width: 200px; }

  .content-area { padding: 20px 16px; }

  .page-header { flex-direction: column; }
  .page-actions { width: 100%; }
  .page-actions .btn-premium { flex: 1; }

  .sidebar-brand { display: block; }
}

@media (max-width: 576px) {
  .topbar-search { display: none; }
  .topbar-user .user-info-sm { display: none; }
}

/* ===== Enterprise ERP Styles ===== */

:root {
  --erp-primary: #F59E0B;
  --erp-primary-dark: #D97706;
  --erp-primary-light: #FDE68A;
  --erp-bg: #F8FAFC;
  --erp-card: #FFFFFF;
  --erp-text: #111827;
  --erp-text-secondary: #6B7280;
  --erp-border: #E5E7EB;
  --erp-success: #10B981;
  --erp-danger: #EF4444;
  --erp-info: #3B82F6;
  --erp-warning: #F59E0B;
  --erp-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --erp-shadow-hover: 0 10px 25px rgba(0,0,0,0.08), 0 4px 10px rgba(0,0,0,0.04);
  --erp-radius: 12px;
  --erp-radius-sm: 8px;
}





/* ---- Summary Cards (smr) ----

Use: .smr-grid > .smr-card (5-up, current balance spans 2 cols)
Overflow-safe: overflow-wrap, word-break, clamp() on financial values
No fixed heights — equal heights via grid stretch
*/

.smr-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.smr-grid > .smr-card-wide {
  grid-column: span 1;
}

.smr-card {
  background: var(--erp-card);
  border: 1px solid var(--erp-border);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  align-items: center;
  transition: all 0.3s;
  min-width: 0;
  overflow-wrap: break-word;
  word-break: break-word;
}

.smr-card:hover {
  box-shadow: var(--erp-shadow-hover);
  transform: translateY(-2px);
}

.smr-card-dark {
  background: linear-gradient(135deg, #111827, #1F2937);
  border-color: #111827;
}

.smr-card-dark .smr-label,
.smr-card-dark .smr-sub { color: #9CA3AF; }

.smr-card-dark .smr-title,
.smr-card-dark .smr-value { color: #fff; }

.smr-card-dark .smr-icon { background: rgba(245,158,11,0.2); color: var(--erp-primary); }

.smr-card-wide {
  grid-column: span 2;
}

.smr-card-print {
  cursor: pointer;
}

.smr-card-inner {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-width: 0;
}

.smr-card-wide .smr-icon {
  width: 52px;
  height: 52px;
  min-width: 52px;
  font-size: 22px;
}

.smr-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  background: var(--erp-bg);
  color: var(--erp-text-secondary);
  flex-shrink: 0;
}

.smr-icn-dr { background: #FEF2F2; color: var(--erp-danger); }
.smr-icn-gr { background: #ECFDF5; color: var(--erp-success); }
.smr-icn-yl { background: #FFFBEB; color: var(--erp-warning); }
.smr-icn-bl { background: #EFF6FF; color: var(--erp-info); }

.smr-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.smr-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--erp-text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.smr-title {
  font-size: clamp(0.8rem, 1.4vw, 1.05rem);
  font-weight: 800;
  color: var(--erp-text);
  line-height: 1.2;
  overflow-wrap: break-word;
  word-break: break-word;
}

.smr-sub {
  font-size: 11px;
  color: var(--erp-text-secondary);
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.smr-value {
  font-size: clamp(0.9rem, 1.8vw, 1.3rem);
  font-weight: 800;
  color: var(--erp-text);
  line-height: 1.2;
  white-space: nowrap;
}

.smr-amount {
  font-size: clamp(1rem, 2.2vw, 1.6rem);
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}

.smr-amount small {
  font-size: 10px;
  font-weight: 600;
  margin-left: 3px;
}

.smr-dr { color: var(--erp-danger); }
.smr-cr { color: var(--erp-success); }



/* ---- Cards ---- */

.erp-card {
  background: var(--erp-card);
  border: 1px solid var(--erp-border);
  border-radius: var(--erp-radius);
  box-shadow: var(--erp-shadow);
  margin-bottom: 20px;
  transition: box-shadow 0.3s;
  overflow-wrap: break-word;
  word-break: break-word;
}

.erp-card:hover { box-shadow: var(--erp-shadow-hover); }

.erp-card-hd {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 0;
  gap: 12px;
}

.erp-card-hd-l {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.erp-card-hd-l h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--erp-text);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.erp-card-hd-l p {
  font-size: 12px;
  color: var(--erp-text-secondary);
  margin: 2px 0 0;
}

.erp-bdg-dft {
  background: #FEF3C7;
  color: #D97706;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}

.erp-card-bd { padding: 24px; }

.erp-card-bd.p-0 { padding: 0; }

/* ---- Form ---- */

.erp-fg {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.erp-fld {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.erp-fld-fw { grid-column: 1 / -1; }

.erp-lbl {
  font-size: 12px;
  font-weight: 600;
  color: var(--erp-text);
  margin-bottom: 2px;
}

.erp-inp {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1px solid var(--erp-border);
  border-radius: var(--erp-radius-sm);
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
  min-height: 40px;
}

.erp-inp:focus-within {
  border-color: var(--erp-primary);
  box-shadow: 0 0 0 3px rgba(245,158,11,0.1);
}

.erp-inp > i {
  font-size: 14px;
  color: #9CA3AF;
  flex-shrink: 0;
}

.erp-inp input, .erp-inp select, .erp-inp textarea {
  flex: 1;
  border: none;
  outline: none;
  font-size: 13px;
  color: var(--erp-text);
  background: transparent;
  padding: 10px 0;
  font-family: inherit;
  min-width: 0;
}

.erp-inp input::placeholder, .erp-inp textarea::placeholder { color: #9CA3AF; }

.erp-inp-ta textarea {
  resize: vertical;
  min-height: 40px;
  padding: 10px 0;
}

.erp-sel {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236B7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0 center;
  padding-right: 20px !important;
  cursor: pointer;
}

.erp-inp-ro {
  background: var(--erp-bg);
  cursor: default;
}

.erp-inp-ro span {
  font-size: 13px;
  font-weight: 600;
  color: var(--erp-text);
  padding: 10px 0;
}

.erp-err { font-size: 11px; color: var(--erp-danger); margin-top: 2px; }

.erp-val-summary {
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: var(--erp-radius-sm);
  padding: 12px 16px;
  margin-bottom: 16px;
  font-size: 12px;
  color: var(--erp-danger);
}

/* ---- Amounts ---- */

.erp-amts {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto;
  gap: 12px;
  align-items: center;
  margin-top: 20px;
  padding: 20px;
  background: var(--erp-bg);
  border-radius: var(--erp-radius-sm);
}

.erp-amt-box {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.erp-amt-box .erp-lbl { font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; }

.erp-inp-mon {
  padding: 0 14px;
  min-height: 44px;
}

.erp-cur {
  font-size: 16px;
  font-weight: 700;
  color: var(--erp-text-secondary);
  flex-shrink: 0;
}

.erp-inp-mon input {
  font-size: 18px;
  font-weight: 700;
  padding: 10px 0;
  text-align: right;
}

.erp-amt-or {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
}

.erp-amt-or span {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--erp-text-secondary);
  background: var(--erp-border);
  padding: 2px 8px;
  border-radius: 4px;
}

.erp-amt-pv {
  text-align: center;
  padding: 8px 16px;
  background: #fff;
  border: 1px solid var(--erp-border);
  border-radius: var(--erp-radius-sm);
  min-width: 0;
  overflow-wrap: break-word;
  word-break: break-word;
}

.erp-amt-pv-lbl {
  display: block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--erp-text-secondary);
  margin-bottom: 4px;
}

.erp-amt-pv-val {
  font-size: clamp(0.9rem, 1.6vw, 1.3rem);
  font-weight: 800;
  display: block;
  white-space: nowrap;
}

.erp-amt-pv-val small { font-size: 12px; font-weight: 600; margin-left: 2px; }

.erp-amt-pv-val.erp-dr { color: var(--erp-danger); }
.erp-amt-pv-val.erp-cr { color: var(--erp-success); }

/* ---- File Upload ---- */

.erp-up {
  position: relative;
  border: 2px dashed var(--erp-border);
  border-radius: var(--erp-radius-sm);
  padding: 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.erp-up:hover { border-color: var(--erp-primary); background: #FFFBEB; }

.erp-up input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.erp-up-c {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.erp-up-c i { font-size: 28px; color: var(--erp-text-secondary); }

.erp-up-c span { font-size: 13px; color: var(--erp-text); }

.erp-up-c strong { color: var(--erp-primary); }

.erp-up-c small { font-size: 11px; color: var(--erp-text-secondary); }

/* ---- Bottom Bar ---- */

.erp-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  background: #fff;
  border: 1px solid var(--erp-border);
  border-radius: var(--erp-radius);
  box-shadow: var(--erp-shadow);
  position: sticky;
  bottom: 16px;
  z-index: 50;
  margin-top: 24px;
}

.erp-bar-l, .erp-bar-r {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ---- Buttons ---- */

.erp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border: none;
  border-radius: var(--erp-radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  white-space: nowrap;
  gap: 6px;
}

.erp-btn-pri {
  background: var(--erp-primary);
  color: #fff;
}

.erp-btn-pri:hover { background: var(--erp-primary-dark); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(245,158,11,0.3); }

.erp-btn-grn {
  background: var(--erp-success);
  color: #fff;
}

.erp-btn-grn:hover { background: #059669; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(16,185,129,0.3); }

.erp-btn-out {
  background: #fff;
  color: var(--erp-text);
  border: 1px solid var(--erp-border);
}

.erp-btn-out:hover { background: var(--erp-bg); border-color: #D1D5DB; }

.erp-btn-gst {
  background: transparent;
  color: var(--erp-text-secondary);
}

.erp-btn-gst:hover { background: var(--erp-bg); color: var(--erp-text); }

.erp-btn-sm { padding: 6px 12px; font-size: 12px; }

.erp-btn:active { transform: translateY(0); }

/* ---- Table ---- */

.erp-tb-wr {
  overflow-x: auto;
}

.erp-tb {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

.erp-tb thead {
  position: sticky;
  top: 0;
  z-index: 2;
}

.erp-tb th {
  padding: 12px 16px;
  font-size: 10px;
  font-weight: 700;
  color: var(--erp-text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  background: var(--erp-bg);
  border-bottom: 2px solid var(--erp-border);
  text-align: left;
  white-space: nowrap;
}

.erp-tb td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--erp-border);
  vertical-align: middle;
  color: var(--erp-text);
}

.erp-tb tbody tr:nth-child(even) td { background: #FAFBFC; }
.erp-tb tbody tr:hover td { background: #FFFBEB; }

.erp-vch {
  font-family: 'Courier New', monospace;
  font-size: 11px;
  font-weight: 600;
  color: var(--erp-text-secondary);
}

.erp-prt {
  display: block;
  max-width: 300px;
  white-space: normal;
  word-break: break-word;
  line-height: 1.3;
}

.erp-tb .r { text-align: right; white-space: nowrap; }
.erp-tb .c { text-align: center; white-space: nowrap; }

.erp-tb-act {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
}

.erp-tb-act-ed { color: var(--erp-info); background: #EFF6FF; }
.erp-tb-act-ed:hover { background: var(--erp-info); color: #fff; }

.erp-tb-act-dl { color: var(--erp-danger); background: #FEF2F2; }
.erp-tb-act-dl:hover { background: var(--erp-danger); color: #fff; }

.erp-dr { color: var(--erp-danger); }
.erp-cr { color: var(--erp-success); }
.erp-bl { font-size: 9px; margin-left: 2px; }
.fw-600 { font-weight: 600; }

/* ---- Animations ---- */

.smr-card {
  animation: erpFadeIn 0.3s ease-out both;
}

.smr-card:nth-child(1) { animation-delay: 0.02s; }
.smr-card:nth-child(2) { animation-delay: 0.04s; }
.smr-card:nth-child(3) { animation-delay: 0.06s; }
.smr-card:nth-child(4) { animation-delay: 0.08s; }
.smr-card:nth-child(5) { animation-delay: 0.10s; }

@keyframes erpFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---- Responsive ---- */

@media (max-width: 1400px) {
  .smr-grid { gap: 14px; }
}

@media (max-width: 1200px) {
  .smr-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 992px) {
  .erp-fg { grid-template-columns: 1fr; }
  .erp-amts { grid-template-columns: 1fr; }
  .erp-amt-or { padding: 4px 0; }
  .smr-grid { grid-template-columns: repeat(2, 1fr); }
  .smr-card-wide { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  .erp-bar { flex-direction: column; gap: 12px; }
  .erp-bar-l, .erp-bar-r { width: 100%; justify-content: center; flex-wrap: wrap; }
  .smr-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .smr-card-wide { grid-column: 1 / -1; }
  .erp-card-hd { flex-direction: column; align-items: flex-start; gap: 8px; }
  .erp-card-bd { padding: 16px; }
}

@media (max-width: 480px) {
  .smr-grid { grid-template-columns: 1fr; }
  .erp-bar-r { flex-direction: column; }
  .erp-bar-r .erp-btn { width: 100%; }
}
