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

:root {
  --primary: #2563eb;
  --primary-dark: #1e40af;
  --primary-light: #eff6ff;
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  --info: #06b6d4;
  --purple: #8b5cf6;
  --purple-light: #f5f3ff;
  --bg: #f1f5f9;
  --card: #ffffff;
  --border: #e2e8f0;
  --text: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --sidebar-bg: #0f172a;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,.08);
  --shadow-lg: 0 20px 40px rgba(0,0,0,.12);
}

/* IE11/Windows 7 fallbacks */
body { background: #f1f5f9; color: #0f172a; }
.btn-primary { background: #2563eb; }
.btn-primary:hover { background: #1e40af; }
.btn-success { background: #10b981; }
.btn-danger { background: #ef4444; }
.btn-ghost { background: #f1f5f9; color: #0f172a; border: 1px solid #e2e8f0; }
.btn-ghost:hover { background: #e2e8f0; }
.card { background: #ffffff; border-radius: 16px; box-shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06); }
.sidebar { background: #0f172a; }
.topbar { background: #ffffff; border-bottom: 1px solid #e2e8f0; }
.form-input, .form-select, .form-textarea { border: 1px solid #e2e8f0; background: #fff; color: #0f172a; }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: #2563eb; }

body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.6; -webkit-font-smoothing: antialiased; }

/* Emoji / symbol icons — consistent rendering on Windows 7 Chrome & Android WebView */
.nav-icon, .nav-icon-wrap, .menu-btn, .empty-icon, .kpi-icon {
  font-family: "Segoe UI Emoji", "Segoe UI Symbol", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
  line-height: 1;
}

::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

/* ── LAYOUT ── */
.app-layout { display: flex; height: 100vh; overflow: hidden; }
.main-wrapper { flex: 1; display: flex; flex-direction: column; overflow: hidden; }

/* ── SIDEBAR ── */
.sidebar { width: 250px; background: var(--sidebar-bg); display: flex; flex-direction: column; flex-shrink: 0; overflow: hidden; transition: transform .25s ease; }
.sidebar-logo { display: flex; align-items: center; gap: 12px; padding: 20px 16px; border-bottom: 1px solid #1e293b; }
.logo-mark { width: 38px; height: 38px; background: linear-gradient(135deg,#3b82f6,#1d4ed8); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.logo-text { color: #fff; font-weight: 800; font-size: 15px; white-space: nowrap; }
.logo-sub { color: #475569; font-size: 11px; }
.sidebar-nav { flex: 1; padding: 10px; overflow-y: auto; display: flex; flex-direction: column; gap: 2px; }
.nav-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; color: #64748b; font-size: 13px; font-weight: 500; text-decoration: none; transition: background-color .15s, color .15s; white-space: nowrap; }
.nav-item:hover { background: #1e293b; color: #cbd5e1; }
.nav-item.active { background: #1e40af; color: #fff; }
.nav-icon { font-size: 17px; flex-shrink: 0; }
.nav-badge { margin-left: auto; background: var(--danger); color: #fff; font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 10px; }
.nav-badge.warn { background: var(--warning); }
.sidebar-footer { padding: 14px 12px; border-top: 1px solid #1e293b; }
.user-card { display: flex; align-items: center; gap: 10px; padding: 10px; background: #1e293b; border-radius: 8px; margin-bottom: 8px; }
.user-card-info { flex: 1; overflow: hidden; }
.user-card-name { color: #e2e8f0; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-card-role { color: #475569; font-size: 11px; text-transform: capitalize; }
.btn-logout { width: 100%; padding: 8px; background: transparent; border: 1px solid #1e293b; border-radius: 8px; color: #475569; cursor: pointer; font-size: 12px; font-family: inherit; transition: background-color .15s, color .15s, border-color .15s; text-align: center; display: block; text-decoration: none; }
.btn-logout:hover { background: #1e293b; color: #94a3b8; }
.sidebar-overlay { display: none; position: fixed; top: 0; right: 0; bottom: 0; left: 0; background: rgba(0,0,0,.45); z-index: 299; }
.sidebar-overlay.show { display: block; }

/* ── TOPBAR ── */
.topbar { height: 60px; background: var(--card); border-bottom: 1px solid var(--border); display: flex; align-items: center; padding: 0 24px; gap: 16px; flex-shrink: 0; }
.menu-btn { background: none; border: none; font-size: 20px; cursor: pointer; color: var(--text-muted); padding: 4px; display: none; }
.search-wrap { position: relative; flex: 1; max-width: 380px; }
.search-wrap input { width: 100%; padding: 9px 12px 9px 38px; border: 1px solid var(--border); border-radius: var(--radius); font-size: 13px; font-family: inherit; background: var(--bg); color: var(--text); outline: none; }
.search-wrap input:focus { border-color: var(--primary); background: #fff; }
.search-icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text-light); font-size: 16px; }
.topbar-right { display: flex; align-items: center; gap: 12px; margin-left: auto; }

/* ── BUTTONS ── */
.btn { display: inline-flex; align-items: center; gap: 6px; padding: 9px 18px; border: none; border-radius: var(--radius); font-size: 13px; font-weight: 600; font-family: inherit; cursor: pointer; transition: background-color .15s, color .15s, border-color .15s, box-shadow .15s; white-space: nowrap; text-decoration: none; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-success { background: var(--success); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-ghost { background: var(--bg); color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--border); }
.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn-icon { padding: 8px; border-radius: 8px; }

/* ── PAGE ── */
.page { flex: 1; overflow-y: auto; padding: 24px; }
.page-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 24px; gap: 16px; flex-wrap: wrap; }
.page-title { font-size: 22px; font-weight: 800; }
.page-subtitle { font-size: 13px; color: var(--text-muted); margin-top: 2px; }

/* ── CARDS ── */
.card { background: var(--card); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: 20px; }
.card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.card-title { font-size: 14px; font-weight: 700; }

/* ── KPI ── */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(180px,1fr)); gap: 16px; margin-bottom: 24px; }
.kpi-card { background: var(--card); border-radius: var(--radius-lg); padding: 20px; box-shadow: var(--shadow); border-left: 4px solid var(--primary); }
.kpi-card.green  { border-left-color: var(--success); }
.kpi-card.amber  { border-left-color: var(--warning); }
.kpi-card.red    { border-left-color: var(--danger); }
.kpi-card.purple { border-left-color: var(--purple); }
.kpi-icon  { font-size: 24px; margin-bottom: 10px; }
.kpi-value { font-size: 30px; font-weight: 800; line-height: 1; margin-bottom: 4px; }
.kpi-label { font-size: 12px; color: var(--text-muted); font-weight: 500; text-transform: uppercase; letter-spacing: .5px; }
.kpi-sub   { font-size: 12px; color: var(--success); font-weight: 600; margin-top: 4px; }

/* ── GRIDS ── */
.grid-2    { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3    { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fit,minmax(280px,1fr)); gap: 20px; }

/* ── TABLE ── */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
thead tr { background: var(--bg); }
th { padding: 11px 14px; text-align: left; font-size: 11px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: .5px; white-space: nowrap; }
td { padding: 12px 14px; border-bottom: 1px solid #f1f5f9; vertical-align: middle; }
tr:hover td { background: #fafbff; }
tr:last-child td { border-bottom: none; }

/* ── BADGES ── */
.badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.s-new              { background:#eef2ff; color:#4338ca; }
.s-contacted        { background:#fffbeb; color:#92400e; }
.s-Details-Shared     { background:#ecfdf5; color:#047857; }
.s-interested       { background:#eff6ff; color:#1e40af; }
.s-visit-scheduled  { background:#f5f3ff; color:#5b21b6; }
.s-visit-done       { background:#ecfeff; color:#155e75; }
.s-negotiation      { background:#fff7ed; color:#9a3412; }
.s-booked           { background:#ecfdf5; color:#065f46; }
.s-lost             { background:#fef2f2; color:#991b1b; }
.s-available        { background:#ecfdf5; color:#065f46; }
.s-blocked          { background:#fffbeb; color:#92400e; }
.s-sold             { background:#eef2ff; color:#4338ca; }

/* ── AVATAR ── */
.avatar { border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0; color: #fff; }

/* ── FILTERS ── */
.filters-bar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; padding: 14px 16px; background: var(--card); border-radius: var(--radius-lg); box-shadow: var(--shadow); margin-bottom: 16px; }
.filter-select, .filter-input { padding: 7px 12px; border: 1px solid var(--border); border-radius: 8px; font-size: 13px; font-family: inherit; background: var(--bg); color: var(--text); outline: none; }
.filter-select:focus, .filter-input:focus { border-color: var(--primary); }

/* ── KANBAN ── */
.kanban-board { display: flex; gap: 14px; overflow-x: auto; padding-bottom: 16px; align-items: flex-start; min-height: 0; }
.kanban-col { min-width: 240px; max-width: 240px; background: var(--bg); border-radius: var(--radius-lg); overflow: hidden; }
.kanban-col-header { padding: 12px 14px; display: flex; align-items: center; justify-content: space-between; }
.kanban-col-title { font-size: 12px; font-weight: 700; }
.kanban-col-count { font-size: 11px; font-weight: 700; background: #fff; padding: 2px 8px; border-radius: 10px; color: var(--text-muted); }
.kanban-cards { padding: 8px; display: flex; flex-direction: column; gap: 8px; min-height: 120px; max-height: calc(100vh - 280px); overflow-y: auto; }
.kanban-card { background: #fff; border-radius: var(--radius); padding: 12px; box-shadow: var(--shadow); cursor: pointer; transition: box-shadow .15s; border-left: 3px solid transparent; }
.kanban-card:hover { box-shadow: var(--shadow-md); }
@supports (transform: translateY(-1px)) {
  .kanban-card { transition: box-shadow .15s, transform .15s; }
  .kanban-card:hover { transform: translateY(-1px); }
}
.kanban-card-name { font-weight: 600; font-size: 13px; margin-bottom: 3px; }
.kanban-card-meta { font-size: 11px; color: var(--text-muted); }
.kanban-card-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }

/* ── TIMELINE ── */
.timeline { padding-left: 28px; position: relative; }
.timeline::before { content:''; position:absolute; left:6px; top:0; bottom:0; width:2px; background:var(--border); }
.timeline-item { position: relative; margin-bottom: 20px; }
.timeline-item::before { content:''; position:absolute; left:-24px; top:4px; width:10px; height:10px; border-radius:50%; background:var(--primary); border:2px solid #fff; box-shadow:0 0 0 2px var(--border); }
.timeline-time { font-size: 11px; color: var(--text-light); margin-bottom: 3px; }
.timeline-text { font-size: 13px; }
.timeline-user { font-size: 11px; color: var(--text-muted); margin-top: 2px; }

/* ── ALERTS ── */
.alert-bar { display: flex; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.alert { flex:1; min-width:200px; display:flex; align-items:center; gap:10px; padding:12px 16px; border-radius:var(--radius); font-size:13px; }
.alert-danger  { background: var(--danger-light);  border: 1px solid #fecaca; }
.alert-warning { background: var(--warning-light); border: 1px solid #fed7aa; }
.alert-title { font-weight: 700; }
.alert-danger  .alert-title { color: var(--danger); }
.alert-warning .alert-title { color: var(--warning); }
.alert-sub { font-size: 11px; color: var(--text-muted); }

/* ── MODAL ── */
.modal-backdrop { position:fixed; top:0; right:0; bottom:0; left:0; background:rgba(15,23,42,.55); display:flex; align-items:center; justify-content:center; z-index:500; padding:20px; }
.modal { background:#fff; border-radius:20px; width:100%; max-width:560px; max-height:90vh; overflow-y:auto; box-shadow:var(--shadow-lg); }
.modal-lg { max-width: 720px; }
.modal-header { display:flex; align-items:center; justify-content:space-between; padding:20px 24px; border-bottom:1px solid var(--border); }
.modal-title { font-size: 17px; font-weight: 700; }
.modal-close { background:var(--bg); border:none; border-radius:8px; padding:6px 10px; cursor:pointer; font-size:16px; color:var(--text-muted); }
.modal-body { padding: 24px; }
.modal-footer { padding:16px 24px; border-top:1px solid var(--border); display:flex; gap:10px; justify-content:flex-end; }

/* ── FORMS ── */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-full { grid-column: 1 / -1; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 12px; font-weight: 600; color: var(--text-muted); }
.form-input, .form-select, .form-textarea { padding:9px 12px; border:1px solid var(--border); border-radius:8px; font-size:13px; font-family:inherit; color:var(--text); background:#fff; transition:border-color .15s; outline:none; }
.form-input:focus, .form-select:focus, .form-textarea:focus { border-color: var(--primary); }
.form-textarea { resize: vertical; min-height: 80px; }

/* ── PROGRESS ── */
.progress-bar { background: var(--border); border-radius: 4px; height: 6px; overflow: hidden; }
.progress-fill { height: 100%; border-radius: 4px; background: var(--primary); transition: width .4s ease; }

/* ── EMPTY STATE ── */
.empty-state { text-align: center; padding: 60px 20px; }
.empty-icon  { font-size: 56px; opacity: .25; margin-bottom: 14px; }
.empty-title { font-size: 16px; font-weight: 700; margin-bottom: 6px; }
.empty-text  { font-size: 13px; color: var(--text-muted); margin-bottom: 20px; }

/* ── SPINNER ── */
.spinner { width:36px; height:36px; border:3px solid var(--border); border-top-color:var(--primary); border-radius:50%; animation:spin .7s linear infinite; margin:60px auto; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── LOGIN ── */
.login-page { min-height:100vh; display:flex; align-items:center; justify-content:center; background:linear-gradient(135deg,#1e3a8a 0%,#1e40af 50%,#2563eb 100%); }
.login-card { background:#fff; border-radius:20px; padding:40px; width:100%; max-width:420px; box-shadow:var(--shadow-lg); }
.login-logo { text-align:center; margin-bottom:32px; }
.login-logo .logo-mark { width:56px; height:56px; font-size:26px; margin:0 auto 14px; }
.login-logo h1 { font-size:22px; font-weight:800; }
.login-logo p { color:var(--text-muted); font-size:13px; margin-top:4px; }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) { .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 768px) {
  .sidebar { position:fixed; left:0; top:0; bottom:0; z-index:300; transform:translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .menu-btn { display: block; }
  .page { padding: 16px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .topbar { padding: 0 16px; }
}
@media (max-width: 480px) {
  .kpi-grid { grid-template-columns: 1fr; }
  .page-header { flex-direction: column; }
  .filters-bar { flex-direction: column; }
}

/* ── MOBILE PWA ── */
@media (max-width: 768px) {

  /* ── App Header (replaces topbar on mobile) ── */
  .topbar {
    height: 56px;
    padding: 0 16px;
    padding-top: 0;
    padding-top: env(safe-area-inset-top, 0);
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
    z-index: 200;
  }
  .topbar .search-wrap { display: none; }
  .topbar .menu-btn { display: none; }
  .topbar-right .topbar-date { display: none; }
  #mobilePageTitle { display: block !important; flex: 1; }

  /* ── Page ── */
  .page {
    padding: 12px 14px;
    padding-bottom: 72px;
    padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px));
  }

  /* ── Sidebar hidden on mobile ── */
  .sidebar { display: none !important; }

  /* ── Bottom Nav ── */
  .mobile-nav {
    display: flex;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: #fff;
    z-index: 400;
    border-top: 1px solid #e2e8f0;
    padding: 6px 4px;
    padding-bottom: calc(6px + env(safe-area-inset-bottom, 6px));
    box-shadow: 0 -4px 20px rgba(0,0,0,.06);
  }
  .mobile-nav a {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: #94a3b8;
    text-decoration: none;
    font-size: 10px;
    font-weight: 600;
    padding: 4px 2px;
    border-radius: 10px;
    transition: color .15s, background-color .15s;
    min-width: 0;
    max-width: 72px;
  }
  .mobile-nav a .nav-icon-wrap {
    width: 36px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    transition: background .15s;
    font-size: 18px;
  }
  .mobile-nav a.active { color: var(--primary); }
  .mobile-nav a.active .nav-icon-wrap {
    background: var(--primary-light);
  }
  .mobile-nav a.logout-link { color: #ef4444; }
  .mobile-nav a.logout-link .nav-icon-wrap { font-size: 18px; }

  /* ── Cards on mobile ── */
  .card { border-radius: 14px; padding: 16px; }
  .kpi-card { border-radius: 14px; padding: 16px; }
  .kpi-grid { grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
  .kpi-value { font-size: 26px; }

  /* ── Page header ── */
  .page-header { margin-bottom: 16px; }
  .page-title { font-size: 20px; }

  /* ── Lead cards ── */
  .lead-card { border-radius: 14px; }

  /* ── Modals become full-screen sheets ── */
  .modal-backdrop { align-items: flex-end; padding: 0; }
  .modal {
    border-radius: 20px 20px 0 0;
    max-height: 92vh;
    max-width: 100%;
  }
}
@media (min-width: 769px) {
  .mobile-nav { display: none; }
}

/* ── LEAD CARDS (mobile) ── */
.lead-cards { display: none; flex-direction: column; gap: 10px; }
.lead-card { background: #fff; border-radius: 14px; box-shadow: var(--shadow); padding: 14px; border-left: 4px solid var(--primary); }
.lead-card-top { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.lead-card-info { flex: 1; min-width: 0; }
.lead-card-name { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lead-card-phone { font-size: 12px; color: var(--text-muted); margin-top: 1px; }
.lead-card-meta { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.lead-card-actions { display: flex; gap: 8px; }
.lead-card-actions a, .lead-card-actions button { flex: 1; display: flex; align-items: center; justify-content: center; gap: 5px; padding: 8px; border-radius: 8px; font-size: 12px; font-weight: 600; border: none; cursor: pointer; font-family: inherit; text-decoration: none; }
.lca-call { background: #ecfdf5; color: #065f46; }
.lca-wa   { background: #f0fdf4; color: #16a34a; }
.lca-edit { background: var(--bg); color: var(--text); border: 1px solid var(--border) !important; }

/* ── FILTER CHIPS ── */
.chip-bar { display: none; gap: 8px; overflow-x: auto; padding: 0 0 6px; -ms-overflow-style: none; scrollbar-width: none; }
.chip-bar::-webkit-scrollbar { display: none; width: 0; height: 0; }
.chip { padding: 6px 14px; border-radius: 20px; font-size: 12px; font-weight: 600; border: 1.5px solid var(--border); background: #fff; color: var(--text-muted); cursor: pointer; white-space: nowrap; text-decoration: none; }
.chip.active { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ── BOTTOM SHEET ── */
.sheet-backdrop { display: none; position: fixed; top: 0; right: 0; bottom: 0; left: 0; background: rgba(15,23,42,.5); z-index: 600; align-items: flex-end; }
.sheet-backdrop.open { display: flex; }
.sheet { background: #fff; border-radius: 20px 20px 0 0; width: 100%; max-height: 92vh; overflow-y: auto; padding: 0; padding-bottom: env(safe-area-inset-bottom, 0); }
.sheet-handle { width: 40px; height: 4px; background: #e2e8f0; border-radius: 2px; margin: 12px auto 0; }
.sheet-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.sheet-title { font-size: 16px; font-weight: 700; }
.sheet-close { background: var(--bg); border: none; border-radius: 8px; padding: 6px 10px; font-size: 16px; cursor: pointer; color: var(--text-muted); }
.sheet-body { padding: 20px; }
.sheet-form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.sheet-label { font-size: 12px; font-weight: 600; color: var(--text-muted); }
.sheet-input, .sheet-select, .sheet-textarea { padding: 11px 14px; border: 1.5px solid var(--border); border-radius: 10px; font-size: 14px; font-family: inherit; color: var(--text); background: #fff; outline: none; width: 100%; }
.sheet-input:focus, .sheet-select:focus, .sheet-textarea:focus { border-color: var(--primary); }
.sheet-textarea { resize: none; min-height: 60px; }
.sheet-status-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.sheet-status-chip { padding: 6px 12px; border-radius: 20px; font-size: 11px; font-weight: 600; border: 1.5px solid transparent; cursor: pointer; }
.sheet-footer { padding: 14px 20px; border-top: 1px solid var(--border); }
.sheet-save-btn { width: 100%; padding: 14px; background: var(--primary); color: #fff; border: none; border-radius: 12px; font-size: 15px; font-weight: 700; font-family: inherit; cursor: pointer; }

@media (max-width: 768px) {
  .lead-cards { display: flex; }
  .leads-table { display: none; }
  .chip-bar { display: flex; }
  .leads-page-header-btns .btn-ghost { display: none; }
  .desktop-filters { display: none; }
}

/* Layout consistency (audit) */
.page-header > div:first-child { min-width: 0; flex: 1; }
.filters-bar { flex-wrap: wrap; gap: 8px; align-items: center; }
.modal-box { max-width: 560px; width: calc(100% - 32px); }
@supports (width: min(100%, 560px)) {
  .modal-box { max-width: min(560px, calc(100vw - 32px)); width: auto; }
}
@media (max-width: 768px) {
  .search-wrap { max-width: none; flex: 1; }
  .page-title { font-size: 18px; }
  .btn, .nav-item { min-height: 40px; }
}
