/* =====================================================
   O3Cloud Manager
   Enterprise Edition
   ===================================================== */

html,
body{

    height:100%;

}

body{

    margin:0;
    padding:0;

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

    background:#f8f9fa;

    color:#2c3e50;

    overflow:hidden;

}

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

.layout{

    display:flex;

    height:100vh;

    min-height:100vh;

    overflow:hidden;

}

.main{

    flex:1;

    display:flex;

    flex-direction:column;

    min-width:0;

    height:100vh;

    overflow:hidden;

}

.content{

    flex:1;

    padding:35px;

    min-width:0;

    overflow:auto;

}

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

.sidebar{

    width:270px;

    flex:0 0 270px;

    height:100vh;

    min-height:0;

    background:#4B1685;

    color:#FFF;

    display:flex;

    flex-direction:column;

    justify-content:flex-start;

    overflow:hidden;

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

}


.sidebar > div:first-child{

    display:flex;

    flex:1 1 auto;

    flex-direction:column;

    min-height:0;

    overflow:hidden;

}

/* ===================================================== */

.sidebar-header{

    padding:22px 22px 18px;

    text-align:center;

    flex:0 0 auto;

}

.logo{

    width:96px;

    margin-bottom:12px;

}

.sidebar-header h4{

    margin:0;

    font-size:24px;

    font-weight:700;

}

.sidebar-header p{

    margin-top:8px;

    line-height:1.35;

    color:rgba(255,255,255,.85);

    font-size:13px;

}

/* ===================================================== */

.sidebar-divider{

    height:1px;

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

}

/* ===================================================== */

.sidebar-menu{

    padding:14px 0;

    flex:1 1 auto;

    min-height:0;

    overflow-y:auto;

    overscroll-behavior:contain;

    scrollbar-width:thin;

    scrollbar-color:rgba(255,255,255,.35) rgba(255,255,255,.08);

}

.sidebar-menu::-webkit-scrollbar{

    width:8px;

}

.sidebar-menu::-webkit-scrollbar-track{

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

}

.sidebar-menu::-webkit-scrollbar-thumb{

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

    border-radius:999px;

}

.sidebar-menu::-webkit-scrollbar-thumb:hover{

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

}

/* ===================================================== */

.menu-item{

    display:flex;

    align-items:center;

    gap:15px;

    color:#FFF;

    text-decoration:none;

    padding:16px 30px;

    border-left:4px solid transparent;

    transition:.25s;

}

.menu-item:hover{

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

    border-left:4px solid #FFF;

    color:#FFF;

    padding-left:36px;

}

.menu-item.active{

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

    border-left:4px solid #FFF;

    font-weight:600;

}

/* ===================================================== */

.sidebar-footer{

    border-top:1px solid rgba(255,255,255,.15);

    padding:25px;

    text-align:center;

    flex:0 0 auto;

    font-size:14px;

}

.status-dot{

    width:10px;

    height:10px;

    display:inline-block;

    border-radius:50%;

    background:#1DD75B;

    margin-right:8px;

}

.sidebar-footer small{

    display:block;

    margin-top:10px;

    color:rgba(255,255,255,.75);

}

/* =====================================================
   NAVBAR
   ===================================================== */

.navbar{

    height:75px;

    background:#FFF;

    border-bottom:1px solid #E6E6E6;

    padding:0 30px;

}

.page-title{

    margin:0;

    font-size:28px;

    font-weight:700;

}

.user-area{

    display:flex;

    align-items:center;

    gap:25px;

}

.edition{

    color:#777;

}

.user{

    font-weight:600;

}

/* =====================================================
   DASHBOARD
   ===================================================== */

.dashboard-title{

    font-size:38px;

    font-weight:700;

    margin-bottom:10px;

}

.dashboard-subtitle{

    color:#888;

    margin-bottom:30px;

}

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

.dashboard-card{

    border:none;

    border-radius:14px;

    box-shadow:0 4px 15px rgba(0,0,0,.08);

    transition:.25s;

}

.dashboard-card:hover{

    transform:translateY(-4px);

}

.dashboard-card .card-body{

    padding:25px;

}

.card-title{

    color:#777;

    font-size:15px;

}

.card-number{

    font-size:38px;

    font-weight:700;

    margin-top:10px;

}

.card-info{

    color:#999;

    font-size:13px;

    margin-top:15px;

}

/* =====================================================
   FOOTER
   ===================================================== */

.footer{

    background:#FFF;

    border-top:1px solid #E6E6E6;

    text-align:center;

    padding:15px;

    color:#888;

    font-size:14px;

}

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

.table{

    background:#FFF;

}

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

.btn-primary{

    background:#4B1685;

    border-color:#4B1685;

}

.btn-primary:hover{

    background:#5d1ba5;

    border-color:#5d1ba5;

}

.menu-section{

    padding:18px 30px 8px;

    color:#bca7e7;

    font-size:12px;

    font-weight:700;

    text-transform:uppercase;

    letter-spacing:1px;

}

.sidebar-menu a{

    display:flex;

    align-items:center;

    gap:12px;

    color:white;

    text-decoration:none;

    padding:12px 30px;

    transition:.25s;

}

.sidebar-menu a:hover{

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

    color:white;

}

.submenu-item{

    padding-left:48px !important;

    font-size:14px;

    opacity:.92;

}


/* =====================================================
   TABELA DE PRECOS
   ===================================================== */

.tabela-precos-page{

    max-width:1400px;

}

.base44-hero{

    background:linear-gradient(135deg,#ffffff 0%,#f4f0fb 100%);

    border:1px solid #e8ddf8;

    border-radius:22px;

    padding:28px 30px;

    display:flex;

    justify-content:space-between;

    align-items:flex-start;

    gap:20px;

    box-shadow:0 14px 40px rgba(75,22,133,.08);

}

.base44-eyebrow{

    font-size:12px;

    font-weight:700;

    letter-spacing:1.2px;

    text-transform:uppercase;

    color:#7d63ab;

    margin-bottom:8px;

}

.base44-title{

    font-size:34px;

    line-height:1.05;

    font-weight:700;

    margin:0;

    color:#231634;

}

.base44-subtitle{

    margin:10px 0 0;

    color:#6f6680;

    font-size:15px;

}

.base44-hero-actions{

    display:flex;

    gap:12px;

    flex-wrap:wrap;

}

.base44-action-secondary{

    border:1px solid #ddd4ec;

    color:#3b2e4f;

    background:#fff;

}

.base44-action-secondary:hover{

    background:#f8f4ff;

    border-color:#c8b8e7;

}

.base44-action-primary{

    min-width:132px;

}

.base44-section{

    background:#fff;

    border:1px solid #ebe7f2;

    border-radius:20px;

    box-shadow:0 10px 26px rgba(32,22,53,.05);

    overflow:hidden;

}

.base44-section-header{

    display:flex;

    justify-content:space-between;

    align-items:center;

    gap:16px;

    padding:24px 26px 14px;

}

.base44-section-title{

    margin:0;

    font-size:24px;

    font-weight:700;

    color:#1f1730;

}

.base44-section-subtitle{

    margin:6px 0 0;

    color:#7d748b;

    font-size:14px;

}

.base44-inline-action{

    white-space:nowrap;

}

.base44-table-shell{

    padding:0 12px 12px;

}

.base44-table{

    --bs-table-bg:transparent;

    margin:0;

}

.base44-table thead th{

    border-top:none;

    border-bottom:1px solid #ece7f4;

    color:#7f7790;

    font-size:12px;

    font-weight:700;

    text-transform:uppercase;

    letter-spacing:.5px;

    padding:14px 14px;

    background:#fcfbfe;

}

.base44-table tbody td{

    border-bottom:1px solid #f0edf6;

    padding:15px 14px;

    vertical-align:middle;

}

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

    border-bottom:none;

}

.base44-table tbody tr:hover{

    background:#faf7ff;

}

.base44-main-cell{

    display:flex;

    flex-direction:column;

    gap:2px;

}

.base44-muted-text{

    color:#645d74;

}

.base44-money{

    font-weight:700;

    color:#2f2442;

    white-space:nowrap;

}

.base44-check-pill{

    display:inline-flex;

    align-items:center;

    gap:6px;

    padding:5px 10px;

    border-radius:999px;

    background:#e8f8ee;

    color:#198754;

    font-weight:600;

    font-size:13px;

}

.base44-empty-pill{

    color:#a39ab3;

    font-weight:600;

}

.base44-category-chip{

    display:inline-flex;

    align-items:center;

    padding:5px 10px;

    border-radius:999px;

    background:#f1ebfb;

    color:#5d3d96;

    font-size:13px;

    font-weight:600;

}

@media (max-width: 991px){

    .base44-hero,
    .base44-section-header{

        flex-direction:column;

        align-items:stretch;

    }

    .base44-title{

        font-size:28px;

    }

    .tabela-precos-page{

        max-width:none;

    }

}


.global-backbar{

    display:flex;

    justify-content:flex-start;

    margin-bottom:18px;

}

.global-back-button{

    border-color:#d9d2e7;

    color:#4b1685;

    background:#fff;

    border-radius:999px;

    padding:8px 16px;

    font-weight:600;

    box-shadow:0 6px 16px rgba(75,22,133,.06);

}

.global-back-button:hover{

    color:#4b1685;

    background:#f7f2ff;

    border-color:#c8b8e7;

}


/* =====================================================
   PIPELINE COMERCIAL
   ===================================================== */

.pipeline-page{

    max-width:100%;

}

.pipeline-board{

    display:grid;

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

    gap:18px;

    align-items:start;

}

.pipeline-column{

    background:linear-gradient(180deg,#ffffff 0%,#f8f6fc 100%);

    border:1px solid #e6def4;

    border-radius:20px;

    min-height:280px;

    overflow:hidden;

}

.pipeline-column-header{

    display:flex;

    justify-content:space-between;

    align-items:flex-start;

    gap:16px;

    padding:18px 18px 14px;

    border-bottom:1px solid #eee7f7;

    background:rgba(75,22,133,.04);

}

.pipeline-column-meta{

    color:#7b7390;

    font-size:13px;

}

.pipeline-column-total{

    font-size:13px;

    font-weight:700;

    color:#4B1685;

}

.pipeline-column-body{

    padding:16px;

    display:flex;

    flex-direction:column;

    gap:14px;

}

.pipeline-card{

    background:#fff;

    border:1px solid #ece7f5;

    border-radius:16px;

    padding:14px;

    box-shadow:0 8px 18px rgba(75,22,133,.06);

}

.pipeline-card-title-row{

    display:flex;

    justify-content:space-between;

    gap:12px;

    align-items:flex-start;

}

.pipeline-probabilidade{

    background:#f1e9ff;

    color:#4B1685;

    border-radius:999px;

    padding:4px 10px;

    font-size:12px;

    font-weight:700;

    white-space:nowrap;

}

.pipeline-card-company{

    color:#4f4b5d;

    font-weight:600;

    margin-bottom:10px;

}

.pipeline-card-meta{

    display:grid;

    gap:6px;

    font-size:13px;

    color:#6c7582;

    margin-bottom:12px;

}

.pipeline-card-actions{

    display:flex;

    gap:8px;

    justify-content:flex-end;

}

.pipeline-empty{

    border:1px dashed #d9cee9;

    border-radius:14px;

    padding:18px;

    text-align:center;

    color:#847b95;

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

}

.pipeline-summary-card{

    background:#fff;

    border:1px solid #ebe4f6;

    border-radius:18px;

    padding:18px 20px;

    height:100%;

}

.pipeline-summary-card.success{

    background:linear-gradient(180deg,#f1fff5 0%,#ffffff 100%);

}

.pipeline-summary-card.danger{

    background:linear-gradient(180deg,#fff3f3 0%,#ffffff 100%);

}

.pipeline-summary-label{

    color:#7a728f;

    font-size:13px;

    margin-bottom:8px;

}

.pipeline-summary-value{

    font-size:24px;

    font-weight:700;

    color:#2c3e50;

}

body.dark-mode .pipeline-column{

    background:linear-gradient(180deg,#1f2937 0%,#172033 100%);

    border-color:#374151;

    box-shadow:0 12px 28px rgba(0,0,0,.22);

}

body.dark-mode .pipeline-column-header{

    background:#111827;

    border-bottom-color:#374151;

}

body.dark-mode .pipeline-column-header h5,
body.dark-mode .pipeline-card-title-row h6{

    color:#f9fafb;

}

body.dark-mode .pipeline-column-meta,
body.dark-mode .pipeline-card-meta,
body.dark-mode .pipeline-summary-label{

    color:#9ca3af;

}

body.dark-mode .pipeline-column-total{

    color:#c4b5fd;

}

body.dark-mode .pipeline-card{

    background:#111827;

    border-color:#374151;

    box-shadow:0 10px 22px rgba(0,0,0,.26);

}

body.dark-mode .pipeline-card-company{

    color:#d1d5db;

}

body.dark-mode .pipeline-probabilidade{

    background:#312e81;

    color:#ddd6fe;

}

body.dark-mode .pipeline-empty{

    background:#111827;

    border-color:#4b5563;

    color:#9ca3af;

}

body.dark-mode .pipeline-summary-card{

    background:#111827;

    border-color:#374151;

}

body.dark-mode .pipeline-summary-card.success{

    background:linear-gradient(180deg,#064e3b 0%,#111827 100%);

    border-color:#047857;

}

body.dark-mode .pipeline-summary-card.danger{

    background:linear-gradient(180deg,#7f1d1d 0%,#111827 100%);

    border-color:#991b1b;

}

body.dark-mode .pipeline-summary-value{

    color:#f9fafb;

}

body.dark-mode .pipeline-semaforo{

    border-color:rgba(255,255,255,.32);

}

@media (max-width: 1600px){

    .pipeline-board{

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

    }

}

@media (max-width: 992px){

    .pipeline-board{

        grid-template-columns:1fr;

    }

}


/* =====================================================
   LOGIN
   ===================================================== */

.login-body{
    min-height:100vh;
    overflow:auto;
    background:#f2f4f7;
}

.login-shell{
    min-height:100vh;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:32px 16px;
}

.login-panel{
    width:100%;
    max-width:430px;
    background:#fff;
    border-radius:8px;
    padding:34px;
}

.login-logo{
    width:92px;
    margin-bottom:16px;
}

.login-panel h1{
    font-size:1.45rem;
    font-weight:700;
    margin:0;
}
/* =====================================================
   USER MENU / THEME
   ===================================================== */

.user-area{
    display:flex;
    align-items:center;
    gap:12px;
}

.user-menu-toggle{
    display:flex;
    align-items:center;
    gap:8px;
    border:1px solid #e5e7eb;
    background:#fff;
    color:#2c3e50;
    padding:5px 10px;
    border-radius:8px;
}

.user-menu-toggle:hover,
.user-menu-toggle:focus{
    background:#f8f9fa;
    border-color:#d7dce2;
}

.user-avatar,
.user-profile-photo{
    width:34px;
    height:34px;
    border-radius:50%;
    object-fit:cover;
    border:1px solid #d7dce2;
    background:#fff;
}

.user-profile-photo{
    width:76px;
    height:76px;
}

.user-avatar-empty,
.user-profile-photo-empty{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    color:#6b7280;
    background:#f1f3f5;
}

.user-profile-photo-empty i{
    font-size:2rem;
}

.user-name{
    max-width:180px;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
}

.user-dropdown{
    min-width:260px;
    border:0;
    box-shadow:0 16px 36px rgba(15,23,42,.16);
    border-radius:8px;
}

.user-dropdown .dropdown-item{
    display:flex;
    align-items:center;
    gap:8px;
}

body.dark-mode{
    background:#111827;
    color:#e5e7eb;
}

body.dark-mode .main,
body.dark-mode .content{
    background:#111827;
}

body.dark-mode .navbar,
body.dark-mode .card,
body.dark-mode .card-header,
body.dark-mode .dropdown-menu,
body.dark-mode .list-group-item,
body.dark-mode .table,
body.dark-mode .modal-content{
    background:#1f2937 !important;
    color:#e5e7eb;
}

body.dark-mode .text-muted,
body.dark-mode small,
body.dark-mode .form-text{
    color:#9ca3af !important;
}

body.dark-mode .form-control,
body.dark-mode .form-select{
    background:#111827;
    border-color:#374151;
    color:#e5e7eb;
}

body.dark-mode .table-light,
body.dark-mode .bg-white,
body.dark-mode .bg-light{
    background:#273244 !important;
    color:#e5e7eb !important;
}

body.dark-mode .user-menu-toggle{
    background:#1f2937;
    border-color:#374151;
    color:#e5e7eb;
}

body.dark-mode .dropdown-item{
    color:#e5e7eb;
}

body.dark-mode .dropdown-item:hover,
body.dark-mode .dropdown-item:focus{
    background:#374151;
}

body.dark-mode .sidebar{
    background:#020617;
    box-shadow:5px 0 20px rgba(0,0,0,.35);
}

body.dark-mode .sidebar-divider{
    background:rgba(255,255,255,.10);
}

body.dark-mode .sidebar-header p,
body.dark-mode .sidebar .section-title{
    color:rgba(255,255,255,.68) !important;
}

body.dark-mode .menu-item,
body.dark-mode .submenu-toggle{
    color:rgba(255,255,255,.86);
}

body.dark-mode .menu-item:hover,
body.dark-mode .submenu-toggle:hover,
body.dark-mode .menu-item.active{
    background:rgba(255,255,255,.10);
    color:#fff;
}

body.dark-mode .submenu{
    background:rgba(255,255,255,.04);
}

body.dark-mode #darkModeSwitch{
    pointer-events:none;
}

body.dark-mode .table{
    --bs-table-bg:#1f2937;
    --bs-table-color:#e5e7eb;
    --bs-table-border-color:#374151;
    --bs-table-striped-bg:#273244;
    --bs-table-striped-color:#e5e7eb;
    --bs-table-hover-bg:#334155;
    --bs-table-hover-color:#fff;
    color:#e5e7eb;
    border-color:#374151;
}

body.dark-mode .table > :not(caption) > * > *,
body.dark-mode .table tbody,
body.dark-mode .table td,
body.dark-mode .table th{
    background-color:var(--bs-table-bg) !important;
    color:#e5e7eb !important;
    border-color:#374151 !important;
}

body.dark-mode .table thead th,
body.dark-mode .table-light > :not(caption) > * > *{
    background:#273244 !important;
    color:#f9fafb !important;
    border-color:#374151 !important;
}

body.dark-mode .table-hover > tbody > tr:hover > *{
    background:#334155 !important;
    color:#fff !important;
}

body.dark-mode .table-responsive{
    background:#1f2937;
}

body.dark-mode .text-dark,
body.dark-mode .text-black{
    color:#e5e7eb !important;
}

body.dark-mode .text-bg-light,
body.dark-mode .badge.bg-light{
    background:#374151 !important;
    color:#f9fafb !important;
    border-color:#4b5563 !important;
}

body.dark-mode .alert-warning,
body.dark-mode .table-warning > :not(caption) > * > *,
body.dark-mode tr.table-warning > td,
body.dark-mode tr.table-warning > th{
    background:#78350f !important;
    color:#fef3c7 !important;
    border-color:#92400e !important;
}

body.dark-mode .alert-warning .text-muted,
body.dark-mode tr.table-warning .text-muted,
body.dark-mode tr.table-warning small{
    color:#fde68a !important;
}

body.dark-mode .alert-danger,
body.dark-mode .table-danger > :not(caption) > * > *,
body.dark-mode tr.table-danger > td,
body.dark-mode tr.table-danger > th{
    background:#7f1d1d !important;
    color:#fee2e2 !important;
    border-color:#991b1b !important;
}

body.dark-mode .alert-danger .text-muted,
body.dark-mode tr.table-danger .text-muted,
body.dark-mode tr.table-danger small{
    color:#fecaca !important;
}

body.dark-mode .text-bg-warning,
body.dark-mode .badge.text-bg-warning,
body.dark-mode .badge.bg-warning{
    background:#f59e0b !important;
    color:#111827 !important;
}

body.dark-mode .text-bg-danger,
body.dark-mode .badge.text-bg-danger,
body.dark-mode .badge.bg-danger{
    background:#ef4444 !important;
    color:#fff !important;
}

body.dark-mode .alert-success,
body.dark-mode .table-success > :not(caption) > * > *,
body.dark-mode tr.table-success > td,
body.dark-mode tr.table-success > th{
    background:#064e3b !important;
    color:#d1fae5 !important;
    border-color:#047857 !important;
}

body.dark-mode .alert-success .text-muted,
body.dark-mode tr.table-success .text-muted,
body.dark-mode tr.table-success small{
    color:#a7f3d0 !important;
}

body.dark-mode .text-bg-success,
body.dark-mode .badge.text-bg-success,
body.dark-mode .badge.bg-success{
    background:#10b981 !important;
    color:#052e16 !important;
}

body.dark-mode .footer{
    background:#111827 !important;
    border-top-color:#1f2937 !important;
    color:#f9fafb !important;
}


.parceiro-categoria {
    border: 1px solid transparent;
    font-weight: 700;
    letter-spacing: 0;
}

.parceiro-categoria-platinium {
    background: #45484d;
    border-color: #2e3034;
    color: #fff;
}

.parceiro-categoria-ouro {
    background: #f2c94c;
    border-color: #c99a17;
    color: #3a2a00;
}

.parceiro-categoria-prata {
    background: #e5e7eb;
    border-color: #c7ccd3;
    color: #333842;
}

.parceiro-categoria-bronze {
    background: #c46a2b;
    border-color: #8f481b;
    color: #fff7ed;
}

/* Oculta controles de exclusao para perfis sem a permissao global. */
body.sem-exclusao a[href*="/excluir"],
body.sem-exclusao a[href*="/desativar"],
body.sem-exclusao a[href*="/inativar"],
body.sem-exclusao form[action*="/excluir"],
body.sem-exclusao form[action*="/desativar"],
body.sem-exclusao form[action*="/inativar"],
body.sem-exclusao button[formaction*="/excluir"],
body.sem-exclusao button[formaction*="/desativar"],
body.sem-exclusao button[formaction*="/inativar"] {
    display: none !important;
}
