/* ==========================================================================
   DISTRIBUIPRO / SAAS STUDIO PRO - GLOBAL TABLES DESIGN SYSTEM
   Modern Clean Flat / SaaS styling for all OmegaGestor DataTables & Tables
   ========================================================================== */

/* ─── 1. WRAPPER, CONTAINERS E ESPAÇAMENTO ───────────────────────────── */
.table-responsive {
    border: none !important;
    margin-bottom: 24px !important;
    border-radius: 14px !important;
    background: #ffffff !important;
    box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.04) !important;
    padding: 0 !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
}

/* Custom slim scrollbar */
.table-responsive::-webkit-scrollbar,
.dataTables_scrollBody::-webkit-scrollbar {
    height: 7px;
    width: 7px;
}
.table-responsive::-webkit-scrollbar-track,
.dataTables_scrollBody::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 9999px;
}
.table-responsive::-webkit-scrollbar-thumb,
.dataTables_scrollBody::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 9999px;
}
.table-responsive::-webkit-scrollbar-thumb:hover,
.dataTables_scrollBody::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ─── 2. TOOLBAR SUPERIOR DO DATATABLES (BUSCA, EXPORTAÇÃO, QUANTIDADE) ─ */
.dataTables_wrapper .dt-toolbar-header,
.dataTables_wrapper > .row:first-child {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    margin-bottom: 16px !important;
    padding: 4px 2px !important;
}

.dataTables_wrapper .dt-toolbar-header:before,
.dataTables_wrapper .dt-toolbar-header:after,
.dataTables_wrapper > .row:first-child:before,
.dataTables_wrapper > .row:first-child:after {
    display: none !important;
}

/* Agrupamento Esquerdo (Mostrar X e Botões) */
.dt-toolbar-left,
.dataTables_wrapper > .row:first-child > [class*="col-"]:first-child {
    display: flex !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    float: none !important;
    width: auto !important;
    padding: 0 !important;
}

/* Agrupamento Direito (Busca) */
.dt-toolbar-right,
.dataTables_wrapper > .row:first-child > [class*="col-"]:last-child {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    float: none !important;
    width: auto !important;
    margin-left: auto !important;
    padding: 0 !important;
}

/* Seletor "Mostrar 25 entradas" */
.dataTables_length {
    display: inline-flex !important;
    align-items: center !important;
    margin: 0 !important;
    float: none !important;
    white-space: nowrap !important;
}
.dataTables_length label {
    display: inline-flex !important;
    align-items: center !important;
    margin-bottom: 0 !important;
    font-weight: 500 !important;
    color: #64748b !important;
    font-size: 13px !important;
    gap: 6px !important;
}
.dataTables_length select {
    height: 38px !important;
    min-width: 72px !important;
    border-radius: 10px !important;
    border: 1px solid #e2e8f0 !important;
    padding: 6px 12px !important;
    color: #1e293b !important;
    background-color: #ffffff !important;
    font-weight: 600 !important;
    font-size: 13px !important;
    margin: 0 4px !important;
    outline: none !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
    transition: all 0.2s ease-in-out !important;
    cursor: pointer !important;
}
.dataTables_length select:focus {
    border-color: #4f46e5 !important;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12) !important;
}

/* Botões de Ação/Exportação (CSV, Excel, Imprimir, PDF, Colunas) */
.dt-buttons {
    display: inline-flex !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 6px !important;
    margin: 0 !important;
    float: none !important;
}
.dt-buttons .btn,
.dt-buttons a.btn,
.dt-buttons .btn-default,
.dt-button {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    color: #475569 !important;
    font-size: 12.5px !important;
    font-weight: 600 !important;
    border-radius: 10px !important;
    padding: 0 14px !important;
    height: 38px !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 7px !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    line-height: normal !important;
    margin: 0 !important;
    text-decoration: none !important;
    cursor: pointer !important;
}
.dt-buttons .btn i,
.dt-buttons a.btn i,
.dt-button i {
    font-size: 13px !important;
    color: #64748b !important;
    transition: color 0.15s !important;
}
.dt-buttons .btn:hover,
.dt-buttons a.btn:hover,
.dt-button:hover {
    background: #f8fafc !important;
    border-color: #cbd5e1 !important;
    color: #0f172a !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 4px 12px -2px rgba(15, 23, 42, 0.08) !important;
}
.dt-buttons .btn:hover i,
.dt-buttons a.btn:hover i,
.dt-button:hover i {
    color: #4f46e5 !important;
}

/* Campo de Busca (Search Input Estilo Studio Pro) */
.dataTables_filter {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    margin: 0 !important;
    float: none !important;
}
.dataTables_filter label {
    display: inline-flex !important;
    align-items: center !important;
    margin-bottom: 0 !important;
    font-weight: 500 !important;
    color: #64748b !important;
    font-size: 13px !important;
    position: relative !important;
}
.dataTables_filter input[type="search"],
.dataTables_filter input {
    height: 38px !important;
    width: 260px !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 10px !important;
    padding: 6px 14px 6px 36px !important;
    font-size: 13px !important;
    color: #0f172a !important;
    background-color: #ffffff !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z'%3E%3C/path%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: 11px center !important;
    background-size: 16px 16px !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    margin-left: 0 !important;
    outline: none !important;
}
.dataTables_filter input::placeholder {
    color: #94a3b8 !important;
}
.dataTables_filter input:focus {
    border-color: #4f46e5 !important;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12) !important;
    width: 300px !important;
}

/* ─── 3. TABELA (ESTRUTURA CLEAN FLAT / STUDIO PRO) ──────────────────── */
table.dataTable,
.table.dataTable,
.table {
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #eef2f6 !important;
    border-radius: 14px !important;
    overflow: hidden !important;
    width: 100% !important;
    margin-top: 6px !important;
    margin-bottom: 16px !important;
    background: #ffffff !important;
}

/* Reset para tabelas aninhadas dentro de células */
.table td table,
table.dataTable td table,
.table td .table-slim,
.table td table.no-border {
    border: none !important;
    box-shadow: none !important;
    margin: 0 !important;
    background: transparent !important;
    border-radius: 0 !important;
}
.table td table th,
.table td table td {
    background: transparent !important;
    border: none !important;
    padding: 4px 6px !important;
}

/* Cabeçalho da Tabela */
table.dataTable thead th,
table.dataTable thead td,
table.dataTable.nowrap thead th,
.table > thead > tr > th {
    background-color: #f8fafc !important;
    color: #64748b !important;
    font-weight: 700 !important;
    font-size: 11px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    padding: 13px 14px !important;
    border-top: none !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-left: none !important;
    border-right: none !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: break-word !important;
    line-height: 1.35 !important;
    vertical-align: middle !important;
    transition: background-color 0.15s ease !important;
}

/* Bordas arredondadas nos cantos superiores do thead */
table.dataTable thead tr:first-child th:first-child,
.table > thead > tr:first-child > th:first-child {
    border-top-left-radius: 13px !important;
}
table.dataTable thead tr:first-child th:last-child,
.table > thead > tr:first-child > th:last-child {
    border-top-right-radius: 13px !important;
}

/* Linhas do Corpo da Tabela (tbody td) */
table.dataTable tbody tr td,
.table > tbody > tr > td {
    padding: 13px 14px !important;
    vertical-align: middle !important;
    border-top: 1px solid #f1f5f9 !important;
    border-bottom: none !important;
    border-left: none !important;
    border-right: none !important;
    color: #1e293b !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    line-height: 1.4 !important;
    background: #ffffff !important;
    transition: background-color 0.15s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Remove listras pesadas do table-striped */
.table-striped > tbody > tr:nth-of-type(odd) td,
table.dataTable.stripe tbody tr.odd td {
    background-color: #ffffff !important;
}

/* Efeito Hover Ultra-Suave */
table.dataTable tbody tr:hover td,
.table-hover > tbody > tr:hover td,
.table-striped > tbody > tr:hover td {
    background-color: #f8fafc !important;
}

/* Bordas arredondadas nos cantos inferiores do último tr */
table.dataTable tbody tr:last-child td:first-child,
.table > tbody > tr:last-child > td:first-child {
    border-bottom-left-radius: 13px !important;
}
table.dataTable tbody tr:last-child td:last-child,
.table > tbody > tr:last-child > td:last-child {
    border-bottom-right-radius: 13px !important;
}

/* ─── 4. CHECKBOXES MODERNOS ─────────────────────────────────────────── */
table.dataTable th input[type="checkbox"],
table.dataTable td input[type="checkbox"],
.table th input[type="checkbox"],
.table td input[type="checkbox"] {
    accent-color: #4f46e5 !important;
    width: 16px !important;
    height: 16px !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    vertical-align: middle !important;
    margin: 0 !important;
}

/* ─── 5. ÍCONES DE ORDENAÇÃO DISCRETOS ────────────────────────────────── */
table.dataTable thead .sorting,
table.dataTable thead .sorting_asc,
table.dataTable thead .sorting_desc {
    cursor: pointer !important;
    position: relative !important;
    padding-right: 22px !important;
}
table.dataTable thead .sorting:after,
table.dataTable thead .sorting_asc:after,
table.dataTable thead .sorting_desc:after {
    position: absolute !important;
    top: 50% !important;
    right: 8px !important;
    transform: translateY(-50%) !important;
    opacity: 0.35 !important;
    font-size: 11px !important;
}
table.dataTable thead .sorting_asc:after,
table.dataTable thead .sorting_desc:after {
    opacity: 0.9 !important;
    color: #4f46e5 !important;
}

/* ─── 6. BOTÕES DE AÇÃO NA LINHA (AÇÕES ▾ / QUICK ACTIONS) ───────────── */
table.dataTable td .btn,
.table td .btn {
    border-radius: 8px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    padding: 6px 12px !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04) !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
}

/* Botão Ações Dropdown Padrão */
table.dataTable td .btn-info,
.table td .btn-info {
    background: #f1f5f9 !important;
    border: 1px solid #e2e8f0 !important;
    color: #334155 !important;
}
table.dataTable td .btn-info:hover,
.table td .btn-info:hover {
    background: #e2e8f0 !important;
    border-color: #cbd5e1 !important;
    color: #0f172a !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 3px 8px -1px rgba(15, 23, 42, 0.1) !important;
}

/* Dropdown Menu de Ações Estilo Studio Pro */
table.dataTable td .dropdown-menu,
.table td .dropdown-menu {
    border-radius: 12px !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.12), 0 8px 10px -6px rgba(15, 23, 42, 0.04) !important;
    padding: 6px !important;
    min-width: 175px !important;
    margin-top: 4px !important;
    background: #ffffff !important;
    z-index: 1050;
}
table.dataTable td .dropdown-menu > li > a,
.table td .dropdown-menu > li > a {
    border-radius: 7px !important;
    padding: 8px 12px !important;
    font-size: 12.5px !important;
    color: #334155 !important;
    font-weight: 500 !important;
    transition: all 0.15s ease !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
}
table.dataTable td .dropdown-menu > li > a:hover,
.table td .dropdown-menu > li > a:hover {
    background-color: #f1f5f9 !important;
    color: #0f172a !important;
}
table.dataTable td .dropdown-menu > li > a i,
.table td .dropdown-menu > li > a i {
    color: #64748b !important;
    font-size: 13px !important;
    width: 16px !important;
    text-align: center !important;
}

/* Dropup de Ações em Tabelas */
table.dataTable td .btn-group.dropup .dropdown-menu,
table.dataTable td .dropdown.dropup .dropdown-menu,
.table td .btn-group.dropup .dropdown-menu,
.table td .dropdown.dropup .dropdown-menu,
.dataTables_wrapper td .btn-group.dropup .dropdown-menu,
.table-responsive td .btn-group.dropup .dropdown-menu,
.dataTables_scrollBody td .btn-group.dropup .dropdown-menu {
    top: auto !important;
    bottom: 100% !important;
    margin-top: 0 !important;
    margin-bottom: 6px !important;
    box-shadow: 0 -10px 25px -5px rgba(15, 23, 42, 0.12), 0 -8px 10px -6px rgba(15, 23, 42, 0.04) !important;
}

/* Caret / Seta apontando para cima no Dropup */
table.dataTable td .btn-group.dropup .dropdown-toggle .caret,
.table td .btn-group.dropup .dropdown-toggle .caret {
    border-bottom: 4px solid currentColor !important;
    border-top: 0 !important;
}

/* Z-Index prioritário para linha com dropdown aberto */
table.dataTable tr.has-open-dropdown,
table.dataTable tr:has(.open),
.table tr:has(.open),
.table-responsive tr:has(.open),
.dataTables_scrollBody tr:has(.open) {
    z-index: 1050 !important;
    position: relative !important;
}

/* ─── 7. STATUS E BADGES EM PÍLULA (STUDIO PRO PILLS) ────────────────── */
table.dataTable .label, table.dataTable .badge,
.table .label, .table .badge,
.box-body .label, .box-body .badge {
    border-radius: 9999px !important;
    font-weight: 600 !important;
    font-size: 11px !important;
    padding: 3.5px 10px !important;
    letter-spacing: 0.02em !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    box-shadow: none !important;
    text-transform: capitalize !important;
}

/* Sucesso / Ativo / Pago */
table.dataTable .label-success, table.dataTable .bg-green,
.table .label-success, .table .bg-green,
.box-body .label-success, .box-body .bg-green {
    background-color: #ecfdf5 !important;
    color: #059669 !important;
    border: 1px solid #a7f3d0 !important;
}

/* Informativo / Aberto */
table.dataTable .label-info, table.dataTable .bg-aqua, table.dataTable .bg-info,
.table .label-info, .table .bg-aqua, .table .bg-info,
.box-body .label-info, .box-body .bg-aqua, .box-body .bg-info {
    background-color: #eff6ff !important;
    color: #2563eb !important;
    border: 1px solid #bfdbfe !important;
}

/* Alerta / Pendente */
table.dataTable .label-warning, table.dataTable .bg-yellow,
.table .label-warning, .table .bg-yellow,
.box-body .label-warning, .box-body .bg-yellow {
    background-color: #fffbeb !important;
    color: #d97706 !important;
    border: 1px solid #fde68a !important;
}

/* Perigo / Cancelado / Inativo */
table.dataTable .label-danger, table.dataTable .bg-red,
.table .label-danger, .table .bg-red,
.box-body .label-danger, .box-body .bg-red {
    background-color: #fef2f2 !important;
    color: #dc2626 !important;
    border: 1px solid #fecaca !important;
}

/* Neutro / Padrão */
table.dataTable .label-default, .table .label-default, .box-body .label-default {
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    border: 1px solid #e2e8f0 !important;
}

/* ─── 8. RODAPÉ DO DATATABLES (INFO E PAGINAÇÃO) ─────────────────────── */
.dataTables_wrapper .dt-toolbar-footer,
.dataTables_wrapper > .row:last-child {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    margin-top: 16px !important;
    padding: 4px 2px !important;
}
.dataTables_wrapper .dt-toolbar-footer:before,
.dataTables_wrapper .dt-toolbar-footer:after,
.dataTables_wrapper > .row:last-child:before,
.dataTables_wrapper > .row:last-child:after {
    display: none !important;
}

.dataTables_info {
    color: #64748b !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    padding: 0 !important;
    float: none !important;
}

.dataTables_paginate {
    display: flex !important;
    justify-content: flex-end !important;
    float: none !important;
    margin: 0 !important;
}
.dataTables_paginate ul.pagination {
    margin: 0 !important;
    display: flex !important;
    gap: 5px !important;
}
.dataTables_paginate ul.pagination > li > a,
.dataTables_paginate ul.pagination > li > span {
    border-radius: 9px !important;
    border: 1px solid #e2e8f0 !important;
    color: #475569 !important;
    font-size: 12.5px !important;
    font-weight: 600 !important;
    padding: 7px 13px !important;
    background: #ffffff !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
}
.dataTables_paginate ul.pagination > li > a:hover {
    background-color: #f8fafc !important;
    border-color: #cbd5e1 !important;
    color: #0f172a !important;
    transform: translateY(-1px) !important;
}
.dataTables_paginate ul.pagination > li.active > a,
.dataTables_paginate ul.pagination > li.active > a:focus,
.dataTables_paginate ul.pagination > li.active > a:hover {
    background: #4f46e5 !important;
    border-color: #4f46e5 !important;
    color: #ffffff !important;
    box-shadow: 0 2px 6px rgba(79, 70, 229, 0.28) !important;
}
.dataTables_paginate ul.pagination > li.disabled > a,
.dataTables_paginate ul.pagination > li.disabled > span {
    color: #94a3b8 !important;
    background-color: #f8fafc !important;
    border-color: #e2e8f0 !important;
    cursor: not-allowed !important;
    box-shadow: none !important;
}

/* ─── 9. MODO ESCURO (COMPATIBILIDADE DISTRIBUIPRO DARK) ──────────────── */
html[data-theme="dark"] .table-responsive {
    background: #111827 !important;
    box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.3) !important;
}
html[data-theme="dark"] table.dataTable,
html[data-theme="dark"] .table.dataTable,
html[data-theme="dark"] .table {
    background: #111827 !important;
    border-color: #1f2937 !important;
}
html[data-theme="dark"] table.dataTable thead th,
html[data-theme="dark"] .table > thead > tr > th {
    background-color: #1e293b !important;
    color: #94a3b8 !important;
    border-bottom-color: #334155 !important;
}
html[data-theme="dark"] table.dataTable tbody tr td,
html[data-theme="dark"] .table > tbody > tr > td {
    background-color: #111827 !important;
    color: #e2e8f0 !important;
    border-top-color: #1f2937 !important;
}
html[data-theme="dark"] table.dataTable tbody tr:hover td,
html[data-theme="dark"] .table-hover > tbody > tr:hover td {
    background-color: #1e293b !important;
}
html[data-theme="dark"] .dataTables_length select {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #e2e8f0 !important;
}
html[data-theme="dark"] .dt-buttons .btn,
html[data-theme="dark"] .dt-buttons a.btn,
html[data-theme="dark"] .dt-button {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #cbd5e1 !important;
}
html[data-theme="dark"] .dt-buttons .btn:hover,
html[data-theme="dark"] .dt-buttons a.btn:hover,
html[data-theme="dark"] .dt-button:hover {
    background-color: #334155 !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .dataTables_filter input {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #f1f5f9 !important;
}
html[data-theme="dark"] table.dataTable td .btn-info,
html[data-theme="dark"] .table td .btn-info {
    background: #1e293b !important;
    border-color: #334155 !important;
    color: #cbd5e1 !important;
}
html[data-theme="dark"] table.dataTable td .btn-info:hover,
html[data-theme="dark"] .table td .btn-info:hover {
    background: #334155 !important;
    color: #ffffff !important;
}
html[data-theme="dark"] table.dataTable td .dropdown-menu,
html[data-theme="dark"] .table td .dropdown-menu {
    background: #1e293b !important;
    border-color: #334155 !important;
}
html[data-theme="dark"] table.dataTable td .btn-group.dropup .dropdown-menu,
html[data-theme="dark"] .table td .btn-group.dropup .dropdown-menu {
    box-shadow: 0 -10px 25px -5px rgba(0, 0, 0, 0.5) !important;
}
html[data-theme="dark"] table.dataTable td .dropdown-menu > li > a,
html[data-theme="dark"] .table td .dropdown-menu > li > a {
    color: #e2e8f0 !important;
}
html[data-theme="dark"] table.dataTable td .dropdown-menu > li > a:hover,
html[data-theme="dark"] .table td .dropdown-menu > li > a:hover {
    background-color: #334155 !important;
}
html[data-theme="dark"] .dataTables_paginate ul.pagination > li > a,
html[data-theme="dark"] .dataTables_paginate ul.pagination > li > span {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #cbd5e1 !important;
}
html[data-theme="dark"] .dataTables_paginate ul.pagination > li > a:hover {
    background-color: #334155 !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .dataTables_info {
    color: #94a3b8 !important;
}

/* ─── 10. MINIATURAS E TIPOGRAFIA DE CÉLULAS ──────────────────────────── */
table.dataTable td img,
.table td img {
    border-radius: 8px !important;
    object-fit: cover !important;
    border: 1px solid #e2e8f0 !important;
    background: #f8fafc !important;
    transition: transform 0.2s ease !important;
}
table.dataTable td img:hover,
.table td img:hover {
    transform: scale(1.08) !important;
}
html[data-theme="dark"] table.dataTable td img,
html[data-theme="dark"] .table td img {
    border-color: #334155 !important;
    background: #1e293b !important;
}

/* Textos em Destaque dentro das Tabelas */
table.dataTable td strong,
.table td strong {
    font-weight: 600 !important;
    color: #0f172a !important;
}
html[data-theme="dark"] table.dataTable td strong,
html[data-theme="dark"] .table td strong {
    color: #f1f5f9 !important;
}

/* Subtítulos e Textos Muted dentro da Célula */
table.dataTable td small,
.table td small,
table.dataTable td .text-muted,
.table td .text-muted {
    color: #64748b !important;
    font-size: 11.5px !important;
}
html[data-theme="dark"] table.dataTable td small,
html[data-theme="dark"] .table td small,
html[data-theme="dark"] table.dataTable td .text-muted,
html[data-theme="dark"] .table td .text-muted {
    color: #94a3b8 !important;
}

/* ─── 11. CARDS DE LOG DE ATIVIDADES / ALTERAÇÕES (STUDIO PRO) ────────── */
.dp-activity-card {
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    padding: 12px 16px !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
    margin: 4px 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
}
.dp-activity-line {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 12px !important;
    font-size: 13px !important;
    line-height: 1.4 !important;
}
.dp-act-label {
    font-weight: 600 !important;
    color: #475569 !important;
    flex-shrink: 0 !important;
}
.dp-act-value {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    flex-wrap: wrap !important;
    justify-content: flex-end !important;
}
.dp-act-pill {
    padding: 3.5px 10px !important;
    border-radius: 9999px !important;
    font-size: 11.5px !important;
    font-weight: 600 !important;
    line-height: 1.2 !important;
    display: inline-flex !important;
    align-items: center !important;
}
.dp-pill-old {
    background: #f1f5f9 !important;
    color: #64748b !important;
    border: 1px solid #cbd5e1 !important;
    text-decoration: line-through !important;
    opacity: 0.8 !important;
}
.dp-pill-new {
    background: #eff6ff !important;
    color: #2563eb !important;
    border: 1px solid #bfdbfe !important;
}
.dp-act-arrow {
    color: #94a3b8 !important;
    font-size: 11px !important;
}
.dp-activity-note {
    font-size: 12.5px !important;
    color: #475569 !important;
    padding-top: 4px !important;
    border-top: 1px dashed #e2e8f0 !important;
}
html[data-theme="dark"] .dp-activity-card {
    background: #111827 !important;
    border-color: #334155 !important;
}
html[data-theme="dark"] .dp-act-label {
    color: #cbd5e1 !important;
}
html[data-theme="dark"] .dp-pill-old {
    background: #1e293b !important;
    border-color: #334155 !important;
    color: #94a3b8 !important;
}
html[data-theme="dark"] .dp-pill-new {
    background: rgba(37, 99, 235, 0.2) !important;
    border-color: rgba(37, 99, 235, 0.4) !important;
    color: #93c5fd !important;
}

/* ─── 13. INTERACTIVE SALE / INVOICE LINK & PILL ─────────────────────── */
.dp-sale-link {
    text-decoration: none !important;
    display: inline-block;
    cursor: pointer;
}
.dp-sale-link:hover,
.dp-sale-link:focus {
    text-decoration: none !important;
    outline: none !important;
}
.dp-invoice-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 9px;
    background: #f8fafc;
    color: #1e293b;
    border: 1px solid #e2e8f0;
    border-radius: 7px;
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
.dp-invoice-pill i.fa-file-invoice,
.dp-invoice-pill i.fa-receipt,
.dp-invoice-pill i.fa-shopping-cart,
.dp-invoice-pill i.fa-tools,
.dp-invoice-pill i.fa-hashtag,
.dp-invoice-pill i.fa-file-text-o,
.dp-invoice-pill i.fa-file {
    color: var(--theme-700, #2563eb);
    font-size: 11.5px;
    transition: transform 0.2s ease;
}
.dp-sale-arrow-icon {
    font-size: 9.5px;
    color: #94a3b8;
    margin-left: 3px;
    opacity: 0.7;
    transition: all 0.2s ease;
}
.dp-sale-link:hover .dp-invoice-pill {
    background: #eff6ff;
    border-color: #93c5fd;
    color: #1d4ed8;
    transform: translateY(-1.5px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}
.dp-sale-link:hover .dp-invoice-pill i:first-child {
    transform: scale(1.1);
}
.dp-sale-link:hover .dp-sale-arrow-icon {
    color: #2563eb;
    opacity: 1;
    transform: translate(1px, -1px);
}
.dp-sale-link:active .dp-invoice-pill {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(37, 99, 235, 0.12);
}

/* Dark mode support */
html[data-theme="dark"] .dp-invoice-pill {
    background: #1e293b !important;
    border-color: #334155 !important;
    color: #f1f5f9 !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3) !important;
}
html[data-theme="dark"] .dp-sale-link:hover .dp-invoice-pill {
    background: #172554 !important;
    border-color: #3b82f6 !important;
    color: #bfdbfe !important;
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.25) !important;
}
html[data-theme="dark"] .dp-sale-link:hover .dp-sale-arrow-icon {
    color: #60a5fa !important;
}

