﻿
    .empty-state i {
        font-size: 3rem;
    }

    .empty-state h3 {
        font-size: 1.25rem;
    }


/* ============================================
   LOADING SPINNER RESPONSIVE
   ============================================ */

.spinner-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 3rem;
}

.spinner-border {
    width: 3rem;
    height: 3rem;
    border: 0.25em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border .75s linear infinite;
}

@keyframes spinner-border {
    to { transform: rotate(360deg); }
}

@media (max-width: 576px) {
    .spinner-wrapper {
        padding: 2rem;
    }

    .spinner-border {
        width: 2rem;
        height: 2rem;
    }
}

/* ============================================
   FLOATING ACTION BUTTON RESPONSIVE
   ============================================ */

.fab {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background-color: #007bff;
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 1000;
}

.fab:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0,0,0,0.4);
}

@media (max-width: 576px) {
    .fab {
        bottom: 1rem;
        right: 1rem;
        width: 48px;
        height: 48px;
    }
}

/* ============================================
   TOOLTIP RESPONSIVE
   ============================================ */

.tooltip-custom {
    position: relative;
    display: inline-block;
}

.tooltip-custom .tooltip-text {
    visibility: hidden;
    background-color: #333;
    color: #fff;
    text-align: center;
    padding: 0.5rem;
    border-radius: 0.25rem;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.3s;
    white-space: nowrap;
    font-size: 0.875rem;
}

.tooltip-custom:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

@media (max-width: 576px) {
    .tooltip-custom .tooltip-text {
        white-space: normal;
        max-width: 200px;
    }
}
/* ============================================
   RESPONSIVE PARA MÓDULOS - Digit Soft
   Estilos específicos para gestión de módulos
   ============================================ */

/* ============================================
   HEADER DE MÓDULOS RESPONSIVE
   ============================================ */

.module-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

@media (max-width: 768px) {
    .module-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .module-header .btn-primary {
        width: 100%;
    }
}

/* ============================================
   TARJETAS DE ESTADÍSTICAS RESPONSIVE
   ============================================ */

.stats-card {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.stats-card:hover {
    transform: translateY(-5px);
}

@media (max-width: 576px) {
    .stats-card {
        padding: 1rem;
    }

    .stats-card h6 {
        font-size: 0.9rem;
    }

    .stats-card h3 {
        font-size: 1.5rem;
    }
}

/* ============================================
   FILTROS Y BÚSQUEDA RESPONSIVE
   ============================================ */

.filter-section {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.filter-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: end;
}

@media (max-width: 768px) {
    .filter-section {
        padding: 1rem;
    }

    .filter-row {
        flex-direction: column;
        gap: 0.75rem;
    }

    .filter-row > div {
        width: 100%;
    }

    .filter-row .form-control {
        width: 100%;
    }

    .filter-row .btn {
        width: 100%;
    }
}

/* ============================================
   TABLAS DE DATOS RESPONSIVE
   ============================================ */

.data-table-wrapper {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.data-table-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

@media (max-width: 768px) {
    .data-table-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .data-table-header h5 {
        margin-bottom: 0.5rem;
    }
}

/* Tabla responsive con scroll horizontal */
.table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table {
    min-width: 800px; /* Ancho mínimo para mantener legibilidad */
}

@media (max-width: 768px) {
    .table {
        font-size: 0.875rem;
    }

    .table th,
    .table td {
        padding: 0.5rem;
        white-space: nowrap;
    }
}

/* Tabla stack en móviles (versión vertical) */
@media (max-width: 576px) {
    .table-responsive-mobile {
        border: 0;
    }

    .table-responsive-mobile thead {
        display: none;
    }

    .table-responsive-mobile tr {
        display: block;
        margin-bottom: 1.5rem;
        border: 1px solid #dee2e6;
        border-radius: 8px;
        padding: 1rem;
        background: white;
    }

    .table-responsive-mobile td {
        display: flex;
        justify-content: space-between;
        padding: 0.75rem 0;
        border: none;
        border-bottom: 1px solid #f0f0f0;
        text-align: right;
    }

    .table-responsive-mobile td:last-child {
        border-bottom: none;
    }

    .table-responsive-mobile td:before {
        content: attr(data-label);
        font-weight: 600;
        text-align: left;
        padding-right: 1rem;
        flex: 0 0 50%;
    }

    .table-responsive-mobile .btn-group {
        display: flex;
        gap: 0.5rem;
        justify-content: flex-end;
        flex-wrap: wrap;
    }

    .table-responsive-mobile .btn-sm {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }
}

/* ============================================
   ACCIONES DE TABLA RESPONSIVE
   ============================================ */

.action-buttons {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

@media (max-width: 576px) {
    .action-buttons {
        flex-wrap: wrap;
        width: 100%;
    }

    .action-buttons .btn {
        flex: 1 1 auto;
        min-width: 40px;
    }
}

/* ============================================
   PAGINACIÓN RESPONSIVE
   ============================================ */

.pagination-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-top: 1px solid #e9ecef;
    flex-wrap: wrap;
    gap: 1rem;
}

.pagination {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 0.25rem;
}

.pagination .page-item {
    display: inline-block;
}

.pagination .page-link {
    padding: 0.5rem 0.75rem;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    color: #007bff;
    text-decoration: none;
    transition: all 0.3s;
}

.pagination .page-link:hover {
    background-color: #e9ecef;
}

.pagination .page-item.active .page-link {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
}

@media (max-width: 576px) {
    .pagination-wrapper {
        flex-direction: column;
        text-align: center;
    }

    .pagination {
        justify-content: center;
        flex-wrap: wrap;
    }

    .pagination .page-link {
        padding: 0.375rem 0.625rem;
        font-size: 0.875rem;
    }

    /* Ocultar números intermedios en móvil */
    .pagination .page-item:not(.active):not(:first-child):not(:last-child):not(.disabled) {
        display: none;
    }
}

/* ============================================
   FORMULARIOS DE MÓDULOS RESPONSIVE
   ============================================ */

.form-section {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.form-row-custom {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
    .form-section {
        padding: 1.5rem;
    }

    .form-row-custom {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

@media (max-width: 576px) {
    .form-section {
        padding: 1rem;
        border-radius: 0;
    }
}

/* ============================================
   MODAL DE DETALLES RESPONSIVE
   ============================================ */

.detail-modal .modal-body {
    padding: 2rem;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.detail-item {
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.detail-item label {
    font-weight: 600;
    color: #6c757d;
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.detail-item p {
    margin: 0;
    font-size: 1rem;
    color: #212529;
}

@media (max-width: 768px) {
    .detail-modal .modal-body {
        padding: 1.5rem;
    }

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

@media (max-width: 576px) {
    .detail-modal .modal-body {
        padding: 1rem;
    }

    .detail-item {
        padding: 0.75rem;
    }
}

/* ============================================
   BADGES Y ESTADOS RESPONSIVE
   ============================================ */

.badge {
    display: inline-block;
    padding: 0.35em 0.65em;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1;
    color: #fff;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: 0.25rem;
}

@media (max-width: 576px) {
    .badge {
        font-size: 0.7rem;
        padding: 0.3em 0.5em;
    }
}

/* ============================================
   ALERTAS Y NOTIFICACIONES RESPONSIVE
   ============================================ */

.alert {
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid transparent;
    border-radius: 0.25rem;
}

@media (max-width: 576px) {
    .alert {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
}

/* ============================================
   BREADCRUMB RESPONSIVE
   ============================================ */

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    list-style: none;
    background-color: #e9ecef;
    border-radius: 0.25rem;
}

@media (max-width: 576px) {
    .breadcrumb {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }

    .breadcrumb-item + .breadcrumb-item {
        padding-left: 0.3rem;
    }
}

/* ============================================
   TABS RESPONSIVE
   ============================================ */

.nav-tabs {
    display: flex;
    flex-wrap: wrap;
    border-bottom: 1px solid #dee2e6;
}

.nav-tabs .nav-item {
    margin-bottom: -1px;
}

.nav-tabs .nav-link {
    padding: 0.5rem 1rem;
    border: 1px solid transparent;
    border-top-left-radius: 0.25rem;
    border-top-right-radius: 0.25rem;
}

@media (max-width: 768px) {
    .nav-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
    }

    .nav-tabs .nav-link {
        white-space: nowrap;
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
    }
}

/* ============================================
   DROPDOWN RESPONSIVE
   ============================================ */

.dropdown-menu {
    min-width: 10rem;
    padding: 0.5rem 0;
    margin: 0.125rem 0 0;
    font-size: 1rem;
    color: #212529;
    background-color: #fff;
    border: 1px solid rgba(0,0,0,.15);
    border-radius: 0.25rem;
}

@media (max-width: 576px) {
    .dropdown-menu {
        position: fixed !important;
        left: 1rem !important;
        right: 1rem !important;
        top: auto !important;
        bottom: 1rem !important;
        transform: none !important;
        max-height: 50vh;
        overflow-y: auto;
    }
}

/* ============================================
   SEARCH BAR RESPONSIVE
   ============================================ */

.search-bar {
    position: relative;
    width: 100%;
    max-width: 500px;
}

.search-bar input {
    width: 100%;
    padding: 0.75rem 2.5rem 0.75rem 1rem;
    border: 1px solid #ced4da;
    border-radius: 25px;
    font-size: 1rem;
}

.search-bar .search-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
}

@media (max-width: 768px) {
    .search-bar {
        max-width: 100%;
    }

    .search-bar input {
        font-size: 16px; /* Evita zoom en iOS */
    }
}

/* ============================================
   EMPTY STATE RESPONSIVE
   ============================================ */

.empty-state {
    text-align: center;
    padding: 3rem 1.5rem;
}

.empty-state i {
    font-size: 4rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.empty-state h3 {
    color: #495057;
    margin-bottom: 1rem;
}

.empty-state p {
    color: #6c757d;
    margin-bottom: 1.5rem;
}

@media (max-width: 576px) {
    .empty-state {
        padding: 2rem 1rem;
    }
}

