:root {
  --bg: #f4f7fb;
  --card: #ffffff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-soft: #eef2f7;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-soft: #eff6ff;
  --danger: #e11d48;
  --danger-soft: #fff1f2;
  --ok: #059669;
  --ok-soft: #ecfdf5;
  --warn: #d97706;
  --warn-soft: #fffbeb;
  --sidebar: #0f172a;
  --sidebar-soft: #1e293b;
  --shadow: 0 8px 28px rgba(15, 23, 42, .06);
  --shadow-lg: 0 24px 60px rgba(15, 23, 42, .18);
  --radius: 14px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Cairo", "Segoe UI", Tahoma, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
.hidden { display: none !important; }
.muted { color: var(--muted); font-size: 13px; }
.error { color: var(--danger); font-size: 13px; margin-top: 8px; }
button, input, select, textarea { font-family: inherit; }
button { transition: background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

/* ---------- Buttons & fields ---------- */
.primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff; border: 0; padding: 10px 18px; border-radius: 9px;
  cursor: pointer; font-weight: 600; box-shadow: 0 4px 12px rgba(37, 99, 235, .22);
}
.primary:hover { transform: translateY(-1px); box-shadow: 0 7px 18px rgba(37, 99, 235, .28); }
.primary:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }
.ghost { background: #fff; border: 1px solid var(--line); color: var(--ink); padding: 9px 13px; border-radius: 9px; cursor: pointer; }
.ghost:hover { border-color: #cbd5e1; background: #f8fafc; }
.ghost svg, .primary svg { vertical-align: middle; margin-inline-end: 5px; }
.danger { background: var(--danger); color: #fff; border: 0; padding: 7px 11px; border-radius: 8px; cursor: pointer; }
.danger:hover { background: #be123c; }
.small { padding: 5px 9px; font-size: 12px; }
.block { width: 100%; }
.icon-btn {
  width: 38px; height: 38px; border: 1px solid var(--line); background: #fff;
  border-radius: 9px; cursor: pointer; font-size: 17px; color: var(--ink); display: none;
  align-items: center; justify-content: center; flex: 0 0 auto;
}
input, select, textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px;
  margin-top: 6px; font-size: 14px; background: #fff; color: var(--ink);
}
input:hover, select:hover, textarea:hover { border-color: #cbd5e1; }
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.10); outline: none; }
textarea { min-height: 76px; resize: vertical; }
select[multiple] { min-height: 96px; padding: 4px; }
select[multiple] option { padding: 5px 7px; }

/* ---------- Login ---------- */
.login-wrap {
  min-height: 100vh; display: grid; place-items: center; padding: 18px;
  background: radial-gradient(circle at 15% 10%, #1e3a8a 0, transparent 45%),
              radial-gradient(circle at 85% 90%, #0f766e 0, transparent 40%), #0f172a;
}
.login-card {
  background: #fff; padding: 30px; border-radius: 18px; width: min(390px, 94vw);
  box-shadow: var(--shadow-lg);
}
.login-brand { display: flex; align-items: center; gap: 12px; }
.login-brand h1 { font-size: 19px; margin: 0; }
.login-brand p { margin: 0; }
.login-divider { height: 1px; background: var(--line); margin: 18px 0 4px; }
.login-card label { display: block; margin: 14px 0 0; font-size: 13px; font-weight: 600; }
.login-card button { margin-top: 20px; }

/* ---------- App shell ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: 244px; flex: 0 0 244px; background: linear-gradient(180deg, var(--sidebar), #111c33);
  color: #cbd5e1; padding: 20px 14px; display: flex; flex-direction: column;
  gap: 6px; position: sticky; top: 0; height: 100vh; z-index: 30;
}
.brand { display: flex; align-items: center; gap: 11px; padding: 4px 8px 20px; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center;
  background: linear-gradient(135deg, #60a5fa, #2563eb); color: #fff;
  font-weight: 800; font-size: 19px; box-shadow: 0 6px 16px rgba(37,99,235,.35); flex: 0 0 auto;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { color: #fff; font-size: 18px; letter-spacing: .3px; }
.brand-text span { font-size: 11px; color: #94a3b8; }
.nav-section-label { font-size: 10px; color: #94a3b8; padding: 0 12px 6px; text-transform: uppercase; letter-spacing: .6px; }
.sidebar nav { display: flex; flex-direction: column; gap: 4px; flex: 1; overflow: auto; }
.sidebar button.nav {
  background: transparent; color: #cbd5e1; border: 0; text-align: right;
  padding: 10px 12px; border-radius: 9px; cursor: pointer; display: flex;
  align-items: center; gap: 10px; font-size: 13px; width: 100%; position: relative;
}
.sidebar button.nav:hover { background: rgba(148,163,184,.12); color: #fff; }
.sidebar button.nav.active { background: rgba(59,130,246,.18); color: #fff; font-weight: 600; }
.sidebar button.nav.active::before {
  content: ""; position: absolute; inset-inline-end: 0; top: 9px; bottom: 9px;
  width: 3px; border-radius: 3px; background: #60a5fa;
}
.nav-icon { width: 18px; height: 18px; flex: 0 0 18px; opacity: .9; }
.sidebar-footer { border-top: 1px solid rgba(148,163,184,.18); padding-top: 12px; margin-top: 8px; }
.side-user { display: flex; align-items: center; gap: 9px; padding: 4px 8px 10px; }
.side-user-meta { display: flex; flex-direction: column; line-height: 1.35; min-width: 0; }
.side-user-meta strong { color: #fff; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-user-meta span { font-size: 11px; color: #94a3b8; }
.sidebar .logout { width: 100%; background: rgba(148,163,184,.08); border-color: rgba(148,163,184,.2); color: #e2e8f0; text-align: center; }
.sidebar .logout:hover { background: rgba(225,29,72,.2); border-color: rgba(225,29,72,.5); color: #fff; }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; flex: 0 0 auto;
  background: linear-gradient(135deg, #93c5fd, #2563eb); color: #fff; font-weight: 700; font-size: 13px;
}
.sidebar-backdrop { display: none; }

.main { flex: 1; min-width: 0; padding: 0 26px 46px; }
.topbar {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 0 18px; border-bottom: 1px solid var(--line); margin-bottom: 22px;
}
.topbar-start { display: flex; align-items: center; gap: 12px; min-width: 0; }
.crumb { font-size: 11px; color: #475569; }
.crumb span { color: #475569; }
.topbar h1 { font-size: 20px; margin: 2px 0 0; line-height: 1.3; }
.topbar-end { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.branch-chip, .date-chip {
  background: #fff; border: 1px solid var(--line); border-radius: 20px;
  padding: 5px 12px; font-size: 11px; color: var(--muted); white-space: nowrap;
  max-width: min(300px, 30vw); overflow: hidden; text-overflow: ellipsis;
}
.date-chip { background: var(--primary-soft); border-color: #dbeafe; color: var(--primary-dark); }
.user-chip { display: flex; align-items: center; gap: 8px; padding-inline-start: 10px; border-inline-start: 1px solid var(--line); }
.user-meta { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.3; }
.user { font-weight: 700; font-size: 13px; white-space: nowrap; }
.user-chip .badge { align-self: flex-start; }

/* ---------- Badges & generic surfaces ---------- */
.badge { background: #e0e7ff; color: #3730a3; padding: 3px 9px; border-radius: 20px; font-size: 10px; font-weight: 700; white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: #047857; }
.badge.warn { background: var(--warn-soft); color: #b45309; }
.badge.bad { background: var(--danger-soft); color: #be123c; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 18px; box-shadow: var(--shadow); }
.card h2 { font-size: 16px; margin: 0 0 14px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.head-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.stat .value { font-size: 23px; font-weight: 800; margin-top: 4px; letter-spacing: -.3px; }
.stat .label { font-size: 12px; color: var(--muted); }
.table-wrap { overflow: auto; max-height: 480px; border-radius: 10px; }
.table-wrap th { position: sticky; top: 0; background: var(--card); z-index: 1; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 10px 9px; border-bottom: 1px solid var(--line-soft); text-align: right; white-space: nowrap; }
th { color: var(--muted); font-weight: 700; font-size: 11px; background: #f8fafc; }
tr:hover td { background: #f8fafc; }
tbody tr:last-child td { border-bottom: 0; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; align-items: center; }
.search-row { display: flex; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.search-row input, .search-row select, .search-row button { min-width: 0; }
.search-row input { margin: 0; }
.hint { font-size: 12px; color: var(--muted); margin-top: 8px; line-height: 1.7; }
.selected { background: var(--primary-soft) !important; }
.batch-list { max-height: 300px; margin-top: 10px; }
.batch-footer {
  position: sticky; bottom: 0; z-index: 3; background: #fff; border: 1px solid var(--line);
  border-radius: 12px; padding: 12px; margin-top: 10px; display: grid;
  grid-template-columns: 1.3fr 1fr 1fr; gap: 10px; align-items: end;
  box-shadow: 0 -6px 18px rgba(15, 23, 42, .08);
}
.batch-footer label { display: flex; flex-direction: column; font-size: 12px; margin: 0; }
.batch-footer label#bpReasonWrap { grid-column: 1 / -1; }
.batch-footer input, .batch-footer textarea { margin-top: 4px; }
.batch-total { font-size: 13px; line-height: 1.9; }
.batch-total strong { font-size: 15px; }

/* ---------- Dashboard ---------- */
.dash-head { display: flex; justify-content: space-between; align-items: end; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.dash-head h2 { font-size: 18px; margin: 0; }
.dash-head p { margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.kpi {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow); position: relative; overflow: hidden; min-height: 116px;
}
.kpi::after { content: ""; position: absolute; inset-block-start: 0; inset-inline-start: 0; width: 100%; height: 3px; background: var(--accent, var(--primary)); }
.kpi-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.kpi-label { font-size: 12px; color: var(--muted); font-weight: 600; }
.kpi-icon { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--soft, var(--primary-soft)); color: var(--accent, var(--primary)); }
.kpi-icon svg { width: 18px; height: 18px; }
.kpi-value { font-size: 25px; font-weight: 800; margin-top: 8px; line-height: 1.25; letter-spacing: -.4px; }
.kpi-note { font-size: 11px; color: var(--muted); margin-top: 2px; }
.kpi.blue { --accent: #2563eb; --soft: #eff6ff; }
.kpi.green { --accent: #059669; --soft: #ecfdf5; }
.kpi.amber { --accent: #d97706; --soft: #fffbeb; }
.kpi.rose { --accent: #e11d48; --soft: #fff1f2; }

.dash-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 17px; min-width: 0; }
.panel.wide { grid-column: span 2; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 14px; }
.panel-head h3 { font-size: 14px; margin: 0; }
.panel-head .muted { font-size: 11px; }
.chart { display: flex; align-items: flex-end; gap: 10px; height: 170px; padding-top: 10px; border-bottom: 1px solid var(--line); }
.chart-col { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 6px; min-width: 0; }
.chart-bar {
  width: min(34px, 70%); border-radius: 7px 7px 2px 2px; min-height: 3px;
  background: linear-gradient(180deg, #60a5fa, #2563eb); position: relative;
}
.chart-bar.zero { background: #e2e8f0; }
.chart-bar:hover { filter: brightness(1.08); }
.chart-label { font-size: 10px; color: var(--muted); white-space: nowrap; }
.chart-value { font-size: 10px; color: var(--ink); font-weight: 700; }
.chart-legend { display: flex; gap: 14px; margin-top: 10px; font-size: 11px; color: var(--muted); flex-wrap: wrap; }
.legend-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-inline-end: 5px; background: var(--primary); }
.legend-dot.ok { background: var(--ok); }
.legend-dot.warn { background: var(--warn); }

.split-row { display: flex; justify-content: space-between; font-size: 12px; margin: 10px 0 5px; }
.split-row strong { font-size: 13px; }
.progress { height: 8px; background: var(--line-soft); border-radius: 20px; overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: 20px; background: var(--primary); }
.progress.ok > span { background: var(--ok); }
.progress.warn > span { background: var(--warn); }
.progress.rose > span { background: var(--danger); }
.mini-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 16px; }
.mini-stat { background: #f8fafc; border: 1px solid var(--line-soft); border-radius: 10px; padding: 9px; text-align: center; }
.mini-stat strong { display: block; font-size: 16px; }
.mini-stat span { font-size: 10px; color: var(--muted); }

.quick-actions { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.quick-action {
  border: 1px solid var(--line); background: #fff; border-radius: 11px; padding: 12px 10px;
  cursor: pointer; text-align: right; display: flex; align-items: center; gap: 9px; color: var(--ink);
}
.quick-action:hover { border-color: #bfdbfe; background: var(--primary-soft); transform: translateY(-1px); }
.quick-action svg { width: 18px; height: 18px; color: var(--primary); flex: 0 0 auto; }
.quick-action span { font-size: 12px; font-weight: 600; }
.alert-list, .activity-list { display: flex; flex-direction: column; gap: 8px; }
.alert-item, .activity-item {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  border: 1px solid var(--line-soft); background: #f8fafc; border-radius: 10px; padding: 9px 11px; font-size: 12px;
}
.alert-item.warn { background: var(--warn-soft); border-color: #fde68a; }
.activity-item { align-items: flex-start; }
.activity-main { display: flex; flex-direction: column; min-width: 0; }
.activity-main strong { font-size: 12px; }
.activity-main span { font-size: 11px; color: var(--muted); }
.dash-empty { padding: 22px 10px; text-align: center; color: var(--muted); font-size: 12px; border: 1px dashed var(--line); border-radius: 10px; }
.skeleton { background: linear-gradient(90deg, #eef2f7 25%, #f8fafc 50%, #eef2f7 75%); background-size: 200% 100%; animation: shimmer 1.3s infinite; border-radius: 10px; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- Modal & toast ---------- */
.toast {
  position: fixed; bottom: 24px; inset-inline-start: 24px; max-width: min(420px, 90vw);
  background: #0f172a; color: #fff; padding: 12px 18px; border-radius: 10px; z-index: 60;
  box-shadow: var(--shadow-lg);
}
.toast.error { background: var(--danger); }
.modal { position: fixed; inset: 0; background: rgba(15,23,42,.52); display: grid; place-items: center; z-index: 50; padding: 12px; backdrop-filter: blur(2px); }
.modal-box { background: #fff; border-radius: 16px; padding: 24px; width: min(920px, 95vw); max-height: 88vh; overflow: auto; position: relative; box-shadow: var(--shadow-lg); }
.modal-close { position: absolute; top: 12px; inset-inline-end: 16px; border: 0; background: #f1f5f9; width: 28px; height: 28px; border-radius: 50%; font-size: 18px; line-height: 1; cursor: pointer; color: var(--muted); }
.modal-close:hover { background: var(--danger-soft); color: var(--danger); }
.modal-box h2 { padding-inline-end: 36px; }
.inline { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; }
.inline > label { display: flex; flex-direction: column; font-size: 13px; }
.inline > * { flex: 1 1 180px; min-width: 160px; }
.inline button { flex: 0 0 auto; align-self: flex-end; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; align-items: start; }
.form-grid label { display: flex; flex-direction: column; font-size: 13px; }
.form-grid .wide { grid-column: 1 / -1; }
.form-actions { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- Receipt image ---------- */
.upload-zone {
  border: 2px dashed #cbd5e1; border-radius: 12px; padding: 22px; text-align: center;
  background: #f8fafc; cursor: pointer; color: var(--muted); margin-top: 12px;
}
.upload-zone:hover, .upload-zone:focus-visible { border-color: var(--primary); background: var(--primary-soft); color: var(--primary-dark); outline: none; }
.upload-zone strong { display: block; color: var(--ink); font-size: 14px; margin-bottom: 3px; }
.upload-zone span { font-size: 11px; }
.upload-preview { margin-top: 14px; text-align: center; }
.receipt-view { text-align: center; min-height: 120px; }
.receipt-image {
  max-width: 100%; max-height: 52vh; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; box-shadow: var(--shadow); object-fit: contain;
}
.file-meta { font-size: 11px; color: var(--muted); margin-top: 8px; line-height: 1.8; word-break: break-word; }

/* ---------- Customer guarantee documents ---------- */
.customer-doc-drafts { display: grid; gap: 10px; margin-top: 14px; }
.customer-doc-draft {
  display: grid; grid-template-columns: 110px 1fr; gap: 12px; align-items: start;
  border: 1px solid var(--line); border-radius: 10px; padding: 10px; background: #f8fafc;
}
.doc-draft-preview { display: grid; place-items: center; min-height: 84px; }
.doc-thumb { max-width: 100px; max-height: 84px; border-radius: 8px; border: 1px solid var(--line); object-fit: cover; background: #fff; }
.pdf-badge {
  width: 68px; height: 68px; border-radius: 10px; display: grid; place-items: center;
  background: var(--danger-soft); color: var(--danger); font-size: 13px; font-weight: 700;
}
.doc-draft-name { font-size: 13px; font-weight: 600; word-break: break-word; }
.doc-draft-row { display: grid; grid-template-columns: 1fr 1.2fr; gap: 8px; margin-top: 8px; }
.doc-draft-row label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; }
.doc-draft-note { display: flex; flex-direction: column; gap: 4px; font-size: 12px; margin-top: 8px; }
.doc-draft-hint { font-size: 11px; align-self: center; }
.doc-draft-remove { margin-top: 8px; }
.customer-doc-meta {
  display: flex; flex-wrap: wrap; gap: 8px 16px; margin: 8px 0 14px;
  font-size: 12px; color: var(--muted);
}
.customer-doc-meta > span { display: inline-flex; align-items: center; gap: 5px; }
.inline-check { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.cd-summary-sub { margin-top: 3px; font-size: 10px; color: var(--muted); white-space: normal; }
.cd-doc-chips { display: flex; flex-wrap: wrap; gap: 4px; max-width: 240px; }
.cd-doc-chips .badge { font-size: 9px; }
.pdf-frame { width: 100%; height: 65vh; border: 1px solid var(--line); border-radius: 10px; background: #f8fafc; }
.table-actions { margin: 0; gap: 5px; }
.table-pager {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: 8px; padding: 10px 4px 2px; font-size: 12px; color: var(--muted);
}
.table-pager button:disabled { opacity: .45; cursor: not-allowed; }
.table-pager select { width: auto; min-width: 105px; padding: 5px 8px; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .panel.wide { grid-column: span 2; }
}
@media (max-width: 860px) {
  .icon-btn { display: flex; }
  .sidebar { position: fixed; inset-block: 0; inset-inline-start: 0; width: min(244px, 82vw); transform: translateX(105%); transition: transform .25s ease; height: 100vh; box-shadow: var(--shadow-lg); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-backdrop.show { display: block; position: fixed; inset: 0; background: rgba(15,23,42,.45); z-index: 29; }
  .main { padding: 0 16px 34px; }
  .topbar { flex-wrap: wrap; }
  .topbar-end { width: 100%; justify-content: flex-start; }
  .branch-chip { max-width: 100%; white-space: normal; }
  .primary, .ghost, .danger, .small { min-height: 40px; }
}
@media (max-width: 640px) {
  .kpi-grid, .dash-grid { grid-template-columns: 1fr; }
  .panel.wide { grid-column: span 1; }
  .user-chip { border-inline-start: 0; padding-inline-start: 0; }
  .date-chip { display: none; }
  .branch-chip { display: inline-block; max-width: 100%; white-space: normal; font-size: 10px; line-height: 1.4; }
  th, td { padding: 8px 6px; font-size: 12px; }
  .quick-actions { grid-template-columns: 1fr; }
  .search-row { flex-direction: column; align-items: stretch; }
  .search-row > * { width: 100%; flex: 1 1 auto; }
  .inline, .form-grid { display: flex; flex-direction: column; align-items: stretch; }
  .inline > *, .inline button, .form-grid > * { width: 100%; flex: 1 1 auto; }
  .batch-footer { position: static; grid-template-columns: 1fr; }
  .batch-footer label#bpReasonWrap { grid-column: auto; }
  .customer-doc-draft { grid-template-columns: 1fr; }
  .doc-draft-row { grid-template-columns: 1fr; }
  .table-pager { justify-content: flex-start; font-size: 11px; gap: 6px; }
  .modal { padding: 8px; }
  .modal-box { padding: 18px; max-height: 92vh; }
  .pdf-frame { height: 52vh; }
}
