/* ==========================================================
   LEADBUILDER ERP UI
   Version: 1.0
   ========================================================== */

:root{

    --primary:#203864;
    --primary-light:#2F75B5;

    --success:#2E8B57;
    --warning:#F0AD4E;
    --danger:#C62828;

    --background:#F4F6F9;

    --card:#FFFFFF;

    --border:#E5E7EB;

    --text:#374151;

    --text-light:#6B7280;

    --sidebar:#1B2430;

    --sidebar-hover:#263445;

    --sidebar-active:#2F75B5;

    --header:#243447;

    --radius:12px;

    --shadow:

        0 2px 12px rgba(0,0,0,.06);

    --transition:.20s;

}

/* ==========================================================
   RESET
   ========================================================== */

*{

    margin:0;

    padding:0;

    box-sizing:border-box;

}

html{

    height:100%;

}

body{

    height:100%;

    background:var(--background);

    font-family:

        Inter,

        "Segoe UI",

        sans-serif;

    color:var(--text);

    font-size:14px;

}

/* ==========================================================
   LINKS
   ========================================================== */

a{

    color:inherit;

    text-decoration:none;

}

a:hover{

    text-decoration:none;

}

/* ==========================================================
   LAYOUT
   ========================================================== */

.lb-app{

    display:flex;

    min-height:100vh;

}

/* ==========================================================
   SIDEBAR
   ========================================================== */

.lb-sidebar{

    width:260px;

    background:var(--sidebar);

    color:white;

    display:flex;

    flex-direction:column;

}

.lb-logo{

    height:72px;

    display:flex;

    align-items:center;

    justify-content:center;

    font-size:24px;

    font-weight:700;

    letter-spacing:1px;

    border-bottom:

        1px solid rgba(255,255,255,.08);

}

.lb-logo span{

    color:#6EC1FF;

}

/* ==========================================================
   MENU
   ========================================================== */

.lb-menu{

    padding:20px 0;

}

.lb-menu a{

    display:flex;

    align-items:center;

    gap:14px;

    color:#D8DEE9;

    padding:

        14px 24px;

    transition:

        var(--transition);

    font-size:15px;

}

.lb-menu a:hover{

    background:

        var(--sidebar-hover);

    color:white;

}

.lb-menu a.active{

    background:

        var(--sidebar-active);

    color:white;

}

.lb-menu i{

    width:22px;

    text-align:center;

    font-size:17px;

}

/* ==========================================================
   CONTENT
   ========================================================== */

.lb-content{

    flex:1;

    display:flex;

    flex-direction:column;

}

/* ==========================================================
   HEADER
   ========================================================== */

.lb-header{

    height:72px;

    background:white;

    border-bottom:

        1px solid var(--border);

    display:flex;

    justify-content:space-between;

    align-items:center;

    padding:

        0 28px;

}

.lb-header-left{

    display:flex;

    align-items:center;

    gap:18px;

}

.lb-header-right{

    display:flex;

    align-items:center;

    gap:20px;

}
/* ==========================================================
   PAGE
   ========================================================== */

.lb-page{

    padding:30px;

}

.lb-page-title{

    font-size:28px;

    font-weight:700;

    color:var(--primary);

    margin-bottom:30px;

}

/* ==========================================================
   GRID
   ========================================================== */

.lb-grid{

    display:grid;

    gap:24px;

}

.lb-grid-2{

    grid-template-columns:repeat(2,1fr);

}

.lb-grid-3{

    grid-template-columns:repeat(3,1fr);

}

.lb-grid-4{

    grid-template-columns:repeat(4,1fr);

}

/* ==========================================================
   CARD
   ========================================================== */

.lb-card{

    background:var(--card);

    border-radius:var(--radius);

    box-shadow:var(--shadow);

    overflow:hidden;

    transition:.25s;

}

.lb-card:hover{

    transform:translateY(-2px);

    box-shadow:

        0 8px 25px rgba(0,0,0,.08);

}

.lb-card-header{

    padding:18px 24px;

    border-bottom:

        1px solid var(--border);

    font-size:17px;

    font-weight:600;

}

.lb-card-body{

    padding:24px;

}

.lb-card-footer{

    padding:18px 24px;

    border-top:

        1px solid var(--border);

}

/* ==========================================================
   KPI
   ========================================================== */

.lb-kpi{

    background:white;

    border-radius:14px;

    padding:24px;

    display:flex;

    justify-content:space-between;

    align-items:center;

    box-shadow:var(--shadow);

    transition:.25s;

}

.lb-kpi:hover{

    transform:translateY(-3px);

}

.lb-kpi-icon{

    width:58px;

    height:58px;

    border-radius:50%;

    display:flex;

    align-items:center;

    justify-content:center;

    font-size:24px;

    color:white;

}

.lb-kpi-primary{

    background:var(--primary);

}

.lb-kpi-success{

    background:var(--success);

}

.lb-kpi-warning{

    background:var(--warning);

}

.lb-kpi-danger{

    background:var(--danger);

}

.lb-kpi-title{

    color:var(--text-light);

    font-size:13px;

    text-transform:uppercase;

    letter-spacing:.6px;

}

.lb-kpi-value{

    font-size:34px;

    font-weight:700;

    margin-top:6px;

}

.lb-kpi-growth{

    color:var(--success);

    font-weight:600;

    margin-top:6px;

}

/* ==========================================================
   BUTTONS
   ========================================================== */

.lb-btn{

    display:inline-flex;

    align-items:center;

    justify-content:center;

    gap:10px;

    padding:11px 22px;

    border:none;

    border-radius:10px;

    cursor:pointer;

    transition:.20s;

    font-weight:600;

}

.lb-btn:hover{

    transform:translateY(-1px);

}

.lb-btn-primary{

    background:var(--primary);

    color:white;

}

.lb-btn-primary:hover{

    background:#15284B;

}

.lb-btn-success{

    background:var(--success);

    color:white;

}

.lb-btn-warning{

    background:var(--warning);

    color:white;

}

.lb-btn-danger{

    background:var(--danger);

    color:white;

}

.lb-btn-light{

    background:#EEF2F7;

    color:#374151;

}

/* ==========================================================
   BADGES
   ========================================================== */

.lb-badge{

    display:inline-block;

    padding:5px 12px;

    border-radius:30px;

    font-size:12px;

    font-weight:600;

}

.lb-badge-success{

    background:#DFF6E4;

    color:#1F7A3A;

}

.lb-badge-warning{

    background:#FFF4D6;

    color:#B77900;

}

.lb-badge-danger{

    background:#FDE5E5;

    color:#B42318;

}

.lb-badge-primary{

    background:#DDEBFA;

    color:#1D4F91;

}
/* ==========================================================
   TABLES
   ========================================================== */

.lb-table-wrapper{

    background:#fff;

    border-radius:14px;

    box-shadow:var(--shadow);

    overflow:hidden;

}

.lb-table{

    width:100%;

    border-collapse:collapse;

}

.lb-table thead{

    background:#F8FAFC;

}

.lb-table thead th{

    padding:18px;

    text-align:left;

    font-size:13px;

    text-transform:uppercase;

    color:#6B7280;

    letter-spacing:.6px;

    border-bottom:1px solid var(--border);

}

.lb-table tbody td{

    padding:16px 18px;

    border-bottom:1px solid #F2F2F2;

    vertical-align:middle;

}

.lb-table tbody tr{

    transition:.18s;

}

.lb-table tbody tr:hover{

    background:#F8FBFF;

}

.lb-table tbody tr:last-child td{

    border-bottom:none;

}

/* ==========================================================
   ACTION BUTTONS
   ========================================================== */

.lb-actions{

    display:flex;

    gap:8px;

}

.lb-action{

    width:34px;

    height:34px;

    display:flex;

    justify-content:center;

    align-items:center;

    border-radius:8px;

    background:#EEF2F7;

    color:#374151;

    transition:.20s;

    cursor:pointer;

}

.lb-action:hover{

    background:var(--primary);

    color:white;

}

/* ==========================================================
   SEARCH BAR
   ========================================================== */

.lb-search{

    display:flex;

    gap:15px;

    align-items:center;

    margin-bottom:25px;

}

.lb-search input{

    flex:1;

    height:44px;

    border:1px solid var(--border);

    border-radius:10px;

    padding:0 18px;

    font-size:14px;

    transition:.20s;

}

.lb-search input:focus{

    outline:none;

    border-color:var(--primary-light);

    box-shadow:0 0 0 3px rgba(47,117,181,.15);

}

.lb-search select{

    height:44px;

    border:1px solid var(--border);

    border-radius:10px;

    padding:0 14px;

    background:white;

}

/* ==========================================================
   FORM
   ========================================================== */

.lb-form{

    display:grid;

    grid-template-columns:repeat(2,1fr);

    gap:22px;

}

.lb-field{

    display:flex;

    flex-direction:column;

}

.lb-field-full{

    grid-column:1 / -1;

}

.lb-label{

    margin-bottom:8px;

    font-weight:600;

    color:#4B5563;

}

.lb-input{

    height:46px;

    border:1px solid var(--border);

    border-radius:10px;

    padding:0 15px;

    transition:.20s;

}

.lb-input:focus{

    outline:none;

    border-color:var(--primary-light);

    box-shadow:0 0 0 3px rgba(47,117,181,.15);

}

textarea.lb-input{

    min-height:130px;

    padding:15px;

    resize:vertical;

}
/* ==========================================================
   TIMELINE
   ========================================================== */

.lb-timeline{

    position:relative;

    margin-left:18px;

    padding-left:28px;

}

.lb-timeline::before{

    content:"";

    position:absolute;

    left:8px;

    top:0;

    bottom:0;

    width:2px;

    background:#D9E2EC;

}

.lb-event{

    position:relative;

    margin-bottom:28px;

}

.lb-event::before{

    content:"";

    position:absolute;

    left:-24px;

    top:6px;

    width:14px;

    height:14px;

    border-radius:50%;

    background:var(--primary);

}

.lb-event-title{

    font-weight:700;

    margin-bottom:4px;

}

.lb-event-date{

    font-size:12px;

    color:#6B7280;

    margin-bottom:8px;

}

.lb-event-text{

    color:#4B5563;

}

/* ==========================================================
   PROGRESS
   ========================================================== */

.lb-progress{

    width:100%;

    height:10px;

    background:#E5E7EB;

    border-radius:50px;

    overflow:hidden;

}

.lb-progress-bar{

    height:100%;

    background:linear-gradient(

        90deg,

        var(--primary),

        var(--primary-light)

    );

}

/* ==========================================================
   STATUS
   ========================================================== */

.lb-status{

    display:inline-flex;

    align-items:center;

    gap:8px;

    font-weight:600;

}

.lb-status-dot{

    width:10px;

    height:10px;

    border-radius:50%;

}

.lb-status-success{

    background:#22C55E;

}

.lb-status-warning{

    background:#F59E0B;

}

.lb-status-danger{

    background:#EF4444;

}

.lb-status-info{

    background:#3B82F6;

}

/* ==========================================================
   RESPONSIVE
   ========================================================== */

@media(max-width:1200px){

    .lb-grid-4{

        grid-template-columns:repeat(2,1fr);

    }

}

@media(max-width:992px){

    .lb-sidebar{

        width:75px;

    }

    .lb-logo{

        font-size:14px;

    }

    .lb-menu span{

        display:none;

    }

    .lb-form{

        grid-template-columns:1fr;

    }

}

@media(max-width:768px){

    .lb-grid-4,

    .lb-grid-3,

    .lb-grid-2{

        grid-template-columns:1fr;

    }

    .lb-page{

        padding:15px;

    }

}
/* ===========================
   HEADER
=========================== */

.lb-search-box{

    width:520px;

    height:44px;

    background:#F3F5F8;

    border-radius:10px;

    display:flex;

    align-items:center;

    padding:0 18px;

}

.lb-search-box i{

    color:#8A94A6;

    margin-right:12px;

}

.lb-search-box input{

    flex:1;

    border:none;

    background:transparent;

    outline:none;

    font-size:14px;

}

.lb-icon-button{

    width:42px;

    height:42px;

    border:none;

    border-radius:10px;

    background:#F3F5F8;

    cursor:pointer;

    position:relative;

    transition:.2s;

}

.lb-icon-button:hover{

    background:#E8EDF4;

}

.lb-badge-notification{

    position:absolute;

    right:-4px;

    top:-4px;

    width:18px;

    height:18px;

    border-radius:50%;

    background:#E53935;

    color:white;

    font-size:10px;

    display:flex;

    align-items:center;

    justify-content:center;

}

.lb-user{

    display:flex;

    align-items:center;

    gap:12px;

}

.lb-avatar{

    width:42px;

    height:42px;

    border-radius:50%;

    background:linear-gradient(135deg,#203864,#2F75B5);

    color:white;

    display:flex;

    align-items:center;

    justify-content:center;

    font-weight:700;

}

.lb-system-status{

    display:flex;

    align-items:center;

    gap:8px;

    font-size:13px;

    color:#555;

}

.lb-online{

    width:10px;

    height:10px;

    border-radius:50%;

    background:#28C76F;

    box-shadow:0 0 8px #28C76F;

}
/* ==========================================================
   LEADBUILDER ERP PREMIUM UI v0.2
   ========================================================== */

:root{

    --lb-primary:#2563eb;
    --lb-primary-dark:#1d4ed8;

    --lb-bg:#f5f7fb;
    --lb-card:#ffffff;

    --lb-text:#1f2937;
    --lb-text-light:#6b7280;

    --lb-border:#e5e7eb;

    --lb-success:#16a34a;
    --lb-warning:#f59e0b;
    --lb-danger:#dc2626;

    --lb-radius:16px;

    --lb-shadow:
        0 10px 30px rgba(15,23,42,.08);

}

body.lb-body{

    background:var(--lb-bg);

    font-family:'Inter',sans-serif;

    color:var(--lb-text);

}

/* ===========================
   LAYOUT
=========================== */

.lb-wrapper{

    display:flex;

    min-height:100vh;

}

.lb-main{

    flex:1;

    margin-left:280px;

    padding:30px;

}

/* ===========================
   SIDEBAR
=========================== */

.lb-sidebar{

    position:fixed;

    left:0;

    top:0;

    width:280px;

    height:100vh;

    background:#0f172a;

    color:#fff;

    display:flex;

    flex-direction:column;

    box-shadow:0 0 40px rgba(0,0,0,.25);

    z-index:1000;

}

.lb-logo{

    display:flex;

    align-items:center;

    gap:15px;

    padding:28px;

    border-bottom:1px solid rgba(255,255,255,.08);

}

.lb-logo-icon{

    width:54px;

    height:54px;

    border-radius:14px;

    background:linear-gradient(135deg,#2563eb,#4f46e5);

    display:flex;

    justify-content:center;

    align-items:center;

    font-size:20px;

    font-weight:700;

}

.lb-logo-title{

    font-size:20px;

    font-weight:700;

}

.lb-logo-version{

    font-size:12px;

    opacity:.6;

}

/* ===========================
   MENU
=========================== */

.lb-menu{

    padding:20px;

    overflow:auto;

    flex:1;

}

.lb-menu-title{

    font-size:11px;

    letter-spacing:2px;

    opacity:.55;

    margin:18px 10px;

}

.lb-menu-item{

    display:flex;

    align-items:center;

    gap:15px;

    color:#d1d5db;

    padding:13px 15px;

    border-radius:12px;

    text-decoration:none;

    transition:.25s;

    margin-bottom:5px;

}

.lb-menu-item:hover{

    background:rgba(255,255,255,.06);

    color:#fff;

}

.lb-menu-item.active{

    background:linear-gradient(90deg,#2563eb,#4f46e5);

    color:#fff;

}

.lb-menu-item i{

    width:22px;

    text-align:center;

}

/* ===========================
   TOPBAR
=========================== */

.lb-topbar{

    background:#fff;

    border-radius:18px;

    box-shadow:var(--lb-shadow);

    padding:18px 25px;

    margin-bottom:30px;

    display:flex;

    justify-content:space-between;

    align-items:center;

}

.lb-search{

    display:flex;

    align-items:center;

    gap:12px;

    width:460px;

    background:#f3f4f6;

    padding:12px 18px;

    border-radius:12px;

}

.lb-search input{

    border:none;

    background:none;

    width:100%;

    outline:none;

}

.lb-icon-button{

    position:relative;

    width:46px;

    height:46px;

    border:none;

    background:#f3f4f6;

    border-radius:12px;

}

.lb-counter{

    position:absolute;

    right:-4px;

    top:-4px;

    background:#ef4444;

    color:#fff;

    width:20px;

    height:20px;

    border-radius:50%;

    font-size:11px;

    display:flex;

    justify-content:center;

    align-items:center;

}

/* ===========================
   CARDS
=========================== */

.lb-card,
.lb-kpi-card{

    background:#fff;

    border-radius:18px;

    box-shadow:var(--lb-shadow);

    border:none;

}

.lb-card{

    overflow:hidden;

}

.lb-card-header{

    padding:22px 28px;

    border-bottom:1px solid var(--lb-border);

    font-size:18px;

    font-weight:600;

}

.lb-kpi-card{

    padding:26px;

}

.lb-kpi-label{

    color:var(--lb-text-light);

    font-size:14px;

}

.lb-kpi-value{

    font-size:38px;

    font-weight:700;

    margin-top:10px;

    margin-bottom:12px;

}

.lb-kpi-footer{

    font-size:13px;

    color:var(--lb-text-light);

}

/* ===========================
   TABLAS
=========================== */

.lb-table{

    margin:0;

}

.lb-table thead{

    background:#f8fafc;

}

.lb-table th{

    border:none;

    font-size:13px;

    text-transform:uppercase;

    letter-spacing:.08em;

    color:#6b7280;

}

.lb-table td{

    vertical-align:middle;

    border-color:#eef2f7;

    padding:16px;

}

/* ===========================
   BADGES
=========================== */

.lb-badge{

    display:inline-block;

    padding:6px 12px;

    border-radius:50px;

    font-size:12px;

    font-weight:600;

}

.lb-danger{

    background:#fee2e2;

    color:#dc2626;

}

/* ===========================
   TIMELINE
=========================== */

.lb-timeline{

    padding:25px;

}

.lb-event{

    position:relative;

    padding-left:28px;

    margin-bottom:22px;

}

.lb-event:before{

    content:"";

    position:absolute;

    left:0;

    top:6px;

    width:10px;

    height:10px;

    border-radius:50%;

    background:#2563eb;

}

/* ===========================
   RESPONSIVE
=========================== */

@media(max-width:1200px){

    .lb-main{
        margin-left:0;
    }

    .lb-sidebar{
        display:block;
        width:280px;
        transform:translateX(-100%);
        position:fixed;
        top:0;
        left:0;
        bottom:0;
        z-index:1100;
        overflow-y:auto;
        box-shadow:0 0 30px rgba(0,0,0,.25);
    }

    body.lb-sidebar-open{
        overflow:hidden;
    }

    body.lb-sidebar-open::before{
        content:"";
        position:fixed;
        inset:0;
        background:rgba(0,0,0,.35);
        z-index:1090;
    }

    body.lb-sidebar-open .lb-sidebar{
        transform:translateX(0);
    }

    .lb-sidebar .lb-menu span{
        display:inline;
    }

    .lb-search{
        width:240px;
    }

}
.lb-activity{

    display:flex;

    gap:15px;

    margin-bottom:22px;

}

.lb-activity:last-child{

    margin-bottom:0;

}

.lb-activity-icon{

    width:42px;

    height:42px;

    border-radius:12px;

    color:#fff;

    display:flex;

    justify-content:center;

    align-items:center;

    flex-shrink:0;

}

.lb-activity-content{

    flex:1;

}
.lb-workflow-column{

    background:#f8fafc;

    border-radius:16px;

    min-height:420px;

    padding:15px;

}

.lb-workflow-header{

    color:#fff;

    font-weight:600;

    padding:12px 16px;

    border-radius:10px;

    display:flex;

    justify-content:space-between;

    margin-bottom:15px;

}

.lb-workflow-card{

    background:#fff;

    border-radius:12px;

    padding:15px;

    margin-bottom:12px;

    box-shadow:0 5px 20px rgba(0,0,0,.06);

    transition:.25s;

    cursor:pointer;

}

.lb-workflow-card:hover{

    transform:translateY(-2px);

    box-shadow:0 15px 35px rgba(0,0,0,.10);

}

.lb-workflow-empty{

    color:#9ca3af;

    text-align:center;

    margin-top:40px;

}
/* ==========================================
   IA
========================================== */

.lb-ai-card{

    background:#fff;

    border-radius:14px;

    padding:18px;

    margin-bottom:18px;

    transition:.25s;

}

.lb-ai-card:hover{

    transform:translateY(-2px);

    box-shadow:0 12px 30px rgba(0,0,0,.08);

}

.lb-ai-icon{

    width:48px;

    min-width:48px;

    font-size:22px;

    margin-right:15px;

    display:flex;

    justify-content:center;

    align-items:flex-start;

}
/* ===================================
   JAVASCRIPT UI
=================================== */

.lb-card,
.lb-kpi-card{

    transition:.30s;

}

.lb-search.active{

    box-shadow:0 0 0 3px rgba(37,99,235,.15);

}

.lb-toast{

    position:fixed;

    right:30px;

    bottom:30px;

    min-width:320px;

    padding:18px 24px;

    border-radius:14px;

    color:#fff;

    font-weight:600;

    opacity:0;

    transform:translateY(30px);

    transition:.30s;

    z-index:99999;

}

.lb-toast.show{

    opacity:1;

    transform:translateY(0);

}

.lb-toast-success{

    background:#16a34a;

}

.lb-toast-danger{

    background:#dc2626;

}

.lb-sidebar-hidden .lb-sidebar{

    transform:translateX(-100%);

}

.lb-sidebar{

    transition:.35s;

}

.lb-sidebar-hidden .lb-main{

    margin-left:0;

}
/* Mobile navigation final overrides */
@media(max-width:1200px){
    .lb-sidebar{width:280px !important;}
}
@media(max-width:768px){
    .lb-topbar{padding:0 14px;}
    .lb-search{width:auto;flex:1;}
    .lb-search input{min-width:0;}
    .lb-topbar-right .lb-status,.lb-topbar-right .lb-date,.lb-topbar-right .lb-user,.lb-topbar-right .lb-icon-button{display:none;}
}
