/* ══════════════════════════════════════════════
   BHARAT ACE GROUP CRM v2 – STYLESHEET
   Brand Colors:
     Charcoal  #2d3a4a   (helmet dark)
     Orange    #f97316   (A – saffron)
     Green     #16a34a   (E – green)
     White     #ffffff
   ══════════════════════════════════════════════ */

/* ── RESET & TOKENS ── */
:root {
  --charcoal: #2d3a4a;
  --charcoal-deep: #1a2535;
  --charcoal-mid: #374557;
  --orange: #f97316;
  --orange-light: #fb923c;
  --orange-pale: #fff7ed;
  --green: #16a34a;
  --green-light: #22c55e;
  --green-pale: #f0fdf4;
  --white: #ffffff;
  --bg: #f0f4f8;
  --bg-card: #ffffff;
  --text: #1e293b;
  --text-mid: #475569;
  --text-light: #94a3b8;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --red: #ef4444;
  --purple: #8b5cf6;
  --blue: #3b82f6;
  --yellow: #f59e0b;

  --sb-w: 242px;
  --sb-w-mini: 64px;
  --topbar-h: 60px;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 8px rgba(0,0,0,0.07);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.10);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.14);
  --tr: all 0.22s cubic-bezier(.4,0,.2,1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; background: var(--bg); color: var(--text); overflow-x: hidden; }
a { text-decoration: none; cursor: pointer; }
ul { list-style: none; }
input, select, textarea, button { font-family: inherit; font-size: inherit; }
img { display: block; max-width: 100%; }

/* ── SCREENS ── */
.page-screen { display: none; }
.page-screen.active { display: flex; }
.inner-page { display: none; animation: fadeUp .28s ease; }
.inner-page.active { display: block; }
@keyframes fadeUp { from { opacity:0; transform:translateY(10px); } to { opacity:1; transform:translateY(0); } }

/* ══════════════════════════════════════════════
   LOGIN PAGE
   ══════════════════════════════════════════════ */
#pg-login { min-height: 100vh; width: 100%; }
.login-wrapper {
  display: flex;
  min-height: 100vh;
  width: 100%;
}

/* LEFT PANEL */
.login-left {
  flex: 1.1;
  background: var(--charcoal-deep);
  background-image:
    radial-gradient(circle at 20% 20%, rgba(249,115,22,0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(22,163,74,0.12) 0%, transparent 50%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  position: relative;
  overflow: hidden;
}
.login-left::before {
  content: '';
  position: absolute;
  width: 400px; height: 400px;
  border-radius: 50%;
  border: 60px solid rgba(255,255,255,0.03);
  top: -100px; left: -100px;
}
.login-left::after {
  content: '';
  position: absolute;
  width: 300px; height: 300px;
  border-radius: 50%;
  border: 40px solid rgba(255,255,255,0.03);
  bottom: -80px; right: -80px;
}
.login-left-content { text-align: center; z-index: 1; }
.login-logo {
  width: 180px; height: 180px;
  object-fit: contain;
  background: rgba(255,255,255,0.96);
  border-radius: 20px;
  padding: 12px;
  margin: 0 auto 20px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.4);
}
.login-brand-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--orange);
  margin-bottom: 6px;
}
.login-brand-sub {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.05em;
  margin-bottom: 32px;
}
.login-features { display: flex; flex-direction: column; gap: 10px; text-align: left; }
.lf-item { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,0.7); font-size: 0.85rem; }
.lf-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.lf-dot.orange { background: var(--orange); }
.lf-dot.green { background: var(--green); }

/* RIGHT PANEL */
.login-right {
  flex: 0.9;
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
}
.login-card { width: 100%; max-width: 380px; }
.login-card-logo-sm {
  display: none;
  width: 70px; height: 70px;
  background: var(--border-light);
  border-radius: 12px;
  overflow: hidden;
  margin: 0 auto 20px;
  padding: 6px;
}
.login-card-logo-sm img { width: 100%; height: 100%; object-fit: contain; }
.login-card h2 { font-family: 'Outfit', sans-serif; font-size: 1.6rem; font-weight: 700; color: var(--charcoal); margin-bottom: 5px; }
.login-card-sub { font-size: 0.875rem; color: var(--text-mid); margin-bottom: 28px; }

.fgrp { margin-bottom: 16px; }
.fgrp label {
  display: block; font-size: 0.75rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .04em;
  color: var(--text-mid); margin-bottom: 6px;
}
.finput-wrap { position: relative; display: flex; align-items: center; }
.ficon { position: absolute; left: 11px; font-size: 0.95rem; pointer-events: none; }
.finput-wrap input {
  width: 100%;
  padding: 10px 11px 10px 36px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--border-light);
  color: var(--text);
  font-size: 0.9rem;
  transition: var(--tr);
}
.finput-wrap input:focus { outline: none; border-color: var(--orange); background: #fff; box-shadow: 0 0 0 3px rgba(249,115,22,.12); }
.eye-btn { position: absolute; right: 10px; background: none; border: none; cursor: pointer; color: var(--text-light); }

.login-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; font-size: 0.82rem; }
.chk-lbl { display: flex; align-items: center; gap: 6px; color: var(--text-mid); cursor: pointer; }
.chk-lbl input { accent-color: var(--orange); }
.forgot { color: var(--orange); font-weight: 600; }
.forgot:hover { color: var(--orange-light); }

.btn-login {
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, var(--orange) 0%, #ea580c 100%);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: .03em;
  transition: var(--tr);
  margin-bottom: 14px;
}
.btn-login:hover { background: linear-gradient(135deg, #ea580c 0%, var(--charcoal) 100%); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(249,115,22,.35); }
.login-hint { text-align: center; font-size: 0.78rem; color: var(--text-light); background: var(--border-light); padding: 8px; border-radius: 6px; }

/* ══════════════════════════════════════════════
   APP SHELL LAYOUT
   ══════════════════════════════════════════════ */
#pg-app { min-height: 100vh; width: 100%; }
#pg-app.active { display: flex; }

/* ── SIDEBAR ── */
.sidebar {
  width: var(--sb-w);
  background: var(--charcoal-deep);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0;
  height: 100vh;
  z-index: 200;
  transition: var(--tr);
  box-shadow: 3px 0 16px rgba(0,0,0,0.2);
  overflow-y: auto;
  overflow-x: hidden;
}
/* Orange left border accent */
.sidebar::after {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 100%;
  background: linear-gradient(180deg, var(--orange) 0%, var(--green) 100%);
}
.sb-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  min-height: 72px;
  flex-shrink: 0;
}
.sb-logo { width: 120px; height: auto; background: rgba(255,255,255,0.94); border-radius: 8px; padding: 4px 6px; object-fit: contain; }
.sb-close-btn { display: none; background: none; border: none; color: rgba(255,255,255,0.5); font-size: 1.1rem; cursor: pointer; padding: 4px; }

.sb-nav { flex: 1; padding: 12px 8px; display: flex; flex-direction: column; gap: 2px; }
.sb-section-lbl { font-size: 0.65rem; font-weight: 700; letter-spacing: .1em; color: rgba(255,255,255,0.25); padding: 10px 10px 4px; text-transform: uppercase; }
.sb-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 8px;
  color: rgba(255,255,255,0.6);
  font-size: 0.83rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--tr);
  position: relative;
  white-space: nowrap;
}
.sb-link:hover { background: rgba(255,255,255,0.07); color: #fff; }
.sb-link.active {
  background: linear-gradient(90deg, rgba(249,115,22,.2) 0%, rgba(249,115,22,.08) 100%);
  color: var(--orange);
  font-weight: 600;
  border-left: 2px solid var(--orange);
}
.sb-icon { font-size: 1rem; flex-shrink: 0; width: 20px; text-align: center; }
.sb-txt { flex: 1; }
.sb-badge {
  background: var(--orange);
  color: var(--white);
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 20px;
  min-width: 20px;
  text-align: center;
}

.sb-foot {
  padding: 12px;
  border-top: 1px solid rgba(255,255,255,0.06);
  flex-shrink: 0;
}
.sb-user { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; overflow: hidden; }
.sb-avatar {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, var(--orange) 0%, #ea580c 100%);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: #fff; font-size: 0.9rem;
  flex-shrink: 0;
}
.sb-uinfo { overflow: hidden; }
.sb-uinfo span { display: block; color: #fff; font-size: 0.82rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sb-uinfo small { display: block; color: rgba(255,255,255,0.4); font-size: 0.7rem; }
.sb-logout {
  width: 100%;
  padding: 7px 10px;
  background: rgba(239,68,68,.08);
  color: rgba(255,255,255,0.5);
  border: 1px solid rgba(239,68,68,.15);
  border-radius: 6px;
  font-size: 0.78rem;
  cursor: pointer;
  transition: var(--tr);
  text-align: left;
}
.sb-logout:hover { background: rgba(239,68,68,.2); color: #f87171; }

/* Sidebar Overlay (mobile) */
.sb-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 199;
  backdrop-filter: blur(2px);
}
.sb-overlay.active { display: block; }

/* ── MAIN WRAP ── */
.main-wrap {
  margin-left: var(--sb-w);
  flex: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: var(--tr);
}

/* ── TOPBAR ── */
.topbar {
  height: var(--topbar-h);
  background: var(--white);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  position: sticky;
  top: 0; z-index: 100;
  box-shadow: var(--shadow);
}
.tb-left { display: flex; align-items: center; gap: 14px; }
.hamburger { display: none; background: none; border: none; font-size: 1.3rem; cursor: pointer; color: var(--text-mid); padding: 4px; }
.tb-breadcrumb { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; color: var(--text-mid); }
.tb-bc-home { cursor: pointer; color: var(--orange); font-size: 1rem; }
.tb-bc-sep { color: var(--text-light); }
#tbBcCurrent { font-weight: 600; color: var(--charcoal); }
.tb-right { display: flex; align-items: center; gap: 12px; }
.tb-search-wrap {
  display: flex; align-items: center; gap: 7px;
  background: var(--border-light);
  border: 1.5px solid var(--border);
  border-radius: 24px;
  padding: 6px 14px;
  min-width: 200px;
  transition: var(--tr);
}
.tb-search-wrap:focus-within { border-color: var(--orange); background: #fff; box-shadow: 0 0 0 3px rgba(249,115,22,.1); }
.tb-search-wrap input { border: none; background: transparent; outline: none; font-size: 0.82rem; color: var(--text); width: 100%; }
.tb-date { font-size: 0.75rem; color: var(--text-light); white-space: nowrap; }
.tb-notif { position: relative; cursor: pointer; font-size: 1.1rem; padding: 4px; }
.notif-dot { position: absolute; top: 2px; right: 2px; width: 7px; height: 7px; background: var(--red); border-radius: 50%; border: 2px solid #fff; }
.tb-avatar-wrap { position: relative; }
.tb-user-avatar {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, var(--orange) 0%, #ea580c 100%);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 0.85rem; cursor: pointer;
}
.tb-user-dropdown {
  display: none;
  position: absolute; top: 42px; right: 0;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  padding: 12px;
  min-width: 160px;
  z-index: 200;
  font-size: 0.82rem;
}
.tb-avatar-wrap:hover .tb-user-dropdown { display: block; }
.tud-name { font-weight: 700; color: var(--charcoal); margin-bottom: 2px; }
.tud-role { color: var(--text-light); font-size: 0.75rem; margin-bottom: 8px; }
.tb-user-dropdown hr { border: none; border-top: 1px solid var(--border); margin-bottom: 8px; }
.tb-user-dropdown button { width: 100%; background: none; border: none; text-align: left; cursor: pointer; color: var(--red); padding: 4px 0; font-size: 0.82rem; }

/* ══════════════════════════════════════════════
   PAGE CONTENT
   ══════════════════════════════════════════════ */
.page-content { flex: 1; padding: 20px; }

.pg-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin-bottom: 18px; gap: 12px; flex-wrap: wrap;
}
.pg-title { font-family: 'Outfit', sans-serif; font-size: 1.4rem; font-weight: 700; color: var(--charcoal); }
.pg-sub { font-size: 0.8rem; color: var(--text-light); margin-top: 2px; }
.pg-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ══════════════════════════════════════════════
   BUTTONS
   ══════════════════════════════════════════════ */
.btn-orange {
  padding: 8px 16px;
  background: linear-gradient(135deg, var(--orange) 0%, #ea580c 100%);
  color: #fff; border: none; border-radius: var(--radius-sm);
  font-size: 0.82rem; font-weight: 600; cursor: pointer; transition: var(--tr);
  display: inline-flex; align-items: center; gap: 5px;
}
.btn-orange:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(249,115,22,.4); }
.btn-green {
  padding: 8px 16px;
  background: linear-gradient(135deg, var(--green) 0%, #15803d 100%);
  color: #fff; border: none; border-radius: var(--radius-sm);
  font-size: 0.82rem; font-weight: 600; cursor: pointer; transition: var(--tr);
}
.btn-green:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(22,163,74,.4); }
.btn-outline {
  padding: 8px 16px;
  background: var(--white); color: var(--charcoal);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); font-size: 0.82rem; font-weight: 500;
  cursor: pointer; transition: var(--tr);
}
.btn-outline:hover { border-color: var(--orange); color: var(--orange); }
.btn-danger { padding: 8px 16px; background: var(--red); color: #fff; border: none; border-radius: var(--radius-sm); font-size: 0.82rem; font-weight: 600; cursor: pointer; }
.btn-link { background: none; border: none; color: var(--orange); font-size: 0.8rem; font-weight: 600; cursor: pointer; }
.btn-link:hover { color: var(--green); }
.btn-orange-sm { padding: 5px 12px; background: var(--orange); color: #fff; border: none; border-radius: 6px; font-size: 0.75rem; font-weight: 600; cursor: pointer; }
.btn-outline-sm { padding: 5px 12px; border: 1.5px solid var(--border); background: #fff; border-radius: 6px; font-size: 0.78rem; cursor: pointer; margin-top: 8px; }
.btn-close-sm { background: none; border: none; font-size: 1rem; cursor: pointer; color: var(--text-light); padding: 2px 6px; }
.btn-close-sm:hover { color: var(--red); }
.hidden { display: none !important; }
.mt-12 { margin-top: 12px; }

/* ══════════════════════════════════════════════
   CARD
   ══════════════════════════════════════════════ */
.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px;
  margin-bottom: 16px;
  border: 1px solid var(--border-light);
}
.card.no-pad { padding: 0; }
.card-hd { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.card-hd h3 { font-family: 'Outfit', sans-serif; font-size: 0.95rem; font-weight: 600; color: var(--charcoal); }

/* ══════════════════════════════════════════════
   KPI ROW
   ══════════════════════════════════════════════ */
.kpi-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.kpi-card {
  flex: 1;
  min-width: 100px;
  background: var(--bg-card);
  border-radius: 10px;
  padding: 11px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
  border-left: 3px solid transparent;
  transition: var(--tr);
  position: relative;
  overflow: hidden;
}
.kpi-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.kpi-icon { font-size: 1.2rem; flex-shrink: 0; }
.kpi-info { flex: 1; min-width: 0; }
.kpi-val { font-family: 'Outfit', sans-serif; font-size: 1.3rem; font-weight: 700; color: var(--charcoal); line-height: 1; }
.kpi-lbl { font-size: 0.68rem; color: var(--text-light); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }

/* KPI colors */
.kpi-total   { border-left-color: var(--charcoal); }
.kpi-pending { border-left-color: var(--yellow); }
.kpi-called  { border-left-color: var(--blue); }
.kpi-int     { border-left-color: var(--green); }
.kpi-visit   { border-left-color: var(--purple); }
.kpi-notint  { border-left-color: var(--red); }
.kpi-cb      { border-left-color: var(--orange); }
.kpi-qg      { border-left-color: #14b8a6; }
.kpi-qp      { border-left-color: var(--orange-light); }

/* ══════════════════════════════════════════════
   WORKFLOW STRIP
   ══════════════════════════════════════════════ */
.workflow-strip {
  background: linear-gradient(135deg, var(--charcoal-deep) 0%, var(--charcoal) 100%);
  border-radius: var(--radius);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.wf-label { font-size: 0.72rem; color: rgba(255,255,255,.4); text-transform: uppercase; letter-spacing: .06em; white-space: nowrap; }
.wf-steps { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.wf-step { padding: 5px 12px; border-radius: 20px; font-size: 0.75rem; font-weight: 500; color: rgba(255,255,255,.55); background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.1); white-space: nowrap; }
.wf-step.wf-active { background: var(--orange); color: #fff; border-color: var(--orange); font-weight: 700; }
.wf-arrow { color: rgba(255,255,255,.25); font-size: 0.9rem; }

/* ══════════════════════════════════════════════
   DASHBOARD GRID
   ══════════════════════════════════════════════ */
.dash-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.dash-grid-3 { grid-template-columns: repeat(3, 1fr); }

/* Followup List */
.followup-list { display: flex; flex-direction: column; gap: 8px; }
.fu-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; background: var(--border-light); border-radius: 8px; }
.fu-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; background: var(--orange); }
.fu-info { flex: 1; min-width: 0; }
.fu-client { font-size: 0.82rem; font-weight: 600; color: var(--charcoal); }
.fu-meta { font-size: 0.72rem; color: var(--text-light); }
.fu-empty { text-align: center; padding: 20px; color: var(--text-light); font-size: 0.8rem; }

/* Chart Bars */
.chart-wrap { display: flex; flex-direction: column; gap: 7px; }
.cb-row { display: flex; align-items: center; gap: 8px; }
.cb-lbl { width: 90px; font-size: 0.72rem; color: var(--text-mid); text-align: right; flex-shrink: 0; }
.cb-track { flex: 1; height: 8px; background: var(--border-light); border-radius: 4px; overflow: hidden; }
.cb-fill { height: 100%; border-radius: 4px; transition: width .6s ease; }
.cb-fill.orange { background: linear-gradient(90deg, var(--orange), var(--orange-light)); }
.cb-fill.green  { background: linear-gradient(90deg, var(--green), var(--green-light)); }
.cb-cnt { font-size: 0.72rem; font-weight: 700; color: var(--charcoal); min-width: 20px; }

/* Quotation Summary */
.quot-summary { display: flex; flex-direction: column; gap: 10px; }
.qs-item { display: flex; justify-content: space-between; align-items: center; padding: 8px 12px; border-radius: 8px; }
.qs-item.given { background: var(--green-pale); }
.qs-item.pending { background: var(--orange-pale); }
.qs-lbl { font-size: 0.8rem; font-weight: 600; }
.qs-val { font-size: 1.1rem; font-weight: 700; }
.qs-item.given .qs-lbl { color: var(--green); }
.qs-item.given .qs-val { color: var(--green); }
.qs-item.pending .qs-lbl { color: var(--orange); }
.qs-item.pending .qs-val { color: var(--orange); }

/* ══════════════════════════════════════════════
   FILTER BAR
   ══════════════════════════════════════════════ */
.filter-bar { background: var(--white); border-radius: var(--radius); padding: 14px; margin-bottom: 14px; box-shadow: var(--shadow); border: 1px solid var(--border-light); }
.filter-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.fsearch-wrap { display: flex; align-items: center; gap: 8px; background: var(--border-light); border: 1.5px solid var(--border); border-radius: 24px; padding: 7px 14px; flex: 1; min-width: 200px; transition: var(--tr); }
.fsearch-wrap:focus-within { border-color: var(--orange); background: #fff; }
.fsearch-wrap input { border: none; background: transparent; outline: none; font-size: 0.82rem; width: 100%; color: var(--text); }
.btn-filter { padding: 7px 14px; background: var(--charcoal); color: #fff; border: none; border-radius: 24px; font-size: 0.78rem; font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 6px; }
.btn-filter:hover { background: var(--orange); }
.btn-clear { padding: 7px 12px; background: none; color: var(--text-mid); border: 1.5px solid var(--border); border-radius: 24px; font-size: 0.78rem; cursor: pointer; }
.btn-clear:hover { border-color: var(--red); color: var(--red); }
#filterCountBadge { background: var(--orange); color: #fff; font-size: 0.65rem; font-weight: 700; padding: 1px 5px; border-radius: 10px; }

.filter-panel { display: none; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border); }
.filter-panel.open { display: block; }
.filter-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.fg-item label { display: block; font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--text-light); margin-bottom: 5px; }
.fg-item select, .fg-item input[type="date"] {
  width: 100%; padding: 7px 10px; border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  font-size: 0.8rem; color: var(--text); background: var(--border-light); cursor: pointer; transition: var(--tr);
}
.fg-item select:focus, .fg-item input[type="date"]:focus { outline: none; border-color: var(--orange); background: #fff; }

/* ══════════════════════════════════════════════
   DATA TABLE
   ══════════════════════════════════════════════ */
.tbl-info-bar { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; border-bottom: 1px solid var(--border); font-size: 0.78rem; color: var(--text-mid); }
.tbl-pp { display: flex; align-items: center; gap: 6px; }
.tbl-pp select { padding: 3px 8px; border: 1.5px solid var(--border); border-radius: 6px; font-size: 0.78rem; cursor: pointer; }
.tbl-wrap { overflow-x: auto; }
.dtbl { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
.dtbl th { background: var(--border-light); padding: 9px 11px; text-align: left; font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--text-mid); border-bottom: 2px solid var(--border); white-space: nowrap; }
.dtbl td { padding: 9px 11px; border-bottom: 1px solid var(--border-light); color: var(--text); vertical-align: middle; }
.dtbl tbody tr { transition: var(--tr); }
.dtbl tbody tr:hover { background: rgba(249,115,22,.03); }
.dtbl tbody tr:last-child td { border-bottom: none; }
.dtbl td strong { color: var(--charcoal); }

/* Pagination */
.pagination { display: flex; align-items: center; justify-content: center; gap: 5px; padding: 12px; flex-wrap: wrap; }
.pg-btn { min-width: 30px; height: 30px; padding: 0 8px; border: 1.5px solid var(--border); border-radius: 6px; background: var(--white); color: var(--text); font-size: 0.78rem; cursor: pointer; transition: var(--tr); }
.pg-btn:hover { border-color: var(--orange); color: var(--orange); }
.pg-btn.active { background: var(--orange); color: #fff; border-color: var(--orange); font-weight: 700; }
.pg-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ══════════════════════════════════════════════
   BADGES
   ══════════════════════════════════════════════ */
.badge { padding: 3px 9px; border-radius: 20px; font-size: 0.68rem; font-weight: 700; display: inline-block; white-space: nowrap; }
.badge-Pending         { background: #fef3c7; color: #92400e; }
.badge-Called          { background: #dbeafe; color: #1e40af; }
.badge-Interested      { background: #dcfce7; color: #166534; }
.badge-Visit-Fixed     { background: #ede9fe; color: #5b21b6; }
.badge-Not-Interested  { background: #fee2e2; color: #991b1b; }
.badge-Assigned-to-SP  { background: #e0e7ff; color: #3730a3; }
.badge-Call-Back       { background: #ffedd5; color: #9a3412; }
.badge-Busy            { background: #f1f5f9; color: #475569; }

.src-badge { padding: 2px 7px; border-radius: 4px; font-size: 0.67rem; font-weight: 700; display: inline-block; }
.src-FB        { background: #1877f2; color: #fff; }
.src-Insta     { background: linear-gradient(135deg,#f09433,#dc2743,#bc1888); color: #fff; }
.src-AXOG      { background: var(--charcoal); color: #fff; }
.src-IndiaMART { background: #0fa44a; color: #fff; }
.src-Reference { background: var(--orange); color: #fff; }

.quot-badge-Given   { background: #dcfce7; color: #166534; }
.quot-badge-Pending { background: #ffedd5; color: #9a3412; }

/* ══════════════════════════════════════════════
   FORM STYLES (shared)
   ══════════════════════════════════════════════ */
.form-card { padding: 24px; }
.form-section-title {
  font-family: 'Outfit', sans-serif;
  font-size: 0.85rem; font-weight: 700; color: var(--charcoal);
  padding: 10px 14px; background: var(--border-light);
  border-radius: var(--radius-sm); margin: 0 0 14px;
  border-left: 3px solid var(--orange);
}
.fgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; margin-bottom: 16px; }
.fgrid-3 { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.fgrp label { display: block; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--text-mid); margin-bottom: 5px; }
.fgrp input, .fgrp select, .fgrp textarea {
  width: 100%; padding: 8px 11px; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); font-size: 0.85rem; color: var(--text);
  background: var(--border-light); transition: var(--tr);
}
.fgrp input:focus, .fgrp select:focus, .fgrp textarea:focus {
  outline: none; border-color: var(--orange); background: #fff;
  box-shadow: 0 0 0 3px rgba(249,115,22,.1);
}
.fgrp textarea { resize: vertical; min-height: 72px; }
.fgrp.full { grid-column: 1 / -1; }
.req { color: var(--red); }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 6px; padding-top: 16px; border-top: 1px solid var(--border); }

/* ══════════════════════════════════════════════
   LEAD DETAIL TABS
   ══════════════════════════════════════════════ */
.tab-bar {
  display: flex; gap: 4px; background: var(--white); border-radius: var(--radius); padding: 6px;
  box-shadow: var(--shadow); margin-bottom: 16px; border: 1px solid var(--border-light); flex-wrap: wrap;
}
.tab-btn {
  padding: 8px 16px; border: none; background: transparent; border-radius: 8px;
  font-size: 0.8rem; font-weight: 500; cursor: pointer; color: var(--text-mid); transition: var(--tr);
}
.tab-btn:hover { background: var(--border-light); color: var(--charcoal); }
.tab-btn.active { background: var(--orange); color: #fff; font-weight: 700; }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* Detail Grid */
.detail-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.df-item { padding: 12px 14px; background: var(--bg-card); border-radius: 10px; box-shadow: var(--shadow); border: 1px solid var(--border-light); }
.df-lbl { font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--text-light); margin-bottom: 5px; }
.df-val { font-size: 0.88rem; color: var(--charcoal); font-weight: 500; }
.df-item.df-full { grid-column: 1 / -1; }

/* Activity List */
.activity-list { display: flex; flex-direction: column; gap: 10px; }
.act-item { display: flex; gap: 12px; padding: 12px; background: var(--border-light); border-radius: 10px; }
.act-icon { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1rem; flex-shrink: 0; }
.act-icon.call { background: #dbeafe; }
.act-icon.fup  { background: #dcfce7; }
.act-icon.quot { background: #ffedd5; }
.act-body { flex: 1; }
.act-title { font-size: 0.83rem; font-weight: 600; color: var(--charcoal); }
.act-meta  { font-size: 0.73rem; color: var(--text-light); margin-top: 2px; }
.act-note  { font-size: 0.78rem; color: var(--text-mid); margin-top: 4px; font-style: italic; }
.act-empty { text-align: center; padding: 24px; color: var(--text-light); font-size: 0.82rem; }

/* Conversion Info */
.conversion-info { padding: 16px; }
.conv-timeline { display: flex; flex-direction: column; gap: 0; }
.conv-step { display: flex; gap: 14px; }
.conv-dot-col { display: flex; flex-direction: column; align-items: center; }
.conv-dot { width: 14px; height: 14px; border-radius: 50%; background: var(--border); border: 2px solid var(--border); flex-shrink: 0; margin-top: 3px; }
.conv-dot.done { background: var(--green); border-color: var(--green); }
.conv-dot.active { background: var(--orange); border-color: var(--orange); }
.conv-line { width: 2px; flex: 1; background: var(--border); min-height: 24px; }
.conv-info { padding-bottom: 18px; }
.conv-stage { font-size: 0.82rem; font-weight: 600; color: var(--text); }
.conv-date  { font-size: 0.72rem; color: var(--text-light); margin-top: 2px; }



/* ══════════════════════════════════════════════
   TEAM MANAGEMENT
   ══════════════════════════════════════════════ */
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.team-card {
  background: var(--bg-card); border-radius: var(--radius); box-shadow: var(--shadow);
  border: 1px solid var(--border-light); overflow: hidden; transition: var(--tr);
}
.team-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.tc-top {
  padding: 20px; text-align: center;
  background: linear-gradient(135deg, var(--charcoal-deep) 0%, var(--charcoal) 100%);
}
.tc-avatar {
  width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; font-weight: 700; color: var(--charcoal); border: 3px solid rgba(255,255,255,.2);
}
.tc-name { font-family: 'Outfit', sans-serif; font-size: 1rem; font-weight: 700; color: #fff; margin-bottom: 4px; }
.tc-role-badge {
  display: inline-block; padding: 3px 12px; border-radius: 20px; font-size: 0.7rem; font-weight: 700;
}
.role-admin     { background: var(--orange); color: #fff; }
.role-executive { background: var(--blue); color: #fff; }
.role-manager   { background: var(--green); color: #fff; }
.tc-body { padding: 14px; }
.tc-info-row { display: flex; align-items: center; gap: 8px; font-size: 0.78rem; color: var(--text-mid); margin-bottom: 6px; }
.tc-foot { padding: 10px 14px; border-top: 1px solid var(--border-light); display: flex; justify-content: space-between; align-items: center; }
.tc-status { font-size: 0.72rem; font-weight: 700; }
.tc-status.active   { color: var(--green); }
.tc-status.inactive { color: var(--text-light); }

/* ══════════════════════════════════════════════
   IMPORT/EXPORT
   ══════════════════════════════════════════════ */
.ie-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.ie-card { text-align: center; padding: 28px 20px; }
.ie-icon { font-size: 2.5rem; margin-bottom: 12px; }
.ie-card h3 { font-family: 'Outfit', sans-serif; font-size: 1rem; font-weight: 700; color: var(--charcoal); margin-bottom: 6px; }
.ie-card p { font-size: 0.8rem; color: var(--text-light); margin-bottom: 14px; }
.drop-zone { border: 2px dashed var(--border); border-radius: var(--radius); padding: 24px; cursor: pointer; transition: var(--tr); background: var(--border-light); }
.drop-zone:hover, .drop-zone.dz-over { border-color: var(--orange); background: var(--orange-pale); }
.drop-zone div { font-size: 1.6rem; margin-bottom: 6px; }
.drop-zone p { margin: 0; font-size: 0.82rem; color: var(--text-mid); }
.drop-zone small { color: var(--text-light); font-size: 0.72rem; }
.ie-msg { margin-top: 10px; padding: 8px 12px; border-radius: 8px; font-size: 0.8rem; }
.ie-msg.success { background: #dcfce7; color: #166534; }
.ie-msg.error   { background: #fee2e2; color: #991b1b; }
.export-stat { background: var(--border-light); padding: 10px 14px; border-radius: 8px; font-size: 0.8rem; color: var(--text-mid); margin-top: 8px; }

/* ══════════════════════════════════════════════
   MODALS
   ══════════════════════════════════════════════ */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(26,37,53,.55);
  backdrop-filter: blur(4px);
  z-index: 500;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  opacity: 0; pointer-events: none;
  transition: opacity .25s ease;
}
.modal-backdrop.open { opacity: 1; pointer-events: all; }
.modal-box {
  background: var(--white);
  border-radius: 16px;
  width: 100%; max-width: 540px; max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 64px rgba(0,0,0,.25);
  transform: scale(.95) translateY(16px);
  transition: transform .28s cubic-bezier(.34,1.56,.64,1);
}
.modal-backdrop.open .modal-box { transform: scale(1) translateY(0); }
.modal-hd {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(90deg, var(--charcoal-deep) 0%, var(--charcoal) 100%);
  border-radius: 16px 16px 0 0;
}
.modal-hd h3 { font-family: 'Outfit', sans-serif; font-size: 1rem; font-weight: 700; color: #fff; }
.modal-hd button { background: rgba(255,255,255,.15); border: none; color: #fff; width: 28px; height: 28px; border-radius: 6px; cursor: pointer; font-size: 0.9rem; }
.modal-box form { padding: 18px; }
.modal-ft { display: flex; justify-content: flex-end; gap: 8px; padding-top: 14px; }
.confirm-box { padding: 24px; text-align: center; max-width: 360px; }
.confirm-icon-wrap { font-size: 3rem; margin-bottom: 12px; }
.confirm-box h3 { font-size: 1.05rem; font-weight: 700; color: var(--charcoal); margin-bottom: 6px; }
.confirm-box p { font-size: 0.8rem; color: var(--text-light); margin-bottom: 16px; }
.confirm-box .modal-ft { justify-content: center; }

/* ══════════════════════════════════════════════
   ACTION BUTTONS IN TABLE
   ══════════════════════════════════════════════ */
.act-btns { display: flex; gap: 4px; }
.ab { width: 27px; height: 27px; border: none; border-radius: 6px; cursor: pointer; font-size: 0.78rem; display: flex; align-items: center; justify-content: center; transition: var(--tr); }
.ab-view { background: #dbeafe; } .ab-view:hover  { background: #bfdbfe; }
.ab-edit { background: #fef3c7; } .ab-edit:hover  { background: #fde68a; }
.ab-del  { background: #fee2e2; } .ab-del:hover   { background: #fecaca; }
.ab-quot { background: #dcfce7; } .ab-quot:hover  { background: #bbf7d0; }

/* ══════════════════════════════════════════════
   TOAST
   ══════════════════════════════════════════════ */
.toast {
  position: fixed; bottom: 80px; right: 16px;
  background: var(--charcoal-deep);
  color: #fff; padding: 11px 18px; border-radius: 10px;
  font-size: 0.83rem; font-weight: 500;
  z-index: 9999; box-shadow: var(--shadow-lg);
  animation: toastIn .3s ease;
  max-width: 300px;
}
.toast.success { background: var(--green); }
.toast.error   { background: var(--red); }
.toast.warning { background: var(--yellow); color: var(--charcoal); }
@keyframes toastIn { from { transform: translateY(10px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* ══════════════════════════════════════════════
   MOBILE FOOTER NAVBAR  (hidden on desktop)
   ══════════════════════════════════════════════ */
.mob-footer-nav {
  display: none; /* hidden on desktop */
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: 62px;
  background: var(--white);
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.10);
  z-index: 300;
  align-items: center;
  justify-content: space-around;
  padding: 0 4px;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.mob-fn-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  flex: 1;
  height: 100%;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 4px;
  position: relative;
  transition: var(--tr);
  color: var(--text-light);
}
.mob-fn-item.active { color: var(--orange); }
.mob-fn-item:active { transform: scale(0.92); }
.mob-fn-icon { font-size: 1.3rem; line-height: 1; }
.mob-fn-lbl  { font-size: 0.6rem; font-weight: 600; letter-spacing: 0.02em; text-transform: uppercase; }
.mob-fn-badge {
  position: absolute;
  top: 6px; right: 18px;
  background: var(--orange);
  color: #fff;
  font-size: 0.55rem;
  font-weight: 700;
  padding: 1px 4px;
  border-radius: 10px;
  min-width: 14px;
  text-align: center;
  line-height: 1.4;
}
/* Active indicator dot above icon */
.mob-fn-item.active .mob-fn-icon::before {
  content: '';
  position: absolute;
  top: 4px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px; height: 4px;
  background: var(--orange);
  border-radius: 50%;
}
/* FAB center button */
.mob-fn-fab {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, var(--orange) 0%, #ea580c 100%);
  border: none;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: 1.6rem;
  font-weight: 300;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(249,115,22,0.5);
  transition: var(--tr);
  flex-shrink: 0;
  margin-bottom: 10px;
  line-height: 1;
}
.mob-fn-fab:active { transform: scale(0.92); }

/* ── Mobile Profile Bottom Sheet ── */
.mob-sheet-backdrop {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 400;
  backdrop-filter: blur(3px);
  align-items: flex-end;
}
.mob-sheet-backdrop.open { display: flex; }
.mob-sheet {
  background: var(--white);
  border-radius: 20px 20px 0 0;
  width: 100%;
  padding: 8px 0 24px;
  box-shadow: 0 -8px 32px rgba(0,0,0,0.2);
  animation: sheetUp .3s cubic-bezier(.34,1.56,.64,1);
  padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
}
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.mob-sheet-handle {
  width: 36px; height: 4px;
  background: var(--border);
  border-radius: 2px;
  margin: 0 auto 16px;
}
.mob-sheet-header {
  display: flex; align-items: center; gap: 14px;
  padding: 0 20px 16px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}
.mob-sheet-avatar {
  width: 48px; height: 48px;
  background: linear-gradient(135deg, var(--orange) 0%, #ea580c 100%);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; font-weight: 700; color: #fff;
  flex-shrink: 0;
}
.mob-sheet-name { font-family: 'Outfit', sans-serif; font-size: 1rem; font-weight: 700; color: var(--charcoal); }
.mob-sheet-role { font-size: 0.75rem; color: var(--text-light); margin-top: 2px; }
.mob-sheet-links { display: flex; flex-direction: column; padding: 4px 12px; gap: 2px; }
.mob-sheet-links button {
  background: none; border: none; text-align: left;
  padding: 13px 10px; font-size: 0.9rem; color: var(--charcoal);
  cursor: pointer; border-radius: 10px; transition: var(--tr);
  display: flex; align-items: center; gap: 10px;
}
.mob-sheet-links button:hover { background: var(--border-light); }
.mob-sheet-logout {
  margin: 8px 20px 0;
  width: calc(100% - 40px);
  padding: 12px;
  background: #fee2e2;
  color: var(--red);
  border: none; border-radius: 10px;
  font-size: 0.9rem; font-weight: 600; cursor: pointer;
  transition: var(--tr);
}
.mob-sheet-logout:hover { background: #fecaca; }

/* ══════════════════════════════════════════════
   RESPONSIVE — TABLET (≤1024px)
   ══════════════════════════════════════════════ */
@media (max-width: 1024px) {
  .dash-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .kpi-row { gap: 8px; }
  .kpi-card { min-width: 110px; }
}

/* ══════════════════════════════════════════════
   RESPONSIVE — MOBILE (≤768px)
   Key rules: sidebar slides off, footer nav shows,
   main gets bottom padding for footer bar
   ══════════════════════════════════════════════ */
@media (max-width: 768px) {
  /* ── Sidebar: slide off-canvas ── */
  .sidebar { transform: translateX(-100%); box-shadow: none; }
  .sidebar.open { transform: translateX(0); box-shadow: 4px 0 24px rgba(0,0,0,0.3); }
  .sb-close-btn { display: flex !important; }

  /* ── Main: no left offset ── */
  .main-wrap { margin-left: 0 !important; padding-bottom: 62px; }

  /* ── Topbar ── */
  .hamburger { display: block; }
  .tb-search-wrap { display: none; }
  .tb-date { display: none; }
  .tb-notif { display: none; }
  .topbar { padding: 0 14px; }

  /* ── Mobile footer nav: show ── */
  .mob-footer-nav { display: flex; }

  /* ── Toast above footer ── */
  .toast { bottom: 74px; right: 12px; left: 12px; right: 12px; max-width: unset; font-size: 0.8rem; }

  /* ── Login page ── */
  .login-left { display: none; }
  .login-right { flex: 1; padding: 28px 20px; justify-content: flex-start; padding-top: 40px; }
  .login-card-logo-sm { display: block; }
  .login-card { max-width: 100%; }

  /* ── Dashboard grids ── */
  .dash-grid   { grid-template-columns: 1fr; }
  .dash-grid-3 { grid-template-columns: 1fr; }

  /* ── KPI row: 2 per row on mobile ── */
  .kpi-row { gap: 8px; }
  .kpi-card { flex: 0 0 calc(50% - 4px); min-width: unset; }

  /* ── Workflow strip ── */
  .workflow-strip { padding: 10px 12px; gap: 6px; }
  .wf-step { padding: 4px 8px; font-size: 0.68rem; }

  /* ── Filter bar ── */
  .filter-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .fsearch-wrap { min-width: 100%; }

  /* ── Forms ── */
  .fgrid  { grid-template-columns: 1fr; gap: 12px; }
  .fgrid-3{ grid-template-columns: 1fr; }
  .form-card { padding: 16px; }
  .form-section-title { font-size: 0.8rem; padding: 8px 12px; }

  /* ── Tables ── */
  .tbl-wrap { -webkit-overflow-scrolling: touch; }

  /* ── Quotation ── */
  .quot-items-header { grid-template-columns: 2fr 60px 90px 32px; }
  .quot-item-row     { grid-template-columns: 2fr 60px 90px 32px; }
  .quot-items-header span:nth-child(4),
  .quot-items-header span:nth-child(5),
  .quot-item-row > *:nth-child(4),
  .quot-item-row > *:nth-child(5) { display: none; }

  /* ── Import/Export ── */
  .ie-grid { grid-template-columns: 1fr; }

  /* ── Team & Products ── */
  .team-grid    { grid-template-columns: 1fr 1fr; gap: 12px; }
  .product-grid { grid-template-columns: 1fr 1fr; gap: 12px; }

  /* ── Page content padding ── */
  .page-content { padding: 12px 12px 80px; }

  /* ── Lead detail tabs: scrollable ── */
  .tab-bar { overflow-x: auto; flex-wrap: nowrap; gap: 2px; padding: 5px; }
  .tab-bar::-webkit-scrollbar { display: none; }
  .tab-btn { flex-shrink: 0; padding: 7px 12px; font-size: 0.75rem; }

  /* ── Detail grid ── */
  .detail-grid { grid-template-columns: 1fr 1fr; gap: 8px; }

  /* ── Page header ── */
  .pg-header { gap: 8px; }
  .pg-title { font-size: 1.2rem; }
  .pg-actions { gap: 6px; }
  .pg-actions .btn-orange,
  .pg-actions .btn-outline,
  .pg-actions .btn-green { padding: 7px 12px; font-size: 0.78rem; }

  /* ── Modal ── */
  .modal-box { border-radius: 16px 16px 0 0; max-height: 88vh; }
  .modal-backdrop { align-items: flex-end; padding: 0; }
  .confirm-box { border-radius: 16px 16px 0 0; max-width: 100%; }
}

/* ══════════════════════════════════════════════
   RESPONSIVE — SMALL PHONES (≤480px)
   ══════════════════════════════════════════════ */
@media (max-width: 480px) {
  /* ── KPI: 2 per row ── */
  .kpi-card { flex: 0 0 calc(50% - 4px); padding: 9px 10px; }
  .kpi-val  { font-size: 1.2rem; }
  .kpi-lbl  { font-size: 0.62rem; }
  .kpi-icon { font-size: 1rem; }

  /* ── Single column forms ── */
  .fgrid { grid-template-columns: 1fr; }
  .filter-grid { grid-template-columns: 1fr; }

  /* ── Team & Products: single col ── */
  .team-grid    { grid-template-columns: 1fr; }
  .product-grid { grid-template-columns: 1fr; }

  /* ── Quotation items: minimal ── */
  .quot-items-header { grid-template-columns: 1fr 55px 80px 32px; }
  .quot-item-row     { grid-template-columns: 1fr 55px 80px 32px; }

  /* ── Topbar ── */
  .topbar { padding: 0 10px; }
  .tb-breadcrumb { font-size: 0.78rem; }

  /* ── Detail grid: single col ── */
  .detail-grid { grid-template-columns: 1fr; }

  /* ── Page actions stack ── */
  .pg-actions { flex-direction: row; flex-wrap: wrap; }

  /* ── Activity items ── */
  .act-item { flex-direction: column; gap: 6px; }
  .act-icon { width: 28px; height: 28px; font-size: 0.85rem; }
}

/* Scrollbar */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: var(--border-light); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-light); }


