:root {
    --cg-navy: #061f49;
    --cg-navy-deep: #041936;
    --cg-blue: #2f80ed;
    --cg-orange: #ff7900;
    --cg-green: #2ca75f;
    --cg-purple: #6941d9;
    --cg-teal: #08a5a8;
    --cg-text: #071b48;
    --cg-muted: #667493;
    --cg-border: #e4e9f2;
    --cg-surface: #ffffff;
    --cg-bg: #f6f8fc;
}

body#builder-layout {
    --font-family: "Noto Sans", Arial, sans-serif;
    --header-height: 88px;
    --header-box-width: 0px;
    --menu-width: 250px;
    --main-color: var(--cg-orange);
    --header-background-color: #fff;
    --header-logo-background: var(--cg-navy);
    --header-border-bottom: var(--cg-border);
    --header-logo-border-right: transparent;
    --header-logo-border-bottom: rgba(255, 255, 255, 0.09);
    --submenu-background-color: var(--cg-navy);
    --submenu-text-color: #f4f7ff;
    --submenu-sub-text-color: #d8e1f2;
    --submenu-text-hover: #fff;
    --submenu-background-check: var(--cg-orange);
    --submenu-check-color: #fff;
    --menu-user-splash-background: var(--cg-navy);
    --menu-master-color-strong: #fff;
    --live-background-color: var(--cg-bg);
    --content-border-radius: 12px;
    --panel-border-radius: 12px;
    color: var(--cg-text);
    background: var(--cg-bg);
}

#builder-layout .container-header {
    box-shadow: none;
    z-index: 20;
}

#builder-layout .header-logo {
    border-right: 0;
    overflow: visible;
}

#builder-layout .company-logo {
    background: var(--cg-navy);
    overflow: hidden;
    padding: 0 18px;
}

#builder-layout .fixed-sidebar-mini-menu,
#builder-layout .container-menu,
#builder-layout .navbar-custom-menu,
#builder-layout .builder-list-themes {
    display: none !important;
}

.codeg7-brand {
    width: 100%;
    min-width: 0;
    color: #fff !important;
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none !important;
}

.codeg7-brand-mark {
    position: relative;
    width: 52px;
    height: 48px;
    flex: 0 0 52px;
    display: flex;
    align-items: center;
    font-style: normal;
    line-height: 1;
}

.codeg7-brand-mark b {
    color: #fff;
    font-size: 43px;
    font-weight: 800;
    letter-spacing: -8px;
    transform: skewX(-7deg);
}

.codeg7-brand-mark em {
    color: var(--cg-orange);
    font-size: 40px;
    font-weight: 900;
    font-style: normal;
    margin-left: -1px;
    transform: skewX(-8deg);
}

.codeg7-brand-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
    line-height: 1;
}

.codeg7-brand-copy strong {
    color: #fff;
    font-size: 25px;
    font-weight: 800;
    letter-spacing: -1px;
}

.codeg7-brand-copy strong span,
.codeg7-brand-copy small {
    color: var(--cg-orange);
}

.codeg7-brand-copy small {
    margin-top: 6px;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: .1px;
    text-transform: uppercase;
    white-space: nowrap;
}

#builder-layout .header-track {
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    padding: 0 20px 0 24px;
}

.codeg7-header-greeting {
    min-width: 300px;
    margin-right: auto;
    display: flex;
    flex-direction: column;
}

.codeg7-header-greeting strong {
    color: var(--cg-text);
    font-size: 22px;
    line-height: 1.2;
}

.codeg7-header-greeting span {
    color: var(--cg-muted);
    font-size: 12px;
    margin-top: 4px;
}

.codeg7-global-search {
    width: min(370px, 34vw);
    height: 46px;
    margin: 0;
    position: relative;
}

.codeg7-global-search input {
    width: 100%;
    height: 46px;
    border: 1px solid #dde3ee;
    border-radius: 9px;
    padding: 0 45px 0 18px;
    color: var(--cg-text);
    background: #fff;
    font-size: 13px;
    box-shadow: 0 2px 8px rgba(6, 31, 73, .025);
}

.codeg7-global-search input:focus {
    border-color: #9bb7df;
    outline: none;
    box-shadow: 0 0 0 3px rgba(47, 128, 237, .1);
}

.codeg7-global-search i {
    position: absolute;
    right: 17px;
    top: 50%;
    color: #637494;
    transform: translateY(-50%);
}

#builder-layout .header-action {
    border: 0;
    padding: 0 4px;
}

#builder-layout .builder-dropdown-menu {
    gap: 5px;
}

#builder-layout .button-circle {
    width: 39px;
    height: 39px;
    border: 0;
    color: var(--cg-navy);
    background: #fff;
}

#builder-layout .button-circle:hover {
    color: var(--cg-orange);
    background: #f6f8fc;
}

#builder-layout .builder-profile-menu {
    width: auto;
    min-width: 145px;
    padding-left: 8px;
}

#builder-layout .header-profile-photo {
    width: 38px;
    height: 38px;
    border: 2px solid #fff;
    box-shadow: 0 2px 7px rgba(6, 31, 73, .15);
}

#builder-layout .header-profile-name {
    color: var(--cg-text);
    font-size: 12px;
    white-space: nowrap;
}

#builder-layout .container-main {
    height: calc(100vh - var(--header-height));
}

#builder-layout .master-menu-content {
    width: var(--menu-width);
    height: 100%;
}

#builder-layout .container-submenu {
    border-right: 0;
    color: #fff;
    padding: 0 12px 12px;
    scrollbar-color: rgba(255, 255, 255, .22) transparent;
}

#builder-layout .splash-user-content {
    padding: 24px 4px 18px;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
}

#builder-layout .splash-user-photo {
    width: 54px;
    height: 54px;
    border: 2px solid rgba(255, 255, 255, .85);
    box-shadow: 0 0 0 2px rgba(255, 121, 0, .9);
}

#builder-layout .splash-user-photo a {
    right: -12px;
    top: 21px;
    color: #fff;
    background: var(--cg-orange);
}

#builder-layout .splash-user-name {
    margin-top: 10px;
    color: #fff;
    font-size: 14px;
}

#builder-layout .splash-user-att {
    margin-top: 4px;
    color: #d4deef;
    font-size: 10px;
}

#builder-layout .container-submenu ul {
    margin: 0;
}

#builder-layout .master-menu-content .container-submenu > ul {
    padding: 6px 0;
}

#builder-layout .master-menu-content .container-submenu > ul > li {
    padding: 0;
}

#builder-layout .container-submenu ul li a {
    min-height: 39px;
    margin: 2px 0;
    padding: 9px 11px;
    border-radius: 7px;
    gap: 8px;
    color: #eef4ff;
    font-size: 12px;
    font-weight: 600;
}

#builder-layout .container-submenu ul li a i {
    min-width: 18px;
    color: #d8e3f4;
    font-size: 15px;
}

#builder-layout .container-submenu ul li a:hover {
    color: #fff;
    background: rgba(255, 255, 255, .08);
}

#builder-layout .container-submenu ul li a:hover i,
#builder-layout .container-submenu ul .checked > a i {
    color: #fff;
}

#builder-layout .container-submenu ul li ul {
    padding: 2px 0 4px 19px;
}

#builder-layout .container-submenu ul li ul a {
    min-height: 31px;
    padding: 7px 10px;
    color: #cbd7ea;
    font-size: 11px;
    font-weight: 500;
}

#builder-layout .container-submenu ul .checked > a {
    background: var(--cg-orange);
    box-shadow: 0 5px 14px rgba(255, 121, 0, .25);
}

.codeg7-primary-nav {
    padding: 10px 0 0 !important;
}

body:has([page-name="Codeg7Dashboard"]) .codeg7-dashboard-link > a {
    color: #fff !important;
    background: var(--cg-orange);
    box-shadow: 0 5px 14px rgba(255, 121, 0, .25);
}

body:has([page-name="Codeg7Dashboard"]) .codeg7-dashboard-link > a i {
    color: #fff !important;
}

.codeg7-sidebar-footer {
    margin-top: auto;
    padding: 14px 4px 2px;
}

.codeg7-security-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 13px;
    border: 1px solid rgba(255, 255, 255, .23);
    border-radius: 9px;
    color: #fff;
    background: rgba(255, 255, 255, .035);
}

.codeg7-security-card > i {
    margin-top: 3px;
    color: #fff;
    font-size: 25px;
}

.codeg7-security-card span {
    display: flex;
    flex-direction: column;
}

.codeg7-security-card strong {
    font-size: 11px;
}

.codeg7-security-card small {
    margin-top: 5px;
    color: #cad6e9;
    font-size: 9px;
    line-height: 1.5;
}

.codeg7-version {
    padding: 10px 2px 3px;
    color: #91a4c3;
    font-size: 9px;
}

.codeg7-builder-tools {
    display: flex;
    gap: 8px;
    margin-top: 2px;
}

.codeg7-builder-tools a {
    color: #879bbb !important;
    font-size: 9px !important;
}

/* Produtos */
.cg-product-panel-title {
    min-width: 0;
    display: inline-flex;
    flex-direction: column;
    vertical-align: middle;
}

.cg-product-panel-title strong {
    color: var(--cg-text);
    font-size: 16px;
    font-weight: 800;
    line-height: 1.3;
}

.cg-product-panel-title small {
    margin-top: 4px;
    color: var(--cg-muted);
    font-size: 11px;
    font-weight: 400;
}

[page-name="ProdutoList"] .panel,
.codeg7-product-form-page .panel {
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
    overflow: hidden;
}

[page-name="ProdutoList"] .panel-heading,
.codeg7-product-form-page .panel-heading {
    min-height: 70px;
    padding: 16px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    background: #fff !important;
}

[page-name="ProdutoList"] .panel-heading .panel-title,
.codeg7-product-form-page .panel-heading .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

[page-name="ProdutoList"] .panel-body {
    padding: 0;
}

[page-name="ProdutoList"] .datagrid-header-actions {
    min-height: 84px;
    padding: 14px 18px;
    gap: 16px;
    border-bottom: 1px solid #edf0f5;
}

[page-name="ProdutoList"] .datagrid-header-actions-left-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

[page-name="ProdutoList"] .datagrid-header-actions .btn {
    min-height: 35px;
    margin: 0 !important;
    padding: 7px 13px;
    border-color: #dbe2ed;
    border-radius: 7px;
    color: var(--cg-text);
    background: #fff;
    font-size: 11px;
    font-weight: 700;
    box-shadow: none;
}

[page-name="ProdutoList"] .datagrid-header-actions .cg-product-new {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

[page-name="ProdutoList"] .datagrid-header-actions .btn:hover {
    border-color: #b9c7da;
    background: #f8faff;
}

[page-name="ProdutoList"] .datagrid-header-actions .cg-product-new:hover {
    border-color: #0a2c61;
    color: #fff;
    background: #0a2c61;
}

.cg-product-filter-count {
    top: -7px;
    right: -7px;
    min-width: 17px;
    height: 17px;
    padding: 2px 4px;
    border: 2px solid #fff;
    border-radius: 50%;
    position: absolute;
    color: #fff;
    background: var(--cg-orange);
    font-size: 8px;
}

.cg-product-total-card {
    min-width: 190px;
    min-height: 58px;
    padding: 9px 15px;
    border: 1px solid #e4e9f2;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    gap: 11px;
    color: var(--cg-text);
    background: #fff;
}

.cg-product-total-icon {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--cg-orange);
    background: #fff0e2;
    font-size: 17px;
}

.cg-product-total-copy {
    display: inline-flex;
    flex-direction: column;
    text-align: left;
}

.cg-product-total-copy small {
    color: var(--cg-muted);
    font-size: 9px;
    font-weight: 600;
}

.cg-product-total-copy strong {
    margin-top: 2px;
    color: var(--cg-text);
    font-size: 19px;
    line-height: 1;
}

[page-name="ProdutoList"] .table-responsive {
    border: 0;
}

[page-name="ProdutoList"] table.table {
    margin-bottom: 0;
    color: var(--cg-text);
    font-size: 10.5px;
}

[page-name="ProdutoList"] table.table thead th {
    height: 39px;
    padding: 9px 8px;
    border-color: #e6ebf3;
    color: var(--cg-text);
    background: #fff;
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
}

[page-name="ProdutoList"] table.table tbody td {
    height: 42px;
    padding: 9px 8px;
    border-color: #e9edf4;
    vertical-align: middle;
    background: #fff;
}

[page-name="ProdutoList"] table.table tbody tr:hover td {
    background: #f8faff;
}

[page-name="ProdutoList"] .tdatagrid_cell.action .btn {
    width: 27px;
    height: 27px;
    margin: 0 2px;
    padding: 4px;
    border: 1px solid #e1e6ef;
    border-radius: 50%;
    background: #fff;
}

.cg-product-status {
    min-width: 52px;
    padding: 4px 8px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    font-weight: 700;
}

.cg-product-status-active {
    color: #27864b;
    background: #eaf8ee;
}

.cg-product-status-inactive {
    color: #db3846;
    background: #ffedef;
}

[page-name="ProdutoList"] .panel-footer {
    min-height: 50px;
    padding: 8px 18px;
    border-top: 1px solid #e8edf4;
    background: #fff;
}

.codeg7-product-form-page {
    width: 100%;
    max-width: 1540px;
    margin: 0 auto;
}

.codeg7-product-form-page > form > .panel,
.codeg7-product-form-page > .panel {
    border: 1px solid #dfe6f0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 4px 16px rgba(7, 27, 72, .05);
    overflow: hidden;
}

.codeg7-product-form-page .panel-body {
    padding: 14px 18px 6px;
}

.codeg7-product-form-page .form-group {
    margin-bottom: 11px;
}

.codeg7-product-form-page label {
    margin-bottom: 6px;
    color: var(--cg-text);
    font-size: 10.5px !important;
    font-weight: 600;
}

.codeg7-product-form-page .cg-required {
    color: #f44336;
    font-weight: 800;
}

.codeg7-product-form-page .cg-item-section-title {
    margin: 2px 0 12px;
    padding: 10px 12px;
    border: 1px solid #e1e7f0;
    border-left: 4px solid var(--cg-orange);
    border-radius: 7px;
    color: var(--cg-text);
    background: #fbfcfe;
    font-size: 12px;
    font-weight: 800;
}

.codeg7-product-form-page .cg-item-section-title:not(:first-child) {
    margin-top: 8px;
}

.codeg7-product-form-page .form-control,
.codeg7-product-form-page .select2-selection {
    min-height: 36px;
    border-color: #dce3ee;
    border-radius: 6px;
    color: var(--cg-text);
    background: #fff;
    box-shadow: none;
    font-size: 11px;
}

.codeg7-product-form-page textarea.form-control {
    min-height: 90px;
    padding: 10px 12px;
}

.codeg7-product-form-page .form-control:focus,
.codeg7-product-form-page .select2-container--focus .select2-selection {
    border-color: #9bb7df;
    box-shadow: 0 0 0 3px rgba(47, 128, 237, .09);
}

.codeg7-product-form-page hr.tseparator-divisor {
    margin: 10px 0 15px;
    border-color: #e7ebf2;
}

.codeg7-product-form-page .tseparator {
    color: var(--cg-text) !important;
    font-size: 14px !important;
    font-weight: 800;
}

.codeg7-product-form-page .label_timagecropper {
    width: 100% !important;
    max-width: 230px;
    min-height: 145px;
    border: 1.5px dashed #cbd6e5;
    border-radius: 8px;
    background: #fbfcff;
}

.codeg7-product-form-page .label_timagecropper:hover,
.codeg7-product-form-page .label_timagecropper.highlight {
    border-color: var(--cg-orange);
    background: #fff9f3;
}

.codeg7-product-form-page .label_timagecropper .placeholder {
    color: #8492aa !important;
}

.codeg7-product-form-page .btn-group[role="group"] {
    display: flex !important;
    width: auto !important;
}

.codeg7-product-form-page .btn-group[role="group"] > label.btn {
    min-width: 52px;
    margin: 0;
    padding: 7px 12px;
    border-color: #dce3ee;
    color: #5e6d86;
    background: #fff;
    font-size: 10.5px !important;
    font-weight: 700;
}

.codeg7-product-form-page .btn-group[role="group"] > label.btn.active {
    border-color: #2da45d;
    color: #fff;
    background: #2da45d;
    box-shadow: none;
}

.codeg7-product-form-page [tradiogroup="permite_pesquisa_precos"] label.btn.active {
    border-color: var(--cg-orange);
    background: var(--cg-orange);
}

.codeg7-product-form-page .panel-footer {
    padding: 13px 18px;
    border-top: 1px solid #e7ebf2;
    background: #fff;
}

.codeg7-product-form-page .panel-footer .btn {
    min-height: 36px;
    margin-right: 8px;
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 11px;
    font-weight: 700;
}

.codeg7-product-form-page .cg-product-save {
    border-color: var(--cg-orange);
    color: #fff;
    background: var(--cg-orange);
}

.codeg7-product-form-page .cg-product-save:hover {
    border-color: #e76d00;
    color: #fff;
    background: #e76d00;
}

.codeg7-product-form-page .cg-product-secondary {
    border-color: #dce3ee;
    color: var(--cg-text);
    background: #fff;
}

.codeg7-product-config-page {
    width: 100%;
    max-width: 1450px;
    margin: 0 auto;
}

.codeg7-product-config-page > .panel,
.codeg7-product-config-form .panel {
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
    overflow: hidden;
}

.codeg7-product-config-page > .panel {
    margin-bottom: 12px;
}

.codeg7-product-config-page .panel-heading {
    min-height: 70px;
    padding: 16px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    background: #fff !important;
}

.codeg7-product-config-page .panel-heading .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

.codeg7-product-config-page > .panel > .panel-body {
    padding: 0;
}

.codeg7-product-config-page .cg-product-config-actions {
    min-height: 74px;
    padding: 13px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.codeg7-product-config-page .datagrid-header-actions-left-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.codeg7-product-config-page .cg-product-config-actions .btn {
    min-height: 35px;
    margin: 0 !important;
    padding: 7px 13px;
    border-color: #dbe2ed;
    border-radius: 7px;
    color: var(--cg-text);
    background: #fff;
    font-size: 11px;
    font-weight: 700;
    box-shadow: none;
}

.codeg7-product-config-page .cg-product-config-actions .cg-product-new {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

.cg-product-config-search {
    min-width: min(430px, 48vw);
    display: flex;
    align-items: center;
    gap: 7px;
}

.cg-product-config-search .tfield {
    min-width: 220px;
    height: 35px;
    border-color: #dbe2ed;
    border-radius: 7px;
    font-size: 11px;
}

.cg-product-config-total {
    min-width: 112px;
    height: 42px;
    padding: 7px 12px;
    border: 1px solid #e4e9f2;
    border-radius: 8px;
    display: inline-grid;
    grid-template-columns: 26px auto;
    grid-template-rows: 14px 16px;
    align-items: center;
    column-gap: 8px;
    color: var(--cg-text);
}

.cg-product-config-total i {
    width: 26px;
    height: 26px;
    grid-row: 1 / 3;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cg-orange);
    background: #fff0e2;
    font-size: 11px;
}

.cg-product-config-total span {
    color: var(--cg-muted);
    font-size: 8px;
}

.cg-product-config-total strong {
    font-size: 14px;
    line-height: 1;
}

.codeg7-product-config-page table.table {
    margin-bottom: 0;
    color: var(--cg-text);
    font-size: 11px;
}

.codeg7-product-config-page table.table thead th {
    height: 39px;
    padding: 9px;
    border-color: #e6ebf3;
    color: var(--cg-text);
    background: #fff;
    font-size: 10px;
    font-weight: 700;
}

.codeg7-product-config-page table.table tbody td {
    height: 42px;
    padding: 9px;
    border-color: #e9edf4;
    vertical-align: middle;
    background: #fff;
}

.codeg7-product-config-page table.table tbody tr:hover td {
    background: #f8faff;
}

.codeg7-product-config-page .tdatagrid_cell.action .btn {
    width: 27px;
    height: 27px;
    margin: 0 2px;
    padding: 4px;
    border: 1px solid #e1e6ef;
    border-radius: 50%;
    background: #fff;
}

.codeg7-product-config-page > .panel > .panel-footer {
    min-height: 50px;
    padding: 8px 18px;
    border-top: 1px solid #e8edf4;
    background: #fff;
}

.cg-product-config-form {
    scroll-margin-top: 14px;
}

.cg-product-config-form .panel-body {
    padding: 14px 18px 5px;
}

.cg-product-config-form label {
    margin-bottom: 6px;
    color: var(--cg-text);
    font-size: 10.5px !important;
    font-weight: 600;
}

.cg-product-config-form .form-control {
    min-height: 36px;
    border-color: #dce3ee;
    border-radius: 6px;
    color: var(--cg-text);
    box-shadow: none;
    font-size: 11px;
}

.cg-product-config-form .panel-footer {
    padding: 13px 18px;
    border-top: 1px solid #e7ebf2;
    background: #fff;
}

.cg-product-config-form .panel-footer .btn {
    min-height: 36px;
    margin-right: 8px;
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 11px;
    font-weight: 700;
}

.cg-product-config-form .cg-product-save {
    border-color: var(--cg-orange);
    color: #fff;
    background: var(--cg-orange);
}

.cg-product-config-form .cg-product-secondary {
    border-color: #dce3ee;
    color: var(--cg-text);
    background: #fff;
}

#builder-layout .master-container {
    background: var(--cg-bg);
}

body#builder-layout .container-main .container-live {
    width: 100%;
    max-width: none;
    padding: 14px 20px 22px;
    background: var(--cg-bg) !important;
    background-image: none !important;
}

.codeg7-dashboard-page {
    width: 100%;
}

.codeg7-dashboard {
    width: 100%;
    max-width: 1450px;
    margin: 0 auto;
    color: var(--cg-text);
}

.cg-mobile-welcome {
    display: none;
}

.cg-metrics-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.cg-metric,
.cg-panel,
.cg-trust-strip {
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: var(--cg-surface);
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
}

.cg-metric {
    min-height: 153px;
    padding: 20px 18px 12px;
    overflow: hidden;
}

.cg-metric-head {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.cg-metric-head > div {
    min-width: 0;
}

.cg-metric-icon {
    width: 43px;
    height: 43px;
    flex: 0 0 43px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #fff;
    font-size: 18px;
}

.cg-metric-label,
.cg-metric-value,
.cg-metric-change {
    display: block;
}

.cg-metric-label {
    min-height: 18px;
    color: var(--cg-text);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.cg-metric-value {
    margin-top: 4px;
    color: var(--cg-text);
    font-size: 24px;
    line-height: 1.08;
    white-space: nowrap;
}

.cg-metric:last-child .cg-metric-value {
    font-size: 18px;
}

.cg-metric-change {
    margin-top: 8px;
    font-size: 11px;
    font-weight: 700;
}

.cg-sparkline {
    width: 100%;
    height: 36px;
    margin-top: 8px;
    overflow: visible;
}

.cg-sparkline path {
    fill: none;
    stroke-width: 1.7;
    vector-effect: non-scaling-stroke;
}

.cg-tone-blue .cg-metric-icon,
.cg-tone-blue.cg-action > i {
    background: linear-gradient(135deg, #223cb2, #071b75);
}

.cg-tone-blue .cg-sparkline path,
.cg-tone-blue .cg-metric-change {
    color: #1e5fd0;
    stroke: #1e5fd0;
}

.cg-tone-green .cg-metric-icon,
.cg-tone-green.cg-action > i {
    background: linear-gradient(135deg, #39bd76, #17934f);
}

.cg-tone-green .cg-sparkline path,
.cg-tone-green .cg-metric-change {
    color: #249a50;
    stroke: #249a50;
}

.cg-tone-orange .cg-metric-icon,
.cg-tone-orange.cg-action > i {
    background: linear-gradient(135deg, #ff9418, #ff6800);
}

.cg-tone-orange .cg-sparkline path,
.cg-tone-orange .cg-metric-change {
    color: #f36e00;
    stroke: #f36e00;
}

.cg-tone-purple .cg-metric-icon,
.cg-tone-purple.cg-action > i {
    background: linear-gradient(135deg, #8057e8, #5831c8);
}

.cg-tone-purple .cg-sparkline path,
.cg-tone-purple .cg-metric-change {
    color: #6941d9;
    stroke: #6941d9;
}

.cg-tone-teal .cg-metric-icon,
.cg-tone-teal.cg-action > i {
    background: linear-gradient(135deg, #1dbab8, #06979d);
}

.cg-tone-teal .cg-sparkline path,
.cg-tone-teal .cg-metric-change {
    color: #08999c;
    stroke: #08999c;
}

.cg-dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.58fr) minmax(380px, 1fr);
    gap: 10px;
    margin-top: 10px;
}

.cg-panel {
    min-width: 0;
    overflow: hidden;
}

.cg-panel-header {
    min-height: 58px;
    padding: 15px 18px 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.cg-panel-header h2 {
    margin: 0;
    color: var(--cg-text);
    font-size: 16px;
    font-weight: 800;
}

.cg-soft-button {
    height: 31px;
    padding: 0 13px;
    border: 0;
    border-radius: 7px;
    color: var(--cg-text);
    background: #f2f5fa;
    font-size: 10px;
    font-weight: 700;
}

.cg-table-wrap {
    padding: 0 18px 8px;
    overflow-x: auto;
}

.cg-table {
    width: 100%;
    border-collapse: collapse;
    color: var(--cg-text);
    font-size: 10.5px;
}

.cg-table th,
.cg-table td {
    height: 36px;
    padding: 6px 7px;
    border-bottom: 1px solid #e8edf5;
    text-align: left;
    white-space: nowrap;
}

.cg-table th {
    color: #687696;
    font-weight: 600;
}

.cg-table tbody tr:last-child td {
    border-bottom: 0;
}

.cg-table tbody tr:hover {
    background: #f8faff;
}

.cg-status {
    display: inline-flex;
    padding: 3px 7px;
    border: 1px solid;
    border-radius: 6px;
    font-size: 9px;
    font-weight: 700;
}

.cg-status-blue {
    border-color: #89c2ff;
    color: #1e78d8;
    background: #eff8ff;
}

.cg-status-orange {
    border-color: #ffc58f;
    color: #ec6b00;
    background: #fff6ed;
}

.cg-status-green {
    border-color: #91d8a9;
    color: #27864b;
    background: #effaf2;
}

.cg-status-gray {
    border-color: #d6dce7;
    color: #596984;
    background: #f3f5f8;
}

.cg-icon-button {
    width: 24px;
    height: 24px;
    padding: 0;
    border: 0;
    color: var(--cg-text);
    background: transparent;
}

.cg-status-content {
    min-height: 202px;
    padding: 8px 18px 18px;
    display: flex;
    align-items: center;
    justify-content: space-around;
    gap: 22px;
}

.cg-donut {
    width: 164px;
    height: 164px;
    flex: 0 0 164px;
    padding: 37px;
    border-radius: 50%;
    background: conic-gradient(#e1e5ec 0 17.9%, #2f80ed 17.9% 42.9%, #ff7900 42.9% 51.8%, #0aa2a6 51.8% 73.2%, #48ad3e 73.2% 96.4%, #eb1f3f 96.4% 100%);
}

.cg-donut > span {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    border-radius: 50%;
    background: #fff;
}

.cg-donut strong {
    font-size: 20px;
}

.cg-donut small {
    margin-top: 2px;
    font-size: 10px;
}

.cg-legend {
    min-width: 210px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.cg-legend li {
    display: grid;
    grid-template-columns: 9px minmax(88px, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-height: 29px;
    font-size: 10px;
}

.cg-legend li strong {
    white-space: nowrap;
}

.cg-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.cg-gray { background: #dfe3ea; }
.cg-blue { background: #2f80ed; }
.cg-orange { background: #ff7900; }
.cg-teal { background: #0aa2a6; }
.cg-green { background: #48ad3e; }
.cg-red { background: #eb1f3f; }

.cg-actions {
    padding: 3px 14px 16px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.cg-action {
    min-height: 139px;
    padding: 14px 10px;
    border: 1px solid #e8edf5;
    border-radius: 10px;
    display: flex;
    align-items: center;
    flex-direction: column;
    text-align: center;
    text-decoration: none !important;
    color: var(--cg-text) !important;
    background: #fff;
    transition: transform .18s ease, box-shadow .18s ease;
}

.cg-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(6, 31, 73, .08);
}

.cg-action > i {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    color: #fff;
    font-size: 16px;
}

.cg-action strong {
    margin-top: 12px;
    font-size: 11px;
}

.cg-action span {
    max-width: 105px;
    margin-top: 7px;
    color: var(--cg-muted);
    font-size: 9px;
    line-height: 1.55;
}

.cg-sources {
    margin: 0;
    padding: 2px 16px 15px;
    list-style: none;
}

.cg-sources li {
    min-height: 28px;
    display: grid;
    grid-template-columns: 25px minmax(150px, 1fr) auto 46px;
    align-items: center;
    gap: 8px;
    color: var(--cg-text);
    font-size: 10px;
}

.cg-sources li > strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cg-sources li > span {
    white-space: nowrap;
}

.cg-sources em {
    font-style: normal;
    font-weight: 700;
    text-align: right;
}

.cg-sources .up { color: #239654; }
.cg-sources .down { color: #ef3049; }

.cg-source-icon {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    font-size: 7px;
    font-style: normal;
    font-weight: 800;
}

.cg-source-navy { background: #111d78; }
.cg-source-green { background: #37a55a; }
.cg-source-orange { background: #ff7900; }
.cg-source-teal { background: #0aa2a6; }
.cg-source-soft-green { color: #258b4c; background: #ccebd6; }

.cg-trust-strip {
    margin-top: 10px;
    padding: 17px 10px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.cg-trust-strip > div {
    min-height: 62px;
    padding: 5px 25px;
    border-right: 1px solid #e9edf4;
    display: flex;
    align-items: center;
    gap: 15px;
}

.cg-trust-strip > div:last-child {
    border-right: 0;
}

.cg-trust-strip > div > i {
    width: 43px;
    height: 43px;
    flex: 0 0 43px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cg-navy);
    background: #f4f7fc;
    font-size: 22px;
}

.cg-trust-strip span {
    display: flex;
    flex-direction: column;
}

.cg-trust-strip strong {
    font-size: 11px;
}

.cg-trust-strip small {
    margin-top: 5px;
    color: var(--cg-muted);
    font-size: 9px;
    line-height: 1.55;
}

@media (max-width: 1450px) {
    .cg-metric {
        padding-left: 13px;
        padding-right: 13px;
    }

    .cg-metric-head {
        gap: 9px;
    }

    .cg-metric-label {
        font-size: 10px;
    }

    .cg-metric-value {
        font-size: 21px;
    }

    .cg-status-content {
        gap: 12px;
    }

    .cg-donut {
        width: 140px;
        height: 140px;
        flex-basis: 140px;
        padding: 31px;
    }
}

@media (max-width: 1200px) {
    .codeg7-header-greeting {
        min-width: 230px;
    }

    .codeg7-header-greeting span {
        display: none;
    }

    .cg-metrics-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .cg-dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 992px) {
    body#builder-layout {
        --header-height: 64px;
        --menu-width: 250px;
    }

    #builder-layout .header-logo {
        width: 100%;
        min-width: 100%;
        background: var(--cg-navy);
    }

    #builder-layout .company-logo {
        justify-content: center;
        padding: 0 64px;
    }

    .codeg7-brand {
        width: 205px;
    }

    .codeg7-brand-mark {
        transform: scale(.82);
    }

    .codeg7-brand-copy strong {
        font-size: 20px;
    }

    #builder-layout .toggle-menu {
        color: #fff;
    }

    #builder-layout .toggle-top-menu {
        color: #fff;
    }

    #builder-layout .header-track {
        padding: 12px;
        background: #fff;
    }

    .codeg7-header-greeting,
    .codeg7-global-search {
        display: none;
    }

    #builder-layout .master-menu-content {
        height: calc(100% - var(--header-height));
    }

    body#builder-layout .container-main .container-live {
        padding: 12px;
    }

    .cg-mobile-welcome {
        margin-bottom: 12px;
        display: flex;
        flex-direction: column;
    }

    .cg-mobile-welcome strong {
        font-size: 20px;
    }

    .cg-mobile-welcome span {
        margin-top: 4px;
        color: var(--cg-muted);
        font-size: 11px;
    }

    .cg-metrics-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 680px) {
    .cg-metrics-grid,
    .cg-trust-strip {
        grid-template-columns: 1fr;
    }

    .cg-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .cg-status-content {
        flex-direction: column;
    }

    .cg-legend {
        width: 100%;
    }

    .cg-trust-strip > div {
        border-right: 0;
        border-bottom: 1px solid #e9edf4;
    }

    .cg-trust-strip > div:last-child {
        border-bottom: 0;
    }
}

@media (max-width: 767px) {
    [page-name="ProdutoList"] .datagrid-header-actions {
        align-items: stretch;
        flex-direction: column;
    }

    [page-name="ProdutoList"] .datagrid-header-actions-left-actions {
        width: 100%;
    }

    .cg-product-total-card {
        width: 100%;
    }

    .codeg7-product-form-page .cg-product-image-column {
        display: flex;
        align-items: center;
        flex-direction: column;
    }

    .codeg7-product-form-page .cg-item-section-title {
        margin-top: 5px;
    }

    .codeg7-product-form-page .panel-body {
        padding-right: 12px;
        padding-left: 12px;
    }

    .codeg7-product-config-page .cg-product-config-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .codeg7-product-config-page .datagrid-header-actions-left-actions,
    .cg-product-config-search {
        width: 100%;
        min-width: 0;
    }

    .cg-product-config-search {
        flex-wrap: wrap;
    }

    .cg-product-config-search .tfield {
        width: 100% !important;
        min-width: 0;
    }

    .cg-product-config-total {
        width: 100%;
    }
}

/* Pesquisa de preços — etapa 4: análise e aprovação */
.codeg7-analysis-page {
    padding-bottom: 18px;
}

.cg-analysis-hero-side {
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
    z-index: 1;
}

.cg-analysis-status {
    border-color: rgba(255, 255, 255, .7);
    color: #fff;
    background: color-mix(in srgb, var(--status-color) 70%, transparent);
}

.cg-analysis-notice {
    margin-bottom: 14px;
    padding: 12px 14px;
}

.cg-analysis-toolbar {
    min-height: 58px;
    margin: 0 0 14px;
    padding: 10px 12px;
    border: 1px solid var(--cg-border);
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
}

.cg-analysis-toolbar > div {
    flex-wrap: wrap;
}

[page-name="CompraPesquisaAnaliseForm"] .panel {
    margin-bottom: 14px;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(7, 27, 72, .05);
    overflow: hidden;
}

[page-name="CompraPesquisaAnaliseForm"] .panel-heading {
    min-height: 62px;
    padding: 13px 18px;
    border-bottom: 1px solid #e9edf4;
    background: #fff !important;
}

[page-name="CompraPesquisaAnaliseForm"] .panel-body {
    padding: 12px 18px 16px;
}

[page-name="CompraPesquisaAnaliseForm"] table.table {
    margin-bottom: 0;
    border-collapse: separate;
    border-spacing: 0;
}

[page-name="CompraPesquisaAnaliseForm"] table.table thead th {
    padding: 10px 9px;
    border-bottom: 1px solid #dfe6f0;
    color: #617089;
    background: #f7f9fc;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
}

[page-name="CompraPesquisaAnaliseForm"] table.table tbody td {
    padding: 11px 9px;
    border-bottom: 1px solid #edf1f6;
    vertical-align: middle;
    font-size: 10.5px;
}

.cg-approval-state {
    min-width: 78px;
    padding: 4px 8px;
    border-radius: 999px;
    display: inline-block;
    font-size: 9px;
    font-weight: 800;
    text-align: center;
}

.cg-approval-state-pendente {
    color: #9a6700;
    background: #fff3cd;
}

.cg-approval-state-aprovado {
    color: #16723c;
    background: #dcfce7;
}

.cg-approval-state-rejeitado {
    color: #b42318;
    background: #fee4e2;
}

.cg-approval-state-cancelado {
    color: #5f6b7a;
    background: #edf0f4;
}

/* Pesquisa de preços — etapa 5: conclusão e relatório final */
.codeg7-conclusion-page {
    padding-bottom: 18px;
}

.cg-conclusion-notice {
    margin-bottom: 14px;
    border-color: #bbf7d0;
    color: #166534;
    background: #f0fdf4;
}

.cg-conclusion-toolbar {
    border-color: #d5e8dc;
}

[page-name="CompraPesquisaConclusaoForm"] .panel {
    margin-bottom: 14px;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(7, 27, 72, .05);
    overflow: hidden;
}

[page-name="CompraPesquisaConclusaoForm"] .panel-heading {
    min-height: 62px;
    padding: 13px 18px;
    border-bottom: 1px solid #e9edf4;
    background: #fff !important;
}

[page-name="CompraPesquisaConclusaoForm"] .panel-body {
    padding: 12px 18px 16px;
}

[page-name="CompraPesquisaConclusaoForm"] table.table thead th {
    padding: 10px 9px;
    border-bottom: 1px solid #dfe6f0;
    color: #617089;
    background: #f7f9fc;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
}

[page-name="CompraPesquisaConclusaoForm"] table.table tbody td {
    padding: 11px 9px;
    border-bottom: 1px solid #edf1f6;
    vertical-align: middle;
    font-size: 10.5px;
}

.cg-conclusion-document {
    min-height: 74px;
    padding: 13px 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: 1px solid #dce3ee;
    border-radius: 9px;
    background: #f8fafc;
}

.cg-conclusion-document-icon {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #dc2626;
    background: #fee2e2;
    font-size: 18px;
}

.cg-conclusion-document-icon.is-ready {
    color: #15803d;
    background: #dcfce7;
}

.cg-conclusion-document > div {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cg-conclusion-document strong {
    color: var(--cg-navy);
    font-size: 12px;
}

.cg-conclusion-document small {
    color: #64748b;
    font-size: 9.5px;
}

.cg-conclusion-document code {
    color: #475569;
    font-size: 8px;
    overflow-wrap: anywhere;
}

@media (max-width: 767px) {
    .cg-analysis-hero {
        align-items: flex-start;
        flex-direction: column;
    }

    .cg-analysis-hero-side {
        width: 100%;
        align-items: stretch;
        flex-direction: column;
    }

    .cg-analysis-status,
    .cg-analysis-hero-side .cg-purchase-hero-back {
        justify-content: center;
        text-align: center;
    }
}

/* Catálogo de itens: listagem, filtros, consulta e cards */
.codeg7-product-list-page,
.codeg7-product-view-page,
.codeg7-product-card-page {
    width: 100%;
    max-width: 1540px;
    margin: 0 auto;
}

right-panel > .container-part[page-name="ProdutoListSearch"] {
    padding: 14px;
    background: #f5f7fb;
    overflow-y: auto;
}

[page-name="ProdutoListSearch"] > .panel,
[page-name="ProdutoListSearch"] .panel {
    min-height: 0 !important;
    margin: 0;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 8px 28px rgba(7, 27, 72, .12);
    overflow: hidden;
}

[page-name="ProdutoListSearch"] .panel-heading {
    min-height: 72px;
    padding: 14px 18px;
    border-bottom: 1px solid #e9edf4;
    display: flex;
    align-items: center;
    background: #fff !important;
}

[page-name="ProdutoListSearch"] .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

[page-name="ProdutoListSearch"] .panel-body {
    padding: 18px 18px 8px;
    background: #fff;
}

[page-name="ProdutoListSearch"] .form-group {
    margin-bottom: 12px;
}

[page-name="ProdutoListSearch"] label {
    margin-bottom: 6px;
    color: var(--cg-text);
    font-size: 10.5px !important;
    font-weight: 600;
}

[page-name="ProdutoListSearch"] .form-control,
[page-name="ProdutoListSearch"] .select2-selection {
    min-height: 36px;
    border-color: #dce3ee;
    border-radius: 6px;
    color: var(--cg-text);
    background: #fff;
    box-shadow: none;
    font-size: 11px;
}

[page-name="ProdutoListSearch"] .form-control:focus,
[page-name="ProdutoListSearch"] .select2-container--focus .select2-selection {
    border-color: #9bb7df;
    box-shadow: 0 0 0 3px rgba(47, 128, 237, .09);
}

[page-name="ProdutoListSearch"] .panel-footer {
    min-height: 62px;
    padding: 13px 18px;
    border-top: 1px solid #e9edf4;
    background: #fbfcfe;
}

[page-name="ProdutoListSearch"] .panel-footer .btn,
[page-name="ProdutoListSearch"] .panel-heading .btn {
    min-height: 34px;
    margin: 0 !important;
    padding: 7px 13px;
    border-radius: 7px;
    font-size: 11px;
    font-weight: 700;
}

[page-name="ProdutoListSearch"] .cg-product-filter-search {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

[page-name="ProdutoListSearch"] .cg-product-filter-search:hover {
    border-color: #0a2c61;
    color: #fff;
    background: #0a2c61;
}

.codeg7-product-view-page > .panel,
.codeg7-product-view-page > form > .panel,
.codeg7-product-card-page > .panel,
.codeg7-product-card-page > form > .panel {
    margin-bottom: 14px;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 4px 16px rgba(7, 27, 72, .05);
    overflow: hidden;
}

.codeg7-product-view-page .panel-heading,
.codeg7-product-card-page > form > .panel > .panel-heading {
    min-height: 70px;
    padding: 14px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    background: #fff !important;
}

.codeg7-product-view-page .panel-heading .panel-title,
.codeg7-product-card-page .panel-heading .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

.codeg7-product-view-page .panel-body,
.codeg7-product-card-page > form > .panel > .panel-body {
    padding: 14px 18px 7px;
}

.codeg7-product-view-page .form-group,
.codeg7-product-card-page .form-group {
    margin-bottom: 12px;
}

.codeg7-product-view-page label,
.codeg7-product-card-page label {
    margin-bottom: 6px;
    color: var(--cg-text);
    font-size: 10.5px !important;
    font-weight: 600;
}

.codeg7-product-view-page .cg-item-section-title {
    margin: 3px 0 13px;
    padding: 10px 12px;
    border: 1px solid #e1e7f0;
    border-left: 4px solid var(--cg-orange);
    border-radius: 7px;
    color: var(--cg-text);
    background: #fbfcfe;
    font-size: 12px;
    font-weight: 800;
}

.codeg7-product-view-page .cg-product-view-value {
    width: 100%;
    min-height: 38px;
    padding: 9px 11px;
    border: 1px solid #e1e7f0;
    border-radius: 6px;
    display: block;
    color: #42536d !important;
    background: #fbfcfe;
    font-size: 11px !important;
    line-height: 1.45;
    white-space: pre-wrap;
}

.codeg7-product-view-page .cg-product-view-image {
    width: 110px !important;
    height: 110px !important;
    padding: 8px;
    border: 1px solid #dce4ef;
    border-radius: 10px;
    display: block;
    object-fit: contain;
    color: var(--cg-orange);
    background: #fbfcfe;
}

.cg-product-flag {
    min-width: 54px;
    padding: 4px 9px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    font-size: 10px;
    font-weight: 800;
}

.cg-product-flag-yes {
    color: #258b4c;
    background: #e5f5e9;
}

.cg-product-flag-no {
    color: #7b8799;
    background: #edf1f6;
}

.codeg7-product-card-page > form > .panel > .panel-footer {
    min-height: 64px;
    padding: 13px 18px;
    border-top: 1px solid #e9edf4;
    background: #fbfcfe;
}

.codeg7-product-card-page .form-control,
.codeg7-product-card-page .select2-selection {
    min-height: 36px;
    border-color: #dce3ee;
    border-radius: 6px;
    color: var(--cg-text);
    background: #fff;
    box-shadow: none;
    font-size: 11px;
}

.codeg7-product-card-page .form-control:focus,
.codeg7-product-card-page .select2-container--focus .select2-selection {
    border-color: #9bb7df;
    box-shadow: 0 0 0 3px rgba(47, 128, 237, .09);
}

.codeg7-product-card-page .panel-footer .btn {
    min-height: 35px;
    margin: 0 6px 0 0 !important;
    padding: 7px 13px;
    border-radius: 7px;
    font-size: 11px;
    font-weight: 700;
}

.codeg7-product-card-page .cg-product-save,
.codeg7-product-card-page .cg-product-new {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

.codeg7-product-card-page .cg-product-secondary {
    border-color: #dbe2ed;
    color: var(--cg-text);
    background: #fff;
}

.codeg7-product-card-page .cg-product-save:hover,
.codeg7-product-card-page .cg-product-new:hover {
    border-color: #0a2c61;
    color: #fff;
    background: #0a2c61;
}

.codeg7-product-card-page .cg-product-secondary:hover {
    border-color: #b9c7da;
    color: var(--cg-text);
    background: #f8faff;
}

.cg-catalog-results-header {
    min-height: 70px;
    padding: 14px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: #fff;
}

.cg-catalog-results-header > div:first-child {
    display: flex;
    flex-direction: column;
}

.cg-catalog-results-header strong {
    color: var(--cg-text);
    font-size: 14px;
    font-weight: 800;
}

.cg-catalog-results-header small {
    margin-top: 4px;
    color: var(--cg-muted);
    font-size: 10px;
}

.cg-catalog-results-total {
    min-width: 116px;
    padding: 9px 13px;
    border: 1px solid #e1e7f0;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    color: var(--cg-text);
    background: #fbfcfe;
}

.cg-catalog-results-total i {
    color: var(--cg-orange);
    font-size: 16px;
}

.cg-catalog-results-total strong {
    font-size: 15px;
}

.cg-catalog-results-total span {
    color: var(--cg-muted);
    font-size: 10px;
}

.cg-catalog-card-grid {
    width: 100%;
    padding: 16px !important;
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
    align-items: stretch;
    justify-content: stretch !important;
    gap: 14px;
    background: #f8faff;
}

.cg-catalog-card {
    width: auto !important;
    min-width: 0;
    margin: 0 !important;
    border: 1px solid #dfe6f0 !important;
    border-radius: 11px !important;
    display: flex !important;
    flex-direction: column;
    background: #fff !important;
    box-shadow: 0 3px 12px rgba(7, 27, 72, .05) !important;
    overflow: hidden !important;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.cg-catalog-card:hover {
    border-color: #b9c9df !important;
    box-shadow: 0 8px 22px rgba(7, 27, 72, .09) !important;
    transform: translateY(-2px);
}

.cg-catalog-card .card-item-title {
    min-height: 68px;
    padding: 12px 14px !important;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
    color: var(--cg-text) !important;
    background: #fff !important;
}

.cg-catalog-card-code {
    padding: 3px 7px;
    border-radius: 999px;
    color: #c65e00;
    background: #fff0df;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .2px;
}

.cg-catalog-card-title {
    width: 100%;
    color: var(--cg-text);
    font-size: 11.5px;
    font-weight: 800;
    line-height: 1.35;
}

.cg-catalog-card .card-item-content {
    height: auto !important;
    min-height: 214px;
    padding: 0 !important;
    flex: 1;
}

.cg-catalog-card-content {
    min-height: 214px;
    padding: 14px;
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 14px;
}

.cg-catalog-card-image {
    width: 112px;
    height: 112px;
    padding: 8px;
    border: 1px solid #e0e6ef;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fbfcfe;
    overflow: hidden;
}

.cg-catalog-card-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
}

.cg-catalog-card-body {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.cg-catalog-card-badges {
    min-height: 23px;
    margin-bottom: 9px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.cg-catalog-card-kind {
    max-width: 100%;
    padding: 4px 8px;
    border-radius: 999px;
    color: #42536d;
    background: #edf2f8;
    font-size: 9px;
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cg-catalog-card-details {
    display: grid;
    gap: 7px;
}

.cg-catalog-card-details > div {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.cg-catalog-card-details small,
.cg-catalog-card-price small {
    color: var(--cg-muted);
    font-size: 8.5px;
    line-height: 1.2;
}

.cg-catalog-card-details strong {
    margin-top: 2px;
    color: #42536d;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cg-catalog-card-price {
    margin-top: auto;
    padding-top: 10px;
    display: flex;
    align-items: flex-end;
    flex-direction: column;
}

.cg-catalog-card-price strong {
    margin-top: 2px;
    color: var(--cg-text);
    font-size: 15px;
    font-weight: 800;
}

.cg-catalog-card .card-item-actions {
    min-height: 48px;
    padding: 8px 12px !important;
    border-top: 1px solid #edf0f5;
    display: flex !important;
    align-items: center;
    justify-content: flex-end;
    gap: 5px;
    background: #fbfcfe !important;
}

.cg-catalog-card .card-item-actions .btn {
    width: 30px;
    height: 30px;
    margin: 0 !important;
    padding: 5px;
    border: 1px solid #dfe5ee;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--cg-text);
    background: #fff;
}

.codeg7-product-card-page > .panel > .panel-footer {
    min-height: 52px;
    padding: 9px 18px;
    border-top: 1px solid #e9edf4;
    background: #fff;
}

@media (max-width: 767px) {
    right-panel > .container-part[page-name="ProdutoListSearch"] {
        width: 100% !important;
        padding: 8px;
    }

    .codeg7-product-view-page .panel-body,
    .codeg7-product-card-page > form > .panel > .panel-body {
        padding-right: 12px;
        padding-left: 12px;
    }

    .codeg7-product-view-page .cg-product-view-image {
        margin: 0 auto;
    }

    .codeg7-product-card-page .panel-footer .btn {
        width: 100%;
        margin: 0 0 7px !important;
    }

    .cg-catalog-results-header {
        align-items: stretch;
        flex-direction: column;
    }

    .cg-catalog-results-total {
        width: 100%;
    }

    .cg-catalog-card-grid {
        padding: 10px !important;
        grid-template-columns: 1fr;
    }

    .cg-catalog-card-content {
        grid-template-columns: 1fr;
    }

    .cg-catalog-card-image {
        width: 100%;
        height: 160px;
    }
}

/* Pesquisa de preços: listagem, montagem do processo e painéis laterais */
.codeg7-purchase-page {
    width: 100%;
    max-width: 1540px;
    margin: 0 auto;
}

.codeg7-purchase-page > .panel,
.codeg7-purchase-page > form > .panel,
.codeg7-purchase-form-page > .panel {
    margin-bottom: 14px;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 4px 16px rgba(7, 27, 72, .05);
    overflow: hidden;
}

.codeg7-purchase-page .panel-heading,
.codeg7-purchase-panel .panel-heading {
    min-height: 68px;
    padding: 14px 18px;
    border-bottom: 1px solid #e9edf4;
    display: flex;
    align-items: center;
    background: #fff !important;
}

.codeg7-purchase-page .panel-title,
.codeg7-purchase-panel .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

.cg-purchase-title {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cg-purchase-title strong {
    color: var(--cg-navy);
    font-size: 15px;
    font-weight: 800;
}

.cg-purchase-title small {
    color: #64748b;
    font-size: 11px;
    font-weight: 500;
}

.codeg7-purchase-page .panel-body,
.codeg7-purchase-panel .panel-body {
    padding: 16px 18px 9px;
}

.codeg7-purchase-page .form-group,
.codeg7-purchase-panel .form-group {
    margin-bottom: 12px;
}

.codeg7-purchase-page label,
.codeg7-purchase-panel label {
    margin-bottom: 6px;
    color: var(--cg-text);
    font-size: 10.5px !important;
    font-weight: 700;
}

.codeg7-purchase-page .form-control,
.codeg7-purchase-page .select2-selection,
.codeg7-purchase-panel .form-control,
.codeg7-purchase-panel .select2-selection {
    min-height: 36px;
    border-color: #dce3ee;
    border-radius: 7px;
    box-shadow: none;
}

.codeg7-purchase-page .panel-footer,
.codeg7-purchase-panel .panel-footer {
    min-height: 60px;
    padding: 12px 18px;
    border-top: 1px solid #e9edf4;
    background: #fbfcfe;
}

.cg-purchase-section {
    margin: 2px 0 14px;
    padding: 10px 12px;
    border: 1px solid #dce6f4;
    border-left: 4px solid var(--cg-navy);
    border-radius: 7px;
    color: var(--cg-navy);
    background: #f8fafc;
    font-size: 12px;
    font-weight: 800;
}

.cg-purchase-toolbar {
    min-height: 54px;
    margin: -4px 0 12px;
    padding: 9px 0 12px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.cg-purchase-toolbar > div {
    display: flex;
    align-items: center;
    gap: 8px;
}

.cg-purchase-total {
    min-width: 155px;
    padding: 8px 12px;
    border: 1px solid #dce6f4;
    border-radius: 9px;
    display: grid !important;
    grid-template-columns: 28px 1fr auto;
    color: var(--cg-navy);
    background: #f8fafc;
}

.cg-purchase-total span {
    grid-row: 1 / 3;
    align-self: center;
    color: #2563eb;
}

.cg-purchase-total small {
    color: #64748b;
    font-size: 10px;
}

.cg-purchase-total strong {
    align-self: center;
    font-size: 18px;
}

.cg-purchase-status {
    --status-color: #64748b;
    padding: 4px 9px;
    border: 1px solid var(--status-color);
    border-radius: 999px;
    color: var(--status-color);
    background: #fff;
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.cg-purchase-count {
    min-width: 27px;
    padding: 3px 7px;
    border-radius: 999px;
    display: inline-block;
    color: #1e40af;
    background: #dbeafe;
    font-weight: 800;
}

.cg-purchase-object {
    max-width: 430px;
    line-height: 1.35;
}

.cg-purchase-detail {
    margin-top: 4px;
    display: block;
    color: #64748b;
    font-size: 10px;
    line-height: 1.35;
}

.cg-purchase-notice {
    padding: 9px 12px;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    color: #1e3a8a;
    background: #eff6ff;
    font-size: 11px;
}

.cg-purchase-secondary {
    border-color: #99f6e4 !important;
    color: #0f766e !important;
    background: #f0fdfa !important;
}

.codeg7-purchase-panel {
    width: 100%;
    padding: 14px;
    background: #f5f7fb;
}

.codeg7-purchase-panel > form > .panel {
    margin: 0;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    box-shadow: 0 8px 28px rgba(7, 27, 72, .12);
    overflow: hidden;
}

@media (max-width: 767px) {
    .cg-purchase-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .cg-purchase-toolbar > div {
        flex-wrap: wrap;
    }

    .cg-purchase-total {
        width: 100%;
    }
}

/* Pesquisa de preços — experiência visual 2026 */
.cg-purchase-hero {
    min-height: 132px;
    margin-bottom: 14px;
    padding: 24px 26px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    position: relative;
    color: #fff;
    background:
        radial-gradient(circle at 82% 22%, rgba(47, 128, 237, .32), transparent 28%),
        linear-gradient(125deg, #041936 0%, #082b61 70%, #0b3e82 100%);
    box-shadow: 0 10px 28px rgba(6, 31, 73, .14);
    overflow: hidden;
}

.cg-purchase-hero::after {
    width: 180px;
    height: 180px;
    right: -55px;
    bottom: -100px;
    border: 24px solid rgba(255, 121, 0, .15);
    border-radius: 50%;
    position: absolute;
    content: "";
}

.cg-purchase-hero-copy {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    z-index: 1;
}

.cg-purchase-hero-icon {
    width: 58px;
    height: 58px;
    flex: 0 0 58px;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(255, 255, 255, .1);
    font-size: 23px;
}

.cg-purchase-hero-copy small {
    color: #9fc2f3;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.cg-purchase-hero-copy h1 {
    margin: 2px 0 4px;
    color: #fff;
    font-size: 24px;
    font-weight: 800;
    line-height: 1.2;
}

.cg-purchase-hero-copy p {
    max-width: 700px;
    margin: 0;
    color: #dce9fa;
    font-size: 11px;
    line-height: 1.5;
}

.cg-purchase-hero-action,
.cg-purchase-hero-back {
    min-height: 39px;
    padding: 9px 15px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    position: relative;
    z-index: 1;
    font-size: 11px;
    font-weight: 800;
    text-decoration: none !important;
    white-space: nowrap;
}

.cg-purchase-hero-action {
    border: 1px solid var(--cg-orange);
    color: #fff !important;
    background: var(--cg-orange);
}

.cg-purchase-hero-action:hover {
    border-color: #ff8e2b;
    color: #fff;
    background: #ff8e2b;
}

.cg-purchase-hero-back {
    border: 1px solid rgba(255, 255, 255, .3);
    color: #fff !important;
    background: rgba(255, 255, 255, .08);
}

.cg-purchase-hero-back:hover {
    border-color: rgba(255, 255, 255, .55);
    background: rgba(255, 255, 255, .15);
}

.cg-purchase-metrics {
    margin-bottom: 14px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.cg-purchase-metric {
    min-height: 82px;
    padding: 14px 16px;
    border: 1px solid var(--cg-border);
    border-radius: 11px;
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
}

.cg-purchase-metric-icon {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
}

.cg-purchase-metric-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.cg-purchase-metric-copy small {
    color: var(--cg-muted);
    font-size: 9.5px;
    font-weight: 700;
    white-space: nowrap;
}

.cg-purchase-metric-copy strong {
    margin-top: 4px;
    color: var(--cg-text);
    font-size: 21px;
    font-weight: 800;
    line-height: 1;
}

.cg-purchase-metric-blue .cg-purchase-metric-icon {
    color: #2563eb;
    background: #eaf2ff;
}

.cg-purchase-metric-orange .cg-purchase-metric-icon {
    color: #e66d00;
    background: #fff0e2;
}

.cg-purchase-metric-teal .cg-purchase-metric-icon {
    color: #087f81;
    background: #e6f8f8;
}

.cg-purchase-metric-purple .cg-purchase-metric-icon {
    color: #6941d9;
    background: #f0ebff;
}

.cg-purchase-steps {
    margin-bottom: 14px;
    padding: 15px 18px;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    background: #fff;
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
}

.cg-purchase-step {
    min-width: 0;
    padding: 3px 14px;
    display: flex;
    align-items: center;
    gap: 9px;
    position: relative;
}

.cg-purchase-step:not(:last-child)::after {
    width: 1px;
    height: 34px;
    top: 5px;
    right: 0;
    position: absolute;
    background: #e6ebf3;
    content: "";
}

.cg-purchase-step-number {
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    border: 1px solid #dce3ee;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #9aa7ba;
    background: #f8fafc;
    font-size: 12px;
}

.cg-purchase-step-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.cg-purchase-step-copy small {
    color: #94a3b8;
    font-size: 8px;
    font-weight: 800;
    text-transform: uppercase;
}

.cg-purchase-step-copy strong {
    margin-top: 1px;
    color: #718096;
    font-size: 10.5px;
    font-weight: 800;
}

.cg-purchase-step-copy em {
    color: #9aa7ba;
    font-size: 8.5px;
    font-style: normal;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cg-purchase-step.is-current .cg-purchase-step-number {
    border-color: var(--cg-orange);
    color: #fff;
    background: var(--cg-orange);
    box-shadow: 0 0 0 4px rgba(255, 121, 0, .1);
}

.cg-purchase-step.is-current .cg-purchase-step-copy strong {
    color: var(--cg-text);
}

.cg-purchase-step.is-complete .cg-purchase-step-number {
    border-color: #2ca75f;
    color: #fff;
    background: #2ca75f;
}

.cg-purchase-step.is-complete .cg-purchase-step-copy strong {
    color: #27864b;
}

[page-name="CompraPesquisaList"] .codeg7-purchase-page > form > .panel {
    margin-bottom: 14px;
}

[page-name="CompraPesquisaList"] .codeg7-purchase-page > form > .panel .panel-heading {
    min-height: 58px;
    padding-top: 12px;
    padding-bottom: 12px;
}

[page-name="CompraPesquisaList"] .codeg7-purchase-page > form > .panel .panel-body {
    padding: 14px 18px 7px;
}

[page-name="CompraPesquisaList"] .codeg7-purchase-page > form > .panel .panel-footer {
    min-height: 54px;
    padding: 9px 18px;
}

[page-name="CompraPesquisaList"] .codeg7-purchase-page > .panel > .panel-body.table-responsive,
[page-name="CompraPesquisaForm"] .codeg7-purchase-page > .panel > .panel-body.table-responsive {
    padding: 0;
    border: 0;
}

[page-name="CompraPesquisaList"] .cg-purchase-toolbar,
[page-name="CompraPesquisaForm"] .cg-purchase-toolbar {
    min-height: 68px;
    margin: 0;
    padding: 13px 18px;
    border-bottom: 1px solid #edf0f5;
}

[page-name="CompraPesquisaList"] .cg-purchase-toolbar .btn,
[page-name="CompraPesquisaForm"] .cg-purchase-toolbar .btn {
    min-height: 35px;
    margin: 0 !important;
    padding: 7px 13px;
    border-color: #dbe2ed;
    border-radius: 7px;
    color: var(--cg-text);
    background: #fff;
    font-size: 10.5px;
    font-weight: 800;
    box-shadow: none;
}

[page-name="CompraPesquisaList"] .cg-purchase-toolbar .btn-primary,
[page-name="CompraPesquisaForm"] .cg-purchase-toolbar .btn-primary {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

[page-name="CompraPesquisaList"] table.table,
[page-name="CompraPesquisaForm"] table.table {
    margin-bottom: 0;
    color: var(--cg-text);
    font-size: 10.5px;
}

[page-name="CompraPesquisaList"] table.table thead th,
[page-name="CompraPesquisaForm"] table.table thead th {
    height: 40px;
    padding: 9px 8px;
    border-color: #e6ebf3;
    color: #42536d;
    background: #f8fafc;
    font-size: 9.5px;
    font-weight: 800;
    letter-spacing: .15px;
    white-space: nowrap;
}

[page-name="CompraPesquisaList"] table.table tbody td,
[page-name="CompraPesquisaForm"] table.table tbody td {
    min-height: 44px;
    padding: 10px 8px;
    border-color: #e9edf4;
    vertical-align: middle;
    background: #fff;
}

[page-name="CompraPesquisaList"] table.table tbody tr:hover td,
[page-name="CompraPesquisaForm"] table.table tbody tr:hover td {
    background: #f8faff;
}

[page-name="CompraPesquisaList"] .tdatagrid_cell.action .btn,
[page-name="CompraPesquisaForm"] .tdatagrid_cell.action .btn {
    width: 28px;
    height: 28px;
    margin: 0 2px;
    padding: 4px;
    border: 1px solid #e1e6ef;
    border-radius: 50%;
    background: #fff;
    box-shadow: none;
}

[page-name="CompraPesquisaList"] .panel-footer,
[page-name="CompraPesquisaForm"] .codeg7-purchase-page > .panel > .panel-footer {
    min-height: 50px;
    padding: 8px 18px;
    border-top: 1px solid #e8edf4;
    background: #fff;
}

.codeg7-purchase-form-page .cg-purchase-section {
    border-left-color: var(--cg-orange);
    color: var(--cg-text);
    background: #fbfcfe;
}

.codeg7-purchase-form-page .panel-footer .btn {
    min-height: 36px;
    margin-right: 7px;
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 10.5px;
    font-weight: 800;
}

.codeg7-purchase-form-page > form > .panel > .panel-footer .btn-primary,
.codeg7-purchase-panel .panel-footer .btn-primary {
    border-color: var(--cg-orange);
    color: #fff;
    background: var(--cg-orange);
}

.codeg7-purchase-form-page textarea.form-control,
.codeg7-purchase-panel textarea.form-control {
    min-height: 82px;
    padding: 10px 12px;
    font-size: 10.5px;
    line-height: 1.45;
}

.codeg7-purchase-page .form-control:focus,
.codeg7-purchase-page .select2-container--focus .select2-selection,
.codeg7-purchase-panel .form-control:focus,
.codeg7-purchase-panel .select2-container--focus .select2-selection {
    border-color: #9bb7df;
    box-shadow: 0 0 0 3px rgba(47, 128, 237, .09);
}

right-panel > .container-part[page-name="CompraPesquisaItemForm"],
right-panel > .container-part[page-name="CompraPesquisaStatusForm"],
right-panel > .container-part[page-name="CompraPrecoColetadoForm"],
right-panel > .container-part[page-name="CompraPrecoDescarteForm"] {
    padding: 0;
    background: #f5f7fb;
    overflow-y: auto;
}

[page-name="CompraPesquisaItemForm"] .codeg7-purchase-panel,
[page-name="CompraPesquisaStatusForm"] .codeg7-purchase-panel,
[page-name="CompraPrecoColetadoForm"] .codeg7-purchase-panel,
[page-name="CompraPrecoDescarteForm"] .codeg7-purchase-panel {
    min-height: 100%;
}

@media (max-width: 1100px) {
    .cg-purchase-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .cg-purchase-steps {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        row-gap: 14px;
    }
}

@media (max-width: 767px) {
    .cg-purchase-hero {
        padding: 19px;
        align-items: stretch;
        flex-direction: column;
    }

    .cg-purchase-hero-copy {
        align-items: flex-start;
    }

    .cg-purchase-hero-icon {
        width: 46px;
        height: 46px;
        flex-basis: 46px;
        font-size: 18px;
    }

    .cg-purchase-hero-copy h1 {
        font-size: 20px;
    }

    .cg-purchase-hero-action,
    .cg-purchase-hero-back {
        width: 100%;
        justify-content: center;
    }

    .cg-purchase-metrics,
    .cg-purchase-steps {
        grid-template-columns: 1fr;
    }

    .cg-purchase-step:not(:last-child)::after {
        width: calc(100% - 48px);
        height: 1px;
        top: auto;
        right: 0;
        bottom: -7px;
    }
}

/* CompraPesquisaList espelha exatamente a composição visual do ProdutoList */
[page-name="CompraPesquisaList"] .panel {
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
    overflow: hidden;
}

[page-name="CompraPesquisaList"] .panel-heading {
    min-height: 70px;
    padding: 16px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    background: #fff !important;
}

[page-name="CompraPesquisaList"] .panel-heading .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

[page-name="CompraPesquisaList"] .panel-body {
    padding: 0;
}

[page-name="CompraPesquisaList"] .datagrid-header-actions {
    min-height: 84px;
    padding: 14px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    gap: 16px;
}

[page-name="CompraPesquisaList"] .datagrid-header-actions-left-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

[page-name="CompraPesquisaList"] .datagrid-header-actions .btn {
    min-height: 35px;
    margin: 0 !important;
    padding: 7px 13px;
    border-color: #dbe2ed;
    border-radius: 7px;
    color: var(--cg-text);
    background: #fff;
    font-size: 11px;
    font-weight: 700;
    box-shadow: none;
}

[page-name="CompraPesquisaList"] .datagrid-header-actions .cg-product-new {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

[page-name="CompraPesquisaList"] .datagrid-header-actions .btn:hover {
    border-color: #b9c7da;
    background: #f8faff;
}

[page-name="CompraPesquisaList"] .datagrid-header-actions .cg-product-new:hover {
    border-color: #0a2c61;
    color: #fff;
    background: #0a2c61;
}

[page-name="CompraPesquisaList"] .table-responsive {
    border: 0;
}

[page-name="CompraPesquisaList"] table.table {
    margin-bottom: 0;
    color: var(--cg-text);
    font-size: 10.5px;
}

[page-name="CompraPesquisaList"] table.table thead th {
    height: 39px;
    padding: 9px 8px;
    border-color: #e6ebf3;
    color: var(--cg-text);
    background: #fff;
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
}

[page-name="CompraPesquisaList"] table.table tbody td {
    height: 42px;
    padding: 9px 8px;
    border-color: #e9edf4;
    vertical-align: middle;
    background: #fff;
}

[page-name="CompraPesquisaList"] table.table tbody tr:hover td {
    background: #f8faff;
}

[page-name="CompraPesquisaList"] .tdatagrid_cell.action .btn {
    width: 27px;
    height: 27px;
    margin: 0 2px;
    padding: 4px;
    border: 1px solid #e1e6ef;
    border-radius: 50%;
    background: #fff;
}

[page-name="CompraPesquisaList"] .panel-footer {
    min-height: 50px;
    padding: 8px 18px;
    border-top: 1px solid #e8edf4;
    background: #fff;
}

right-panel > .container-part[page-name="CompraPesquisaListSearch"] {
    width: 700px;
    padding: 14px;
    background: #f5f7fb;
    overflow-y: auto;
}

[page-name="CompraPesquisaListSearch"] > .panel,
[page-name="CompraPesquisaListSearch"] .panel {
    min-height: 0 !important;
    margin: 0;
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 8px 28px rgba(7, 27, 72, .12);
    overflow: hidden;
}

[page-name="CompraPesquisaListSearch"] .panel-heading {
    min-height: 72px;
    padding: 14px 18px;
    border-bottom: 1px solid #e9edf4;
    display: flex;
    align-items: center;
    background: #fff !important;
}

[page-name="CompraPesquisaListSearch"] .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

[page-name="CompraPesquisaListSearch"] .panel-body {
    padding: 18px 18px 8px;
    background: #fff;
}

[page-name="CompraPesquisaListSearch"] .form-group {
    margin-bottom: 12px;
}

[page-name="CompraPesquisaListSearch"] label {
    margin-bottom: 6px;
    color: var(--cg-text);
    font-size: 10.5px !important;
    font-weight: 600;
}

[page-name="CompraPesquisaListSearch"] .form-control,
[page-name="CompraPesquisaListSearch"] .select2-selection {
    min-height: 36px;
    border-color: #dce3ee;
    border-radius: 6px;
    color: var(--cg-text);
    background: #fff;
    box-shadow: none;
    font-size: 11px;
}

[page-name="CompraPesquisaListSearch"] .form-control:focus,
[page-name="CompraPesquisaListSearch"] .select2-container--focus .select2-selection {
    border-color: #9bb7df;
    box-shadow: 0 0 0 3px rgba(47, 128, 237, .09);
}

[page-name="CompraPesquisaListSearch"] .panel-footer {
    min-height: 62px;
    padding: 13px 18px;
    border-top: 1px solid #e9edf4;
    background: #fbfcfe;
}

[page-name="CompraPesquisaListSearch"] .panel-footer .btn,
[page-name="CompraPesquisaListSearch"] .panel-heading .btn {
    min-height: 34px;
    margin: 0 !important;
    padding: 7px 13px;
    border-radius: 7px;
    font-size: 11px;
    font-weight: 700;
}

[page-name="CompraPesquisaListSearch"] .cg-product-filter-search {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

@media (max-width: 767px) {
    [page-name="CompraPesquisaList"] .datagrid-header-actions {
        align-items: stretch;
        flex-direction: column;
    }

    [page-name="CompraPesquisaList"] .datagrid-header-actions-left-actions,
    [page-name="CompraPesquisaList"] .cg-product-total-card {
        width: 100%;
    }

    right-panel > .container-part[page-name="CompraPesquisaListSearch"] {
        width: 100% !important;
        padding: 8px;
    }
}

/* Formulários de compras usam o mesmo acabamento do ProdutoForm */
.codeg7-product-side-form {
    width: 100%;
    padding: 14px;
}

.codeg7-product-side-form > form > .panel,
.codeg7-product-side-form > .panel {
    margin: 0;
}

[page-name="CompraPesquisaItemForm"],
[page-name="CompraPesquisaStatusForm"],
[page-name="CompraPrecoColetadoForm"],
[page-name="CompraPrecoDescarteForm"] {
    background: #f5f7fb;
}

[page-name="CompraPesquisaItemForm"] .panel-heading,
[page-name="CompraPesquisaStatusForm"] .panel-heading,
[page-name="CompraPrecoColetadoForm"] .panel-heading,
[page-name="CompraPrecoDescarteForm"] .panel-heading,
[page-name="CompraPesquisaForm"] .panel-heading {
    min-height: 70px;
    padding: 16px 18px;
}

[page-name="CompraPesquisaItemForm"] .panel-footer,
[page-name="CompraPesquisaStatusForm"] .panel-footer,
[page-name="CompraPrecoColetadoForm"] .panel-footer,
[page-name="CompraPrecoDescarteForm"] .panel-footer,
[page-name="CompraPesquisaForm"] .panel-footer {
    background: #fff;
}

[page-name="CompraPesquisaForm"] table.table thead th {
    height: 39px;
    padding: 9px 8px;
    color: var(--cg-text);
    background: #fff;
    font-size: 10px;
    font-weight: 700;
}

[page-name="CompraPesquisaForm"] table.table tbody td {
    height: 42px;
    padding: 9px 8px;
}

.codeg7-purchase-form-page .cg-purchase-notice {
    border-color: #ffd6b2;
    color: #9a4a00;
    background: #fff8f1;
}

.codeg7-purchase-form-page .cg-purchase-notice i {
    color: var(--cg-orange);
}

.cg-manual-help {
    margin-top: 3px;
    float: right;
}

.cg-manual-help a {
    width: 29px;
    height: 29px;
    border: 1px solid transparent;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #58708f;
    font-size: 15px;
    text-decoration: none !important;
}

.cg-manual-help a:hover {
    border-color: #dce3ee;
    color: var(--cg-orange);
    background: #fff8f1;
}

/* Etapa 3: coleta manual e formação da cesta de preços */
[page-name="CompraPesquisaColetaForm"] .panel {
    border: 1px solid var(--cg-border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(6, 31, 73, .04);
    overflow: hidden;
}

[page-name="CompraPesquisaColetaForm"] .panel-heading {
    min-height: 70px;
    padding: 16px 18px;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    background: #fff !important;
}

[page-name="CompraPesquisaColetaForm"] .panel-heading .panel-title {
    width: 100%;
    color: var(--cg-text) !important;
}

[page-name="CompraPesquisaColetaForm"] .panel-body {
    padding: 0;
}

[page-name="CompraPesquisaColetaForm"] .datagrid-header-actions {
    min-height: 72px;
    padding: 12px 18px;
    border-top: 1px solid #edf0f5;
    border-bottom: 1px solid #edf0f5;
    display: flex;
    align-items: center;
    gap: 16px;
}

[page-name="CompraPesquisaColetaForm"] .datagrid-header-actions-left-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

[page-name="CompraPesquisaColetaForm"] .datagrid-header-actions .btn {
    min-height: 35px;
    margin: 0 !important;
    padding: 7px 13px;
    border-color: #dbe2ed;
    border-radius: 7px;
    color: var(--cg-text);
    background: #fff;
    font-size: 11px;
    font-weight: 700;
    box-shadow: none;
}

[page-name="CompraPesquisaColetaForm"] .datagrid-header-actions .cg-product-new {
    border-color: var(--cg-navy);
    color: #fff;
    background: var(--cg-navy);
}

[page-name="CompraPesquisaColetaForm"] table.table {
    margin-bottom: 0;
    color: var(--cg-text);
    font-size: 10.5px;
}

[page-name="CompraPesquisaColetaForm"] table.table thead th {
    height: 39px;
    padding: 9px 8px;
    border-color: #e6ebf3;
    color: var(--cg-text);
    background: #fff;
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
}

[page-name="CompraPesquisaColetaForm"] table.table tbody td {
    height: 46px;
    padding: 9px 8px;
    border-color: #e9edf4;
    vertical-align: middle;
    background: #fff;
}

[page-name="CompraPesquisaColetaForm"] table.table tbody tr:hover td {
    background: #f8faff;
}

[page-name="CompraPesquisaColetaForm"] .tdatagrid_cell.action .btn {
    width: 27px;
    height: 27px;
    margin: 0 2px;
    padding: 4px;
    border: 1px solid #e1e6ef;
    border-radius: 50%;
    background: #fff;
}

.cg-price-item-summary {
    min-width: 680px;
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--cg-text);
    background: #fbfcfe;
}

.cg-price-item-icon {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 11px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: var(--cg-navy);
    font-size: 16px;
}

.cg-price-item-copy {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.cg-price-item-copy strong {
    font-size: 13px;
    line-height: 1.35;
}

.cg-price-item-copy small {
    color: #64748b;
    font-size: 10.5px;
}

.cg-price-notice {
    margin: 12px 18px 0;
}

.cg-price-state,
.cg-price-count {
    min-width: 72px;
    padding: 4px 9px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    font-weight: 800;
    white-space: nowrap;
}

.cg-price-state-selected,
.cg-price-count-ready {
    color: #137333;
    background: #e7f7ed;
}

.cg-price-state-discarded {
    color: #b42318;
    background: #fff0ee;
}

.cg-price-state-pending,
.cg-price-count-empty {
    color: #9a4a00;
    background: #fff3e8;
}

.cg-price-origin-link {
    width: 28px;
    height: 28px;
    border: 1px solid #dce3ee;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #2563eb;
    background: #fff;
}

.cg-price-metrics {
    min-width: 760px;
    padding: 16px 18px 18px;
    border-top: 1px solid #edf0f5;
    display: grid;
    grid-template-columns: repeat(6, minmax(120px, 1fr));
    gap: 10px;
    background: #fbfcfe;
}

.cg-price-metric {
    min-height: 72px;
    padding: 12px;
    border: 1px solid #e1e7f0;
    border-radius: 9px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 7px;
    color: var(--cg-text);
    background: #fff;
}

.cg-price-metric span {
    color: #64748b;
    font-size: 9.5px;
    font-weight: 700;
}

.cg-price-metric span i {
    width: 16px;
    color: var(--cg-orange);
}

.cg-price-metric strong {
    font-size: 12px;
}

.cg-price-metric-highlight {
    border-color: #ffd0aa;
    background: #fff8f1;
}

.cg-price-metric-highlight strong {
    color: #c65100;
}

@media (max-width: 1100px) {
    .cg-price-metrics {
        grid-template-columns: repeat(3, minmax(150px, 1fr));
    }
}

@media (max-width: 767px) {
    [page-name="CompraPesquisaColetaForm"] .datagrid-header-actions {
        align-items: stretch;
        flex-direction: column;
    }

    [page-name="CompraPesquisaColetaForm"] .datagrid-header-actions-left-actions,
    [page-name="CompraPesquisaColetaForm"] .cg-product-total-card {
        width: 100%;
    }

    .cg-price-item-summary {
        min-width: 0;
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .cg-price-metrics {
        min-width: 0;
        grid-template-columns: 1fr;
    }
}

/* Pesquisa de preços — etapa 6: integração com fontes públicas */
.codeg7-public-search-page {
    display: grid;
    gap: 18px;
}

.cg-public-search-summary {
    margin: 0 0 14px;
    border: 1px solid #dbe7f4;
    border-radius: 12px;
    background: linear-gradient(135deg, #f7fbff, #f0fdfa);
}

.cg-public-search-help {
    display: block;
    margin: 0 0 16px;
}

.cg-public-search-help a {
    color: #075985;
    text-decoration: underline;
}

.cg-public-search-result-notice {
    margin: 0 0 12px;
    padding: 11px 14px;
    border: 1px solid #bae6fd;
    border-radius: 9px;
    background: #f0f9ff;
    color: #0c4a6e;
}

.cg-public-search-result-notice i {
    margin-right: 7px;
}

.cg-public-search-button {
    border-color: #0284c7 !important;
    background: #0284c7 !important;
}

@media (max-width: 768px) {
    .codeg7-public-search-page .panel-footer {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }
}

/* Pesquisa de preços — etapa 7: inteligência e automações */
.cg-intelligence-button {
    background: #d97706 !important;
    border-color: #d97706 !important;
}

.cg-intelligence-summary {
    gap: 14px;
}

.cg-intelligence-catalog {
    margin-left: auto;
    padding: 8px 12px;
    border-radius: 999px;
    background: #fff7ed;
    color: #9a3412;
    font-weight: 700;
    white-space: nowrap;
}

.cg-intelligence-explanation {
    border-left-color: #d97706;
    background: #fffbeb;
}

.cg-intelligence-toolbar {
    justify-content: flex-start;
    gap: 8px;
    padding: 12px 0;
}

.cg-intelligence-metrics {
    margin: 4px 0 14px;
}

.cg-intelligence-compatibility,
.cg-intelligence-alert {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin: 2px;
    padding: 4px 7px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}

.cg-intelligence-compatibility.alta {
    background: #dcfce7;
    color: #166534;
}

.cg-intelligence-compatibility.media {
    background: #fef3c7;
    color: #92400e;
}

.cg-intelligence-compatibility.baixa {
    background: #fee2e2;
    color: #991b1b;
}

.cg-intelligence-compatibility.indefinida {
    background: #e2e8f0;
    color: #475569;
}

.cg-intelligence-alert-price {
    background: #ffedd5;
    color: #c2410c;
}

.cg-intelligence-alert-ok {
    background: #ecfdf5;
    color: #047857;
}

@media (max-width: 767px) {
    .cg-intelligence-summary {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .cg-intelligence-catalog {
        margin-left: 0;
    }
}

/* Pesquisa de preços — etapa 8: aprovação, comunicação, BI e ERP */
.codeg7-advanced-page,
.codeg7-bi-page,
.codeg7-api-page {
    display: grid;
    gap: 16px;
}

.cg-advanced-hero,
.cg-bi-hero,
.cg-api-hero {
    background:
        radial-gradient(circle at 82% 15%, rgba(196, 181, 253, .24), transparent 26%),
        linear-gradient(135deg, #312e81, #5b21b6 58%, #0f766e);
}

.cg-advanced-valid {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #047857;
    font-weight: 700;
}

.cg-advanced-invalid {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #b91c1c;
    font-weight: 700;
}

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

.cg-bi-grid .cg-bi-panel:last-child {
    grid-column: 1 / -1;
}

.cg-bi-panel {
    margin: 0;
    overflow: hidden;
    border-radius: 12px;
}

.cg-bi-panel .table {
    margin-bottom: 0;
}

.cg-bi-dot {
    display: inline-block;
    width: 9px;
    height: 9px;
    margin-right: 8px;
    border-radius: 50%;
}

.cg-bi-quality {
    margin: 0;
    border-left-color: #7c3aed;
    background: #f5f3ff;
    color: #4c1d95;
}

.cg-api-token-once {
    margin-top: 12px;
    padding: 12px;
    overflow-wrap: anywhere;
    border: 1px dashed #7c3aed;
    border-radius: 8px;
    background: #f5f3ff;
    user-select: all;
}

.cg-api-token-once code {
    color: #4c1d95;
    font-size: 13px;
}

.cg-api-doc {
    padding: 4px 2px;
}

.cg-api-doc pre {
    padding: 14px;
    overflow: auto;
    border: 1px solid #d8b4fe;
    border-radius: 10px;
    background: #faf5ff;
    color: #3b0764;
}

@media (max-width: 767px) {
    .cg-bi-grid {
        grid-template-columns: 1fr;
    }

    .cg-bi-grid .cg-bi-panel:last-child {
        grid-column: auto;
    }
}
