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

/* ───────────────────────────────────────────
   Design tokens
─────────────────────────────────────────── */
:root {
    --saulto-900: #0f2a1c;
    --saulto-800: #1a4731;
    --saulto-700: #235e40;
    --saulto-600: #2d7551;
    --saulto-500: #378a60;
    --saulto-400: #52a87c;
    --saulto-300: #84c8a4;
    --saulto-100: #d6f0e0;
    --saulto-50:  #edf8f2;

    --sidebar-width: 236px;
    --sidebar-bg: #ffffff;
    --sidebar-border: #e5e9f0;
    --page-bg: #f5f7fa;
    --card-bg: #ffffff;
    --border: #e0e6ef;

    --text-primary: #1e2d3d;
    --text-secondary: #516f90;
    --text-muted: #8fadc6;

    --radius-sm: 6px;
    --radius: 10px;
    --radius-lg: 14px;

    --shadow-sm: 0 1px 3px rgba(16,30,54,.06), 0 1px 2px rgba(16,30,54,.04);
    --shadow:    0 4px 12px rgba(16,30,54,.08), 0 1px 3px rgba(16,30,54,.04);
    --shadow-lg: 0 12px 32px rgba(16,30,54,.10), 0 2px 6px rgba(16,30,54,.05);
}

/* ───────────────────────────────────────────
   Reset & base
─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: var(--text-primary);
    background: var(--page-bg);
    margin: 0;
    min-height: 100vh;
}

a { color: var(--saulto-700); text-decoration: none; }
a:hover { color: var(--saulto-900); }

/* ───────────────────────────────────────────
   App layout
─────────────────────────────────────────── */
.app-layout {
    display: flex;
    min-height: 100vh;
}

/* ───────────────────────────────────────────
   Sidebar
─────────────────────────────────────────── */
.sidebar {
    width: var(--sidebar-width);
    min-height: 100vh;
    background: var(--sidebar-bg);
    border-right: 1px solid var(--sidebar-border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0; left: 0; bottom: 0;
    z-index: 100;
    transition: transform 0.25s ease;
}

.sidebar-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 20px 16px 18px;
    border-bottom: 1px solid var(--sidebar-border);
    text-decoration: none;
}
.sidebar-brand img { height: 52px; }
.sidebar-brand-sub {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    line-height: 1;
}

.sidebar-nav {
    flex: 1;
    padding: 10px 10px;
    overflow-y: auto;
}

.sidebar-section-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    padding: 16px 8px 6px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 13.5px;
    font-weight: 500;
    transition: all 0.12s ease;
    margin-bottom: 2px;
    text-decoration: none;
}
.sidebar-link i { font-size: 16px; width: 18px; text-align: center; flex-shrink: 0; }
.sidebar-link:hover {
    background: var(--saulto-50);
    color: var(--saulto-800);
    text-decoration: none;
}
.sidebar-link.active {
    background: var(--saulto-50);
    color: var(--saulto-800);
    font-weight: 600;
}
.sidebar-link.active i { color: var(--saulto-700); }

.sidebar-footer {
    border-top: 1px solid var(--sidebar-border);
    padding: 12px 10px;
}
.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background 0.12s;
}
.sidebar-user:hover { background: var(--saulto-50); }
.sidebar-avatar {
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--saulto-100);
    color: var(--saulto-800);
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 700;
    flex-shrink: 0;
}
.sidebar-username {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
}
.sidebar-email {
    font-size: 11px;
    color: var(--text-muted);
}

/* ───────────────────────────────────────────
   Main content
─────────────────────────────────────────── */
.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.topbar {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border);
    padding: 0 28px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 50;
}
.topbar-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}
.topbar-actions { display: flex; align-items: center; gap: 10px; }

.page-body {
    padding: 24px 28px;
    flex: 1;
}

/* ───────────────────────────────────────────
   Flash alerts
─────────────────────────────────────────── */
.flash-container { margin-bottom: 16px; }
.alert {
    border-radius: var(--radius);
    border: none;
    font-size: 13.5px;
    font-weight: 500;
    padding: 12px 16px;
    box-shadow: var(--shadow-sm);
}
.alert-success  { background: #e8f8f0; color: #0a6640; }
.alert-danger   { background: #fef0f0; color: #c0392b; }
.alert-warning  { background: #fef9e7; color: #8a6a00; }
.alert-info     { background: #eaf4fb; color: #1a6fa8; }

/* ───────────────────────────────────────────
   Stat cards
─────────────────────────────────────────── */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 20px;
}

/* ── Unified stat strip (Option C) ── */
.stat-strip {
    display: flex;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    margin-bottom: 20px;
}
.stat-seg {
    flex: 1;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    transition: background 0.12s;
    text-decoration: none;
    border-right: 1px solid var(--border);
}
.stat-seg:last-child { border-right: none; }
.stat-seg:hover { background: var(--bg-secondary); text-decoration: none; }
.stat-seg.active-filter { background: var(--saulto-50); }
.stat-seg-row {
    display: flex;
    align-items: center;
    gap: 7px;
}
.stat-dot {
    width: 9px; height: 9px;
    border-radius: 50%;
    flex-shrink: 0;
}
.stat-dot.all   { background: #3b5bdb; }
.stat-dot.vet   { background: #0a6640; }
.stat-dot.pend  { background: #d97706; }
.stat-dot.sni   { background: #c0392b; }
.stat-dot.spni  { background: #c2410c; }
.stat-seg-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    line-height: 1.3;
}
.stat-seg-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}
.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: border-color 0.15s, box-shadow 0.15s;
    text-decoration: none;
}
.stat-card:hover {
    border-color: var(--saulto-400);
    box-shadow: var(--shadow);
    text-decoration: none;
}
.stat-card.active-filter {
    border-color: var(--saulto-700);
    background: var(--saulto-50);
}
.stat-icon-wrap {
    width: 42px; height: 42px;
    border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}
.stat-icon-wrap.all       { background: #e8f0fe; color: #3b5bdb; }
.stat-icon-wrap.vetted    { background: #e8f8f0; color: #0a6640; }
.stat-icon-wrap.pending   { background: #fef9e7; color: #8a6a00; }
.stat-icon-wrap.not-int        { background: #fef0f0; color: #c0392b; }
.stat-icon-wrap.client-not-int { background: #fff7ed; color: #c2410c; }

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}
.stat-label {
    font-size: 11.5px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 3px;
}

/* ───────────────────────────────────────────
   Filter toolbar
─────────────────────────────────────────── */
.filter-toolbar {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius) var(--radius) 0 0;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    border-bottom: none;
}
.filter-search {
    display: flex;
    align-items: center;
    background: var(--page-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0 12px;
    height: 36px;
    gap: 8px;
    min-width: 240px;
    flex: 1;
    max-width: 340px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.filter-search:focus-within {
    border-color: var(--saulto-500);
    box-shadow: 0 0 0 3px rgba(52,139,96,.12);
    background: #fff;
}
.filter-search i { color: var(--text-muted); font-size: 14px; flex-shrink: 0; }
.filter-search input {
    border: none;
    background: transparent;
    outline: none;
    font-size: 13.5px;
    color: var(--text-primary);
    font-family: inherit;
    width: 100%;
}
.filter-search input::placeholder { color: var(--text-muted); }

.filter-select {
    height: 36px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--page-bg);
    padding: 0 28px 0 10px;
    font-size: 13px;
    color: var(--text-secondary);
    font-family: inherit;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16'%3E%3Cpath fill='%23516f90' d='M7.247 11.14L2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    cursor: pointer;
    transition: border-color 0.15s;
}
.filter-select:focus { border-color: var(--saulto-500); outline: none; background-color: #fff; }

/* Multi-select button (shares .filter-select sizing) */
.multi-select-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 10px;
    cursor: pointer;
    white-space: nowrap;
    min-width: 130px;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    background-image: none;
}
.multi-select-btn span { flex: 1; overflow: hidden; text-overflow: ellipsis; }

.multi-select-wrap { position: relative; }

.multi-select-panel {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    min-width: 220px;
    max-width: 280px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
    z-index: 200;
    overflow: hidden;
}
.multi-select-search {
    padding: 8px 10px;
    border-bottom: 1px solid var(--border);
}
.multi-select-search input {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 5px 10px;
    font-size: 12.5px;
    font-family: inherit;
    outline: none;
    background: var(--page-bg);
}
.multi-select-search input:focus { border-color: var(--saulto-500); }
.multi-select-options {
    max-height: 220px;
    overflow-y: auto;
    padding: 4px 0;
}
.multi-select-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
    user-select: none;
    transition: background 0.1s;
}
.multi-select-option:hover { background: var(--saulto-50); color: var(--saulto-700); }
.multi-select-option input[type=checkbox] {
    accent-color: var(--saulto-600);
    width: 14px; height: 14px;
    flex-shrink: 0;
    cursor: pointer;
}
.multi-select-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    border-top: 1px solid var(--border);
    background: var(--page-bg);
}

/* Active filter chips */
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--saulto-50);
    border: 1px solid var(--saulto-200);
    color: var(--saulto-700);
    border-radius: 20px;
    padding: 3px 10px;
    font-size: 12px;
    font-weight: 500;
}

/* Clickable tag variant */
.tag-link {
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.tag-link:hover {
    background: var(--saulto-200);
    color: var(--saulto-800);
    border-color: var(--saulto-400);
}

.filter-actions { margin-left: auto; display: flex; gap: 8px; }

/* ───────────────────────────────────────────
   CRM Table
─────────────────────────────────────────── */
.crm-table-wrap {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-top: none;
    border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}
.crm-table {
    width: 100%;
    border-collapse: collapse;
}
.crm-table thead tr {
    border-bottom: 1px solid var(--border);
    background: #fafbfc;
}
.crm-table thead th {
    padding: 10px 16px;
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    white-space: nowrap;
    text-align: left;
}
.crm-table tbody tr {
    border-bottom: 1px solid #f0f3f7;
    transition: background 0.1s;
    cursor: pointer;
}
.crm-table tbody tr:last-child { border-bottom: none; }
.crm-table tbody tr:hover { background: var(--saulto-50); }
.crm-table tbody td {
    padding: 13px 16px;
    vertical-align: middle;
    color: var(--text-primary);
    font-size: 13.5px;
}
.firm-name-cell {
    font-weight: 600;
    color: var(--saulto-800);
    font-size: 13.5px;
}
.firm-name-cell:hover { text-decoration: underline; }
.firm-website-link {
    color: var(--text-muted);
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 2px;
    text-decoration: none;
}
.firm-website-link:hover { color: var(--saulto-700); }

.cell-secondary { color: var(--text-secondary); font-size: 13px; }
.cell-muted { color: var(--text-muted); font-size: 12.5px; }

/* Row actions */
.row-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}
.row-action-btn {
    width: 28px; height: 28px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: white;
    color: var(--text-secondary);
    display: flex; align-items: center; justify-content: center;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.12s;
    text-decoration: none;
}
.row-action-btn:hover {
    background: var(--saulto-50);
    border-color: var(--saulto-400);
    color: var(--saulto-800);
}

/* ───────────────────────────────────────────
   Status badges
─────────────────────────────────────────── */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: 20px;
    font-size: 11.5px;
    font-weight: 600;
    white-space: nowrap;
    letter-spacing: 0.01em;
}
.status-badge::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}
.status-suggested    { background: #f0f4ff; color: #3730a3; }
.status-suggested::before { background: #818cf8; }
.status-vetted       { background: #e8f8f0; color: #065f46; }
.status-vetted::before { background: #10b981; }
.status-pending      { background: #fef9e7; color: #7c5e10; }
.status-pending::before { background: #f59e0b; }
.status-not-interested       { background: #fef0f0; color: #991b1b; }
.status-not-interested::before { background: #ef4444; }
.status-saulto-not-interested { background: #fef0f0; color: #991b1b; }
.status-saulto-not-interested::before { background: #ef4444; }
.status-client-not-interested { background: #fff7ed; color: #9a3412; }
.status-client-not-interested::before { background: #c2410c; }

/* ───────────────────────────────────────────
   Status radio selector (detail page)
─────────────────────────────────────────── */
.status-radio-group { display: flex; gap: 10px; flex-wrap: wrap; }
.status-radio-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    border-radius: var(--radius-sm);
    border: 1.5px solid var(--border);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.15s;
    user-select: none;
}
.status-radio-label:hover { border-color: #9ca3af; color: var(--text-primary); }
.status-radio-label .dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.status-radio-input { display: none; }

.status-radio-vetted .dot    { background: #10b981; }
.status-radio-pending .dot   { background: #f59e0b; }
.status-radio-not-interested .dot         { background: #ef4444; }
.status-radio-saulto-not-interested .dot  { background: #ef4444; }
.status-radio-client-not-interested .dot  { background: #c2410c; }

.status-radio-vetted.active                    { border-color: #10b981; background: #f0fdf8; color: #065f46; }
.status-radio-pending.active                   { border-color: #f59e0b; background: #fef9e7; color: #7c5e10; }
.status-radio-not-interested.active            { border-color: #ef4444; background: #fef0f0; color: #991b1b; }
.status-radio-saulto-not-interested.active     { border-color: #ef4444; background: #fef0f0; color: #991b1b; }
.status-radio-client-not-interested.active     { border-color: #c2410c; background: #fff7ed; color: #9a3412; }

/* ───────────────────────────────────────────
   Buttons
─────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 13.5px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: all 0.15s ease;
    text-decoration: none;
    line-height: 1;
    white-space: nowrap;
}
.btn:hover { text-decoration: none; }

.btn-primary {
    background: var(--saulto-800);
    border-color: var(--saulto-800);
    color: #fff;
}
.btn-primary:hover {
    background: var(--saulto-700);
    border-color: var(--saulto-700);
    color: #fff;
    box-shadow: 0 3px 10px rgba(26,71,49,.25);
}
.btn-secondary {
    background: #fff;
    border-color: var(--border);
    color: var(--text-secondary);
}
.btn-secondary:hover {
    border-color: #9ca3af;
    color: var(--text-primary);
    background: var(--page-bg);
}
.btn-ghost {
    background: transparent;
    border-color: transparent;
    color: var(--text-secondary);
    padding: 6px 10px;
}
.btn-ghost:hover {
    background: var(--saulto-50);
    color: var(--saulto-800);
}
.btn-sm { padding: 5px 10px; font-size: 12.5px; }
.btn-danger {
    background: #fef0f0;
    border-color: #fecaca;
    color: #991b1b;
}
.btn-danger:hover { background: #fee2e2; border-color: #ef4444; }

/* ───────────────────────────────────────────
   Cards / panels (detail page)
─────────────────────────────────────────── */
.panel {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    margin-bottom: 16px;
}
.panel-header {
    padding: 14px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.panel-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    margin: 0;
}
.panel-body { padding: 20px; }
.panel-body-sm { padding: 14px 20px; }

/* Form fields */
.field-group { margin-bottom: 14px; }
.field-label {
    display: block;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 5px;
}
.field-input {
    width: 100%;
    height: 36px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0 12px;
    font-size: 13.5px;
    color: var(--text-primary);
    font-family: inherit;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
    outline: none;
}
.field-input:focus {
    border-color: var(--saulto-500);
    box-shadow: 0 0 0 3px rgba(52,139,96,.12);
}
.field-textarea {
    width: 100%;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    font-size: 13.5px;
    color: var(--text-primary);
    font-family: inherit;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
    outline: none;
    resize: vertical;
    min-height: 80px;
}
.field-textarea:focus {
    border-color: var(--saulto-500);
    box-shadow: 0 0 0 3px rgba(52,139,96,.12);
}
.field-select {
    width: 100%;
    height: 36px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0 30px 0 12px;
    font-size: 13.5px;
    color: var(--text-primary);
    font-family: inherit;
    background: #fff;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16'%3E%3Cpath fill='%23516f90' d='M7.247 11.14L2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    cursor: pointer;
    outline: none;
    transition: border-color 0.15s;
}
.field-select:focus { border-color: var(--saulto-500); box-shadow: 0 0 0 3px rgba(52,139,96,.12); }

/* ───────────────────────────────────────────
   Detail page breadcrumb & header
─────────────────────────────────────────── */
.detail-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}
.detail-title { font-size: 22px; font-weight: 700; color: var(--text-primary); margin: 0 0 4px; }
.detail-meta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.detail-meta-item { display: flex; align-items: center; gap: 5px; font-size: 13px; color: var(--text-secondary); }

.breadcrumb-nav { margin-bottom: 16px; display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text-muted); }
.breadcrumb-nav a { color: var(--text-muted); }
.breadcrumb-nav a:hover { color: var(--saulto-700); }

/* ───────────────────────────────────────────
   History timeline
─────────────────────────────────────────── */
.timeline-item {
    display: flex;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}
.timeline-item:last-child { border-bottom: none; padding-bottom: 0; }
.timeline-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--saulto-300);
    margin-top: 5px;
    flex-shrink: 0;
}
.timeline-content { flex: 1; }
.timeline-title { font-size: 13px; font-weight: 500; color: var(--text-primary); }
.timeline-time { font-size: 11.5px; color: var(--text-muted); margin-top: 1px; }

/* ───────────────────────────────────────────
   Empty state
─────────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: 60px 24px;
    color: var(--text-muted);
}
.empty-state i { font-size: 48px; opacity: 0.3; display: block; margin-bottom: 16px; }
.empty-state h3 { font-size: 16px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
.empty-state p { font-size: 13.5px; max-width: 320px; margin: 0 auto 20px; }

/* ───────────────────────────────────────────
   Login page
─────────────────────────────────────────── */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: stretch;
}
.login-left {
    flex: 1;
    background: linear-gradient(160deg, var(--saulto-900) 0%, var(--saulto-700) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 48px;
    position: relative;
    overflow: hidden;
}
.login-left::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='20'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
}
.login-left-content { position: relative; z-index: 1; text-align: center; max-width: 360px; }
.login-logo { max-width: 200px; margin-bottom: 32px; filter: brightness(0) invert(1); }
.login-tagline {
    font-size: 28px;
    font-weight: 700;
    color: #fff;
    line-height: 1.25;
    margin-bottom: 16px;
}
.login-tagline em { font-style: normal; color: var(--saulto-300); }
.login-desc { font-size: 14.5px; color: rgba(255,255,255,.65); line-height: 1.6; }

.login-right {
    width: 460px;
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 48px;
}
.login-form-wrap { width: 100%; max-width: 360px; }
.login-form-title { font-size: 22px; font-weight: 700; color: var(--text-primary); margin-bottom: 4px; }
.login-form-sub { font-size: 13.5px; color: var(--text-muted); margin-bottom: 28px; }
.login-field { margin-bottom: 16px; }
.login-field label { display: block; font-size: 12.5px; font-weight: 600; color: var(--text-secondary); margin-bottom: 5px; }
.login-input-wrap { position: relative; display: flex; align-items: center; }
.login-input-icon {
    position: absolute; left: 12px;
    color: var(--text-muted);
    font-size: 15px;
    pointer-events: none;
}
.login-input {
    width: 100%;
    height: 42px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0 12px 0 38px;
    font-size: 14px;
    color: var(--text-primary);
    font-family: inherit;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
    outline: none;
}
.login-input:focus {
    border-color: var(--saulto-500);
    box-shadow: 0 0 0 3px rgba(52,139,96,.12);
}
.login-password-toggle {
    position: absolute; right: 12px;
    background: none; border: none;
    color: var(--text-muted);
    cursor: pointer; font-size: 15px;
    padding: 0; display: flex;
    transition: color 0.12s;
}
.login-password-toggle:hover { color: var(--text-primary); }
.login-remember { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-secondary); margin-bottom: 20px; cursor: pointer; }
.login-remember input { cursor: pointer; accent-color: var(--saulto-700); }
.login-btn {
    width: 100%;
    height: 44px;
    background: var(--saulto-800);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 15px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.login-btn:hover {
    background: var(--saulto-700);
    box-shadow: 0 4px 14px rgba(26,71,49,.3);
}

/* ───────────────────────────────────────────
   Utility
─────────────────────────────────────────── */
.text-muted { color: var(--text-muted) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.fw-500 { font-weight: 500; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.divider { border: none; border-top: 1px solid var(--border); margin: 16px 0; }
.tag {
    display: inline-flex; align-items: center;
    padding: 2px 8px;
    background: #f0f3f7;
    color: var(--text-secondary);
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

/* ───────────────────────────────────────────
   Scrollbar
─────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #d0d9e6; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #b0bccf; }

/* ───────────────────────────────────────────
   Responsive
─────────────────────────────────────────── */
@media (max-width: 640px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar.open { transform: translateX(0); }
    .main-content { margin-left: 0; }
    .login-left { display: none; }
    .login-right { width: 100%; }
    .stat-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── Toggle switches: red off, green on ── */
.form-check.form-switch .form-check-input {
    background-color: #ef4444;
    border-color: #ef4444;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
}
.form-check.form-switch .form-check-input:focus {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239,68,68,.2);
}
.form-check.form-switch .form-check-input:checked {
    background-color: #22c55e;
    border-color: #22c55e;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
}
.form-check.form-switch .form-check-input:checked:focus {
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34,197,94,.2);
}
