﻿:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
}
/* Estilos específicos para edición de catálogos */
.form-switch .form-check-input {
    width: 3em;
    height: 1.5em;
}

    .form-switch .form-check-input:checked {
        background-color: #198754;
        border-color: #198754;
    }

.list-group-item {
    border: none;
    padding: 10px 0;
}

.btn-group-sm > .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Estilos para la tabla de categorías */
#categoriasTable th {
    font-weight: 600;
    background-color: #f8f9fa;
}

#categoriasTable td {
    vertical-align: middle;
}
body {
    padding-top: 56px;
    background-color: #f8f9fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.navbar-brand {
    font-weight: bold;
    font-size: 1.2rem;
}

.sidebar {
    position: fixed;
    top: 56px;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 20px 0;
    overflow-x: hidden;
    overflow-y: auto;
    border-right: 1px solid #dee2e6;
    background-color: #fff;
    width: 220px;
}

    .sidebar .nav-link {
        font-weight: 500;
        color: #495057;
        padding: 10px 15px;
        border-radius: 5px;
        margin: 2px 10px;
        transition: all 0.3s;
    }

        .sidebar .nav-link:hover {
            background-color: #e9ecef;
            color: var(--primary-color);
        }

        .sidebar .nav-link.active {
            color: #fff;
            background-color: var(--primary-color);
        }

.main-content {
    margin-left: 220px;
    padding: 20px;
    min-height: calc(100vh - 56px);
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        position: relative;
        top: 0;
        padding: 10px;
        border-right: none;
        border-bottom: 1px solid #dee2e6;
    }

    .main-content {
        margin-left: 0;
    }
}

.card {
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    border: none;
}

.card-header {
    background-color: #fff;
    border-bottom: 2px solid var(--primary-color);
    font-weight: 600;
    padding: 15px 20px;
}

.stat-card {
    text-align: center;
    padding: 20px;
    border-radius: 10px;
    color: white;
    margin-bottom: 20px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

    .stat-card.primary {
        background: linear-gradient(135deg, var(--primary-color), #0b5ed7);
    }

    .stat-card.success {
        background: linear-gradient(135deg, var(--success-color), #157347);
    }

    .stat-card.warning {
        background: linear-gradient(135deg, var(--warning-color), #e0a800);
    }

    .stat-card.info {
        background: linear-gradient(135deg, var(--info-color), #0ba8d0);
    }

    .stat-card.danger {
        background: linear-gradient(135deg, var(--danger-color), #bb2d3b);
    }

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

.quick-action {
    text-align: center;
    padding: 20px;
    border-radius: 10px;
    background-color: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s;
    cursor: pointer;
    border: 1px solid #e9ecef;
}

    .quick-action:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 15px rgba(0,0,0,0.2);
        border-color: var(--primary-color);
    }

    .quick-action i {
        font-size: 2.5rem;
        margin-bottom: 10px;
        color: var(--primary-color);
    }

    .quick-action h6 {
        font-weight: 600;
        margin-bottom: 5px;
    }

    .quick-action p {
        font-size: 0.85rem;
        color: #6c757d;
        margin: 0;
    }

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

    .btn-primary:hover {
        background-color: #0b5ed7;
        border-color: #0b5ed7;
    }

.table-hover tbody tr:hover {
    background-color: rgba(13, 110, 253, 0.05);
}

.badge {
    font-weight: 500;
    padding: 5px 10px;
}

.page-title {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e9ecef;
}

    .page-title h2 {
        color: #343a40;
        font-weight: 600;
    }

    .page-title p {
        color: #6c757d;
        margin-bottom: 0;
    }

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* Estilos para formularios */
.form-label {
    font-weight: 500;
    color: #495057;
}

.form-control, .form-select {
    border-radius: 8px;
    border: 1px solid #ced4da;
    padding: 10px 15px;
}

    .form-control:focus, .form-select:focus {
        border-color: var(--primary-color);
        box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
    }

/* Estilos para modales */
.modal-header {
    background-color: var(--primary-color);
    color: white;
    border-radius: 10px 10px 0 0;
}

/* Estilos para gráficos */
.chart-container {
    position: relative;
    height: 300px;
    width: 100%;
}
/* layout.css - agregar estas reglas */

/* Tarjetas de acceso rápido */
.card-access {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    border-radius: 12px;
}

    .card-access:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 25px rgba(0,0,0,0.1) !important;
    }

.icon-circle {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

/* Responsive para tarjetas */
@media (max-width: 768px) {
    .icon-circle {
        width: 60px;
        height: 60px;
    }

        .icon-circle i {
            font-size: 1.5rem !important;
        }
}

/* Estilos para el menú móvil */
.mobile-menu-container {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1050;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}

    .mobile-menu-container.show {
        transform: translateX(0);
    }

.mobile-menu-header {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding: 1.5rem;
}

.mobile-menu-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    padding: 0.5rem;
    margin-right: -0.5rem;
}

.mobile-menu-user {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.mobile-user-avatar {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
}

.mobile-user-info h5 {
    color: white;
    margin: 0;
    font-weight: 600;
}

.mobile-user-info small {
    color: rgba(255, 255, 255, 0.8);
}

.mobile-menu-body {
    padding: 1.5rem;
}

.mobile-menu-section {
    margin-bottom: 2rem;
}

.mobile-section-title {
    color: white;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
    padding-left: 0.5rem;
    font-weight: 600;
    opacity: 0.8;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    margin-bottom: 0.75rem;
    text-decoration: none;
    color: white;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

    .mobile-menu-item:hover {
        background: rgba(255, 255, 255, 0.2);
        transform: translateX(5px);
        border-color: rgba(255, 255, 255, 0.3);
    }

    .mobile-menu-item.active {
        background: rgba(255, 255, 255, 0.25);
        border-left: 4px solid #fff;
    }

.mobile-menu-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.mobile-menu-text h6 {
    margin: 0;
    font-weight: 600;
    font-size: 1rem;
}

.mobile-menu-text small {
    font-size: 0.85rem;
    opacity: 0.8;
    display: block;
    margin-top: 0.25rem;
}

.mobile-menu-footer {
    padding: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    margin-top: auto;
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1049;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

    .menu-overlay.show {
        opacity: 1;
        visibility: visible;
    }

/* Botón de menú mejorado */
.navbar-toggler.menu-trigger {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 0.5rem 0.75rem;
    margin-right: 0.5rem;
}

/* Estilos para desktop */
@media (min-width: 768px) {
    .mobile-menu-container {
        display: none !important;
    }

    .menu-overlay {
        display: none !important;
    }

    .navbar-toggler.menu-trigger {
        display: none !important;
    }
}

.sidebar {
    /*background: linear-gradient(180deg, #2c3e50 0%, #1a2530 100%);*/
    min-height: calc(100vh - 56px);
    padding-top: 20px;
}

.nav-link {
    color: #b0b7c3;
    padding: 12px 20px;
    margin: 2px 0;
    border-radius: 5px;
    transition: all 0.3s ease;
}

    .nav-link:hover, .nav-link.active {
        background-color: #3498db;
        color: white;
        transform: translateX(5px);
    }

.nav-category {
    margin-top: 20px;
    margin-bottom: 10px;
}

.main-content {
    padding-top: 20px;
    background-color: #f8f9fa;
    min-height: calc(100vh - 56px);
}

.card {
    border-radius: 10px;
    border: none;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: transform 0.3s ease;
}

    .card:hover {
        transform: translateY(-5px);
        box-shadow: 0 5px 20px rgba(0,0,0,0.15);
    }

.mobile-menu-container {
    background: linear-gradient(180deg, #2c3e50 0%, #1a2530 100%);
    position: fixed;
    top: 0;
    left: -300px;
    width: 280px;
    height: 100vh;
    z-index: 1050;
    transition: left 0.3s ease;
}

    .mobile-menu-container.show {
        left: 0;
    }

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

    .menu-overlay.show {
        opacity: 1;
        visibility: visible;
    }

.mobile-menu-header {
    padding: 20px;
    background: rgba(0,0,0,0.2);
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.mobile-menu-user {
    display: flex;
    align-items: center;
    gap: 15px;
}

.mobile-user-avatar {
    width: 50px;
    height: 50px;
    background: #3498db;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-user-info h5 {
    color: white;
    margin-bottom: 0;
}

.mobile-user-info small {
    color: rgba(255,255,255,0.7);
}

.mobile-menu-close {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s ease;
}

    .mobile-menu-close:hover {
        background: rgba(255,255,255,0.1);
    }

.mobile-menu-body {
    padding: 20px;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
}

.mobile-menu-section {
    margin-bottom: 25px;
}

.mobile-section-title {
    color: rgba(255,255,255,0.5);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
    padding-left: 10px;
}

.mobile-menu-item {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: white;
    text-decoration: none;
    border-radius: 10px;
    margin-bottom: 5px;
    transition: all 0.3s ease;
}

    .mobile-menu-item:hover, .mobile-menu-item.active {
        background: rgba(255,255,255,0.1);
        transform: translateX(5px);
    }

.mobile-menu-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    background: rgba(255,255,255,0.1);
}

    .mobile-menu-icon.bg-primary {
        background-color: #3498db;
    }

    .mobile-menu-icon.bg-success {
        background-color: #2ecc71;
    }

    .mobile-menu-icon.bg-info {
        background-color: #17a2b8;
    }

    .mobile-menu-icon.bg-warning {
        background-color: #f39c12;
    }

    .mobile-menu-icon.bg-danger {
        background-color: #e74c3c;
    }

    .mobile-menu-icon.bg-secondary {
        background-color: #7f8c8d;
    }

.mobile-menu-text h6 {
    margin-bottom: 2px;
    font-size: 15px;
}

.mobile-menu-text small {
    color: rgba(255,255,255,0.7);
    font-size: 12px;
}

.mobile-menu-footer {
    padding: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0,0,0,0.2);
}

.menu-trigger {
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    background: rgba(255,255,255,0.1);
}

.fade-in {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.badge-stock-low {
    background-color: #e74c3c;
    color: white;
}

.badge-stock-normal {
    background-color: #2ecc71;
    color: white;
}

.badge-stock-high {
    background-color: #f39c12;
    color: white;
}