/* Gestión Servicio Público - CSS consolidado
 * Duplicados y sobrescrituras redundantes eliminados.
 * Generado a partir de gestion(2).css.
 */

.ca-bandeja {
    width: 100%;
    background: #f4f6f9;
    padding: 15px;
    color: #111827;
    box-sizing: border-box;
    font-family: "Segoe UI", sans-serif;
}

.ca-header {
    margin-bottom: 18px;
}

.ca-header h1 {
    margin: 0;
    -webkit-text-stroke: 0.5px black;
    color: rgb(54, 169, 224);
    font-size: 28px;
    font-weight: 700;
}

.ca-header label {
    display: block;
    margin-top: 4px;
    color: #64748b;
    font-size: 14px;
}

.ca-kpi-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
    margin-bottom: 18px;
}

.ca-kpi-card {
    background: #fff;
    border: 1px solid #d8dee8;
    border-radius: 10px;
    min-height: 95px;
    padding: 14px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .04);
}

.ca-kpi-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 10px;
    width: 4px;
    height: 72px;
    border-radius: 10px;
}

.ca-border-blue::before {
    background: #1976d2;
}

.ca-border-red::before {
    background: #ef4444;
}

.ca-border-yellow::before {
    background: #f6c105;
}

.ca-border-green::before {
    background: #16a34a;
}

.ca-kpi-title {
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 6px;
    text-transform: uppercase;
}

.ca-kpi-value {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 6px;
}

.ca-kpi-link {
    font-size: 12px;
    color: #374151;
}

.ca-kpi-icon {
    width: 52px;
    height: 52px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 22px;
}

.ca-blue-bg {
    background: #1976d2;
}

.ca-red-bg {
    background: #ef4444;
}

.ca-yellow-bg {
    background: #f6c105;
}

.ca-green-bg {
    background: #16a34a;
}

.ca-blue-text {
    color: #1976d2;
}

.ca-red-text {
    color: #ef4444;
}

.ca-yellow-text {
    color: #c58b00;
}

.ca-green-text {
    color: #16a34a;
}

.ca-filters-card {
    background: #fff;
    border: 1px solid #d8dee8;
    border-radius: 8px;
    padding: 14px;
    margin-bottom: 18px;
}

.ca-filters-grid {
    display: grid;
    grid-template-columns: 2fr 1.2fr 1fr 1fr 1fr 1fr 1fr 1fr 1fr auto;
    gap: 10px;
    align-items: end;
}

.ca-field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #374151;
}

.ca-field input {
    width: 100%;
    height: 38px;
    border: 1px solid #cfd6df;
    border-radius: 4px;
    padding: 0 10px;
    background: #fff;
    outline: none;
    box-sizing: border-box;
}

.ca-search-buttons {
    display: flex;
    gap: 8px;
}

.ca-btn-search, .ca-btn-clear {
    height: 38px;
    padding: 0 18px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}

.ca-btn-search {
    background: #0d5db8;
    color: #fff;
    border: none;
}

.ca-btn-search:hover {
    background: #084d98;
}

.ca-btn-clear {
    background: #fff;
    border: 1px solid #cfd6df;
    color: #374151;
}

.ca-btn-clear:hover {
    background: #f3f4f6;
}

.ca-actions-bar {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.ca-action-btn {
    height: 40px;
    padding: 0 18px;
    border: none;
    border-radius: 4px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: .2s;
}

.ca-action-btn:hover {
    transform: translateY(-1px);
}

.ca-btn-export-excel {
    height: 40px;
    padding: 0 16px;
    border: none;
    border-radius: 4px;
    background: #f8f9fa;
    color: #009d57;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .12);
    transition: .2s ease;
}

.ca-btn-export-excel i {
    color: #009d57;
    font-size: 15px;
}

.ca-btn-export-excel:hover {
    background: #ffffff;
    color: #008849;
    box-shadow: 0 3px 8px rgba(0, 0, 0, .16);
    transform: translateY(-1px);
}

.ca-btn-export-excel:hover i {
    color: #008849;
}

.ca-btn-blue {
    background: #0d6efd;
}

.ca-btn-green {
    background: #198754;
}

.ca-btn-purple {
    background: #6f42c1;
}

.ca-btn-excel {
    background: #198754;
}

.ca-btn-cyan {
    background: #17a2b8;
}

.ca-table-wrapper {
    background: #fff;
    border: 1px solid #d8dee8;
    border-radius: 6px;
    margin-bottom: 14px;
    overflow: hidden;
}

.ca-table-scroll {
    width: 100%;
    overflow-x: auto;
}

.ca-criticality-card {
    border-radius: 6px;
    padding: 12px;
    text-align: center;
    border: 1px solid #d8dee8;
}

.ca-criticality-card span {
    display: block;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 6px;
}

.ca-criticality-card small {
    display: block;
    font-size: 11px;
    line-height: 1.4;
}

.ca-criticality-card.low {
    border-color: #3b82f6;
    background: #eff6ff;
    color: #1d4ed8;
}

.ca-criticality-card.medium {
    border-color: #facc15;
    background: #fefce8;
    color: #854d0e;
}

.ca-criticality-card.high {
    border-color: #fb923c;
    background: #fff7ed;
    color: #c2410c;
}

.ca-criticality-card.critical {
    border-color: #ef4444;
    background: #fef2f2;
    color: #b91c1c;
}

.ca-critical-box {
    min-height: 150px;
    overflow: visible;
    padding: 12px;
}

.ca-critical-box h4 {
    text-align: center;
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 700;
}

.ca-gauge {
    width: 150px;
    height: 75px;
    margin: 0 auto;
    border-radius: 150px 150px 0 0;
    position: relative;
    overflow: hidden;
}

.ca-gauge::after {
    content: "";
    position: absolute;
    width: 110px;
    height: 55px;
    background: #ffffff;
    border-radius: 110px 110px 0 0;
    left: 20px;
    top: 20px;
    z-index: 2;
}

.ca-gauge.low {
    background: linear-gradient(90deg, #bfdbfe, #60a5fa, #2563eb);
}

.ca-gauge.medium {
    background: linear-gradient(90deg, #fde68a, #facc15, #ca8a04);
}

.ca-gauge.high {
    background: linear-gradient(90deg, #fed7aa, #fb923c, #ea580c);
}

.ca-gauge.critical {
    background: linear-gradient(90deg, #fca5a5, #ef4444, #dc2626);
}

.ca-needle {
    position: absolute;
    width: 55px;
    height: 3px;
    background: #111827;
    left: 75px;
    top: 60px;
    transform-origin: left center;
    z-index: 10;
    transition: transform .25s ease;
}

.ca-gauge.low .ca-needle {
    transform: rotate(-155deg);
}

.ca-gauge.medium .ca-needle {
    transform: rotate(-105deg);
}

.ca-gauge.high .ca-needle {
    transform: rotate(-70deg);
}

.ca-gauge.critical .ca-needle {
    transform: rotate(-40deg);
}

.ca-critical-label {
    display: block;
    text-align: center;
    font-weight: 700;
    margin-top: 10px;
    text-transform: uppercase;
    font-size: 14px;
    line-height: 18px;
}

.ca-critical-label.low {
    color: #2563eb;
}

.ca-critical-label.medium {
    color: #ca8a04;
}

.ca-critical-label.high {
    color: #ea580c;
}

.ca-critical-label.critical {
    color: #dc2626;
}

.ca-quick-action:disabled {
    opacity: .55;
    cursor: not-allowed;
}

#datatableConsumosAtipicos {
    width: 100%;
    min-width: 1280px;
    border-collapse: collapse;
    font-size: 12px;
    color: #000;
}

#datatableConsumosAtipicos th {
    background: #f3f4f6;
    border: 1px solid #d8dee8;
    padding: 10px 8px;
    text-align: center;
    font-weight: 700;
}

#datatableConsumosAtipicos td {
    border: 1px solid #e5e7eb;
    padding: 9px 8px;
    text-align: center;
    vertical-align: middle;
}

.ca-dot {
    width: 11px;
    height: 11px;
    display: inline-block;
    border-radius: 50%;
    margin-right: 7px;
}

.ca-dot-red {
    background: #ef4444;
}

.ca-dot-orange {
    background: #f97316;
}

.ca-dot-yellow {
    background: #facc15;
}

.ca-dot-blue {
    background: #2563eb;
}

.ca-variation {
    color: #dc2626;
    font-weight: 700;
}

.ca-pill {
    display: inline-block;
    min-width: 70px;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
}

.ca-pill-critical {
    background: #ef4444;
    color: #fff;
}

.ca-pill-high {
    background: #fb923c;
    color: #fff;
}

.ca-pill-medium {
    background: #facc15;
    color: #111;
}

.ca-pill-low {
    background: #3b82f6;
    color: #fff;
}

.ca-pill-pending {
    background: #fde68a;
    color: #111;
}

.ca-pill-assigned {
    background: #bfdbfe;
    color: #111;
}

.ca-pill-review {
    background: #cbd5e1;
    color: #111;
}

.ca-eye-btn {
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 4px;
    background: #0d5db8;
    color: #fff;
    cursor: pointer;
}

.ca-eye-btn:hover {
    transform: translateY(-1px);
}

.ca-detail-section {
    display: grid;
    grid-template-columns: 1fr 250px;
    gap: 16px;
    margin-top: 15px;
}

.ca-detail-main, .ca-detail-sidebar-card {
    background: #fff;
    border: 1px solid #d8dee8;
    border-radius: 6px;
}

.ca-detail-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #d8dee8;
}

.ca-detail-head h3 {
    font-size: 15px;
    font-weight: 700;
    margin: 0;
}

.ca-detail-code {
    color: #dc2626;
    font-weight: 700;
}

.ca-detail-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 16px;
    padding: 14px;
}

.ca-subscriber-info {
    font-size: 12px;
}

.ca-subscriber-info div {
    margin-bottom: 10px;
    line-height: 1.4;
}

.ca-consumption-panel h4 {
    text-align: center;
    margin-bottom: 12px;
    font-size: 12px;
}

.ca-bars-chart {
    height: 180px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-bottom: 1px solid #d8dee8;
    padding-bottom: 10px;
}

.ca-bar-col {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ca-bar-col span {
    font-size: 11px;
    font-weight: 700;
    margin-bottom: 5px;
}

.ca-bar {
    width: 24px;
    border-radius: 3px 3px 0 0;
}

.ca-bar-blue {
    background: #1976d2;
}

.ca-bar-red {
    background: #ef4444;
}

.ca-bar-col small {
    margin-top: 6px;
    font-size: 11px;
}

.ca-resume-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 12px;
}

.ca-resume-grid div {
    border: 1px solid #d8dee8;
    text-align: center;
    padding: 10px;
}

.ca-resume-grid small {
    display: block;
    color: #64748b;
    margin-bottom: 6px;
    font-size: 11px;
}

.ca-resume-grid strong {
    font-size: 20px;
    color: #1565c0;
}

.ca-danger-text {
    color: #dc2626 !important;
}

.ca-result-box {
    margin-top: 12px;
    border: 1px solid #22c55e;
    background: #ecfdf5;
    color: #15803d;
    text-align: center;
    padding: 10px;
    border-radius: 4px;
}

.ca-result-box strong {
    display: block;
    margin-top: 4px;
}

.result-box {
    margin-top: 12px;
    text-align: center;
    padding: 10px;
    border-radius: 4px;
    font-weight: 600;
}

.result-box strong {
    display: block;
    margin-top: 4px;
}

.result-box.low {
    border: 1px solid #3b82f6;
    background: #eff6ff;
    color: #1d4ed8;
}

.result-box.medium {
    border: 1px solid #facc15;
    background: #fefce8;
    color: #854d0e;
}

.result-box.high {
    border: 1px solid #fb923c;
    background: #fff7ed;
    color: #c2410c;
}

.result-box.critical {
    border: 1px solid #ef4444;
    background: #fef2f2;
    color: #b91c1c;
}

.ca-detail-sidebar {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ca-detail-sidebar-card {
    padding: 12px;
}

.ca-detail-sidebar-card h4 {
    text-align: center;
    margin-bottom: 10px;
    font-size: 13px;
}

.ca-quick-action {
    width: 100%;
    height: 34px;
    border: none;
    border-radius: 4px;
    color: white;
    margin-bottom: 8px;
    cursor: pointer;
    font-size: 12px;
}

.ca-quick-blue {
    background: #1565c0;
}

.ca-quick-yellow {
    background: #f4b400;
}

.ca-quick-cyan {
    background: #14b8a6;
}

.ca-quick-purple {
    background: #7c3aed;
}

.dot {
    width: 11px;
    height: 11px;
    display: inline-block;
    border-radius: 50%;
    margin-right: 7px;
}

.dot.red {
    background: #ef4444;
}

.dot.orange {
    background: #f97316;
}

.dot.yellow {
    background: #facc15;
}

.dot.blue {
    background: #2563eb;
}

.variation {
    font-weight: 700;
}

.variation.low {
    color: #2563eb;
}

.variation.medium {
    color: #ca8a04;
}

.variation.high {
    color: #ea580c;
}

.variation.critical {
    color: #dc2626;
}

.pill {
    display: inline-block;
    min-width: 70px;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 700;
}

.pill.critical {
    background: #ef4444;
    color: white;
}

.pill.high {
    background: #fb923c;
    color: white;
}

.pill.medium {
    background: #facc15;
    color: #111;
}

.pill.low {
    background: #3b82f6;
    color: white;
}

.pill.pending {
    background: #fde68a;
    color: #111;
}

.pill.assigned {
    background: #bfdbfe;
    color: #111;
}

.pill.review {
    background: #cbd5e1;
    color: #111;
}

.bars-chart {
    height: 180px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-bottom: 1px solid #d8dee8;
    padding-bottom: 10px;
}

.bar-col {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.bar-col span {
    font-size: 11px;
    font-weight: 700;
    margin-bottom: 5px;
}

.bar {
    width: 24px;
    border-radius: 3px 3px 0 0;
}

.bar.blue {
    background: #1976d2;
}

.bar.red {
    background: #ef4444;
}

.bar-col small {
    margin-top: 6px;
    font-size: 11px;
}

#detalleResultadoBox {
    display: block !important;
    min-height: 42px !important;
    padding: 10px !important;
    text-align: center !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    overflow: visible !important;
    visibility: visible !important;
    opacity: 1 !important;
}

#detalleResultadoBox strong {
    display: block !important;
    margin-top: 4px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    visibility: visible !important;
    opacity: 1 !important;
}

#detalleResultadoBox.low {
    border: 1px solid #3b82f6 !important;
    background: #eff6ff !important;
    color: #1d4ed8 !important;
}

#detalleResultadoBox.medium {
    border: 1px solid #facc15 !important;
    background: #fefce8 !important;
    color: #854d0e !important;
}

#detalleResultadoBox.high {
    border: 1px solid #fb923c !important;
    background: #fff7ed !important;
    color: #c2410c !important;
}

#detalleResultadoBox.critical {
    border: 1px solid #ef4444 !important;
    background: #fef2f2 !important;
    color: #dc2626 !important;
}

.select2-container--default .select2-selection--single {
    height: 38px !important;
    border: 1px solid #cfd6df !important;
    border-radius: 4px !important;
    background-color: #fff !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #1f2937 !important;
    line-height: 38px !important;
    padding-left: 10px !important;
    padding-right: 28px !important;
    font-size: 13px !important;
    font-weight: 400 !important;
}

.select2-container--default .select2-selection--single .select2-selection__placeholder {
    color: #64748b !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 38px !important;
    right: 6px !important;
}

.select2-container--default.select2-container--focus .select2-selection--single {
    border-color: #1976d2 !important;
    box-shadow: 0 0 0 3px rgba(25, 118, 210, .12) !important;
}

.ca-map-btn {
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 4px;
    background: #198754;
    color: #fff;
    cursor: pointer;
    margin-left: 4px;
}

.ca-map-btn:hover {
    transform: translateY(-1px);
}

.ca-detail-map-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.ca-map-detail-btn, .ca-map-detail-close-btn {
    height: 34px;
    padding: 0 12px;
    border: none;
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
}

.ca-map-detail-btn {
    background: #17a2b8;
}

.ca-map-detail-close-btn {
    background: #dc2626;
}

.ca-map-detail-btn:hover, .ca-map-detail-close-btn:hover {
    transform: translateY(-1px);
}

@media (max-width: 1200px) {
    .ca-kpi-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .ca-filters-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .ca-detail-section {
        grid-template-columns: 1fr;
    }

    .ca-detail-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .ca-kpi-grid, .ca-filters-grid, .ca-resume-grid {
        grid-template-columns: 1fr;
    }

    .ca-search-buttons {
        flex-direction: column;
    }
}

.ca-filters-grid-asignar-operario {
    grid-template-columns: 1.25fr 1.6fr 1.45fr 1.1fr 1.1fr 1fr 1fr auto;
}

.ca-button-bottom-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    margin-bottom: 4px;
}

.ca-action-primary {
    min-height: 40px;
    padding: 0 18px;
    border: none;
    border-radius: 4px;
    background: #0d6efd;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: .2s ease;
}

.ca-action-primary:hover {
    background: #0b5ed7;
    transform: translateY(-1px);
}

#datatableAsignarOperario {
    width: 100%;
    min-width: 1280px;
    border-collapse: collapse;
    font-size: 12px;
    color: #000;
}

#datatableAsignarOperario th {
    background: #f3f4f6;
    border: 1px solid #d8dee8;
    padding: 10px 8px;
    text-align: center;
    font-weight: 700;
}

#datatableAsignarOperario td {
    border: 1px solid #e5e7eb;
    padding: 9px 8px;
    text-align: center;
    vertical-align: middle;
}

.ca-row-action-btn {
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 4px;
    background: #0d5db8;
    color: #fff;
    cursor: pointer;
    margin: 0 2px;
}

.ca-row-action-btn:hover {
    transform: translateY(-1px);
}

.ca-pill-draft {
    background: #e5e7eb;
    color: #111827;
}

.ca-pill-rescheduled {
    background: #ddd6fe;
    color: #4c1d95;
}

.ca-pill-cancelled {
    background: #fee2e2;
    color: #991b1b;
}

.ca-pill-closed {
    background: #dcfce7;
    color: #166534;
}

.ca-form-card {
    background: #fff;
    border: 1px solid #d8dee8;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 18px;
    box-sizing: border-box;
}

.ca-form-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 14px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #e5e7eb;
    color: #111827;
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
}

.ca-form-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    align-items: end;
}

.ca-form-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.ca-form-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.ca-form-grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

.ca-form-grid-5 {
    grid-template-columns: repeat(5, 1fr);
}

.ca-form-field {
    width: 100%;
    box-sizing: border-box;
}

.ca-form-field.ca-col-2 {
    grid-column: span 2;
}

.ca-form-field.ca-col-3 {
    grid-column: span 3;
}

.ca-form-field.ca-col-4 {
    grid-column: span 4;
}

.ca-form-field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #374151;
}

.ca-form-field label span.required, .ca-form-field label .required {
    color: #dc2626;
    font-weight: 700;
}

.ca-form-field input, .ca-form-field select, .ca-form-field textarea {
    width: 100%;
    min-height: 38px;
    border: 1px solid #cfd6df;
    border-radius: 4px;
    padding: 0 10px;
    background: #fff;
    color: #111827;
    outline: none;
    box-sizing: border-box;
    font-size: 13px;
}

.ca-form-field textarea {
    min-height: 92px;
    padding: 10px;
    resize: vertical;
    line-height: 1.45;
}

.ca-form-field input:focus, .ca-form-field select:focus, .ca-form-field textarea:focus {
    border-color: #1976d2;
    box-shadow: 0 0 0 3px rgba(25, 118, 210, .12);
}

.ca-form-field input[readonly], .ca-form-field textarea[readonly], .ca-form-field select[readonly], .ca-form-field input:disabled, .ca-form-field textarea:disabled, .ca-form-field select:disabled {
    background: #f3f4f6;
    color: #6b7280;
    cursor: not-allowed;
}

.ca-form-field .select2-container {
    width: 100% !important;
    display: block !important;
}

.ca-form-help {
    display: block;
    margin-top: 4px;
    color: #64748b;
    font-size: 11px;
    line-height: 1.35;
}

.ca-form-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding-top: 12px;
    border-top: 1px solid #e5e7eb;
}

.ca-btn-primary, .ca-btn-secondary, .ca-btn-danger {
    min-height: 38px;
    padding: 0 18px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.ca-btn-primary {
    background: #0d5db8;
    color: #fff;
}

.ca-btn-primary:hover {
    background: #084d98;
}

.ca-btn-secondary {
    background: #fff;
    border: 1px solid #cfd6df;
    color: #374151;
}

.ca-btn-secondary:hover {
    background: #f3f4f6;
}

.ca-btn-danger {
    background: #dc2626;
    color: #fff;
}

.ca-btn-danger:hover {
    background: #b91c1c;
}

.ca-checkbox-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.ca-checkbox-item {
    min-height: 38px;
    border: 1px solid #cfd6df;
    border-radius: 4px;
    padding: 8px 10px;
    background: #fff;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    box-sizing: border-box;
    cursor: pointer;
}

.ca-checkbox-item:hover {
    background: #f8fafc;
    border-color: #1976d2;
}

.ca-checkbox-item input[type="checkbox"] {
    width: auto;
    min-height: auto;
    margin-top: 2px;
}

.ca-checkbox-item span {
    color: #111827;
    font-size: 12px;
    line-height: 1.35;
}

.ca-inner-table-wrapper {
    width: 100%;
    overflow-x: auto;
    margin-top: 10px;
}

.ca-inner-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    color: #000;
}

.ca-inner-table th {
    background: #f3f4f6;
    border: 1px solid #d8dee8;
    padding: 9px 8px;
    text-align: center;
    font-weight: 700;
}

.ca-inner-table td {
    border: 1px solid #e5e7eb;
    padding: 8px;
    vertical-align: middle;
}

@media (max-width: 1200px) {
    .ca-filters-grid-asignar-operario {
        grid-template-columns: repeat(3, 1fr);
    }

    .ca-form-grid, .ca-form-grid-4, .ca-form-grid-5 {
        grid-template-columns: repeat(2, 1fr);
    }

    .ca-form-field.ca-col-3, .ca-form-field.ca-col-4 {
        grid-column: span 2;
    }

    .ca-checkbox-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .ca-filters-grid-asignar-operario, .ca-form-grid, .ca-form-grid-2, .ca-form-grid-3, .ca-form-grid-4, .ca-form-grid-5 {
        grid-template-columns: 1fr;
    }

    .ca-form-field.ca-col-2, .ca-form-field.ca-col-3, .ca-form-field.ca-col-4 {
        grid-column: span 1;
    }

    .ca-form-actions, .ca-button-bottom-right {
        justify-content: stretch;
        flex-direction: column;
    }

    .ca-btn-primary, .ca-btn-secondary, .ca-btn-danger, .ca-action-primary {
        width: 100%;
        justify-content: center;
    }
}

.asg-header-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #ffffff;
}

.asg-row-cards {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1fr 1fr 1fr 1fr;
    gap: 14px;
    margin-bottom: 20px;
}

.asg-card-main {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 18px 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.asg-card-main-label {
    font-size: 11px;
    color: #9ca3af;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.asg-card-main-title {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    margin-top: 4px;
}

.asg-card-main-desc {
    font-size: 14px;
    color: #6b7280;
    margin-top: 2px;
}

.asg-tags {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.asg-tag {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.asg-tag-danger {
    background: #fee2e2;
    color: #dc2626;
}

.asg-tag-warning {
    background: #fef3c7;
    color: #d97706;
}

.asg-tag-primary {
    background: #dbeafe;
    color: #2563eb;
}

.asg-card-metric {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 14px 12px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.asg-card-metric i {
    font-size: 18px;
    color: #9ca3af;
    margin-bottom: 4px;
}

.asg-card-metric-label {
    font-size: 10px;
    color: #9ca3af;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.asg-card-metric-value {
    font-size: 17px;
    font-weight: 700;
    color: #111827;
}

.asg-card-metric-sub {
    font-size: 10px;
    color: #9ca3af;
}

.asg-text-danger {
    color: #dc2626 !important;
}

.asg-text-warning {
    color: #d97706 !important;
}

.asg-row-content {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 18px;
}

.asg-col-left {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.asg-col-right {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.asg-section-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.asg-section-header {
    padding: 14px 18px;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
    font-weight: 600;
    color: #111827;
}

.asg-section-header i {
    margin-right: 8px;
    color: #2563eb;
}

.asg-section-body {
    padding: 16px 18px;
}

.asg-section-subtitle {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 14px;
}

.asg-info-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px 16px;
}

.asg-info-grid label {
    display: block;
    font-size: 10px;
    color: #9ca3af;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.asg-info-grid span {
    font-size: 14px;
    font-weight: 600;
    color: #111827;
    display: block;
    margin-top: 2px;
}

.asg-form-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
}

.asg-field {
    display: flex;
    flex-direction: column;
}

.asg-field label {
    font-size: 10px;
    color: #9ca3af;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 4px;
}

.asg-field select, .asg-field input {
    width: 100%;
    height: 36px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 0 12px;
    font-size: 13px;
    background: #ffffff;
    transition: border-color 0.2s;
}

.asg-field select:focus, .asg-field input:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

.asg-field input[readonly] {
    background: #f9fafb;
    color: #6b7280;
}

.asg-finding-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.asg-btn-finding {
    border: 1px solid #e5e7eb;
    background: #ffffff;
    border-radius: 8px;
    padding: 12px 14px;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s;
}

.asg-btn-finding:hover {
    border-color: #93c5fd;
    background: #f8fafc;
}

.asg-btn-finding.active {
    border-color: #2563eb;
    background: #eff6ff;
}

.asg-btn-finding strong {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #111827;
}

.asg-btn-finding strong i {
    margin-right: 6px;
}

.asg-btn-finding.active strong {
    color: #2563eb;
}

.asg-btn-finding span {
    font-size: 11px;
    color: #9ca3af;
    display: block;
    margin-top: 3px;
}

.asg-btn-finding.active span {
    color: #6b7280;
}

.asg-textarea-obs {
    display: block;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    height: 72px;
    min-height: 72px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 10px 14px;
    box-sizing: border-box;
    resize: vertical;
    overflow-x: hidden;
    overflow-y: auto;
    font-size: 13px;
    line-height: 1.4;
    font-family: inherit;
    background: #fafafa;
}

.asg-textarea-obs:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

.asg-map-container {
    margin-top: 14px;
}

.asg-btn-map {
    background: #f3f4f6;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    color: #4b5563;
    font-weight: 600;
    font-size: 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background 0.2s;
}

.asg-btn-map:hover {
    background: #e5e7eb;
}

.asg-bottom-actions {
    display: flex;
    gap: 12px;
}

.asg-sidebar-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 18px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.asg-sidebar-card span {
    display: block;
    color: #9ca3af;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 4px;
}

.asg-sidebar-card strong {
    display: block;
    color: #111827;
    font-size: 14px;
    font-weight: 600;
}

.asg-sidebar-card h3 {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: #111827;
}

.asg-sidebar-card p {
    color: #6b7280;
    font-size: 13px;
    margin: 0;
    line-height: 1.5;
}

.asg-sidebar-critical {
    background: #fef2f2;
    border: 1px solid #fecaca;
}

.asg-sidebar-critical span {
    color: #dc2626;
}

.asg-sidebar-critical h3 {
    color: #dc2626;
}

.asg-sidebar-critical p {
    color: #dc2626;
}

.asg-sidebar-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    margin-bottom: 12px;
}

.asg-sidebar-icon.blue {
    background: #dbeafe;
    color: #2563eb;
}

.asg-sidebar-icon.red {
    background: #fee2e2;
    color: #dc2626;
}

.asg-sidebar-icon.green {
    background: #dcfce7;
    color: #16a34a;
}

.asg-sidebar-icon.purple {
    background: #ede9fe;
    color: #7c3aed;
}

.asg-btn-map-mini {
    width: 100%;
    height: 36px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-top: 12px;
    cursor: pointer;
    background: #ffffff;
    color: #4b5563;
    font-size: 12px;
    font-weight: 600;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.asg-btn-map-mini:hover {
    background: #f9fafb;
}

.asg-history {
    margin-top: 8px;
}

.asg-history-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid #f3f4f6;
}

.asg-history-row:last-child {
    border-bottom: none;
}

.asg-history-row span {
    font-size: 12px;
    color: #9ca3af;
    margin: 0;
}

.asg-history-row strong {
    font-size: 12px;
    color: #4b5563;
    margin: 0;
    font-weight: 500;
}

.asg-btn-history {
    width: 100%;
    height: 36px;
    border: none;
    background: transparent;
    color: #2563eb;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 12px;
    margin-top: 10px;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.asg-btn-history:hover {
    background: #f3f4f6;
}

@media (max-width: 1400px) {
    .asg-row-cards {
        grid-template-columns: 1fr 1fr 1fr;
    }

    .asg-card-main {
        grid-column: span 3;
    }

    .asg-row-content {
        grid-template-columns: 1fr;
    }

    .asg-col-right {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 14px;
    }
}

@media (max-width: 1100px) {
    .asg-info-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .asg-form-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .asg-finding-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .asg-col-right {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .asg-row-cards {
        grid-template-columns: 1fr;
    }

    .asg-card-main {
        grid-column: span 1;
    }

    .asg-col-right {
        grid-template-columns: 1fr;
    }

    .asg-info-grid {
        grid-template-columns: 1fr;
    }

    .asg-form-grid {
        grid-template-columns: 1fr;
    }

    .asg-finding-grid {
        grid-template-columns: 1fr;
    }

    .asg-bottom-actions {
        flex-direction: column;
    }

    .asg-btn-map {
        width: 100%;
        justify-content: center;
    }
}

.ao-asg-page {
    width: 100%;
    background: #f4f6f9;
    color: #111827;
    box-sizing: border-box;
    font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, sans-serif;
    padding: 0;
    margin: 0;
}

.asg-page-header {
    background: linear-gradient(135deg, #07192f, #0d5db8);
    color: #ffffff;
    padding: 18px 22px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 8px 8px 0 0;
    box-sizing: border-box;
}

.asg-page-header-left, .asg-page-header-right {
    display: flex;
    align-items: center;
    gap: 14px;
}

.asg-page-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
}

.asg-page-header span {
    color: #dbeafe;
    font-size: 14px;
}

.asg-page-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 90px;
    height: 34px;
    padding: 0 14px;
    border-radius: 8px;
    font-size: 12px !important;
    font-weight: 800;
    color: #ffffff !important;
    text-transform: uppercase;
}

.asg-page-status-danger {
    background: #ef4444;
}

.asg-page-status-warning {
    background: #f59e0b;
}

.asg-page-status-info {
    background: #2563eb;
}

.asg-page-back {
    width: 40px;
    height: 40px;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 34px;
}

.asg-page-back:hover {
    color: #dbeafe;
}

.asg-page-body {
    padding: 18px;
    background: #f4f6f9;
}

.asg-page-footer {
    background: #ffffff;
    border-top: 1px solid #e2e8f0;
    padding: 14px 18px;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    border-radius: 0 0 8px 8px;
}

.asg-page-footer .btn-light, .asg-page-footer .btn-primary {
    height: 42px;
    padding: 0 18px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 700;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.asg-page-footer .btn-light {
    background: #ffffff;
    border: 1px solid #d1d5db;
    color: #111827;
}

.asg-page-footer .btn-light:hover {
    background: #f3f4f6;
}

.asg-page-footer .btn-primary {
    background: #0d5db8;
    color: #ffffff;
}

.asg-page-footer .btn-primary:hover {
    background: #084d98;
}

.asg-field-span-2 {
    grid-column: span 2;
}

.asg-field .select2-container {
    width: 100% !important;
}

.asg-field .select2-container--default .select2-selection--single {
    height: 36px !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 8px !important;
}

.asg-field .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 36px !important;
    font-size: 13px !important;
    color: #111827 !important;
}

.asg-field .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 36px !important;
}

.asg-btn-finding input[type="checkbox"] {
    display: none;
}

.asg-text-counter {
    text-align: right;
    margin-top: 5px;
    font-size: 11px;
    color: #6b7280;
}

@media (max-width: 768px) {
    .asg-page-header, .asg-page-header-left, .asg-page-header-right, .asg-page-footer {
        flex-direction: column;
        align-items: stretch;
    }

    .asg-page-header-right {
        align-items: flex-end;
    }

    .asg-field-span-2 {
        grid-column: span 1;
    }

    .asg-page-footer .btn-light, .asg-page-footer .btn-primary {
        width: 100%;
    }
}

.ao-asg-page .asg-service-program-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: 16px !important;
    align-items: stretch !important;
    margin-bottom: 18px !important;
}

.ao-asg-page .asg-service-card, .ao-asg-page .asg-program-card, .ao-asg-page .asg-objectives-card, .ao-asg-page .asg-observations-card {
    width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

.ao-asg-page .asg-info-split {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: 0 22px !important;
}

.ao-asg-page .asg-info-col + .asg-info-col {
    border-left: 1px solid #e5e7eb !important;
    padding-left: 22px !important;
}

.ao-asg-page .asg-info-item {
    display: grid !important;
    grid-template-columns: 24px minmax(0, 1fr) !important;
    gap: 10px !important;
    align-items: center !important;
    padding: 9px 0 !important;
    border-bottom: 1px solid #eef2f7 !important;
}

.ao-asg-page .asg-info-item > i {
    color: #2563eb !important;
    font-size: 16px !important;
    text-align: center !important;
}

.ao-asg-page .asg-info-item label {
    display: block !important;
    margin: 0 0 2px 0 !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    color: #64748b !important;
}

.ao-asg-page .asg-info-item strong {
    display: block !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    line-height: 1.25 !important;
    word-break: break-word !important;
}

.ao-asg-page .asg-btn-map {
    width: 100% !important;
    margin-top: 12px !important;
    height: 34px !important;
    border: 1px solid #bfdbfe !important;
    background: #ffffff !important;
    color: #2563eb !important;
    border-radius: 6px !important;
    font-weight: 700 !important;
    font-size: 12px !important;
    cursor: pointer !important;
}

.ao-asg-page .asg-program-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px 18px !important;
}

.ao-asg-page .asg-program-grid .asg-field {
    min-width: 0 !important;
    width: 100% !important;
}

.ao-asg-page .asg-program-grid input, .ao-asg-page .asg-program-grid select {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: 38px !important;
    box-sizing: border-box !important;
}

.ao-asg-page .asg-program-grid input[readonly] {
    background: #f8fafc !important;
    color: #0f172a !important;
    font-weight: 600 !important;
}

.ao-asg-page .asg-btn-finding {
    position: relative !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 10px !important;
    background: #ffffff !important;
    text-align: left !important;
    cursor: pointer !important;
}

.ao-asg-page .asg-btn-finding.active {
    border-color: #2563eb !important;
    background: #eff6ff !important;
}

.ao-asg-page .asg-finding-icon {
    border-radius: 999px !important;
    background: #eff6ff !important;
    color: #2563eb !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 14px !important;
}

.ao-asg-page .asg-btn-finding.active .asg-finding-icon {
    background: #2563eb !important;
    color: #ffffff !important;
}

.ao-asg-page .asg-finding-content strong {
    display: block !important;
    color: #0f172a !important;
    font-weight: 700 !important;
    word-break: normal !important;
    overflow-wrap: anywhere !important;
}

.ao-asg-page .asg-finding-content small {
    display: block !important;
    color: #64748b !important;
    overflow-wrap: anywhere !important;
}

.ao-asg-page .asg-check-circle {
    border-radius: 999px !important;
    border: 2px solid #cbd5e1 !important;
    background: #ffffff !important;
    color: #ffffff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 10px !important;
    flex-shrink: 0 !important;
}

.ao-asg-page .asg-btn-finding.active .asg-check-circle {
    border-color: #2563eb !important;
    background: #2563eb !important;
    color: #ffffff !important;
}

.ao-asg-page .asg-btn-finding input[type="checkbox"] {
    display: none !important;
}

@media (max-width: 1300px) {
    .ao-asg-page .asg-finding-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 1100px) {
    .ao-asg-page .asg-service-program-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    .ao-asg-page .asg-info-split, .ao-asg-page .asg-program-grid, .ao-asg-page .asg-finding-grid {
        grid-template-columns: 1fr !important;
    }

    .ao-asg-page .asg-info-col + .asg-info-col {
        border-left: none !important;
        padding-left: 0 !important;
    }
}

.ao-asg-page .asg-main-sidebar-layout {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 280px !important;
    gap: 18px !important;
    align-items: start !important;
}

.ao-asg-page .asg-main-content {
    min-width: 0 !important;
}

.ao-asg-page .asg-alert-sidebar {
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
    min-width: 0 !important;
}

.ao-asg-page .asg-alert-card {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 10px !important;
    padding: 20px 18px !important;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08) !important;
    min-height: 130px !important;
    box-sizing: border-box !important;
}

.ao-asg-page .asg-alert-card-critical {
    background: #fff5f5 !important;
    border-color: #fecaca !important;
}

.ao-asg-page .asg-alert-icon {
    width: 28px !important;
    height: 28px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin-bottom: 10px !important;
    color: #0f172a !important;
    font-size: 18px !important;
}

.ao-asg-page .asg-alert-label {
    display: block !important;
    margin-bottom: 6px !important;
    color: #94a3b8 !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    letter-spacing: .02em !important;
    text-transform: uppercase !important;
}

.ao-asg-page .asg-alert-card strong {
    display: block !important;
    color: #0f172a !important;
    font-size: 22px !important;
    font-weight: 800 !important;
    line-height: 1.15 !important;
}

.ao-asg-page .asg-alert-card p {
    margin: 8px 0 0 !important;
    color: #64748b !important;
    font-size: 13px !important;
    line-height: 1.35 !important;
}

.ao-asg-page .asg-alert-card-critical strong, .ao-asg-page .asg-alert-card-critical p, .ao-asg-page .asg-alert-card-critical .asg-alert-label {
    color: #dc2626 !important;
}

.ao-asg-page .asg-history-list {
    margin-top: 12px !important;
}

.ao-asg-page .asg-history-row {
    display: grid !important;
    grid-template-columns: 82px minmax(0, 1fr) !important;
    gap: 8px !important;
    padding: 8px 0 !important;
    border-bottom: 1px solid #eef2f7 !important;
    align-items: center !important;
}

.ao-asg-page .asg-history-row:last-child {
    border-bottom: none !important;
}

.ao-asg-page .asg-history-row span {
    color: #94a3b8 !important;
    font-size: 12px !important;
}

.ao-asg-page .asg-history-row strong {
    color: #0f172a !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    text-align: right !important;
    line-height: 1.25 !important;
}

.ao-asg-page .asg-link-history {
    width: 100% !important;
    margin-top: 12px !important;
    border: none !important;
    background: transparent !important;
    color: #2563eb !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    text-align: center !important;
}

.ao-asg-page .asg-link-history i {
    margin-left: 4px !important;
}

@media (max-width: 1200px) {
    .ao-asg-page .asg-main-sidebar-layout {
        grid-template-columns: 1fr !important;
    }

    .ao-asg-page .asg-alert-sidebar {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    }
}

@media (max-width: 768px) {
    .ao-asg-page .asg-alert-sidebar {
        grid-template-columns: 1fr !important;
    }
}

.ao-asg-page .asg-alert-card-address {
    padding: 18px 20px !important;
    text-align: left !important;
}

.ao-asg-page .asg-address-head {
    display: grid !important;
    grid-template-columns: 32px minmax(0, 1fr) !important;
    gap: 12px !important;
    align-items: center !important;
    margin-bottom: 12px !important;
}

.ao-asg-page .asg-address-icon {
    width: 30px !important;
    height: 30px !important;
    color: #1d4ed8 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 22px !important;
}

.ao-asg-page .asg-address-head span {
    color: #34416a !important;
    font-size: 13px !important;
    font-weight: 800 !important;
}

.ao-asg-page .asg-alert-card-address strong {
    display: block !important;
    color: #0f172a !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    margin: 0 0 4px 44px !important;
    line-height: 1.3 !important;
}

.ao-asg-page .asg-alert-card-address p {
    color: #0f172a !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    margin: 2px 0 0 44px !important;
    line-height: 1.25 !important;
}

.ao-asg-page .asg-btn-side-map {
    height: 36px !important;
    min-width: 150px !important;
    margin: 14px auto 0 auto !important;
    padding: 0 18px !important;
    border: 1px solid #bfdbfe !important;
    border-radius: 6px !important;
    background: #ffffff !important;
    color: #0d5db8 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
}

.ao-asg-page .asg-btn-side-map:hover {
    background: #eff6ff !important;
    border-color: #60a5fa !important;
}

.ca-map-window {
    position: fixed;
    top: 110px;
    left: 280px;
    width: 900px;
    height: 550px;
    min-width: 520px;
    min-height: 360px;
    background: #ffffff;
    border: 1px solid #d8dee8;
    border-radius: 10px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .25);
    z-index: 9999;
    display: none;
    overflow: hidden;
    resize: both;
}

.ca-map-window.show {
    display: block;
}

.ca-map-header {
    height: 52px;
    background: linear-gradient(135deg, #07192f, #0d5db8);
    color: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 16px;
    cursor: move;
    user-select: none;
}

.ca-map-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
}

.ca-map-close {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    background: rgba(255, 255, 255, .18);
    color: #ffffff;
}

.ca-map-close:hover {
    background: rgba(255, 255, 255, .30);
}

.ca-map-body {
    height: calc(100% - 52px);
    padding: 16px;
    background: #f4f6f9;
    box-sizing: border-box;
}

.ca-map-layout {
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 14px;
}

.ca-map-sidebar {
    background: #ffffff;
    border: 1px solid #d8dee8;
    border-radius: 8px;
    overflow-y: auto;
}

.ca-map-card-header {
    background: linear-gradient(135deg, #07192f, #0d5db8);
    color: #ffffff;
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ca-map-card-header h3 {
    margin: 0;
    font-size: 14px;
}

.ca-map-card-header span {
    font-size: 11px;
    opacity: .9;
}

.ca-map-data {
    padding: 12px;
}

.ca-map-item {
    border-bottom: 1px solid #e5e7eb;
    padding: 9px 0;
}

.ca-map-item label {
    display: block;
    font-size: 11px;
    color: #64748b;
    font-weight: 700;
    margin-bottom: 3px;
}

.ca-map-item span {
    font-size: 12px;
    color: #111827;
    font-weight: 600;
    word-break: break-word;
}

#osmMap {
    width: 100%;
    height: 100%;
    min-height: 300px;
    background: #ffffff;
    border-radius: 8px;
    border: 1px solid #d8dee8;
}

@media (max-width: 768px) {
    .ca-map-window {
        left: 10px !important;
        top: 70px !important;
        width: calc(100% - 20px) !important;
        height: 520px !important;
        min-width: 0 !important;
    }

    .ca-map-layout {
        grid-template-columns: 1fr !important;
    }
}

.ao-pill {
    display: inline-block !important;
    min-width: 70px !important;
    padding: 5px 8px !important;
    border-radius: 4px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    text-align: center !important;
}

.ao-pill-critical {
    background: #ef4444 !important;
    color: #ffffff !important;
}

.ao-pill-high {
    background: #fb923c !important;
    color: #ffffff !important;
}

.ao-pill-medium {
    background: #facc15 !important;
    color: #111827 !important;
}

.ao-pill-low {
    background: #3b82f6 !important;
    color: #ffffff !important;
}

.ao-pill-draft {
    background: #dbeafe !important;
    color: #1d4ed8 !important;
}

.ao-pill-assigned {
    background: #bfdbfe !important;
    color: #111827 !important;
}

.ao-pill-review {
    background: #cbd5e1 !important;
    color: #111827 !important;
}

.ao-pill-cancelled {
    background: #fee2e2 !important;
    color: #991b1b !important;
}

.ao-pill-closed {
    background: #dcfce7 !important;
    color: #166534 !important;
}

.ao-eye-btn {
    width: 30px !important;
    height: 30px !important;
    border: none !important;
    border-radius: 4px !important;
    background: #0d5db8 !important;
    color: #ffffff !important;
    cursor: pointer !important;
}

.ao-eye-btn:hover {
    transform: translateY(-1px) !important;
}

.ao-asg-page .asg-buttons-card {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 12px !important;
    padding: 14px 18px !important;
    box-sizing: border-box !important;
}

.ao-asg-page .asg-form-buttons-inside {
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 12px !important;
    width: 100% !important;
}

.ao-asg-page .asg-btn-form-inside {
    height: 40px !important;
    min-width: 145px !important;
    padding: 0 18px !important;
    border-radius: 6px !important;
    border: none !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: .2s ease !important;
}

.ao-asg-page .asg-btn-form-cancel {
    background: #ffffff !important;
    color: #374151 !important;
    border: 1px solid #cfd6df !important;
}

.ao-asg-page .asg-btn-form-cancel:hover {
    background: #f3f4f6 !important;
}

.ao-asg-page .asg-btn-form-draft {
    background: #f59e0b !important;
    color: #111827 !important;
}

.ao-asg-page .asg-btn-form-draft:hover {
    background: #d97706 !important;
}

.ao-asg-page .asg-btn-form-primary {
    background: #0d5db8 !important;
    color: #ffffff !important;
}

.ao-asg-page .asg-btn-form-primary:hover {
    background: #084d98 !important;
}

.ao-asg-page .asg-page-footer {
    display: none !important;
}

@media (max-width: 768px) {
    .ao-asg-page .asg-form-buttons-inside {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    .ao-asg-page .asg-btn-form-inside {
        width: 100% !important;
    }
}

.vo-form-page .ca-form-field.vo-select2-required-invalid .select2-container--default .select2-selection--single {
    border: 1px solid #ef4444 !important;
    border-left: 3px solid #ef4444 !important;
}

.vo-form-page .ca-form-field.vo-select2-required-invalid .select2-container--default.select2-container--focus .select2-selection--single, .vo-form-page .ca-form-field.vo-select2-required-invalid .select2-container--default.select2-container--open .select2-selection--single {
    border-color: #ef4444 !important;
    border-left: 3px solid #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, .12) !important;
}

.asg-field select.select2:required:valid + .select2-container .select2-selection--single {
    border-left: 1px solid #e5e7eb !important;
    border-color: #e5e7eb !important;
}

.asg-field input[type="date"]:required:invalid, .asg-field input[type="time"]:required:invalid {
    border-left: 3px solid #ef4444 !important;
    border-color: #ef4444 !important;
}

.asg-field input[type="date"]:required:valid, .asg-field input[type="time"]:required:valid {
    border-left: 1px solid #e5e7eb !important;
    border-color: #e5e7eb !important;
}

.asg-field input[type="date"]:required:valid:focus, .asg-field input[type="time"]:required:valid:focus {
    border-color: #2563eb !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08) !important;
}

.ca-filters-grid-visita-operario {
    grid-template-columns: 1.3fr 1.2fr 1.1fr 1fr 1fr auto;
}

#datatableVisitaOperario {
    width: 100%;
    min-width: 1550px;
    border-collapse: collapse;
    font-size: 12px;
    color: #000;
}

#datatableVisitaOperario th {
    background: #f3f4f6;
    border: 1px solid #d8dee8;
    padding: 10px 8px;
    text-align: center;
    font-weight: 700;
}

#datatableVisitaOperario td {
    border: 1px solid #e5e7eb;
    padding: 9px 8px;
    text-align: center;
    vertical-align: middle;
}

@media (max-width: 1200px) {
    .ca-filters-grid-visita-operario {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .ca-filters-grid-visita-operario {
        grid-template-columns: 1fr;
    }
}

.vo-actions-bar {
    justify-content: flex-end;
}

#datatableVisitasAsignacion {
    width: 100%;
    min-width: 1300px;
    border-collapse: collapse;
    font-size: 12px;
    color: #000;
}

#datatableVisitasAsignacion th {
    background: #f3f4f6;
    border: 1px solid #d8dee8;
    padding: 10px 8px;
    text-align: center;
    font-weight: 700;
}

#datatableVisitasAsignacion td {
    border: 1px solid #e5e7eb;
    padding: 9px 8px;
    text-align: center;
    vertical-align: middle;
}

.vo-form-page {
    padding-bottom: 30px;
}

.vo-top-summary {
    display: grid;
    grid-template-columns: 2fr repeat(5, 1fr);
    gap: 12px;
    margin-bottom: 18px;
}

.vo-main-card, .vo-metric-card {
    background: #fff;
    border: 1px solid #d8dee8;
    border-radius: 10px;
    padding: 14px;
    box-sizing: border-box;
}

.vo-main-card span, .vo-metric-card span {
    display: block;
    color: #64748b;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.vo-main-card h2 {
    margin: 0;
    color: #111827;
    font-size: 20px;
    font-weight: 700;
}

.vo-main-card p {
    margin: 6px 0 10px;
    color: #64748b;
    font-size: 12px;
}

.vo-metric-card {
    text-align: center;
}

.vo-metric-card i {
    display: block;
    margin-bottom: 6px;
    color: #0d5db8;
    font-size: 20px;
}

.vo-metric-card strong {
    display: block;
    color: #111827;
    font-size: 14px;
    font-weight: 700;
    word-break: break-word;
}

.vo-finding-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.vo-btn-finding:hover {
    border-color: #1976d2;
    background: #f8fafc;
}

.vo-finding-icon {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: #e5eefb;
    color: #0d5db8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.vo-finding-content strong {
    display: block;
    color: #111827;
    font-size: 13px;
    margin-bottom: 3px;
}

.vo-finding-content small {
    display: block;
    color: #64748b;
    font-size: 11px;
    line-height: 1.35;
}

.vo-evidence-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 12px;
}

.vo-empty-evidence td {
    text-align: center;
    color: #64748b;
    font-style: italic;
}

.vo-evidence-row textarea {
    width: 100%;
    min-height: 60px;
    border: 1px solid #cfd6df;
    border-radius: 4px;
    padding: 8px;
    resize: vertical;
    box-sizing: border-box;
}

.vo-evidence-preview {
    font-size: 11px;
    color: #64748b;
}

.vo-evidence-preview img {
    max-width: 90px;
    max-height: 70px;
    border: 1px solid #d8dee8;
    border-radius: 4px;
    display: block;
    margin-top: 5px;
}

.vo-state-help {
    background: #f8fafc;
    border: 1px solid #d8dee8;
    border-radius: 8px;
    padding: 12px;
    color: #374151;
    font-size: 12px;
    line-height: 1.45;
}

.vo-help-review {
    margin-bottom: 6px;
}

.vo-help-closed strong {
    color: #166534;
}

.vo-help-review strong {
    color: #0d5db8;
}

@media (max-width: 1400px) {
    .vo-top-summary {
        grid-template-columns: repeat(3, 1fr);
    }

    .vo-main-card {
        grid-column: span 3;
    }
}

@media (max-width: 1200px) {
    .vo-finding-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .vo-top-summary, .vo-finding-grid {
        grid-template-columns: 1fr;
    }

    .vo-main-card {
        grid-column: span 1;
    }

    .vo-evidence-toolbar {
        flex-direction: column;
        align-items: stretch;
    }
}

.vo-actions-bar-bottom {
    display: flex;
    justify-content: flex-end;
    margin-top: 14px;
    margin-bottom: 6px;
}

#datatableEvidenciasVisita_wrapper {
    width: 100%;
    margin: 0;
    overflow: visible;
}

#datatableEvidenciasVisita {
    width: 100% !important;
    min-width: 720px;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0;
    margin: 0 !important;
    font-size: 12px;
    color: #111827;
}

#datatableEvidenciasVisita thead th {
    height: 38px;
    padding: 9px 12px !important;
    background: #35a2d1;
    color: #ffffff;
    border-top: none;
    border-right: 1px solid rgba(255, 255, 255, .22);
    border-bottom: 1px solid #2389b5;
    border-left: none;
    text-align: center;
    vertical-align: middle;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    box-sizing: border-box;
}

#datatableEvidenciasVisita thead th:first-child {
    border-top-left-radius: 5px;
}

#datatableEvidenciasVisita thead th:last-child {
    border-top-right-radius: 5px;
    border-right: none;
}

#datatableEvidenciasVisita tbody tr {
    height: auto !important;
    min-height: 96px;
    background: #ffffff;
}

#datatableEvidenciasVisita tbody tr:hover {
    background: #f8fafc;
}

#datatableEvidenciasVisita tbody td {
    height: auto !important;
    min-height: 96px;
    padding: 12px !important;
    border-top: none;
    border-right: 1px solid #e5e7eb;
    border-bottom: 1px solid #d8dee8;
    border-left: none;
    text-align: center;
    vertical-align: middle !important;
    line-height: 1.4;
    white-space: normal;
    word-break: break-word;
    overflow: visible !important;
    box-sizing: border-box;
}

#datatableEvidenciasVisita tbody td:first-child {
    border-left: 1px solid #d8dee8;
}

#datatableEvidenciasVisita tbody td:last-child {
    border-right: 1px solid #d8dee8;
}

#datatableEvidenciasVisita th:nth-child(1), #datatableEvidenciasVisita td:nth-child(1) {
    width: 28% !important;
}

#datatableEvidenciasVisita th:nth-child(2), #datatableEvidenciasVisita td:nth-child(2) {
    width: 24% !important;
}

#datatableEvidenciasVisita th:nth-child(3), #datatableEvidenciasVisita td:nth-child(3) {
    width: 38% !important;
}

#datatableEvidenciasVisita th:nth-child(4), #datatableEvidenciasVisita td:nth-child(4) {
    width: 10% !important;
    min-width: 72px;
}

#datatableEvidenciasVisita .select2-container {
    width: 100% !important;
    min-width: 0;
}

#datatableEvidenciasVisita .select2-container--default .select2-selection--single {
    width: 100% !important;
    height: 38px !important;
    border: 1px solid #cfd6df !important;
    border-radius: 5px !important;
}

#datatableEvidenciasVisita .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 36px !important;
    text-align: left;
}

#datatableEvidenciasVisita input[type="file"] {
    display: block;
    width: 100%;
    max-width: 100%;
    padding: 6px;
    border: 1px solid #cfd6df;
    border-radius: 5px;
    background: #ffffff;
    color: #374151;
    font-size: 11px;
    box-sizing: border-box;
}

#datatableEvidenciasVisita textarea {
    display: block;
    width: 100%;
    min-height: 74px;
    max-height: 160px;
    margin: 0;
    padding: 9px 10px;
    border: 1px solid #cfd6df;
    border-radius: 5px;
    background: #ffffff;
    color: #111827;
    font-family: inherit;
    font-size: 12px;
    line-height: 1.4;
    resize: vertical;
    box-sizing: border-box;
}

#datatableEvidenciasVisita textarea:focus {
    border-color: #1976d2;
    outline: none;
    box-shadow: 0 0 0 3px rgba(25, 118, 210, .12);
}

#datatableEvidenciasVisita img {
    display: block;
    width: 82px;
    height: 72px;
    max-width: 100%;
    margin: 0 auto;
    border: 1px solid #d8dee8;
    border-radius: 6px;
    background: #f8fafc;
    object-fit: cover;
    cursor: pointer;
}

#datatableEvidenciasVisita img:hover {
    border-color: #1976d2;
    box-shadow: 0 3px 10px rgba(15, 23, 42, .15);
}

.vo-evidence-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    width: 100%;
    margin-top: 8px;
}

.vo-evidence-preview:empty {
    display: none;
}

.vo-evidence-preview span {
    display: block;
    width: 100%;
    color: #64748b;
    font-size: 10px;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#datatableEvidenciasVisita .ca-row-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    margin: 0 auto;
    padding: 0;
    border: none;
    border-radius: 5px;
    background: #0d5db8;
    color: #ffffff;
    cursor: pointer;
}

#datatableEvidenciasVisita .ca-row-action-btn:hover {
    background: #084d98;
    transform: translateY(-1px);
}

#datatableEvidenciasVisita_wrapper .dataTables_scroll, #datatableEvidenciasVisita_wrapper .dataTables_scrollBody {
    height: auto !important;
    max-height: none !important;
    overflow-y: visible !important;
}

#datatableEvidenciasVisita_wrapper .dataTables_scrollBody {
    border-bottom: none !important;
}

#datatableEvidenciasVisita .dataTables_empty, #datatableEvidenciasVisita .vo-empty-evidence td {
    height: 64px !important;
    padding: 18px !important;
    color: #64748b;
    text-align: center;
    font-style: italic;
}

.vo-evidence-button-right #agregarEvidenciaVisita {
    min-height: 38px;
}

@media (max-width: 768px) {
    #datatableEvidenciasVisita {
        min-width: 700px;
    }

    #datatableEvidenciasVisita tbody td {
        padding: 9px !important;
    }
}

.vo-btn-finding {
    min-height: 76px;
    border: 1px solid #cfd6df;
    border-radius: 8px;
    background: #fff;
    padding: 12px 42px 12px 12px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    text-align: left;
    position: relative;
}

.vo-btn-finding input[type="checkbox"] {
    display: block !important;
    appearance: none;
    -webkit-appearance: none;
    position: absolute;
    top: 10px;
    right: 10px;
    width: 19px;
    height: 19px;
    min-width: 19px;
    min-height: 19px;
    border: 2px solid #94a3b8;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    margin: 0;
    padding: 0;
    z-index: 3;
}

.vo-btn-finding input[type="checkbox"]:checked {
    border-color: #0d5db8;
    background: #0d5db8;
}

.vo-btn-finding input[type="checkbox"]:checked::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 5px;
    width: 4px;
    height: 8px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.vo-btn-finding.active {
    border-color: #0d5db8;
    background: #eff6ff;
}

.vo-evidence-button-right {
    width: 100%;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: 14px;
    margin-bottom: 4px;
}

.vo-evidence-button-right #agregarEvidenciaVisita {
    margin-left: auto;
}

.vo-assignment-summary {
    display: grid;
    grid-template-columns: 1.2fr 1fr 2fr 1fr;
    gap: 14px;
    margin-bottom: 18px;
}

.vo-summary-card {
    background: #fff;
    border: 1px solid #d8dee8;
    border-radius: 8px;
    padding: 12px 14px;
    box-sizing: border-box;
}

.vo-summary-card span {
    display: block;
    color: #64748b;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.vo-summary-card strong {
    display: block;
    color: #111827;
    font-size: 14px;
    font-weight: 700;
    word-break: break-word;
}

#descripcionBandejaVisitasOperario {
    display: block;
    margin-top: 4px;
    color: #4b5563;
    font-size: 13px;
    line-height: 1.45;
}

#descripcionBandejaVisitasOperario strong {
    color: #111827;
    font-weight: 700;
}

#voDescripcionDetalleAsignacion {
    color: #4b5563;
}

.vo-form-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 285px;
    gap: 16px;
    align-items: start;
}

.vo-form-main {
    min-width: 0;
}

.vo-alert-sidebar {
    position: sticky;
    top: 12px;
}

.vo-alert-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.vo-alert-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #111827;
    font-size: 13px;
    font-weight: 700;
    padding-bottom: 10px;
    border-bottom: 1px solid #e5e7eb;
    margin-bottom: 8px;
}

.vo-alert-title i {
    color: #dc2626;
    font-size: 15px;
}

.vo-alert-row {
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
}

.vo-alert-row:last-child {
    border-bottom: none;
}

.vo-alert-row label {
    display: block;
    margin-bottom: 3px;
    color: #64748b;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.vo-alert-row strong {
    display: block;
    color: #111827;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.35;
}

.vo-alert-critical {
    color: #dc2626 !important;
    text-transform: uppercase;
}

.vo-alert-high {
    color: #ea580c !important;
    text-transform: uppercase;
}

.vo-alert-medium {
    color: #ca8a04 !important;
    text-transform: uppercase;
}

.vo-alert-low {
    color: #2563eb !important;
    text-transform: uppercase;
}

.vo-alert-row-observacion p {
    margin: 0;
    color: #374151;
    font-size: 11px;
    line-height: 1.4;
    max-height: 96px;
    overflow-y: auto;
}

@media (max-width: 1200px) {
    .vo-form-layout {
        grid-template-columns: 1fr;
    }

    .vo-alert-sidebar {
        position: static;
    }
}

.ca-detail-visits-card {
    background: #ffffff;
    border: 1px solid #d8dee8;
    border-radius: 10px;
    padding: 14px;
    margin-top: 16px;
    box-sizing: border-box;
}

.pill.closed, .ca-pill-closed {
    background: #dcfce7;
    color: #166534;
}

.ca-detail-tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 12px 0 14px;
    border-bottom: 1px solid #d8dee8;
    padding-bottom: 0;
}

.ca-detail-tab {
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid #d8dee8;
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    background: #f8fafc;
    color: #475569;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    position: relative;
    top: 1px;
}

.ca-detail-tab:hover {
    background: #eef2f7;
    color: #0d5db8;
}

.ca-detail-tab.active {
    background: #ffffff;
    color: #0d5db8;
    border-color: #d8dee8;
    border-bottom: 1px solid #ffffff;
}

.ca-detail-tab-content {
    display: none;
}

.ca-detail-tab-content.active {
    display: block;
}

.ca-tab-count {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: #e0f2fe;
    color: #0369a1;
    font-size: 11px;
    font-weight: 700;
}

.ca-detail-visits-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.ca-detail-visits-head h4 {
    margin: 0;
    color: #111827;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
}

.ca-detail-visits-head span {
    display: block;
    margin-top: 3px;
    color: #64748b;
    font-size: 12px;
}

#datatableHistorialVisitasTecnicas {
    width: 100%;
    min-width: 1650px;
    border-collapse: collapse;
    font-size: 12px;
    color: #000;
}

#datatableHistorialVisitasTecnicas th {
    background: #f3f4f6;
    border: 1px solid #d8dee8;
    padding: 10px 8px;
    text-align: center;
    font-weight: 700;
}

#datatableHistorialVisitasTecnicas td {
    border: 1px solid #e5e7eb;
    padding: 9px 8px;
    text-align: center;
    vertical-align: middle;
}

.ca-visit-evidence-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 24px;
    padding: 0 8px;
    border-radius: 999px;
    background: #e0f2fe;
    color: #0369a1;
    font-weight: 700;
}

.revision-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 16px;
    padding: 16px;
}

.revision-history {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.revision-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.revision-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.revision-title {
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}

.revision-counter {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #2563eb;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
}

.revision-filter {
    height: 34px;
    border: 1px solid #d8dee8;
    border-radius: 6px;
    padding: 0 12px;
    background: #ffffff;
}

.visit-card {
    background: #ffffff;
    border: 1px solid #d8dee8;
    border-radius: 10px;
    overflow: hidden;
}

.visit-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    border-bottom: 1px solid #eef2f7;
}

.visit-title {
    font-size: 22px;
    font-weight: 700;
    color: #07192f;
}

.visit-status {
    padding: 7px 13px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
}

.visit-status.danger {
    background: #fee2e2;
    color: #dc2626;
}

.visit-status.warning {
    background: #fef3c7;
    color: #92400e;
}

.visit-status.success {
    background: #dcfce7;
    color: #15803d;
}

.visit-status.neutral {
    background: #e2e8f0;
    color: #475569;
}

.visit-meta {
    display: flex;
    gap: 24px;
    padding: 12px 18px;
    font-size: 12px;
    color: #64748b;
    border-bottom: 1px solid #eef2f7;
    flex-wrap: wrap;
}

.visit-meta i {
    margin-right: 6px;
    color: #64748b;
}

.visit-metrics {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    border-bottom: 1px solid #eef2f7;
}

.metric-box {
    padding: 14px;
    border-right: 1px solid #eef2f7;
}

.metric-box:last-child {
    border-right: none;
}

.metric-box span {
    display: block;
    color: #64748b;
    font-size: 11px;
    margin-bottom: 4px;
}

.metric-box strong {
    font-size: 18px;
    font-weight: 700;
    color: #07192f;
}

.text-danger {
    color: #dc2626 !important;
}

.text-success {
    color: #16a34a !important;
}

.visit-findings {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 14px 18px;
}

.erp-tag {
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
}

.erp-tag.success {
    background: #dcfce7;
    color: #15803d;
}

.erp-tag.danger {
    background: #fee2e2;
    color: #dc2626;
}

.erp-tag.warning {
    background: #fef3c7;
    color: #92400e;
}

.erp-tag.neutral {
    background: #e2e8f0;
    color: #475569;
}

.visit-conclusion {
    padding: 0 18px 14px;
    font-size: 13px;
    line-height: 1.6;
    color: #374151;
}

.visit-conclusion strong {
    color: #07192f;
}

.visit-footer {
    display: flex;
    justify-content: flex-end;
    padding: 12px 18px;
    border-top: 1px solid #eef2f7;
}

.detail-link {
    border: none;
    background: none;
    color: #2563eb;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
}

.erp-card {
    background: #ffffff;
    border: 1px solid #d8dee8;
    border-radius: 10px;
    padding: 16px;
}

.erp-card h4 {
    margin: 0 0 14px;
    font-size: 14px;
    font-weight: 700;
}

.diagnostic-alert {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 16px;
}

.diagnostic-icon {
    color: #dc2626;
    font-size: 18px;
}

.diagnostic-alert strong {
    display: block;
    color: #dc2626;
}

.diagnostic-alert small {
    color: #64748b;
}

.info-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #eef2f7;
}

.info-row:last-child {
    border-bottom: none;
}

.info-row span {
    color: #64748b;
    font-size: 12px;
}

.info-row strong {
    text-align: right;
    font-size: 13px;
}

.evidence-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.evidence-item {
    text-align: center;
    padding: 12px 8px;
    background: #f8fafc;
    border-radius: 8px;
}

.evidence-item i {
    display: block;
    font-size: 18px;
    color: #2563eb;
    margin-bottom: 8px;
}

.evidence-item strong {
    display: block;
    font-size: 18px;
}

.evidence-item span {
    font-size: 11px;
    color: #64748b;
}

.recommendation-card {
    background: #eff6ff;
    border-color: #bfdbfe;
}

.recommendation-card p {
    margin: 0;
    color: #0f3f8f;
    font-size: 13px;
    line-height: 1.7;
}

@media (max-width: 1200px) {
    .revision-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .visit-metrics {
        grid-template-columns: repeat(2, 1fr);
    }
}

.diagnostic-alert.diagnostic-danger {
    background: #fef2f2;
    border-color: #fecaca;
}

.diagnostic-alert.diagnostic-danger .diagnostic-icon, .diagnostic-alert.diagnostic-danger strong {
    color: #dc2626;
}

.diagnostic-alert.diagnostic-warning {
    background: #fffbeb;
    border-color: #fde68a;
}

.diagnostic-alert.diagnostic-warning .diagnostic-icon, .diagnostic-alert.diagnostic-warning strong {
    color: #d97706;
}

.diagnostic-alert.diagnostic-success {
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.diagnostic-alert.diagnostic-success .diagnostic-icon, .diagnostic-alert.diagnostic-success strong {
    color: #16a34a;
}

.diagnostic-alert.diagnostic-neutral {
    background: #f8fafc;
    border-color: #e2e8f0;
}

.diagnostic-alert.diagnostic-neutral .diagnostic-icon, .diagnostic-alert.diagnostic-neutral strong {
    color: #475569;
}

.text-warning {
    color: #d97706 !important;
}

.text-neutral {
    color: #475569 !important;
}

.info-row strong {
    display: block !important;
    color: #111827;
    visibility: visible !important;
    opacity: 1 !important;
}

.diagnostic-alert {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.diagnostic-icon {
    width: 22px;
    min-width: 22px;
    padding-top: 2px;
}

.diagnostic-content {
    display: block;
    min-width: 0;
    flex: 1;
}

.diagnostic-content strong {
    display: block !important;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
    margin-bottom: 3px;
    visibility: visible !important;
    opacity: 1 !important;
}

.diagnostic-content small {
    display: block !important;
    color: #64748b !important;
    font-size: 11px;
    line-height: 1.35;
    visibility: visible !important;
    opacity: 1 !important;
}

.diagnostic-alert.diagnostic-danger .diagnostic-content strong {
    color: #dc2626 !important;
}

.diagnostic-alert.diagnostic-warning .diagnostic-content strong {
    color: #d97706 !important;
}

.diagnostic-alert.diagnostic-success .diagnostic-content strong {
    color: #16a34a !important;
}

.diagnostic-alert.diagnostic-neutral .diagnostic-content strong {
    color: #475569 !important;
}

.vo-form-page .ca-form-field input:required:invalid, .vo-form-page .ca-form-field textarea:required:invalid {
    border-left: 3px solid #ef4444 !important;
    border-color: #ef4444 !important;
}

.vo-form-page .ca-form-field input:required:valid, .vo-form-page .ca-form-field textarea:required:valid {
    border-left: 1px solid #cfd6df !important;
    border-color: #cfd6df !important;
}

.vo-form-page .ca-form-field select.select2:required:invalid + .select2-container .select2-selection--single {
    border-left: 3px solid #ef4444 !important;
    border-color: #ef4444 !important;
}

.vo-form-page .ca-form-field select.select2:required:valid + .select2-container .select2-selection--single {
    border-left: 1px solid #cfd6df !important;
    border-color: #cfd6df !important;
}

.vo-form-page .ca-form-field input:required:invalid:focus, .vo-form-page .ca-form-field textarea:required:invalid:focus {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, .12) !important;
}

.vo-form-page .ca-form-field input:required:valid:focus, .vo-form-page .ca-form-field textarea:required:valid:focus {
    border-color: #1976d2 !important;
    box-shadow: 0 0 0 3px rgba(25, 118, 210, .12) !important;
}

.vo-form-page .ca-form-field select.select2:required:valid + .select2-container.select2-container--focus .select2-selection--single {
    border-color: #1976d2 !important;
    box-shadow: 0 0 0 3px rgba(25, 118, 210, .12) !important;
}

.vo-form-page .ca-form-field select.select2:required:invalid + .select2-container.select2-container--focus .select2-selection--single {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, .12) !important;
}

.vo-form-page .ca-form-field.vo-select2-required-invalid .select2-container .select2-selection--single {
    border: 1px solid #ef4444 !important;
    border-left: 3px solid #ef4444 !important;
    box-shadow: none !important;
}

.vo-form-page .ca-form-field.vo-select2-required-invalid .select2-container--open .select2-selection--single, .vo-form-page .ca-form-field.vo-select2-required-invalid .select2-container--focus .select2-selection--single {
    border-color: #ef4444 !important;
    border-left: 3px solid #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, .12) !important;
}

.visit-card.selected {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .10);
}

.visit-card.selected .visit-card-header {
    background: #eff6ff;
}

.evidence-grid.evidence-grid-single {
    grid-template-columns: 1fr;
}

.evidence-item-button {
    width: 100%;
    border: none;
    font-family: inherit;
    cursor: pointer;
    transition: transform .15s ease,
        box-shadow .15s ease,
        background .15s ease;
}

.evidence-item-button:not(:disabled):hover {
    background: #eff6ff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, .12);
    transform: translateY(-1px);
}

.evidence-item-button:disabled {
    cursor: not-allowed;
    opacity: .58;
}

.evidence-item-button small {
    display: block;
    margin-top: 5px;
    color: #64748b;
    font-size: 10px;
}

body.ca-evidence-modal-open {
    overflow: hidden;
}

.ca-evidence-modal {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .68);
    box-sizing: border-box;
}

.ca-evidence-modal.show {
    display: flex;
}

.ca-evidence-modal-dialog {
    width: min(1050px, 96vw);
    max-height: 90vh;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 24px 70px rgba(0, 0, 0, .32);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.ca-evidence-modal-header {
    min-height: 62px;
    padding: 14px 18px;
    background: linear-gradient(
            135deg,
            #07192f,
            #0d5db8
        );
    color: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.ca-evidence-modal-header h3 {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
}

.ca-evidence-modal-header small {
    display: block;
    margin-top: 4px;
    opacity: .88;
}

.ca-evidence-modal-close {
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    border: none;
    border-radius: 6px;
    background: rgba(255, 255, 255, .16);
    color: #ffffff;
    cursor: pointer;
}

.ca-evidence-modal-close:hover {
    background: rgba(255, 255, 255, .28);
}

.ca-evidence-modal-body {
    padding: 18px;
    overflow-y: auto;
    background: #f8fafc;
}

.ca-evidence-modal-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.ca-evidence-modal-card {
    min-width: 0;
    background: #ffffff;
    border: 1px solid #d8dee8;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(15, 23, 42, .06);
}

.ca-evidence-modal-image {
    display: block;
    width: 100%;
    height: 220px;
    background: #e5e7eb;
    overflow: hidden;
}

.ca-evidence-modal-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    background: #111827;
}

.ca-evidence-modal-info {
    padding: 12px 14px;
}

.ca-evidence-modal-info strong {
    display: block;
    color: #111827;
    font-size: 13px;
}

.ca-evidence-modal-info small {
    display: block;
    margin-top: 3px;
    color: #64748b;
    font-size: 11px;
    word-break: break-word;
}

.ca-evidence-modal-info p {
    margin: 10px 0 0;
    color: #374151;
    font-size: 12px;
    line-height: 1.5;
}

.ca-evidence-modal-empty {
    grid-column: 1 / -1;
    padding: 36px;
    background: #ffffff;
    border: 1px dashed #cbd5e1;
    border-radius: 10px;
    color: #64748b;
    text-align: center;
}

@media (max-width: 900px) {
    .ca-evidence-modal-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .ca-evidence-modal {
        padding: 10px;
    }

    .ca-evidence-modal-grid {
        grid-template-columns: 1fr;
    }

    .ca-evidence-modal-image {
        height: 210px;
    }
}

button.ca-evidence-modal-image {
    padding: 0;
    border: none;
    cursor: zoom-in;
    font-family: inherit;
}

button.ca-evidence-modal-image:focus {
    outline: 3px solid rgba(37, 99, 235, .25);
    outline-offset: -3px;
}

.ca-evidence-viewer {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 28px;
    background: rgba(2, 6, 23, .94);
    box-sizing: border-box;
}

.ca-evidence-viewer.show {
    display: flex;
}

.ca-evidence-viewer img {
    display: block;
    width: auto;
    max-width: 96%;
    height: auto;
    max-height: 94%;
    object-fit: contain;
    border-radius: 6px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .45);
}

.ca-evidence-viewer-close {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 40px;
    height: 40px;
    z-index: 6;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, .16);
    color: #ffffff;
    font-size: 18px;
    cursor: pointer;
}

.ca-evidence-viewer-close:hover {
    background: rgba(255, 255, 255, .28);
}

.ca-quick-red {
    background: #dc2626;
}

.ca-quick-red:hover:not(:disabled) {
    background: #b91c1c;
}

.ca-quick-green {
    background: #16a34a;
}

.ca-quick-green:hover:not(:disabled) {
    background: #15803d;
}

.ao-asg-page .asg-finding-grid {
    display: grid !important;
    grid-template-columns: repeat(
            auto-fit,
            minmax(240px, 1fr)
        ) !important;
    gap: 12px !important;
    width: 100% !important;
    min-width: 0 !important;
}

.ao-asg-page .asg-btn-finding {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 105px !important;
    height: auto !important;
    display: grid !important;
    grid-template-columns: 32px
        minmax(0, 1fr)
        20px !important;
    gap: 10px !important;
    align-items: flex-start !important;
    padding: 14px 12px !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
}

.ao-asg-page .asg-finding-icon {
    width: 30px !important;
    min-width: 30px !important;
    height: 30px !important;
}

.ao-asg-page .asg-finding-content {
    width: 100% !important;
    min-width: 0 !important;
}

.ao-asg-page .asg-finding-content strong, .ao-asg-page .asg-finding-content small {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: normal !important;
    hyphens: none !important;
}

.ao-asg-page .asg-finding-content strong {
    font-size: 12px !important;
    line-height: 1.35 !important;
}

.ao-asg-page .asg-finding-content small {
    margin-top: 5px !important;
    font-size: 11px !important;
    line-height: 1.35 !important;
}

.ao-asg-page .asg-check-circle {
    width: 20px !important;
    min-width: 20px !important;
    height: 20px !important;
}

@media (max-width: 520px) {
    .ao-asg-page .asg-finding-grid {
        grid-template-columns: 1fr !important;
    }
}

/* =========================================================
   CONSUMOS ATÍPICOS - COMPARTIR UBICACIÓN
   ========================================================= */

.ca-map-share {
    padding-top: 14px;
    margin-top: 12px;
    border-top: 1px solid #e5e7eb;
}

.ca-map-share-title {
    margin-bottom: 9px;
    color: #111827;
    font-size: 12px;
    font-weight: 700;
}

.ca-map-share-title i {
    margin-right: 5px;
    color: #0d5db8;
}

.ca-map-share-btn {
    width: 100%;
    min-height: 34px;
    margin-bottom: 7px;
    padding: 7px 10px;
    border: none;
    border-radius: 5px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
}

.ca-map-share-whatsapp {
    background: #16a34a;
}

.ca-map-share-whatsapp:hover {
    background: #15803d;
}

.ca-map-share-email {
    background: #0d5db8;
}

.ca-map-share-email:hover {
    background: #084d98;
}

.ca-map-share-copy {
    background: #475569;
}

.ca-map-share-copy:hover {
    background: #334155;
}

.ca-map-share-native {
    background: #7c3aed;
}

.ca-map-share-native:hover {
    background: #6d28d9;
}

/* Modal de correo */

body.ca-share-email-open {
    overflow: hidden;
}

.ca-share-email-modal {
    position: fixed;
    inset: 0;
    z-index: 12500;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, .68);
    box-sizing: border-box;
}

.ca-share-email-modal.show {
    display: flex;
}

.ca-share-email-dialog {
    width: min(620px, 96vw);
    max-height: 92vh;
    overflow-y: auto;
    background: #ffffff;
    border-radius: 10px;
    box-shadow:
        0 24px 70px rgba(0, 0, 0, .32);
}

.ca-share-email-header {
    min-height: 64px;
    padding: 14px 18px;
    background:
        linear-gradient(
            135deg,
            #07192f,
            #0d5db8
        );
    color: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    border-radius: 10px 10px 0 0;
}

.ca-share-email-header h3 {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
}

.ca-share-email-header small {
    display: block;
    margin-top: 4px;
    opacity: .88;
}

.ca-share-email-close {
    width: 34px;
    min-width: 34px;
    height: 34px;
    border: none;
    border-radius: 6px;
    background: rgba(255, 255, 255, .16);
    color: #ffffff;
    cursor: pointer;
}

.ca-share-email-close:hover {
    background: rgba(255, 255, 255, .28);
}

.ca-share-email-body {
    padding: 18px;
}

.ca-share-email-field {
    margin-bottom: 14px;
}

.ca-share-email-field label {
    display: block;
    margin-bottom: 6px;
    color: #374151;
    font-size: 12px;
    font-weight: 700;
}

.ca-share-email-field label span {
    color: #dc2626;
}

.ca-share-email-field input,
.ca-share-email-field textarea {
    width: 100%;
    border: 1px solid #cfd6df;
    border-radius: 5px;
    background: #ffffff;
    color: #111827;
    font-family: inherit;
    font-size: 13px;
    box-sizing: border-box;
}

.ca-share-email-field input {
    height: 38px;
    padding: 0 10px;
}

.ca-share-email-field textarea {
    min-height: 110px;
    padding: 10px;
    resize: vertical;
    line-height: 1.45;
}

.ca-share-email-field input:focus,
.ca-share-email-field textarea:focus {
    border-color: #1976d2;
    outline: none;
    box-shadow:
        0 0 0 3px rgba(25, 118, 210, .12);
}

.ca-share-email-field input[readonly] {
    background: #f3f4f6;
    color: #64748b;
}

.ca-share-email-actions {
    padding: 14px 18px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

@media (max-width: 600px) {
    .ca-share-email-actions {
        flex-direction: column;
    }

    .ca-share-email-actions button {
        width: 100%;
        justify-content: center;
    }
}


/*
 * Complemento visual para los módulos:
 * - Asignación Corte / Reconexión
 * - Visita Corte / Reconexión
 *
 * Debe cargarse después de gestion.css.
 */

.cr-filters-assignment {
    grid-template-columns: 1.25fr 1.55fr 1.35fr 1fr 1fr 1fr 1fr 1fr auto;
}

.cr-filters-visit {
    grid-template-columns: 1.25fr 1.55fr 1fr 1fr 1fr 1fr auto;
}

.cr-summary-grid {
    grid-template-columns: 2.1fr repeat(4, minmax(135px, 1fr));
}

.cr-operation-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(240px, 1fr));
    gap: 14px;
}

.cr-operation-card {
    position: relative;
    min-height: 122px;
    padding: 18px;
    border: 2px solid #d8dee8;
    border-radius: 10px;
    background: #ffffff;
    cursor: pointer;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
    box-sizing: border-box;
}

.cr-operation-card:hover:not(.is-disabled) {
    border-color: #2563eb;
    box-shadow: 0 5px 14px rgba(15, 23, 42, .10);
    transform: translateY(-1px);
}

.cr-operation-card.is-selected {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .13);
}

.cr-operation-card.is-disabled {
    background: #f3f4f6;
    color: #9ca3af;
    cursor: not-allowed;
    opacity: .65;
}

.cr-operation-card.cr-operation-cut.is-selected {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, .12);
}

.cr-operation-card.cr-operation-reconnection.is-selected {
    border-color: #16a34a;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, .12);
}

.cr-operation-card-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 9px;
}

.cr-operation-card-icon {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    font-size: 19px;
    background: #eff6ff;
    color: #2563eb;
}

.cr-operation-cut .cr-operation-card-icon {
    background: #fef2f2;
    color: #dc2626;
}

.cr-operation-reconnection .cr-operation-card-icon {
    background: #f0fdf4;
    color: #16a34a;
}

.cr-operation-card-title {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #111827;
}

.cr-operation-card.is-disabled .cr-operation-card-title {
    color: #6b7280;
}

.cr-operation-card-description {
    margin: 0;
    color: #64748b;
    font-size: 12px;
    line-height: 1.45;
}

.cr-operation-card-state {
    position: absolute;
    top: 12px;
    right: 12px;
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 0 9px;
    border-radius: 999px;
    background: #e5e7eb;
    color: #4b5563;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
}

.cr-operation-card.is-selected .cr-operation-card-state {
    background: #dbeafe;
    color: #1d4ed8;
}

.cr-operation-cut.is-selected .cr-operation-card-state {
    background: #fee2e2;
    color: #b91c1c;
}

.cr-operation-reconnection.is-selected .cr-operation-card-state {
    background: #dcfce7;
    color: #166534;
}

.cr-location-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 14px;
}

.cr-operation-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 92px;
    min-height: 26px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.cr-pill-cut {
    background: #fee2e2;
    color: #b91c1c;
}

.cr-pill-reconnection {
    background: #dcfce7;
    color: #166534;
}

.cr-pill-pending {
    background: #fef3c7;
    color: #92400e;
}

#datatableAsignarCorteReconexion,
#datatableVisitaCorteReconexion,
#datatableVisitasAsignacionCorteReconexion {
    width: 100%;
    min-width: 1380px;
    border-collapse: collapse;
    color: #000000;
    font-size: 12px;
}

#datatableAsignarCorteReconexion th,
#datatableVisitaCorteReconexion th,
#datatableVisitasAsignacionCorteReconexion th {
    padding: 10px 8px;
    border: 1px solid #d8dee8;
    background: #f3f4f6;
    text-align: center;
    font-weight: 700;
}

#datatableAsignarCorteReconexion td,
#datatableVisitaCorteReconexion td,
#datatableVisitasAsignacionCorteReconexion td {
    padding: 9px 8px;
    border: 1px solid #e5e7eb;
    text-align: center;
    vertical-align: middle;
}

#datatableEvidenciasCorteReconexion textarea {
    width: 100%;
    min-width: 220px;
    min-height: 62px;
    padding: 8px;
    border: 1px solid #cfd6df;
    border-radius: 4px;
    box-sizing: border-box;
    resize: vertical;
}

#datatableEvidenciasCorteReconexion input[type="file"] {
    width: 100%;
    min-width: 230px;
}

.cr-evidence-saved a {
    color: #0d5db8;
    font-weight: 600;
    text-decoration: none;
}

.cr-evidence-saved a:hover {
    text-decoration: underline;
}

.cr-readonly-note {
    padding: 10px 12px;
    border: 1px solid #bfdbfe;
    border-radius: 6px;
    background: #eff6ff;
    color: #1e40af;
    font-size: 12px;
    line-height: 1.45;
}

@media (max-width: 1360px) {
    .cr-filters-assignment,
    .cr-filters-visit {
        grid-template-columns: repeat(3, minmax(180px, 1fr));
    }

    .cr-summary-grid {
        grid-template-columns: repeat(2, minmax(220px, 1fr));
    }

    .cr-summary-grid > :first-child {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .cr-filters-assignment,
    .cr-filters-visit,
    .cr-summary-grid,
    .cr-operation-grid {
        grid-template-columns: 1fr;
    }

    .cr-summary-grid > :first-child {
        grid-column: span 1;
    }

    .cr-location-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .cr-location-actions .ca-btn-secondary {
        width: 100%;
        justify-content: center;
    }
}

/* Compatibilidad con el HTML generado por controladorAsignarCorteReconexion.js. */
.cr-operation-card.disabled {
    background: #f3f4f6;
    color: #9ca3af;
    cursor: not-allowed;
    opacity: .65;
}

.cr-operation-card.selected {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .13);
}

.cr-operation-card > i {
    width: 42px;
    height: 42px;
    margin-right: 10px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    background: #eff6ff;
    color: #2563eb;
    font-size: 19px;
}

.cr-operation-card > strong {
    display: inline-block;
    vertical-align: middle;
    color: #111827;
    font-size: 16px;
}

.cr-operation-card > span,
.cr-operation-card > small {
    display: block;
    margin-top: 9px;
    color: #64748b;
    font-size: 12px;
    line-height: 1.4;
}

.cr-operation-card > small {
    color: #475569;
    font-weight: 700;
}

.cr-operation-cut > i {
    background: #fef2f2;
    color: #dc2626;
}

.cr-operation-cut.selected {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, .12);
}

.cr-operation-reconnect > i {
    background: #f0fdf4;
    color: #16a34a;
}

.cr-operation-reconnect.selected {
    border-color: #16a34a;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, .12);
}

/* Evita que los campos Select2 amplíen las columnas del grid. */
.cr-filters-assignment .ca-field,
.cr-filters-visit .ca-field {
    min-width: 0;
}

/* Mantiene los Select2 dentro del ancho disponible. */
.cr-filters-assignment .select2-container,
.cr-filters-visit .select2-container,
#facturaServicioPublico + .select2-container {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
}

/* Recorta el texto seleccionado y agrega puntos suspensivos. */
#filtro_factura_servicio_publico
    + .select2-container
    .select2-selection__rendered,
#facturaServicioPublico
    + .select2-container
    .select2-selection__rendered {
    display: block;
    max-width: 100%;
    overflow: hidden;
    padding-right: 45px !important;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Conserva espacio para la X y la flecha. */
#filtro_factura_servicio_publico
    + .select2-container
    .select2-selection__clear,
#facturaServicioPublico
    + .select2-container
    .select2-selection__clear {
    position: relative;
    z-index: 2;
}

/* Permite que las opciones largas se distribuyan en varias líneas. */
.select2-results__option {
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

#datatableEvidenciasVisita_wrapper {
    width: 100%;
    margin: 0;
    overflow: visible;
}

#datatableEvidenciasCorteReconexion {
    width: 100% !important;
    min-width: 720px;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0;
    margin: 0 !important;
    font-size: 12px;
    color: #111827;
}

#datatableEvidenciasCorteReconexion thead th {
    height: 38px;
    padding: 9px 12px !important;
    background: #35a2d1;
    color: #ffffff;
    border-top: none;
    border-right: 1px solid rgba(255, 255, 255, .22);
    border-bottom: 1px solid #2389b5;
    border-left: none;
    text-align: center;
    vertical-align: middle;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
    box-sizing: border-box;
}

#datatableEvidenciasCorteReconexion thead th:first-child {
    border-top-left-radius: 5px;
}

#datatableEvidenciasCorteReconexion thead th:last-child {
    border-top-right-radius: 5px;
    border-right: none;
}

#datatableEvidenciasCorteReconexion tbody tr {
    height: auto !important;
    min-height: 96px;
    background: #ffffff;
}

#datatableEvidenciasCorteReconexion tbody tr:hover {
    background: #f8fafc;
}

#datatableEvidenciasCorteReconexion tbody td {
    height: auto !important;
    min-height: 96px;
    padding: 12px !important;
    border-top: none;
    border-right: 1px solid #e5e7eb;
    border-bottom: 1px solid #d8dee8;
    border-left: none;
    text-align: center;
    vertical-align: middle !important;
    line-height: 1.4;
    white-space: normal;
    word-break: break-word;
    overflow: visible !important;
    box-sizing: border-box;
}

#datatableEvidenciasCorteReconexion tbody td:first-child {
    border-left: 1px solid #d8dee8;
}

#datatableEvidenciasCorteReconexion tbody td:last-child {
    border-right: 1px solid #d8dee8;
}

#datatableEvidenciasCorteReconexion th:nth-child(1), #datatableEvidenciasCorteReconexion td:nth-child(1) {
    width: 28% !important;
}

#datatableEvidenciasCorteReconexion th:nth-child(2), #datatableEvidenciasCorteReconexion td:nth-child(2) {
    width: 24% !important;
}

#datatableEvidenciasCorteReconexion th:nth-child(3), #datatableEvidenciasCorteReconexion td:nth-child(3) {
    width: 38% !important;
}

#datatableEvidenciasCorteReconexion th:nth-child(4), #datatableEvidenciasCorteReconexion td:nth-child(4) {
    width: 10% !important;
    min-width: 72px;
}

#datatableEvidenciasCorteReconexion .select2-container {
    width: 100% !important;
    min-width: 0;
}

#datatableEvidenciasCorteReconexion .select2-container--default .select2-selection--single {
    width: 100% !important;
    height: 38px !important;
    border: 1px solid #cfd6df !important;
    border-radius: 5px !important;
}

#datatableEvidenciasCorteReconexion .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 36px !important;
    text-align: left;
}

#datatableEvidenciasCorteReconexion input[type="file"] {
    display: block;
    width: 100%;
    max-width: 100%;
    padding: 6px;
    border: 1px solid #cfd6df;
    border-radius: 5px;
    background: #ffffff;
    color: #374151;
    font-size: 11px;
    box-sizing: border-box;
}

#datatableEvidenciasCorteReconexion textarea {
    display: block;
    width: 100%;
    min-height: 74px;
    max-height: 160px;
    margin: 0;
    padding: 9px 10px;
    border: 1px solid #cfd6df;
    border-radius: 5px;
    background: #ffffff;
    color: #111827;
    font-family: inherit;
    font-size: 12px;
    line-height: 1.4;
    resize: vertical;
    box-sizing: border-box;
}

#datatableEvidenciasCorteReconexion textarea:focus {
    border-color: #1976d2;
    outline: none;
    box-shadow: 0 0 0 3px rgba(25, 118, 210, .12);
}

#datatableEvidenciasCorteReconexion img {
    display: block;
    width: 82px;
    height: 72px;
    max-width: 100%;
    margin: 0 auto;
    border: 1px solid #d8dee8;
    border-radius: 6px;
    background: #f8fafc;
    object-fit: cover;
    cursor: pointer;
}

#datatableEvidenciasCorteReconexion img:hover {
    border-color: #1976d2;
    box-shadow: 0 3px 10px rgba(15, 23, 42, .15);
}

.vo-evidence-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    width: 100%;
    margin-top: 8px;
}

.vo-evidence-preview:empty {
    display: none;
}

.vo-evidence-preview span {
    display: block;
    width: 100%;
    color: #64748b;
    font-size: 10px;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#datatableEvidenciasCorteReconexion .ca-row-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    margin: 0 auto;
    padding: 0;
    border: none;
    border-radius: 5px;
    background: #0d5db8;
    color: #ffffff;
    cursor: pointer;
}

#datatableEvidenciasCorteReconexion .ca-row-action-btn:hover {
    background: #084d98;
    transform: translateY(-1px);
}

#datatableEvidenciasCorteReconexion_wrapper .dataTables_scroll, #datatableEvidenciasCorteReconexion_wrapper .dataTables_scrollBody {
    height: auto !important;
    max-height: none !important;
    overflow-y: visible !important;
}

#datatableEvidenciasCorteReconexion_wrapper .dataTables_scrollBody {
    border-bottom: none !important;
}

.vo-evidence-saved-image {
    display: block;
    width: 90px;
    height: 70px;
    margin: 0 auto;
    object-fit: cover;
    border: 1px solid #d7dde5;
    border-radius: 6px;
    cursor: pointer;
}