
/* CSS para estilos personalizados y responsividad */
.bone-white-background {
    background-image: url('images/fondo/background.jpeg'), radial-gradient(circle at 10% 20%, rgba(135,206,235,0.08) 0%, transparent 20%), radial-gradient(circle at 90% 80%, rgba(135,206,235,0.06) 0%, transparent 25%);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.full-height {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-panel {
    width: 100%;
    max-width: 400px;
    padding: 2rem;
    margin-bottom: 5rem;
}



.input-container {
    position: relative;
    margin-bottom: 1rem;
}

    .input-container input {
        width: 100% !important;
        height: 45px !important;
        padding-right: 45px !important; /* ← ESPACIO BOTÓN */
        font-size: 15px;
        box-sizing: border-box;
    }

.input-button {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    height: 28px;
    min-width: 28px;
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #0054C2 !important;
    z-index: 5;
}

    .input-button:hover {
        background-color: rgba(0, 84, 194, 0.08) !important;
    }


.login-text {
    color: white;
}

.spaced-input {
    margin-top: 1.2rem;
}

.login-input .mud-input-root {
    background-color: white;
    border-radius: 14px;
}

.login-input .mud-input-outlined-border {
    border-color: rgba(255, 255, 255, 0.4);
}

.login-input:hover .mud-input-outlined-border {
    border-color: white;
}

.login-input.mud-input-focused .mud-input-outlined-border {
    border-color: white;
}

.login-input .mud-input-label {
    color: rgba(255, 255, 255, 0.9);
}

.login-input input {
    color: #222;
    font-weight: 500;
}

.login-button {
    background-color: #0054C2 !important;
    color: white !important;
    border-radius: 14px;
    font-weight: 600;
    height: 56px;
    transition: all 0.25s ease;
}

    .login-button:hover {
        background-color: #003E91 !important;
        transform: translateY(-1px);
    }

.logo-img {
    width: 100px;
    height: auto;
}

@media (min-width: 1024px) {
    .logo-img {
        width: 180px;
        height: 190px;
    }
}

/* LINKS BLANCOS */
.login-links {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

    .login-links a {
        color: white;
        text-decoration: none;
        font-size: 0.9rem;
    }

        .login-links a:hover {
            opacity: 0.7;
        }

@media (max-width: 600px) {

    .login-panel {
        max-width: 400px;
        padding: 2rem;
        padding-bottom: 8.5rem;
        /*margin-bottom:2rem;*/
    }

    .mud-grid {
        width: 100%;
    }
}


/* Estilo SideBar y MainLayout */
/*se hicieron cambios*/


.layout {
    z-index: 1;
    overflow-x: visible !important;
}

    .layout .header {
        padding: 10px;
    }

    .layout .content {
        padding: 12px 10px;
    }

    .layout .footer {
        text-align: center;
        margin-top: auto;
        margin-bottom: 20px;
        padding: 20px;
    }

.sidebar {
    color: #7d84ab;
    /*overflow-x: hidden !important;*/
    position: relative;
}

    .sidebar::-webkit-scrollbar-thumb {
        border-radius: 4px;
    }

    .sidebar:hover::-webkit-scrollbar-thumb {
        background-color: #1a4173;
    }

    .sidebar::-webkit-scrollbar {
        width: 6px;
        background-color: #0c1e35;
    }

    .sidebar .image-wrapper {
        overflow: hidden;
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;
        z-index: 1;
        display: none;
    }

        .sidebar .image-wrapper > img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            object-position: center;
        }

    .sidebar.has-bg-image .image-wrapper {
        display: block;
    }

    .sidebar .sidebar-layout {
        height: auto;
        min-height: 100%;
        display: flex;
        flex-direction: column;
        position: relative;
        background-color: white;
        z-index: 2;
        border-right: 1px solid #E4E4E4;
    }


        .sidebar .sidebar-layout .sidebar-header {
            height: 100px;
            min-height: 100px;
            display: flex;
            align-items: center;
            padding: 0 20px;
        }

            .sidebar .sidebar-layout .sidebar-header > span {
                overflow: hidden;
                white-space: nowrap;
                text-overflow: ellipsis;
            }

        .sidebar .sidebar-layout .sidebar-content {
            flex-grow: 1;
        }

        .sidebar .sidebar-layout .sidebar-footer {
            margin-top: auto;
            height: auto;
            min-height: 0;
            display: flex;
            align-items: flex-end;
            padding: 0 50px 12px;
        }

            .sidebar .sidebar-layout .sidebar-footer > span {
                overflow: hidden;
                white-space: nowrap;
                text-overflow: ellipsis;
            }

@keyframes swing {
    0%, 30%, 50%, 70%, 100% {
        transform: rotate(0deg);
    }

    10% {
        transform: rotate(10deg);
    }

    40% {
        transform: rotate(-10deg);
    }

    60% {
        transform: rotate(5deg);
    }

    80% {
        transform: rotate(-5deg);
    }
}

.layout .sidebar .menu ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.layout .sidebar .menu .menu-header {
    font-weight: 600;
    padding: 10px 10px;
    font-size: 0.8em;
    letter-spacing: 2px;
    transition: opacity 0.3s;
    opacity: 0.5;
}

.layout .sidebar .menu .menu-item a {
    display: flex;
    align-items: center;
    height: 60px;
    font-size: 17px;
    padding: 0 20px;
    color: #0054C2; /*color de los botones del sidebar*/
}

    .layout .sidebar .menu .menu-item a .menu-icon {
        font-size: 1.2em;
        width: 35px;
        min-width: 35px;
        height: 35px;
        line-height: 35px;
        text-align: center;
        display: inline-block;
        margin-right: 10px;
        border-radius: 2px;
        transition: color 0.3s;
    }

        .layout .sidebar .menu .menu-item a .menu-icon i {
            display: inline-block;
        }

    .layout .sidebar .menu .menu-item a .menu-title {
        font-size: 0.9em;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        flex-grow: 1;
        transition: color 0.3s;
    }

    .layout .sidebar .menu .menu-item a .menu-prefix,
    .layout .sidebar .menu .menu-item a .menu-suffix {
        display: inline-block;
        padding: 5px;
        opacity: 1;
        transition: opacity 0.3s;
    }

    .layout .sidebar .menu .menu-item a:hover .menu-title {
        color: #5CA3FF; /*Color de los iconos */
    }

    .layout .sidebar .menu .menu-item a:hover .menu-icon {
        color: #5CA3FF; /*Hover de los iconos*/
    }

        .layout .sidebar .menu .menu-item a:hover .menu-icon i {
            animation: swing ease-in-out 0.5s 1 alternate;
        }

    .layout .sidebar .menu .menu-item a:hover::after {
        border-color: #0054C2 !important;
    }

.layout .sidebar .menu .menu-item.sub-menu {
    position: relative;
}

    .layout .sidebar .menu .menu-item.sub-menu > a::after {
        content: "";
        transition: transform 0.3s;
        border-right: 2px solid currentcolor;
        border-bottom: 2px solid currentcolor;
        width: 5px;
        height: 5px;
        transform: rotate(-45deg);
    }

    .layout .sidebar .menu .menu-item.sub-menu > .sub-menu-list {
        padding-left: 20px;
        display: none;
        overflow: hidden;
        z-index: 999;
    }

    .layout .sidebar .menu .menu-item.sub-menu.open > a {
        color: #dee2ec;
    }

        .layout .sidebar .menu .menu-item.sub-menu.open > a::after {
            transform: rotate(45deg);
        }

.layout .sidebar .menu .menu-item.active > a .menu-title {
    color: #dee2ec;
}

.layout .sidebar .menu .menu-item.active > a::after {
    border-color: #dee2ec;
}

.layout .sidebar .menu .menu-item.active > a .menu-icon {
    color: #dee2ec;
}

.layout .sidebar .menu > ul > .sub-menu > .sub-menu-list {
    background-color: #0b1a2c;
}

.layout .sidebar .menu.icon-shape-circle .menu-item a .menu-icon, .layout .sidebar .menu.icon-shape-rounded .menu-item a .menu-icon, .layout .sidebar .menu.icon-shape-square .menu-item a .menu-icon {
    background-color: #0b1a2c;
}

.layout .sidebar .menu.icon-shape-circle .menu-item a .menu-icon {
    border-radius: 50%;
}

.layout .sidebar .menu.icon-shape-rounded .menu-item a .menu-icon {
    border-radius: 4px;
}

.layout .sidebar .menu.icon-shape-square .menu-item a .menu-icon {
    border-radius: 0;
}

.layout .sidebar:not(.collapsed) .menu > ul > .menu-item.sub-menu > .sub-menu-list {
    visibility: visible !important;
    position: static !important;
    transform: translate(0, 0) !important;
}

.layout .sidebar.collapsed .menu > ul > .menu-header {
    opacity: 0;
}

.layout .sidebar.collapsed .menu > ul > .menu-item > a .menu-prefix,
.layout .sidebar.collapsed .menu > ul > .menu-item > a .menu-suffix {
    opacity: 0;
}

.layout .sidebar.collapsed .menu > ul > .menu-item.sub-menu > a::after {
    content: "";
    width: 5px;
    height: 5px;
    background-color: currentcolor;
    border-radius: 50%;
    display: inline-block;
    position: absolute;
    right: 10px;
    top: 50%;
    border: none;
    transform: translateY(-50%);
}

.layout .sidebar.collapsed .menu > ul > .menu-item.sub-menu > a:hover::after {
    background-color: #dee2ec;
}

.layout .sidebar.collapsed .menu > ul > .menu-item.sub-menu > .sub-menu-list {
    /*transition: none !important;*/
    width: 200px;
    margin-left: 3px !important;
    border-radius: 4px;
    display: block !important;
}

.layout .sidebar.collapsed .menu > ul > .menu-item.active > a::after {
    background-color: #dee2ec;
}

.layout .sidebar.has-bg-image .menu.icon-shape-circle .menu-item a .menu-icon, .layout .sidebar.has-bg-image .menu.icon-shape-rounded .menu-item a .menu-icon, .layout .sidebar.has-bg-image .menu.icon-shape-square .menu-item a .menu-icon {
    background-color: rgba(11, 26, 44, 0.6);
}

.layout .sidebar.has-bg-image:not(.collapsed) .menu > ul > .sub-menu > .sub-menu-list {
    background-color: rgba(11, 26, 44, 0.6);
    transition: 0.3s;
}

.layout.rtl .sidebar .menu .menu-item a .menu-icon {
    margin-left: 10px;
    margin-right: 0;
}

.layout.rtl .sidebar .menu .menu-item.sub-menu > a::after {
    transform: rotate(135deg);
}

.layout.rtl .sidebar .menu .menu-item.sub-menu > .sub-menu-list {
    padding-left: 0;
    padding-right: 20px;
}

.layout.rtl .sidebar .menu .menu-item.sub-menu.open > a::after {
    transform: rotate(45deg);
}

.layout.rtl .sidebar.collapsed .menu > ul > .menu-item.sub-menu a::after {
    right: auto;
    left: 10px;
}

.layout.rtl .sidebar.collapsed .menu > ul > .menu-item.sub-menu > .sub-menu-list {
    margin-left: -3px !important;
}



body {
    margin: 0;
    height: 100vh;
    font-family: "Poppins", sans-serif;
    color: #3f4750;
    font-size: 0.9rem;
}

a {
    text-decoration: none;
}

@media (max-width: 576px) {
    #btn-collapse {
        display: none;
    }
}

.layout .sidebar .pro-sidebar-logo {
    display: flex;
    align-items: center;
}

.layout.fixed-sidebar .sidebar {
    overflow-x: hidden
}

.layout .sidebar .pro-sidebar-logo > div {
    width: 40px;
    min-width: 40px;
    height: 35px;
    min-height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    color: white;
    font-size: 24px;
    font-weight: 700;
    background-color: #F2F2F3;
    margin-right: 10px;
    overflow: hidden;
}


.layout .sidebar .pro-sidebar-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}


.layout .sidebar .pro-sidebar-logo > h5 {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 20px;
    line-height: 30px;
    transition: opacity 0.3s;
    opacity: 1;
}

.layout .sidebar .footer-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 0.8em;
    padding: 20px 0;
    border-radius: 8px;
    width: 180px;
    min-width: 190px;
    margin: 0 auto;
    background-color: white;
}

    .layout .sidebar .footer-box img.react-logo {
        width: 40px;
        height: 40px;
        margin-bottom: 10px;
    }

    .layout .sidebar .footer-box a {
        color: #fff;
        font-weight: 600;
        margin-bottom: 10px;
    }

.layout .sidebar .sidebar-collapser {
    transition: left, right, 0.3s;
    position: fixed;
    left: 260px;
    top: 10px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #0054C2; /*Color del Boton de Colapso*/
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-align: center;
    align-items: center;
    justify-content: center;
    font-size: 1.2em;
    transform: translateX(50%);
    z-index: 111;
    cursor: pointer;
    color: white;
    box-shadow: 1px 1px 4px #0c1e35;
}

.layout .sidebar .sidebar-collapsed .pro-sidebar-logo .img {
    width: 50%;
    height: 50%;
    object-fit: contain;
}

.layout .sidebar.collapsed .pro-sidebar-logo > h5 {
    opacity: 0;
}

.layout .sidebar.collapsed .footer-box {
    display: none;
}

.layout .sidebar.collapsed .sidebar-collapser {
    left: 80px;
}

    .layout .sidebar.collapsed .sidebar-collapser i {
        transform: rotate(180deg);
    }

.layout .sidebar.collapsed .pro-sidebar-logo {
    width: 40px;
    height: 40px;
    margin: 0 auto;
}

.badge {
    display: inline-block;
    padding: 0.25em 0.4em;
    font-size: 75%;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: 0.25rem;
    color: #fff;
    background-color: #6c757d;
}

    .badge.primary {
        background-color: #ab2dff;
    }

    .badge.secondary {
        background-color: #079b0b;
    }

.sidebar-toggler {
    position: absolute;
    right: 20px;
    top: 20px;
    z-index: 10;
    /*cursor:pointer;*/
}

.social-links a {
    margin: 0 10px;
    color: #3f4750;
}



.sidebar.collapsed {
    overflow: visible !important;
}

.layout .sidebar.collapsed .menu > ul > .menu-item.sub-menu.open > .sub-menu-list {
    position: absolute;
    left: 70px;
    top: 0;
    transform: translateY(calc(-50% + 25px));
}


/*Tareas CSS*/

/* Estilos para mejorar la apariencia general */
.custom-table {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08) !important;
}

    .custom-table .mud-table-head th {
        background-color: var(--mud-palette-primary-lighten);
        color: white;
        font-weight: 600;
        text-transform: uppercase;
        font-size: 0.85rem;
    }

    .custom-table .mud-table-row:hover {
        background-color: var(--mud-palette-primary-lighten1) !important;
        transition: background-color 0.2s;
    }

.custom-drawer {
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
    box-shadow: -8px 0 32px rgba(0,0,0,0.15) !important;
    background: var(--mud-palette-background-grey);
}

.custom-fab {
    box-shadow: 0 6px 20px rgba(33, 150, 243, 0.4) !important;
    transition: all 0.3s ease;
}

    .custom-fab:hover {
        transform: translateY(-4px);
        box-shadow: 0 12px 30px rgba(33, 150, 243, 0.5) !important;
    }

.mud-chip {
    font-weight: 500;
}


/*CSS DE LOS DIALOGOS*/

.responsive-dialog {
    min-width: 280px;
}

@media (max-width: 600px) {
    .responsive-dialog {
        margin: 0;
    }
}

@media (min-width: 600px) and (max-width: 1024px) {
    .responsive-dialog {
        max-width: 90vw;
    }
}

@media (min-width: 1024px) {
    .responsive-dialog {
        max-width: 60vw;
    }
}

@media (min-width: 1600px) {
    .responsive-dialog {
        max-width: 40vw;
    }
}

/*CSS DESCRIPCION*/
.descripcion-field textarea {
    min-height: 140px;
}

@media (min-width: 600px) {
    .descripcion-field textarea {
        min-height: 180px;
    }
}

@media (min-width: 1024px) {
    .descripcion-field textarea {
        min-height: 220px;
    }
}

@media (min-width: 1600px) {
    .descripcion-field textarea {
        min-height: 260px;
    }
}



/*CSS DE HOME*/

.home-container {
    min-height: calc(100vh - 64px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 1.5rem;
}

.home-title {
    font-size: clamp(1.5rem, 4vw, 2.4rem);
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #0054C2;
}

.home-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.2rem);
    color: #6b7280;
    margin-bottom: 1.5rem;
    max-width: 600px;
}

.home-image-wrapper {
    width: 100%;
    max-width: 420px;
    margin-bottom: 1.5rem;
}

.home-image {
    width: 100%;
    height: auto;
}

.home-button {
    margin-top: 0.5rem;
}


/*CSS DE CARGA*/

.svg-loader-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.85);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.svg-loader {
    width: 120px;
    height: auto;
}


/*CSS DE LA CONVERSACION*/


.chat-fullscreen {
    min-height: 100vh;
    max-height: 100vh;
    overflow: hidden;
}

.header-sticky {
    position: sticky;
    top: 0;
    z-index: 20;
}

.messages-container {
    padding-bottom: 1rem;
}

.sticky-bottom {
    position: sticky;
    bottom: 0;
    z-index: 15;
}

.chat-bubble {
    border-radius: 8.5px !important;
    padding: 8px 12px !important;
    max-width: 100% !important;
    margin: 2px 8px !important;
    word-wrap: break-word;
}

.adjuntos-container {
    -webkit-overflow-scrolling: touch;
}

.adjunto-item {
    background: white;
    border-radius: 8px;
    padding: 6px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}

@media (min-width: 1200px) {
    .messages-container {
        padding: 2rem 15% !important;
    }

    .chat-bubble {
        max-width: 100% !important;
        min-width: 110% !important;
    }
}

@media (max-width: 600px) {
    .input-bar {
        padding: 0.75rem !important;
    }

    .adjuntos-container {
        max-height: 110px;
    }
}


.limpiar-adjuntos-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    cursor: pointer;
    z-index: 20;
}



/*Table Responsive*/

.ticket-title {
    font-size: 1.05rem;
    font-weight: 500;
    line-height: 1.3;
    color: #111;
}

.ticket-subtitle {
    font-size: 0.85rem;
    color: #555;
    margin-top: 4px;
}

.priority-dot {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin-right: 8px;
    vertical-align: middle;
}

.date-text {
    font-size: 0.82rem;
    color: #777;
    white-space: nowrap;
}

.chat-icon {
    color: #075e54;
}

.desktop-table {
    display: table;
}

.mobile-list {
    display: none;
}

@media (max-width: 599px) {
    .desktop-table {
        display: none !important;
    }

    .mobile-list {
        display: block !important;
    }

    .mud-table-toolbar {
        display: none;
    }
}

@media (min-width: 600px) {
    .mud-table .mud-table-head th {
        font-weight: bold;
        color: #333;
    }

    .mud-table-row:hover {
        background-color: #f8f9fa;
    }
}



.mud-drawer {
    transition: none !important;
}

.mud-drawer-content {
    transition: none !important;
}

.mud-overlay {
    transition: none !important;
}


.mensaje-container {
    width: 100%;
    max-height: 30vh;
    overflow-y: auto;
    padding-right: 6px;
}


.chat-input {
    position: sticky;
    bottom: 0;
    width: 100%;
    background: white;
    z-index: 20;
    padding: 12px;
    border-top: 1px solid #e0e0e0;
}

@media (max-width: 768px) {
    .chat-input {
        position: fixed;
        bottom: env(safe-area-inset-bottom);
        left: 0;
        right: 0;
    }
}



@media (max-width: 768px) {
    .mud-grid .mud-item {
        flex: 0 0 100% !important;
        max-width: 100% !important;
        justify-content: flex-start !important;
    }

    .mud-grid .mud-item {
        margin-bottom: 1rem !important;
    }
}

.chat-wrapper {
    display: flex;
    flex-direction: column;
    height: 50%;
}

.chat-messages {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-right: 8px;
}

@media (max-width: 768px) {
    .chat-messages {
        max-height: calc(90vh - 120px);
        margin-bottom: 9rem;
    }
}

@media (min-width: 769px) {
    .chat-messages {
        max-height: calc(100vh - 320px);
    }
}



@media (max-width:768px) {
    .nocomments {
        margin-bottom: 12rem !important;
    }
}


/*CSS DEL DIALOGO */

.confirm-dialog {
    padding: 1.5rem;
    max-width: 100%;
}

.dialog-title {
    font-weight: bold;
    text-align: center;
}

.dialog-description {
    margin-top: 1rem;
    display: block;
}

.dialog-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

@media (max-width: 600px) {


    .dialog-buttons {
        flex-direction: row;
    }

    .dialog-btn {
        width: 100%;
    }
}


.tooltip-blanco + .tooltip .tooltip-inner {
    background-color: white;
    color: black;
    border: 1px solid #ddd;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.tooltip-blanco + .tooltip.bs-tooltip-left .tooltip-arrow::before {
    border-left-color: white;
}

.comentario-limitado {
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.comentario-expandido {
    display: block;
}

/* Badge: colaborador-img-sm y menciones (addgroup) */
.mensaje-html .colaborador-img-sm,
.descripcion-html .colaborador-img-sm,
.mensaje-html img.colaborador-img-sm,
.descripcion-html img.colaborador-img-sm,
.mensaje-html .mencion-badge,
.descripcion-html .mencion-badge,
.mensaje-html img[class*="mencion"],
.descripcion-html img[class*="mencion"] {
    max-width: 50px !important;
    max-height: 25px !important;
    width: auto !important;
    height: auto !important;
    object-fit: cover;
    border-radius: 40px;
    margin: 4px 6px 4px 0;
    display: inline-block;
    vertical-align: middle;
    font-size: 0px;
}

/* Imágenes adjuntos (sin clase o con estilos inline): más anchas y altas que badges */
.mensaje-html img:not(.colaborador-img-sm):not([class*="mencion"]):not(.doc-icon),
.descripcion-html img:not(.colaborador-img-sm):not([class*="mencion"]):not(.doc-icon) {
    max-width: 500px !important;
    max-height: 200px !important;
    width: auto !important;
    height: auto !important;
    object-fit: cover;
    border-radius: 8px;
    margin: 4px 6px 4px 0;
    display: inline-block;
    vertical-align: middle;
    font-size:0px;
}
/* Contenedor para adjuntos + usuarios: alineación */
.mensaje-html .adjuntos-inline,
.descripcion-html .adjuntos-inline {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin: 4px 0;
    vertical-align: middle;
}

.mensaje-html a.img-zoomable,
.descripcion-html a.img-zoomable {
    cursor: pointer;
    display: inline-block;
}

.mensaje-html a.img-zoomable img,
.descripcion-html a.img-zoomable img {
    transition: opacity 0.2s ease;
}

.mensaje-html a.img-zoomable:hover img,
.descripcion-html a.img-zoomable:hover img {
    opacity: 0.9;
}

/* Contenedor de contenido para alinear texto e imágenes */
.mensaje-html,
.descripcion-html {
    line-height: 1.5;
    word-wrap: break-word;
}

.mensaje-html p,
.descripcion-html p,
.mensaje-html div,
.descripcion-html div {
    margin-bottom: 0.5em;
}

.mensaje-html p:last-child,
.descripcion-html p:last-child {
    margin-bottom: 0;
}

/* Enlaces a documentos: tamaño según tipo, abrir en nueva pestaña */
.doc-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 4px 8px 4px 0;
    padding: 4px 8px;
    border-radius: 6px;
    background: #f5f5f5;
    vertical-align: middle;
}

.doc-link .doc-icon {
    width: 22px;
    height: 22px;
    object-fit: contain;
    flex-shrink: 0;
}

.doc-link a {
    color: #0054C2 !important;
    text-decoration: underline !important;
    font-size: 0.875rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}

.doc-link a:hover {
    color: #003E91 !important;
}

/* Tamaños por tipo de documento */
.doc-link-pdf .doc-icon { width: 24px; height: 24px; }
.doc-link-word .doc-icon { width: 24px; height: 24px; }
.doc-link-excel .doc-icon { width: 24px; height: 24px; }
.doc-link-image .doc-icon { width: 20px; height: 20px; }
.doc-link-video .doc-icon { width: 24px; height: 24px; }

/* Lightbox zoom para imágenes */
.img-lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.img-lightbox-content {
    max-width: 95vw;
    max-height: 95vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}

.img-lightbox-toolbar {
    position: absolute;
    top: 16px;
    right: 16px;
    display: flex;
    gap: 8px;
    z-index: 100000;
}

.img-lightbox-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,0.2);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: background 0.2s;
}

.img-lightbox-btn:hover {
    background: rgba(255,255,255,0.35);
}


.drop-zone {
    border: 2px dashed #bdbdbd;
    border-radius: 10px;
    padding: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #fafafa;
}

    .drop-zone.dragging {
        border-color: #0054C2;
        background: #eef4ff;
    }

.file-input-hidden {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}


/*CSS COUNT*/

.cuenta-container {
    display: flex;
    justify-content: center;
    padding: 20px;
}

.cuenta-card {
    width: 100%;
    max-width: 420px;
    padding: 25px;
    border-radius: 14px;
}

.avatar-container {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.avatar-img {
    width: 130px;
    height: 128px;
    object-fit: cover;
}

@media (min-width: 600px) {
    .avatar-img {
        width: 170px;
        height: 200px;
    }
}

@media (min-width: 960px) {
    .avatar-img {
        width: 250px;
        height: 240px;
    }
}


/*Holver de Css de los botones*/

.descripcion-cell {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

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

.row-action-btn {
    opacity: 0;
    transition: all 0.2s ease;
}

.mud-table-row:hover .row-action-btn {
    opacity: 1;
}

/* UI de reconexion para Blazor Server */
#components-reconnect-modal {
    position: fixed;
    inset: 0;
    z-index: 20000;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 20% 10%, rgba(59, 130, 246, 0.18), transparent 45%), rgba(2, 6, 23, 0.42);
    backdrop-filter: blur(5px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

    #components-reconnect-modal.components-reconnect-show,
    #components-reconnect-modal.components-reconnect-failed,
    #components-reconnect-modal.components-reconnect-rejected,
    #components-reconnect-modal.reconnect-timeout,
    #components-reconnect-modal[style*="display: block"] {
        opacity: 1;
        visibility: visible;
        pointer-events: all;
    }

.reconnect-card {
    width: min(92vw, 380px);
    background: linear-gradient(180deg, #ffffff, #f8fbff);
    border-radius: 16px;
    box-shadow: 0 16px 40px rgba(2, 6, 23, 0.32);
    border: 1px solid rgba(255, 255, 255, 0.85);
    padding: 1.15rem 1.35rem;
    text-align: center;
}

.reconnect-spinner {
    width: 36px;
    height: 36px;
    margin: 0 auto 0.9rem;
    border-radius: 50%;
    border: 3px solid #dbeafe;
    border-top-color: #0054C2;
    animation: reconnect-spin 0.85s linear infinite;
}

.reconnect-text {
    color: #0f172a;
    font-weight: 600;
    font-size: 0.94rem;
    line-height: 1.35;
}

.reconnect-failed,
.reconnect-btn {
    display: none;
}

#components-reconnect-modal.components-reconnect-show .reconnect-trying {
    display: block;
}

#components-reconnect-modal.components-reconnect-show .reconnect-spinner {
    display: block;
}

#components-reconnect-modal.components-reconnect-failed .reconnect-trying,
#components-reconnect-modal.components-reconnect-rejected .reconnect-trying,
#components-reconnect-modal.reconnect-timeout .reconnect-trying,
#components-reconnect-modal.components-reconnect-failed .reconnect-spinner,
#components-reconnect-modal.components-reconnect-rejected .reconnect-spinner,
#components-reconnect-modal.reconnect-timeout .reconnect-spinner {
    display: none;
}

#components-reconnect-modal.components-reconnect-failed .reconnect-failed,
#components-reconnect-modal.components-reconnect-rejected .reconnect-failed,
#components-reconnect-modal.reconnect-timeout .reconnect-failed,
#components-reconnect-modal.components-reconnect-failed .reconnect-btn,
#components-reconnect-modal.components-reconnect-rejected .reconnect-btn,
#components-reconnect-modal.reconnect-timeout .reconnect-btn {
    display: block;
}

.reconnect-btn {
    margin: 0.95rem auto 0;
    border: 0;
    border-radius: 9px;
    padding: 0.52rem 1.05rem;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(180deg, #1d6ee8, #0054C2);
    cursor: pointer;
    box-shadow: 0 6px 14px rgba(0, 84, 194, 0.35);
}

    .reconnect-btn:hover {
        filter: brightness(1.05);
    }

@keyframes reconnect-spin {
    to {
        transform: rotate(360deg);
    }
}
