:root { --creditflow-radius: 0.65rem; }
body { min-height: 100vh; }
.cursor-pointer { cursor: pointer; }
.creditflow-logo { display:flex;align-items:center;gap:.65rem;font-size:1.3rem; }
.creditflow-logo span,.creditflow-toggle-logo { width:38px;height:38px;border-radius:12px;display:inline-flex;align-items:center;justify-content:center;background:rgb(var(--primary-rgb));color:#fff;font-weight:800; }
.creditflow-logo strong { color:var(--default-text-color); }
.creditflow-toggle-logo { width:34px;height:34px;font-size:.75rem; }
.main-sidebar-header .header-logo img,.horizontal-logo .header-logo img { max-width:176px; height:42px; object-fit:contain; }
.avatar-initials { display:flex;align-items:center;justify-content:center;width:100%;height:100%;font-weight:700; }
.creditflow-auth-visual { background: radial-gradient(circle at 20% 15%, rgba(255,255,255,.18), transparent 32%), linear-gradient(135deg, rgb(var(--primary-rgb)) 0%, #352c9a 100%); }
.creditflow-auth-visual:before,.creditflow-auth-visual:after { content:"";position:absolute;border-radius:50%;border:1px solid rgba(255,255,255,.16); }
.creditflow-auth-visual:before { width:480px;height:480px;left:-150px;top:-100px; }
.creditflow-auth-visual:after { width:640px;height:640px;right:-280px;bottom:-300px; }
.auth-copy { max-width:620px;position:relative;z-index:2; }
.ajax-page-loading { min-height:55vh;display:flex;align-items:center;justify-content:center; }
.page-content-fade { animation: pageFade .22s ease; }
@keyframes pageFade { from { opacity:0; transform:translateY(4px); } to { opacity:1; transform:none; } }
.workflow-card { overflow:visible; }
.credit-workflow { display:grid;grid-template-columns:repeat(6,1fr);gap:0;position:relative; }
.workflow-step { position:relative;display:flex;align-items:center;gap:.65rem;padding:.7rem .35rem; }
.workflow-step:not(:last-child):after { content:"";position:absolute;height:2px;background:var(--default-border);top:50%;left:calc(50% + 22px);right:calc(-50% + 22px);z-index:0; }
.workflow-step.completed:not(:last-child):after { background:rgb(var(--primary-rgb)); }
.workflow-marker { width:34px;height:34px;flex:0 0 34px;border-radius:50%;border:2px solid var(--default-border);background:var(--custom-white);display:flex;align-items:center;justify-content:center;font-weight:700;position:relative;z-index:1; }
.workflow-step.completed .workflow-marker,.workflow-step.active .workflow-marker { background:rgb(var(--primary-rgb));border-color:rgb(var(--primary-rgb));color:#fff;box-shadow:0 0 0 5px rgba(var(--primary-rgb),.12); }
.workflow-step.active .workflow-marker { animation:pulseMarker 1.8s infinite; }
@keyframes pulseMarker { 50% { box-shadow:0 0 0 9px rgba(var(--primary-rgb),.04); } }
.mini-layout-card { height:65px;border:1px solid var(--default-border);border-radius:.35rem;background:var(--custom-white);display:flex;overflow:hidden;cursor:pointer;padding:5px;gap:4px; }
.mini-sidebar { width:22%;background:rgba(var(--primary-rgb),.12);border-radius:3px; }
.mini-sidebar.closed { width:12%; }.mini-sidebar.icontext { width:32%; }.mini-sidebar.overlay { width:42%;margin-right:-30%;z-index:1; }.mini-sidebar.detached { margin:4px;border-radius:6px; }.mini-sidebar.doublemenu { width:38%;box-shadow:inset 9px 0 rgba(var(--primary-rgb),.12); }
.mini-content { flex:1;background:linear-gradient(var(--default-border) 0 0) 8px 10px/60% 4px no-repeat,linear-gradient(var(--default-border) 0 0) 8px 21px/80% 4px no-repeat,linear-gradient(var(--default-border) 0 0) 8px 32px/45% 4px no-repeat; }
.btn-check:checked + .mini-layout-card { border-color:rgb(var(--primary-rgb));box-shadow:0 0 0 1px rgb(var(--primary-rgb)); }
.menu-bg-thumb { width:44px;height:44px;border-radius:.35rem;border:2px solid transparent;overflow:hidden;display:flex;align-items:center;justify-content:center;cursor:pointer;background:var(--custom-white); }
.menu-bg-thumb img { width:100%;height:100%;object-fit:cover; }.btn-check:checked + .menu-bg-thumb { border-color:rgb(var(--primary-rgb)); }.no-bg { border-color:var(--default-border); }
.color-input { width:30px;height:30px;border-radius:50%;appearance:none;background:var(--color);cursor:pointer;border:3px solid var(--custom-white);box-shadow:0 0 0 1px var(--default-border); }.color-input:checked { box-shadow:0 0 0 2px rgb(var(--primary-rgb)); }
.header-search-bar { min-width:360px; }
.table > tbody > tr.cursor-pointer:hover { background:rgba(var(--primary-rgb),.04); }
.activity-timeline li:not(:last-child) { position:relative; }.activity-timeline li:not(:last-child):after { content:"";position:absolute;left:15px;top:34px;bottom:-11px;border-left:1px dashed var(--default-border); }
[data-menu-bg="1"] .app-sidebar { background-image:linear-gradient(rgba(15,23,42,.82),rgba(15,23,42,.82)),url('../../images/menu-bg-images/bg-img1.jpg');background-size:cover; }
[data-menu-bg="2"] .app-sidebar { background-image:linear-gradient(rgba(15,23,42,.82),rgba(15,23,42,.82)),url('../../images/menu-bg-images/bg-img2.jpg');background-size:cover; }
[data-menu-bg="3"] .app-sidebar { background-image:linear-gradient(rgba(15,23,42,.82),rgba(15,23,42,.82)),url('../../images/menu-bg-images/bg-img3.jpg');background-size:cover; }
[data-menu-bg="4"] .app-sidebar { background-image:linear-gradient(rgba(15,23,42,.82),rgba(15,23,42,.82)),url('../../images/menu-bg-images/bg-img4.jpg');background-size:cover; }
[data-menu-bg="5"] .app-sidebar { background-image:linear-gradient(rgba(15,23,42,.82),rgba(15,23,42,.82)),url('../../images/menu-bg-images/bg-img5.jpg');background-size:cover; }
@media (max-width: 991.98px) { .credit-workflow { grid-template-columns:repeat(3,1fr);row-gap:1rem; }.workflow-step:after { display:none; }.header-search-bar { min-width:250px; } }
@media (max-width: 575.98px) { .credit-workflow { grid-template-columns:repeat(2,1fr); }.workflow-step { align-items:flex-start; }.workflow-step > div:last-child span { display:none; } }
@media print { .app-header,.app-sidebar,.footer,.btn,.offcanvas,.modal,.page-header-breadcrumb a { display:none!important; }.main-content.app-content { margin:0!important;padding:0!important; }.page { background:#fff!important; } }

/* Nilova shell fidelity — CreditFlow V1.2 */
.main-sidebar-header .header-logo img,
.horizontal-logo .header-logo img {
  width: auto;
  max-width: 190px;
  height: 30px;
  object-fit: contain;
}

#app-page-content {
  min-height: calc(100vh - 8rem);
}

.creditflow-page-loader {
  min-height: calc(100vh - 10rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.ajax-page-loading {
  min-height: calc(100vh - 8rem);
  display: block;
}

.page-content-fade {
  animation: pageFade .2s ease;
}

.sales-dashboard .card.custom-card.dashboard-card-1 {
  min-height: 146px;
}

.sales-dashboard .card.custom-card.dashboard-card-1 .card-body {
  position: relative;
  z-index: 1;
}

.sales-dashboard #credit-status-chart {
  min-height: 238px;
}

.sales-dashboard #credit-statistics {
  min-height: 335px;
}

.kyc-summary-item:last-child {
  margin-bottom: 0 !important;
}

.dashboard-activity-list > li:last-child {
  margin-bottom: 0 !important;
}

.dashboard-activity-list .avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.app-sidebar .doublemenu_bottom-menu {
  z-index: 12;
}

.app-sidebar .doublemenu_bottom-menu #mainProfile {
  border-radius: .35rem;
}

.app-sidebar .doublemenu_bottom-menu #mainProfile .side-menu__label {
  min-width: 0;
}

.app-sidebar .doublemenu_bottom-menu #mainProfile .side-menu__label span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

[data-menu-styles="dark"] .app-sidebar .doublemenu_bottom-menu,
[data-menu-styles="dark"] .app-sidebar .main-sidebar-header {
  background-color: var(--menu-bg);
}

[data-menu-styles="dark"] .app-sidebar #mainProfile {
  background: rgba(255,255,255,.06);
}

.main-header-container .header-search-bar {
  min-width: 330px;
}

@media (max-width: 1199.98px) {
  .sales-dashboard .card.custom-card.dashboard-card-1 {
    min-height: 138px;
  }
}

@media (max-width: 991.98px) {
  #app-page-content { min-height: calc(100vh - 5rem); }
  .creditflow-page-loader { min-height: 60vh; }
  .main-header-container .header-search-bar { min-width: 250px; }
}

@media (max-width: 575.98px) {
  .page-header-breadcrumb { padding-inline: 1rem; }
  .page-container { padding-inline: 1rem; }
  .sales-dashboard #credit-statistics { min-height: 300px; }
}

/* Client intake and KYC1 — CreditFlow V1.3 */
.client-filter-select { min-width: 155px; }
.credit-wizard-nav .credit-step-indicator { border-radius: .45rem; white-space: nowrap; }
.credit-wizard-nav .credit-step-indicator .avatar { width: 1.25rem; height: 1.25rem; font-size: .65rem; }
.credit-wizard-step { animation: pageFade .2s ease; }
.credit-client-preview { background: linear-gradient(145deg, rgba(var(--primary-rgb),.05), transparent 70%); }
.credit-capacity-preview { background: rgba(var(--success-rgb),.035) !important; }
.tab-style-6 .nav-link { color: var(--default-text-color); }
.tab-style-6 .nav-link.active { color: rgb(var(--primary-rgb)); }
.client-form .form-label,
.credit-wizard-form .form-label { font-weight: 500; }
.client-form textarea,
.credit-wizard-form textarea { resize: vertical; }
.table td .avatar.avatar-md { flex: 0 0 auto; }
@media (max-width: 767.98px) {
  .credit-wizard-nav .credit-step-indicator { font-size: 0; padding-inline: .5rem; }
  .credit-wizard-nav .credit-step-indicator .avatar { font-size: .65rem; margin-inline-end: 0 !important; }
  .client-filter-select { min-width: 100%; }
}

/* CreditFlow 1.6.0 · KYC5, desembolso, KYC6 e custódia documental */
.kyc-workspace-card{overflow:hidden}.kyc-workspace-card .card-header{background:linear-gradient(90deg,rgba(var(--primary-rgb),.06),transparent)}.kyc-workspace-card.border-info .card-header{background:linear-gradient(90deg,rgba(var(--info-rgb),.07),transparent)}.kyc-workspace-card .border{border-color:rgba(119,119,142,.16)!important}.table .opacity-50{filter:grayscale(.25)}@media(max-width:767.98px){.kyc-workspace-card .card-header{align-items:flex-start;gap:.75rem}}

/* V1.7.0 · Visualizador documental global */
.document-viewer-modal{height:min(88vh,920px);overflow:hidden}
.document-preview-body{height:calc(min(88vh,920px) - 72px);min-height:420px;background:var(--default-background)}
.document-preview-content{width:100%;height:100%;overflow:hidden;background:var(--custom-white)}
.document-preview-pdf,.document-preview-html{width:100%;height:100%;border:0;background:var(--custom-white)}
.document-preview-image-stage{width:100%;height:100%;display:flex;align-items:center;justify-content:center;padding:1rem;overflow:auto;background:var(--default-background)}
.document-preview-image{max-width:100%;max-height:100%;object-fit:contain;border-radius:.5rem;background:var(--custom-white);box-shadow:0 .25rem 1rem rgba(0,0,0,.08)}
.document-preview-message{max-width:560px}
@media (max-width:575.98px){.document-viewer-modal{height:94vh}.document-preview-body{height:calc(94vh - 112px);min-height:320px}.document-viewer-modal .modal-header{align-items:flex-start;flex-wrap:wrap}.document-viewer-modal .modal-header .d-flex{order:3;width:100%;margin:0!important}.document-viewer-modal .modal-header .d-flex .btn{flex:1}}

/* V1.11.0 · Meu trabalho e pesquisa global */
.global-search-results{max-height:520px;overflow-y:auto;padding-right:.25rem}
.global-search-results .ajax-nav{color:inherit;transition:background-color .15s ease,border-color .15s ease,transform .15s ease}
.global-search-results .ajax-nav:hover{background:rgba(var(--primary-rgb),.06);border-color:rgba(var(--primary-rgb),.25)!important;transform:translateY(-1px)}
.min-w-0{min-width:0}
#work-credit-table td{vertical-align:middle}
@media (max-width:575.98px){.global-search-results{max-height:60vh}}

/* CreditFlow V2.2.0 R9 · Simulador, capacidade e scoring */
.credit-risk-simulator-form .form-label{font-weight:500}
.credit-risk-simulator-form .risk-policy-summary{min-height:38px;display:flex;align-items:center;color:var(--default-text-color)}
.risk-result-card{position:sticky;top:5.5rem;overflow:hidden}
.risk-result-card .card-header{background:linear-gradient(120deg,rgba(var(--primary-rgb),.08),transparent 72%)}
.risk-score-panel{height:100%;min-height:150px;border:1px solid rgba(var(--primary-rgb),.18);border-radius:1rem;padding:1.25rem .75rem;background:radial-gradient(circle at top,rgba(var(--primary-rgb),.14),rgba(var(--primary-rgb),.025) 68%);display:flex;flex-direction:column;align-items:center;justify-content:center}
.risk-score-number{font-size:2.65rem;font-weight:700;line-height:1;color:rgb(var(--primary-rgb));letter-spacing:-.06em;margin-bottom:.45rem}
.risk-opinion-box{border-radius:.85rem;border-width:1px}
.risk-result-card .table td,.risk-result-card .table th{padding:.55rem .5rem}
.risk-result-card .accordion-item{border-radius:.75rem;overflow:hidden}
.risk-result-card .accordion-button{font-size:.82rem;font-weight:600}
.risk-result-card .sticky-top{z-index:1}
.credit-risk-summary-card,.risk-assessment-summary{background:linear-gradient(135deg,rgba(var(--primary-rgb),.07),rgba(var(--success-rgb),.035));border-color:rgba(var(--primary-rgb),.16)!important}
@media(max-width:1199.98px){.risk-result-card{position:static}}
@media(max-width:575.98px){.risk-score-number{font-size:2.1rem}.risk-score-panel{min-height:130px}.risk-result-card .col-4,.risk-result-card .col-8{width:100%}}


/* CreditFlow V2.3.0 R10 · Governança do workflow e aprovações */
.credit-approval-governance-card .progress,
.credit-approval-progress .progress { height: 0.4rem; border-radius: 999px; }
.credit-approval-governance-card .table > :not(caption) > * > *,
.credit-workflow-track .table > :not(caption) > * > * { vertical-align: middle; }
.credit-workflow-track .badge,
.credit-approval-governance-card .badge { white-space: normal; }

/* CreditFlow V2.5.0 R12 · Carteira, cobranças e recuperação */

/* CreditFlow R13 · Cliente 360º */
.cf-360-highlight{position:relative;overflow:hidden}
.cf-360-highlight:after{content:"360°";position:absolute;right:-8px;bottom:-18px;font-size:56px;font-weight:800;opacity:.045;line-height:1}
.cf-client-hero{position:relative}
.cf-client-hero:before{content:"";position:absolute;inset:0 0 auto 0;height:4px;background:linear-gradient(90deg,var(--primary-color),rgba(var(--primary-rgb),.25))}
.cf-360-tabs{gap:.25rem;flex-wrap:wrap}
.cf-360-tabs .nav-link{border-radius:.5rem .5rem 0 0;white-space:nowrap}
.cf-360-activity-scroll{max-height:680px;overflow:auto}
.cf-client-timeline{position:relative;padding-left:8px}
.cf-client-timeline:before{content:"";position:absolute;left:25px;top:10px;bottom:10px;width:1px;background:var(--default-border)}
.cf-client-timeline-item{display:flex;gap:14px;position:relative;padding-bottom:18px}
.cf-client-timeline-icon{width:36px;height:36px;border-radius:50%;display:flex;align-items:center;justify-content:center;flex:0 0 36px;background:rgb(var(--primary-rgb),.10);color:rgb(var(--primary-rgb));border:4px solid var(--custom-white);z-index:1}
.cf-client-timeline-content{flex:1;min-width:0;border:1px solid var(--default-border);border-radius:.65rem;padding:.85rem 1rem;background:var(--custom-white)}
@media (max-width: 767.98px){.cf-360-tabs{overflow-x:auto;flex-wrap:nowrap;padding-bottom:.35rem}.cf-client-timeline{padding-left:0}.cf-client-timeline:before{left:18px}.cf-client-timeline-icon{width:32px;height:32px;flex-basis:32px}}
