/*
.main-sidebar {
    margin-block-start: 0;
}
*/

/* Estilos para el botón de colapso del menú */
.pc-sidebar-collapse {
    margin-right: auto;
    padding: 10px;
}

/* RESET COMPLETO PARA MENU NORMAL Y COLAPSADO */
/* 1. Estilo base para el sidebar */
.pc-sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1025;
    width: 260px;
    height: 100vh;
    transition: all 0.3s ease;
}

/* 2. Estilo para el sidebar colapsado - completamente oculto */
.pc-sidebar.pc-sidebar-hide {
    width: 0 !important;
    min-width: 0 !important;
    max-width: 0 !important;
    overflow: hidden;
}

/* 3. Ocultar elementos cuando el sidebar está colapsado */
.pc-sidebar.pc-sidebar-hide .pc-caption,
.pc-sidebar.pc-sidebar-hide .pc-item span:not(.pc-micon) {
    display: none !important;
}

/* 4. RESET COMPLETO para el contenedor principal - Menu NORMAL */
body .pc-container {
    position: relative;
    margin-left: 260px;
    min-height: 100vh;
    padding: 0;
    transition: all 0.3s ease;
}

/* 5. RESET COMPLETO para el contenedor principal - Menu COLAPSADO - Ancho completo */
body .pc-sidebar.pc-sidebar-hide ~ .pc-container {
    margin-left: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    padding-left: 0 !important;
    flex: 0 0 100% !important;
}

/* Asegurar que el botón de colapso sea visible en dispositivos móviles */
@media (max-width: 1024px) {
    .pc-header .pc-h-item.pc-sidebar-collapse {
        display: block !important;
    }
}

/* 6. RESET para el header */
body .pc-header {
    position: fixed;
    top: 0;
    right: 0;
    left: 260px;
    z-index: 1024;
    transition: all 0.3s ease;
}

body .pc-sidebar.pc-sidebar-hide ~ .pc-header {
    left: 0 !important;
    width: 100% !important;
}

.desktop-rhin-logo {
    display: block;
    margin: auto;
    /* Se elimina vertical-align porque no funciona con display:block */
    border-style: none;
    max-width: 80%;
}
.required {
    color: red;
}

/* Aplicar fondo gris claro solo en modo claro */
body:not([data-pc-theme="dark"]) .pc-container .pc-content {
    background-color: #f2f2f2;
}

.skeleton {
    background-color: #e2e2e2;
    border-radius: 4px;
    height: 16px;
    width: 100%;
    animation: pulse 1.5s infinite ease-in-out;
}

@keyframes pulse {
    0% { background-color: #e2e2e2; }
    50% { background-color: #cccccc; }
    100% { background-color: #e2e2e2; }
}

.skeleton-row:nth-child(1) .skeleton {
    animation-delay: 0s;
}

.skeleton-row:nth-child(2) .skeleton {
    animation-delay: 0.1s;
}

.skeleton-row:nth-child(3) .skeleton {
    animation-delay: 0.2s;
}

.skeleton-row:nth-child(4) .skeleton {
    animation-delay: 0.3s;
}

.form-skeleton:nth-child(1) .skeleton {
    animation-delay: 0s;
}

.form-skeleton:nth-child(2) .skeleton {
    animation-delay: 0.1s;
}

.form-skeleton:nth-child(3) .skeleton {
    animation-delay: 0.2s;
}

.form-skeleton:nth-child(4) .skeleton {
    animation-delay: 0.3s;
}

.form-skeleton:nth-child(5) .skeleton {
    animation-delay: 0.4s;
}

.form-skeleton:nth-child(6) .skeleton {
    animation-delay: 0.5s;
}

.skeleton-btn {
    display: inline-block;
    height: 20px; /* Altura aproximada de tu botón pequeño */
    width: 100px; /* Ancho aproximado de tu botón pequeño */
    background-color: #e0e0e0;
    border-radius: 4px;
    margin-right: 8px;
    animation: skeleton-loading 1.5s infinite linear;
}

@keyframes skeleton-loading {
    0% {
        background-color: #e0e0e0;
    }
    50% {
        background-color: #c0c0c0;
    }
    100% {
        background-color: #e0e0e0;
    }
}

.skeleton-btn {
    width: 100px;
    height: 30px;
}

.skeleton-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.skeleton-badge {
    width: 60px;
    height: 20px;
}

.skeleton-icon {
    width: 20px;
    height: 20px;
}

.skeleton-row td {
    padding: 1rem;
}

.skeleton td div {
    height: 1rem;
}

.country-selector {
    width: 1rem;
    height: 1rem;
}
.rounded-circle {
    border-radius: 50% !important;
}
.img-fluid {
    max-width: 70%;
    height: auto;
    max-height: 100px;
}
.lang-icon{
    margin: 0 15px;
}

/* background transparente sweetalert */
body .swal2-container.swal2-noanimation,
body .swal2-container.swal2-backdrop-show {
    background: transparent !important;
}

div:where(.swal2-container).swal2-backdrop-show,
div:where(.swal2-container).swal2-noanimation {
    background: transparent !important;
}

.login-logo{
    height: 60px;
}

.pad-bot-20{
    padding-bottom: 20px;
}

.simplebar-offset {
    direction: inherit !important;
    box-sizing: inherit !important;
    resize: none !important;
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    padding: 0;
    margin: 0;
    -webkit-overflow-scrolling: touch;
    width: 260px;
}

/* Estilos para el chat flotante */
.chat-toggle-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    z-index: 999;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.chat-toggle-btn:hover {
    transform: scale(1.05);
}

.floating-chat-container {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 350px;
    height: 450px;
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    z-index: 998;
    opacity: 0;
    transform: translateY(20px) scale(0.9);
    pointer-events: none;
    transition: all 0.3s ease;
}

.floating-chat-container.open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: all;
}

.chat-header {
    padding: 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.chat-body {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-message {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 18px;
    position: relative;
    margin-bottom: 5px;
}

.system-message {
    align-self: flex-start;
    background-color: #f1f1f1;
    color: #333;
    border-bottom-left-radius: 5px;
}

.user-message {
    align-self: flex-end;
    background-color: var(--bs-primary);
    color: white;
    border-bottom-right-radius: 5px;
}

.message-content {
    word-break: break-word;
}

.message-time {
    display: block;
    font-size: 0.7rem;
    margin-top: 5px;
    opacity: 0.7;
    text-align: right;
}

.chat-header h5{
    color: white;
}

.chat-footer {
    padding: 15px;
    border-top: 1px solid #e9e9e9;
}

.chat-input-form {
    display: flex;
    align-items: center;
}

.chat-input-form .form-control {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.chat-input-form .btn {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

/* Modo oscuro */
body[data-pc-theme="dark"] .floating-chat-container {
    background-color: #2c3e50;
    border: 1px solid #34495e;
}

body[data-pc-theme="dark"] .system-message {
    background-color: #34495e;
    color: #ecf0f1;
}

body[data-pc-theme="dark"] .chat-footer {
    border-top: 1px solid #34495e;
}

body[data-pc-theme="dark"] .chat-input-form .form-control {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

/* Animaciones para los mensajes */
@keyframes messageIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chat-message {
    animation: messageIn 0.3s ease forwards;
}

/* Estilos para los botones de opciones */
.chat-options {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 10px;
    width: 100%;
}

.options-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    max-width: 90%;
}

.option-btn {
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 18px;
    padding: 8px 15px;
    text-align: left;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    cursor: pointer;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: normal;
}

.option-btn:hover {
    background-color: #e9ecef;
    border-color: #ced4da;
    transform: translateY(-2px);
}

body[data-pc-theme="dark"] .option-btn {
    background-color: #34495e;
    border-color: #2c3e50;
    color: #ecf0f1;
}

body[data-pc-theme="dark"] .option-btn:hover {
    background-color: #2c3e50;
    border-color: #1a252f;
}

.top-bottom-padding{
    padding-top: 10px;
    padding-bottom: 10px;
}

/* Media queries para dispositivos móviles */
@media (max-width: 767px) {
    .chat-toggle-btn {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
    
    .floating-chat-container {
        bottom: 80px;
        right: 10px;
        width: calc(100% - 20px);
        max-width: 350px;
        height: 60vh;
        max-height: 450px;
    }
    
    .chat-message {
        max-width: 85%;
    }
    
    .option-btn {
        font-size: 0.85rem;
        padding: 7px 12px;
    }
}

/* Para dispositivos muy pequeños */
@media (max-width: 375px) {
    .floating-chat-container {
        width: calc(100% - 20px);
        height: 70vh;
        right: 10px;
        left: 10px;
    }
    
    .chat-body {
        padding: 10px;
    }
    
    .chat-footer {
        padding: 10px;
    }
}