@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&display=swap");

:root {
    --ink: #152027;
    --muted: #6d7881;
    --line: #dce7e9;
    --paper: #f4f8f8;
    --panel: #ffffff;
    --nav: #081316;
    --nav-soft: #101f23;
    --teal: #2ec4b6;
    --teal-dark: #15988d;
    --gold: #f2c94c;
    --gold-soft: #fff6d8;
    --danger: #c94141;
    --success: #11835f;
    --shadow: 0 20px 45px rgba(8, 19, 22, .08);
    --shadow-soft: 0 10px 24px rgba(8, 19, 22, .06);
}

* { box-sizing: border-box; }

html { min-height: 100%; }

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Montserrat", Arial, Helvetica, sans-serif;
    color: var(--ink);
    background:
        linear-gradient(135deg, rgba(46, 196, 182, .08), transparent 34%),
        linear-gradient(180deg, #fbfdfd 0%, var(--paper) 42%, #eef5f4 100%);
    letter-spacing: 0;
}

a { color: var(--teal-dark); text-decoration: none; font-weight: 600; }
a:hover { color: var(--ink); }

button, .button {
    border: 0;
    background: linear-gradient(135deg, var(--teal), var(--teal-dark));
    color: #041113;
    padding: 11px 16px;
    border-radius: 6px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 12px 22px rgba(46, 196, 182, .22);
    transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}

button:hover, .button:hover {
    color: #041113;
    transform: translateY(-1px);
    box-shadow: 0 16px 28px rgba(46, 196, 182, .28);
    filter: saturate(1.04);
}

button:active, .button:active { transform: translateY(0); }

.button-soft {
    background: #ffffff;
    color: var(--ink);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-soft);
}

.button-ghost {
    background: transparent;
    color: var(--teal-dark);
    border: 1px solid rgba(46, 196, 182, .34);
    box-shadow: none;
}

.button-danger {
    background: linear-gradient(135deg, #f05a5a, var(--danger));
    color: #fff;
    box-shadow: 0 12px 22px rgba(201, 65, 65, .2);
}

.button-danger:hover {
    color: #fff;
    box-shadow: 0 16px 28px rgba(201, 65, 65, .28);
}

input, select, textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 11px 12px;
    background: #fff;
    color: var(--ink);
    font: inherit;
    font-size: 13px;
    outline: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}

input:focus, select:focus, textarea:focus {
    border-color: var(--teal);
    box-shadow: 0 0 0 4px rgba(46, 196, 182, .14);
}

textarea { min-height: 120px; resize: vertical; line-height: 1.55; }

label {
    display: grid;
    gap: 7px;
    font-size: 12px;
    color: var(--muted);
    font-weight: 700;
}

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: 270px;
    background:
        linear-gradient(180deg, rgba(46, 196, 182, .14), transparent 26%),
        linear-gradient(165deg, #071113 0%, #101b1f 62%, #071113 100%);
    color: #fff;
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    border-right: 1px solid rgba(255, 255, 255, .08);
    box-shadow: 16px 0 40px rgba(8, 19, 22, .12);
}

.brand {
    display: flex;
    align-items: center;
    color: #fff;
    min-height: 58px;
    padding: 6px 4px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.brand img {
    display: block;
    width: 200px;
    max-width: 100%;
    height: auto;
}

nav { display: grid; gap: 7px; }

nav a {
    position: relative;
    color: #cbd8d9;
    padding: 12px 13px 12px 16px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 13px;
    transition: background .15s ease, color .15s ease;
}

nav a::before {
    content: "";
    position: absolute;
    left: 7px;
    top: 50%;
    width: 4px;
    height: 0;
    border-radius: 99px;
    background: var(--gold);
    transform: translateY(-50%);
    transition: height .15s ease;
}

nav a.active, nav a:hover {
    background: rgba(255, 255, 255, .08);
    color: #fff;
}

nav a.active::before, nav a:hover::before { height: 22px; }

.user-card {
    margin-top: auto;
    display: grid;
    gap: 7px;
    color: #b8c7c8;
    font-size: 12px;
    padding: 16px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 8px;
}

.user-card strong { color: #fff; font-size: 13px; }
.user-card a { color: var(--gold); }

.content {
    margin-left: 270px;
    padding: 34px;
    min-height: 100vh;
}

.page-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 22px;
    margin-bottom: 22px;
    padding: 20px 0 4px;
}

.page-head p {
    margin: 0 0 7px;
    color: var(--teal-dark);
    font-weight: 800;
    text-transform: uppercase;
    font-size: 11px;
}

.page-head h1 {
    margin: 0;
    font-size: 32px;
    line-height: 1.15;
    font-weight: 800;
    color: #0c1a1d;
}

.page-head span {
    display: block;
    margin-top: 8px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
}

.page-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.panel, .kpis > div, .login-panel, .lead-filters, .bulk-bar {
    background: rgba(255, 255, 255, .92);
    border: 1px solid rgba(220, 231, 233, .95);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(10px);
}

.panel {
    padding: 20px;
    margin-bottom: 18px;
}

.panel h2 {
    margin: 0 0 16px;
    font-size: 17px;
    font-weight: 800;
    color: #0c1a1d;
}

.panel h3 { margin: 18px 0 8px; font-size: 14px; }

.kpis {
    display: grid;
    grid-template-columns: repeat(5, minmax(130px, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.performance-kpis { grid-template-columns: repeat(6, minmax(120px, 1fr)); }

.kpis div {
    position: relative;
    overflow: hidden;
    padding: 19px;
}

.kpis div::after {
    content: "";
    position: absolute;
    right: -28px;
    top: -42px;
    width: 88px;
    height: 88px;
    border-radius: 50%;
    background: rgba(46, 196, 182, .14);
}

.kpis span {
    display: block;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.kpis strong {
    display: block;
    margin-top: 9px;
    font-size: 28px;
    line-height: 1;
    font-weight: 800;
    color: #0b171a;
}

.grid { display: grid; gap: 18px; }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.filters {
    display: flex;
    gap: 10px;
    align-items: end;
    flex-wrap: wrap;
}

.filters label { min-width: 160px; }

.lead-filters {
    display: grid;
    grid-template-columns: minmax(260px, 1.5fr) minmax(180px, .8fr) minmax(180px, .8fr) auto auto;
    align-items: end;
    padding: 15px;
    margin-bottom: 14px;
}

.lead-filters input { min-width: 240px; }

.filter-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.filter-actions .button,
.filter-actions button {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.status-filter {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 8px;
    min-width: 0;
    padding-top: 2px;
}

.status-filter > span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    line-height: 1.2;
}

.status-chips {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 7px;
    width: 100%;
    justify-self: start;
}

.status-chip {
    width: auto;
    min-width: 0;
    max-width: max-content;
    flex: 0 0 auto;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: flex-start;
    gap: 7px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: #506064;
    font-size: 12px;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease, color .15s ease, box-shadow .15s ease;
}

.filters .status-chip {
    min-width: 0;
}

.status-chip input {
    flex: 0 0 13px;
    width: 13px !important;
    height: 13px !important;
    min-width: 13px;
    margin: 0;
    padding: 0;
    border-radius: 2px;
    box-shadow: none;
    accent-color: var(--teal-dark);
}

.status-chip input:focus {
    box-shadow: none;
}

.status-chip.selected {
    background: #e8fbf8;
    border-color: rgba(46, 196, 182, .65);
    color: #0d5952;
    box-shadow: 0 8px 16px rgba(46, 196, 182, .12);
}

.status-chip:hover {
    border-color: var(--teal);
    color: var(--ink);
}

.lead-overview {
    display: grid;
    grid-template-columns: repeat(5, minmax(130px, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.lead-overview div {
    padding: 15px 16px;
    background: linear-gradient(180deg, #ffffff, #f8fcfb);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.lead-overview span {
    display: block;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.lead-overview strong {
    display: block;
    margin-top: 7px;
    font-size: 24px;
    line-height: 1;
    font-weight: 800;
}

.bulk-bar {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 12px 16px;
    align-items: start;
    padding: 13px;
    margin-bottom: 14px;
}

.bulk-bar select { max-width: 240px; }

.bulk-title {
    min-width: 210px;
    display: grid;
    gap: 3px;
}

.bulk-title strong {
    font-size: 13px;
    font-weight: 800;
}

.bulk-title span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
}

.toolbar-sort {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.toolbar-actions {
    grid-column: 2;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding-top: 2px;
}

.toolbar-actions button,
.toolbar-actions select {
    min-height: 40px;
}

.toolbar-actions button {
    padding: 10px 12px;
    white-space: nowrap;
}

.toolbar-actions select {
    min-width: 180px;
}

.sort-controls {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
}

.sort-label {
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.sort-segment {
    display: inline-flex;
    gap: 4px;
    padding: 4px;
    background: #f2f8f7;
    border: 1px solid var(--line);
    border-radius: 7px;
}

.sort-segment a {
    padding: 7px 9px;
    border-radius: 5px;
    color: #59686b;
    font-size: 12px;
    font-weight: 800;
}

.sort-segment a.active {
    background: #fff;
    color: var(--ink);
    box-shadow: 0 6px 14px rgba(8, 19, 22, .08);
}

.sort-direction {
    padding: 8px 10px;
    border-radius: 6px;
    color: var(--teal-dark);
    background: #fff;
    border: 1px solid rgba(46, 196, 182, .35);
    font-size: 12px;
    font-weight: 800;
}

.sort-direction.active {
    color: #7b5d00;
    background: var(--gold-soft);
    border-color: rgba(242, 201, 76, .45);
}

.view-switch {
    display: inline-flex;
    flex: 0 0 auto;
    padding: 4px;
    background: #eef6f5;
    border: 1px solid var(--line);
    border-radius: 7px;
}

.view-switch a {
    padding: 8px 11px;
    border-radius: 5px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.modal {
    width: min(820px, calc(100vw - 32px));
    padding: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--ink);
}

.modal::backdrop {
    background: rgba(8, 19, 22, .62);
    backdrop-filter: blur(4px);
}

.modal-panel {
    display: grid;
    gap: 18px;
    padding: 22px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, .28);
}

.modal-panel header,
.modal-panel footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.modal-panel header p {
    margin: 0 0 5px;
    color: var(--teal-dark);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.modal-panel header h2 {
    margin: 0;
    font-size: 22px;
}

.modal-close {
    background: #f2f8f7;
    color: var(--ink);
    box-shadow: none;
}

.modal-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px;
}

.modal-statuses {
    display: grid;
    gap: 8px;
}

.modal-statuses > span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.view-switch a.active {
    background: #fff;
    color: var(--ink);
    box-shadow: 0 6px 14px rgba(8, 19, 22, .08);
}

.lead-management-form { margin: 0; }

.pipeline-board {
    display: grid;
    grid-template-columns: repeat(5, minmax(250px, 1fr));
    gap: 14px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.pipeline-column {
    min-width: 250px;
    background: rgba(255, 255, 255, .72);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
}

.pipeline-column header {
    position: sticky;
    top: 0;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 14px;
    background: linear-gradient(180deg, #ffffff, #f9fcfc);
    border-bottom: 1px solid var(--line);
    border-radius: 8px 8px 0 0;
}

.pipeline-column header span {
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.pipeline-column header strong {
    min-width: 28px;
    min-height: 28px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--gold-soft);
    color: #7b5d00;
    font-size: 12px;
}

.pipeline-cards {
    display: grid;
    gap: 10px;
    padding: 12px;
}

.lead-card {
    display: grid;
    gap: 8px;
    padding: 13px;
    background: #fff;
    border: 1px solid #e6eeee;
    border-radius: 8px;
    box-shadow: 0 8px 18px rgba(8, 19, 22, .05);
}

.lead-card-title {
    color: var(--ink);
    font-size: 14px;
    font-weight: 800;
}

.lead-card > span {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}

.lead-check {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
}

.lead-check input { width: auto; }

.lead-card-meta {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4px;
    padding-top: 8px;
    border-top: 1px solid #edf2f3;
}

.lead-card-meta small {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
}

.table-wrap {
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
}

th, td {
    text-align: left;
    padding: 13px 14px;
    border-bottom: 1px solid #edf2f3;
    vertical-align: top;
    font-size: 13px;
}

th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8fbfb;
    color: #59686b;
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 800;
}

tbody tr { transition: background .15s ease; }
tbody tr:hover { background: #f7fcfb; }
tbody tr:last-child td { border-bottom: 0; }

td small {
    display: block;
    color: var(--muted);
    margin-top: 5px;
    font-size: 12px;
    font-weight: 500;
}

.pill {
    display: inline-block;
    padding: 6px 9px;
    border-radius: 999px;
    background: var(--gold-soft);
    color: #7b5d00;
    border: 1px solid rgba(242, 201, 76, .45);
    font-size: 11px;
    font-weight: 800;
}

.followup-date {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 5px 8px;
    border-radius: 999px;
    background: #f1f6f6;
    color: #526366;
    font-size: 12px;
    font-weight: 800;
}

.followup-date.today {
    background: #e8fbf8;
    color: #0d5952;
    border: 1px solid rgba(46, 196, 182, .35);
}

.followup-date.overdue {
    background: #fff0f0;
    color: var(--danger);
    border: 1px solid rgba(201, 65, 65, .25);
}

.followup-date.upcoming {
    background: var(--gold-soft);
    color: #7b5d00;
    border: 1px solid rgba(242, 201, 76, .35);
}

.bars { display: grid; gap: 13px; }

.bars div {
    position: relative;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    padding-bottom: 12px;
    font-size: 13px;
}

.bars strong { color: #0b171a; }

.bars i {
    position: absolute;
    left: 0;
    bottom: 0;
    height: 6px;
    background: linear-gradient(90deg, var(--teal), var(--gold));
    border-radius: 99px;
    box-shadow: 0 5px 14px rgba(46, 196, 182, .25);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

.wide { grid-column: 1 / -1; }
.stack { display: grid; gap: 13px; }
.compact-form {
    gap: 11px;
}

.compact-form button {
    width: max-content;
}
.check { display: flex; align-items: center; gap: 8px; }
.check input { width: auto; }

.detail-list { display: grid; gap: 10px; }

.detail-list div {
    display: grid;
    grid-template-columns: 170px 1fr;
    gap: 12px;
    border-bottom: 1px solid #edf2f3;
    padding-bottom: 9px;
}

.detail-list span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.detail-list strong { font-size: 13px; }

.timeline {
    list-style: none;
    padding: 0;
    margin: 14px 0 0;
    display: grid;
    gap: 10px;
}

.timeline li {
    border-left: 3px solid var(--teal);
    padding: 11px 12px;
    background: #fbfdfd;
    border-radius: 0 6px 6px 0;
    box-shadow: inset 0 0 0 1px #edf2f3;
}

.timeline span {
    display: block;
    color: var(--muted);
    font-size: 12px;
    margin: 5px 0;
}

.timeline p { margin: 7px 0 0; line-height: 1.55; }
.note-form { display: grid; gap: 10px; }
.empty { color: var(--muted); margin: 0; font-size: 13px; }

.flash {
    background: #e9fbf8;
    color: #0a5f58;
    border: 1px solid rgba(46, 196, 182, .35);
    padding: 13px 15px;
    border-radius: 8px;
    margin-bottom: 16px;
    box-shadow: var(--shadow-soft);
    font-weight: 600;
    font-size: 13px;
}

.followup-alert {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    padding: 14px 16px;
    border-radius: 8px;
    background: linear-gradient(135deg, #e8fbf8, #fff8df);
    border: 1px solid rgba(46, 196, 182, .34);
    box-shadow: var(--shadow-soft);
}

.followup-alert strong {
    color: #0b171a;
    font-size: 13px;
    font-weight: 800;
}

.followup-alert span {
    color: #3d5054;
    font-size: 13px;
    font-weight: 600;
}

.followup-alert a {
    margin-left: auto;
    color: #0d5952;
}

.followup-kpis {
    grid-template-columns: repeat(3, minmax(150px, 1fr));
}

.followup-panel h2 {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.followup-panel h2 span {
    min-width: 30px;
    min-height: 30px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #eef6f5;
    color: var(--ink);
    font-size: 12px;
}

.followup-panel.today h2 span { background: #e8fbf8; color: #0d5952; }
.followup-panel.overdue h2 span { background: #fff0f0; color: var(--danger); }
.followup-panel.upcoming h2 span { background: var(--gold-soft); color: #7b5d00; }

.followup-list {
    display: grid;
    gap: 10px;
}

.followup-card {
    display: grid;
    gap: 7px;
    padding: 13px;
    background: #fff;
    border: 1px solid #e6eeee;
    border-radius: 8px;
    box-shadow: 0 8px 18px rgba(8, 19, 22, .05);
}

.followup-card a {
    color: var(--ink);
    font-weight: 800;
}

.followup-card span,
.followup-card small {
    display: block;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
}

.followup-card strong {
    width: max-content;
    padding: 5px 8px;
    border-radius: 999px;
    background: #f1f6f6;
    font-size: 12px;
}

.followup-card p {
    margin: 0;
    color: #304247;
    font-size: 12px;
    line-height: 1.5;
}

.account-summary {
    display: grid;
    gap: 10px;
}

.account-summary div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 12px;
    border: 1px solid #edf2f3;
    border-radius: 8px;
    background: #fbfdfd;
}

.account-summary span {
    font-size: 13px;
    font-weight: 800;
}

.account-summary strong {
    padding: 5px 8px;
    border-radius: 999px;
    background: #e8fbf8;
    color: #0d5952;
    font-size: 11px;
}

.account-list {
    display: grid;
    gap: 12px;
}

.account-row {
    display: grid;
    grid-template-columns: 1fr 1.45fr .7fr 1fr auto 1.2fr;
    gap: 12px;
    align-items: end;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 8px 18px rgba(8, 19, 22, .04);
}

.account-active {
    align-self: center;
}

.account-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.account-actions button {
    padding: 10px 12px;
    white-space: nowrap;
}

.self-note {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.login-screen {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
    background:
        linear-gradient(145deg, rgba(46, 196, 182, .2), transparent 32%),
        linear-gradient(315deg, rgba(242, 201, 76, .18), transparent 34%),
        #071113;
}

.login-panel {
    position: relative;
    width: min(460px, calc(100vw - 32px));
    padding: 32px;
    border-color: rgba(255, 255, 255, .18);
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 28px 70px rgba(0, 0, 0, .26);
}

.login-panel::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 5px;
    border-radius: 8px 8px 0 0;
    background: linear-gradient(90deg, var(--teal), var(--gold));
}

.login-logo {
    display: block;
    width: 270px;
    max-width: 100%;
    height: auto;
    margin-bottom: 20px;
}

.login-panel h1 {
    margin: 0 0 9px;
    font-size: 26px;
    line-height: 1.18;
    font-weight: 800;
}

.login-panel p { color: var(--muted); line-height: 1.55; font-size: 13px; }
.login-panel form { display: grid; gap: 15px; margin-top: 22px; }

@media (max-width: 1100px) {
    .kpis, .performance-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .lead-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pipeline-board { grid-template-columns: repeat(3, minmax(250px, 1fr)); }
    .grid.three { grid-template-columns: 1fr; }
    .account-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .account-actions { justify-content: flex-start; }
}

@media (max-width: 900px) {
    .sidebar {
        position: static;
        width: auto;
        min-height: auto;
        border-right: 0;
    }
    .content { margin-left: 0; padding: 20px; }
    .grid.two, .form-grid { grid-template-columns: 1fr; }
    .page-head { align-items: stretch; flex-direction: column; }
    .filters, .bulk-bar { display: grid; }
    .bulk-bar { grid-template-columns: 1fr; }
    .toolbar-sort,
    .toolbar-actions { grid-column: 1; }
    .toolbar-sort { align-items: flex-start; flex-direction: column; }
    .lead-filters { grid-template-columns: 1fr; }
    .filter-actions { justify-content: flex-start; }
    .status-filter { grid-template-columns: 1fr; gap: 8px; }
    .status-filter > span { line-height: 1.2; }
    .bulk-title { min-width: 0; }
    .view-switch { margin-left: 0; width: max-content; }
}

@media (max-width: 620px) {
    .content { padding: 16px; }
    .kpis, .performance-kpis, .followup-kpis, .lead-overview { grid-template-columns: 1fr; }
    .page-head h1 { font-size: 25px; }
    .panel { padding: 16px; }
    .detail-list div { grid-template-columns: 1fr; gap: 4px; }
    .pipeline-board { grid-template-columns: repeat(2, minmax(235px, 1fr)); }
    .modal-grid { grid-template-columns: 1fr; }
    .modal-panel header,
    .modal-panel footer { align-items: stretch; flex-direction: column; }
    .account-row { grid-template-columns: 1fr; }
}
