/* ============================================== */
/* ESTILOS PERSONALIZADOS MUYHUMANO              */
/* Paleta: Naranja #ff4600, Verde #12b338,       */
/*         Azul Oscuro #127cb3, Azul Claro #0dacff */
/* ============================================== */

/* ─────────────────────────────────────────────── */
/* TABLAS DATATABLES                              */
/* ─────────────────────────────────────────────── */
table.dataTable {
    border-collapse: collapse !important;
    border: 1px solid #e9ecef !important;
}

table.dataTable td,
table.dataTable th {
    border: 1px solid #e9ecef !important;
}

table.dataTable .td-actions {
    display: flex;
    border: none !important;
    justify-content: end;
}

/* ─────────────────────────────────────────────── */
/* TEMA GENERAL                                   */
/* ─────────────────────────────────────────────── */
.app-theme-green.app-container {
    background: #f8fafc;
}

/* ─────────────────────────────────────────────── */
/* SIDEBAR - FONDO CON GRADIENTE Y PATRÓN SVG    */
/* ─────────────────────────────────────────────── */
.app-theme-green .app-sidebar {
    background:
        /* Patrón SVG sutil de ondas */
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 320'%3E%3Cpath fill='%23ffffff' fill-opacity='0.03' d='M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,154.7C960,171,1056,181,1152,165.3C1248,149,1344,107,1392,85.3L1440,64L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z'%3E%3C/path%3E%3C/svg%3E") bottom/100% auto no-repeat,
        /* Patrón de círculos sutiles */
        url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='30' cy='30' r='1.5' fill='%23ffffff' fill-opacity='0.05'/%3E%3C/svg%3E"),
        /* Gradiente principal verde */
        linear-gradient(180deg, #12b338 0%, #0d9a2e 50%, #087a23 100%);
}

/* Efecto de brillo sutil en la parte superior */
.app-theme-green .app-sidebar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 150px;
    background: linear-gradient(180deg, rgba(255,255,255,0.1) 0%, transparent 100%);
    pointer-events: none;
}

/* Línea decorativa naranja en el borde derecho */
.app-theme-green .app-sidebar::after {
    content: '';
    position: absolute;
    top: 60px;
    right: 0;
    width: 3px;
    height: calc(100% - 60px);
    background: linear-gradient(180deg, #ff4600 0%, #ff4600 30%, transparent 100%);
    pointer-events: none;
}


/* ─────────────────────────────────────────────── */
/* SIDEBAR - MENÚ VERTICAL                        */
/* ─────────────────────────────────────────────── */
.app-theme-green .vertical-nav-menu {
    position: relative;
    z-index: 2;
}

.app-theme-green .vertical-nav-menu li a {
    color: #ffffff;
    background: transparent;
    font-weight: 500;
    border-radius: 8px;
    margin: 2px 0;
    transition: all 0.2s ease;
}

.app-theme-green .vertical-nav-menu li a:hover {
    color: #12b338;
    background: rgba(255, 255, 255, 0.95);
    font-weight: 500;
    transform: translateX(3px);
}

.app-theme-green .vertical-nav-menu li a.mm-active {
    color: #087a23;
    background: #ffffff;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Iconos del menú */
.app-theme-green .vertical-nav-menu li a i.metismenu-icon {
    opacity: 0.9;
}

.app-theme-green .vertical-nav-menu li a:hover i.metismenu-icon,
.app-theme-green .vertical-nav-menu li a.mm-active i.metismenu-icon {
    opacity: 1;
}

/* Submenús */
.app-theme-green .vertical-nav-menu ul {
    background: transparent;
    margin: 4px 0;
    padding: 0 0 0 0.5rem !important;
}

/* Ocultar la línea vertical del base CSS */
.app-theme-green .vertical-nav-menu ul::before {
    display: none;
}

.app-theme-green .vertical-nav-menu ul > li > a {
    color: rgba(255, 255, 255, 0.85);
    font-size: 13px;
    padding-left: 1rem;
    border-left: 2px solid transparent;
    border-radius: 8px;
    margin-left: 0.5rem;
}

.app-theme-green .vertical-nav-menu ul > li > a:hover {
    color: #12b338;
    background: rgba(255, 255, 255, 0.9);
    border-left-color: #12b338;
}

.app-theme-green .vertical-nav-menu ul > li > a.mm-active {
    color: #087a23;
    background: #ffffff;
    border-left-color: #12b338;
    font-weight: 600;
}

/* Submenús anidados (segundo nivel) */
.app-theme-green .vertical-nav-menu ul ul > li > a {
    padding-left: 1.5rem;
    font-size: 12px;
}

/* Encabezados de sección */
.app-theme-green .app-sidebar__heading {
    color: rgba(255, 255, 255, 0.7) !important;
    font-size: 11px;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 0.75rem 1.5rem 0.5rem;
    margin-top: 0.5rem;
}

/* ─────────────────────────────────────────────── */
/* SIDEBAR - SCROLLBAR                            */
/* ─────────────────────────────────────────────── */
.scrollbar-sidebar {
    position: relative;
    padding-bottom: 20px;
    overflow-y: auto;
    overflow-x: hidden;
    max-height: calc(100vh - 60px);
}

.scrollbar-sidebar::-webkit-scrollbar {
    width: 4px;
}

.scrollbar-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.scrollbar-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.scrollbar-sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.35);
}

.scrollbar-sidebar .btn-sidebar {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
}

.logo-mh-sidebar {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 50%;
}

/* ─────────────────────────────────────────────── */
/* HEADER                                         */
/* ─────────────────────────────────────────────── */
.app-theme-green .app-header {
    background: linear-gradient(90deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

/* Línea decorativa multicolor en el header */
.app-theme-green .app-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg,
        #ff4600 0%, #ff4600 20%,
        #12b338 20%, #12b338 40%,
        #127cb3 40%, #127cb3 60%,
        #0dacff 60%, #0dacff 80%,
        transparent 80%);
    pointer-events: none;
}

/* Info del usuario en el header */
.app-theme-green .header-user-info .widget-heading {
    color: #1f2937;
    font-weight: 600;
    font-size: 14px;
}

.app-theme-green .header-user-info .widget-subheading {
    color: #6b7280;
    font-size: 11px;
    letter-spacing: 0.5px;
}

/* Dropdown del usuario */
.app-theme-green .dropdown-menu-header .dropdown-menu-header-inner {
    background: linear-gradient(135deg, #12b338 0%, #087a23 100%) !important;
}

.app-theme-green .dropdown-menu-header .widget-heading {
    color: #ffffff;
    font-weight: 600;
}

.app-theme-green .dropdown-menu-header .widget-subheading {
    color: rgba(255, 255, 255, 0.8);
}

/* Botón del drawer */
.app-theme-green .btn-icon-only.btn-link {
    color: #127cb3;
    transition: all 0.2s ease;
}

.app-theme-green .btn-icon-only.btn-link:hover {
    color: #0dacff;
    transform: scale(1.1);
}

/* ─────────────────────────────────────────────── */
/* FOOTER                                         */
/* ─────────────────────────────────────────────── */
.app-theme-green .app-footer .app-footer__inner {
    background: linear-gradient(90deg, #1f2937 0%, #374151 100%);
    border-top: 3px solid #12b338;
    border-left: none;
    color: rgba(255, 255, 255, 0.8);
}

.app-theme-green .app-footer .app-footer__inner .nav-item {
    color: rgba(255, 255, 255, 0.8);
}

/* Fixed Footer - Contenido con scroll por detrás */
.fixed-footer .app-footer {
    z-index: 15; /* Por encima del contenido */
}

.fixed-footer.fixed-header .app-main__outer {
    height: calc(100vh - 60px); /* 100vh - altura del header */
    overflow: hidden;
    padding-bottom: 0; /* Removemos el padding-bottom del base.css */
}

.fixed-footer .app-main__inner {
    overflow-y: auto;
    height: 100%;
    padding-bottom: 80px; /* Espacio para el footer + margen */
}

/* Ajuste del footer cuando sidebar está cerrado */
.closed-sidebar.fixed-footer .app-footer .app-footer__inner {
    margin-left: 80px !important;
}

/* ─────────────────────────────────────────────── */
/* PAGE TITLE                                     */
/* ─────────────────────────────────────────────── */
.app-theme-green .app-page-title {
    background: rgba(255, 255, 255, 0.45);
}

/* ─────────────────────────────────────────────── */
/* LOGO EN HEADER                                 */
/* ─────────────────────────────────────────────── */
.app-theme-green.fixed-header .app-header__logo {
    background: transparent;
}

.app-theme-green .app-header__logo .logo-src {
    background: url("../../images/logo-muyhumano-lineal.png") center/contain no-repeat;
}
