@import url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css");

/* Ocultar elementos de PDF en pantalla y mostrarlos en impresión */
.mostrarPDF {
    display: none !important;
}

@media print {
    .ocultaPDF {
        display: none !important;
    }
    .mostrarPDF {
        display: block !important;
    }
}

/* ==========================================================================
   Reporte Krypto Global Styles (TreeView, RPC Hierarchy, Modales)
   ========================================================================== */

.contenedor-seniveles {
    border-radius: 5px;
    list-style-type: none;
    margin: 0;
}

.contenedor-seniveles.main {
    padding-left: 0px !important;
}

.contenedor-seniveles ul {
    list-style-type: none;
    margin: 0;
    padding-left: 30px;
}

.contenedor-seniveles li {
    text-decoration: none;
    margin: 4px 0;
}

.contenedor-seniveles a,
.contenedor-seniveles a:link,
.contenedor-seniveles a:visited,
.contenedor-seniveles a:hover,
.contenedor-seniveles a:active {
    color: inherit !important;
}

.nivel-1 {
    color: #107fc9;
}

.nivel-2 {
    color: #fac414;
}

.nivel-3 {
    color: #333333;
}

.nivel-4 {
    color: #333333;
}

.nivel-default {
    color: #6c757d;
}

.breadcrumb-hierachy {
    white-space: nowrap;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.siger-subtitle {
    font-size: 0.95rem !important;
    font-weight: 600;
}

.modalFixed {
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow-y: auto;
}

.modalFixed .modal-dialog {
    width: 100%;
    max-width: 800px;
    margin: auto;
}

.modalFixed .modal-content {
    background-color: #ffffff !important;
    border: none !important;
    border-radius: 12px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3) !important;
    overflow: hidden;
}

.modalFixed .modal-header {
    background-color: #002b49 !important;
    color: #ffffff !important;
    padding: 12px 20px !important;
    border-bottom: none;
}

.modalFixed .modal-body {
    background-color: #ffffff !important;
    color: #333333 !important;
    padding: 20px 24px !important;
    font-size: 13px;
    line-height: 1.6;
    word-break: break-word;
    white-space: pre-wrap;
}

.modalFixed .modal-footer {
    background-color: #f8fafc;
    border-top: 1px solid #e2e8f0;
    padding: 10px 20px !important;
}

/* ==========================================================================
   Acordeones Azules Uniformes
   ========================================================================== */
.apolo-accordion-btn {
    background-color: #107fc9;
    color: #ffffff !important;
    font-weight: 700;
    font-size: 13px;
    padding: 10px 16px;
    border-radius: 4px;
    border: none;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    margin-bottom: 8px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.apolo-accordion-btn:hover {
    background-color: #0d6ba8;
    color: #ffffff !important;
}

.apolo-accordion-btn.collapsed {
    background-color: #107fc9;
    opacity: 0.95;
}

.apolo-accordion-content {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    padding: 16px;
    margin-bottom: 16px;
}

/* Acordeones Azules de Registro Público (SIGER) al ras del Card */
.apolo-siger-accordion-btn {
    background-color: #107fc9;
    color: #ffffff !important;
    font-weight: 700;
    font-size: 13px;
    padding: 11px 18px;
    border: none;
    border-radius: 0;
    width: 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    text-align: left;
    margin: 0;
    cursor: pointer;
    transition: background-color 0.2s ease;
    box-shadow: none;
}

.apolo-siger-accordion-btn:hover {
    background-color: #0d6ba8;
    color: #ffffff !important;
}

.apolo-siger-accordion-btn.collapsed {
    background-color: #107fc9;
}

.apolo-siger-accordion-content {
    background: #ffffff;
    padding: 18px 24px;
    border-bottom: 1px solid #e2e8f0;
}

/* ==========================================================================
   Tablas Estándar Apolo (tableGeneral, tableGeneralDoble, etc.)
   ========================================================================== */
.tableEstadoResultados, .tableGeneralDoble, .tableGeneral, .tableCumplimientos, .tablaKey {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    color: #333333;
}

.tableGeneralDoble tr td, .tableGeneralDoble tr th {
    text-align: left;
    width: 50%;
    padding: 6px 10px;
    border-bottom: 1px solid #f2f2f2;
}

.tableGeneral tr td, .tableGeneral tr th {
    text-align: left;
    width: auto;
    padding: 6px 10px;
    border-bottom: 1px solid #f2f2f2;
}

.tableEstadoResultados tr.filaMarcada th,
.tableEstadoResultados tr.filaMarcada td,
.tableGeneralDoble tr.filaMarcada th,
.tableGeneral tr.filaMarcada th {
    background-color: #f2f2f2;
    font-weight: 700;
    font-style: normal !important;
}

.tableCumplimientos {
    border-top: solid 1px #f2f2f2;
    border-bottom: solid 1px #f2f2f2;
}

.tableCumplimientos td, .tableCumplimientos th {
    padding: 8px 10px;
}

.encabezadoPeriodos th {
    background-color: #f2f2f2;
    font-weight: 700;
    padding: 6px 10px;
    text-transform: uppercase;
}

/* ==========================================================================
   Círculos de Estatus
   ========================================================================== */
.circle-status, .circle-share {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    flex-shrink: 0;
}

.circle-status-found {
    background-color: #ddffe2;
    color: #28a745;
}

.circle-status-notfound {
    background-color: #fff3cd;
    color: #856404;
}

/* ==========================================================================
   Clases PDF (.ocultaPDF / .mostrarPDF)
   ========================================================================== */
.mostrarPDF {
    display: none;
}

@media print {
    .ocultaPDF {
        display: none !important;
    }
    .mostrarPDF {
        display: block !important;
    }
}

/* ==========================================================================
   Tarjetas de Documentos y Avisos Fallback
   ========================================================================== */
.apolo-doc-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.apolo-fallback-alert {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 16px;
}

.bg-apolo-b {
    background-color: #002b49 !important;
}

.text-apolo-b {
    color: #002b49 !important;
}

.br-apolo {
    border-radius: 4px !important;
}

/* ==========================================================================
   Alineación de Fuentes de Información y Badges (Iconos FontAwesome)
   ========================================================================== */
.apolo-krypto-reporte__source-card {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    min-height: 54px;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.apolo-krypto-reporte__source-label {
    font-size: 13px;
    color: #1e293b;
    font-weight: 500;
    flex: 1 1 auto;
    margin-right: 12px;
}

.apolo-krypto-reporte__source-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.apolo-krypto-reporte__badge {
    border-radius: 9999px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    width: 120px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-align: center;
}

.apolo-krypto-reporte__badge--valid {
    background-color: #dcfce7;
    color: #166534;
}

.apolo-krypto-reporte__badge--not-found {
    background-color: #fee2e2;
    color: #991b1b;
}

.apolo-krypto-reporte__source-icon-slot {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    text-decoration: none;
    font-size: 13px;
    flex-shrink: 0;
    transition: color 0.2s ease;
}

.apolo-krypto-reporte__source-icon-slot:hover {
    color: #107fc9;
}

.highlight {
    background-color: #fffca8 !important;
    color: #212529 !important;
    font-weight: bold !important;
    padding: 1px 3px;
    border-radius: 2px;
}




/* ==========================================================================
   ESTILOS REPORTE FINANCIERO Y RESUMEN ANUAL
   ========================================================================== */
.valoresNegativos {
    color: #ff3f3f !important;
}

.tableEstadoResultados {
    width: 100%;
    border-collapse: collapse;
}

.tableEstadoResultados th,
.tableEstadoResultados td {
    padding: 6px 10px;
    font-size: 0.85rem;
}

.tableEstadoResultados tr.filaMarcada {
    background-color: #f8fafc;
    font-weight: 700;
}

.tableEstadoResultados tr.filaMarcada td:first-child {
    font-weight: 700;
}

.tableEstadoResultados tr td:not(:first-child) {
    text-align: right;
}

.tableEstadoResultados tr td:last-child {
    font-weight: 700;
}

.encabezadoPeriodos > th {
    border-top: solid 1px #e2e8f0;
    border-bottom: solid 1px #e2e8f0;
    text-transform: uppercase;
    text-align: right;
    font-size: 0.8rem;
    color: #64748b;
    padding: 8px 10px;
}

.encabezadoPeriodos > th:first-child {
    text-align: left;
}

.containerGrafica {
    margin-top: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
}

.content-tabla-grafica {
    margin: 0 auto;
    font-size: 0.85rem;
    display: flex;
    flex-flow: row wrap;
    justify-content: center;
    gap: 12px;
    padding: 8px 0;
}

.grafica-legend {
    text-align: start;
    margin: 0;
    font-size: 0.8rem;
    color: #475569;
}

.grafica-legend::before {
    background-color: #333333;
    content: "";
    display: inline-block;
    height: 3px;
    position: relative;
    vertical-align: middle;
    width: 20px;
    margin-right: 6px;
}

.grafica-legend.ventas::before {
    background-color: #b51427;
}

.grafica-legend.gasto::before {
    background-color: #16c981;
}

.grafica-legend.utilidades::before,
.grafica-legend.perdidaneta::before {
    background-color: #107FC9;
}

.grafica-legend.activo::before {
    background-color: #61CBF4;
}

.grafica-legend.pasivo::before {
    background-color: #002855;
}

.grafica-legend.costo::before {
    background-color: #333333;
}

.grafica-legend.utilidadbruta::before {
    background-color: #002855;
}

.grafica-legend.cobranza::before {
    background-color: #F59E0B;
}

.grafica-legend.utilidadneta::before {
    background-color: #97C0E9;
}

.grafica-legend.capitalcontable::before {
    background-color: #C8BFB0;
}

/* Control de visibilidad Pantalla vs PDF */
.mostrarPDF {
    display: none !important;
}

@media print {
    .mostrarPDF {
        display: block !important;
    }
    .ocultaPDF {
        display: none !important;
    }
}

