/* === FCM ESTILOS UNIFICADOS === */

/* === GENERAL === */
body {
    background: linear-gradient(135deg, #74b9ff 0%, #6c5ce7 100%);
    min-height: 100vh;
    font-family: 'Segoe UI', sans-serif;
}

/* === MAIN CARD === */
.main-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    margin: 3rem auto;
    max-width: 1200px;
    overflow: hidden;
}

/* === HEADER === */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    text-align: center;
}

.header h1, .header h2 {
    margin: 0;
    font-weight: 600;
}

/* === BREADCRUMB === */
.breadcrumb-nav {
    background: #f8f9fa;
    padding: 1rem 2rem;
    border-bottom: 1px solid #e9ecef;
}

.breadcrumb-nav a {
    color: #6c5ce7;
    text-decoration: none;
    font-weight: 500;
}

.breadcrumb-nav a:hover {
    text-decoration: underline;
}

/* === STATUS BAR === */
.status-bar {
    background: linear-gradient(135deg, #ff7675 0%, #fd79a8 100%);
    color: white;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    margin-bottom: 1.5rem;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0 0.5rem;
}

.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

.status-success { background-color: #00b894; }
.status-warning { background-color: #e84393; }
.status-danger { background-color: #e17055; }
.status-info { background-color: #74b9ff; }

.status-divider {
    height: 20px;
    width: 1px;
    background-color: rgba(255, 255, 255, 0.3);
    margin: 0 0.5rem;
}

/* === ACTION SECTION === */
.action-section,
.filter-section {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border-left: 4px solid #667eea;
    padding: 2rem;
    margin: 0;
}

.action-title,
.filter-title {
    color: #667eea;
    font-weight: 600;
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.dataTables_length, .dataTables_filter {
    padding: 0.5rem 1rem;
}
.dataTables_wrapper .row:last-child {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 1rem;
}

/* === FORMULARIOS === */
.form-control, .form-select {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.form-check-input:checked {
    background-color: #667eea;
    border-color: #667eea;
}

.form-check {
    margin-bottom: 0.75rem;
}

.form-check-label {
    font-weight: 500;
    color: #495057;
}

/* === BOTONES === */
.btn-primary,
.btn-filter {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 8px;
    padding: 0.75rem 2rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary:hover,
.btn-filter:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}

.btn-filter {
    width: 100%;
}

.btn-success,
.btn-save-obras {
    background: linear-gradient(135deg, #00b894 0%, #00a085 100%);
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    color: white;
}

.btn-success:hover,
.btn-save-obras:hover {
    background: linear-gradient(135deg, #00a085 0%, #009975 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 184, 148, 0.3);
    color: white;
}

.btn-save-obras {
    padding: 0.75rem 2rem;
}

.btn-add-obra {
    background: linear-gradient(135deg, #00b894 0%, #00a085 100%);
    border: none;
    border-radius: 8px;
    color: white;
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 184, 148, 0.2);
    min-width: 40px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-add-obra:hover {
    background: linear-gradient(135deg, #00a085 0%, #009975 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 184, 148, 0.3);
    color: white;
}

.btn-warning {
    background: linear-gradient(135deg, #fdcb6e 0%, #e17055 100%);
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-warning:hover {
    background: linear-gradient(135deg, #fab1a0 0%, #d63031 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(253, 203, 110, 0.3);
}

.btn-danger {
    background: linear-gradient(135deg, #fd79a8 0%, #e84393 100%);
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #e84393 0%, #d63031 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(253, 121, 168, 0.3);
}

.btn-secondary {
    background: #6c757d;
    border: none;
    border-radius: 8px;
    padding: 0.75rem 2rem;
    font-weight: 500;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
    margin: 0 0.2rem;
}

/* === SECCIONES DE MONTO === */
.total-amount, .balance-amount {
    color: white;
    padding: 1rem;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 500;
    text-align: center;
    margin-bottom: 1.5rem;
}

.total-amount {
    background: linear-gradient(135deg, #00b894 0%, #00a085 100%);
}

.balance-amount {
    background: linear-gradient(135deg, #e84393 0%, #fd79a8 100%);
}

/* === MODALES === */
.modal-content {
    border: none;
    border-radius: 16px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 16px 16px 0 0;
    border: none;
    padding: 1.5rem 2rem;
}

.modal-title {
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.modal-body {
    padding: 2rem;
}

/* === SECCIÓN DE OBRAS === */
.obra-selection {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.obra-selection h6 {
    color: #667eea;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.selected-obras {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    border-radius: 12px;
    padding: 1.5rem;
    border-left: 4px solid #667eea;
}

.selected-obras h6 {
    color: #667eea;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* === TAGS DE OBRA === */
.obra-tag {
    display: inline-flex;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    margin: 0.25rem;
    font-weight: 500;
}

.btn-remove-tag {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    transition: all 0.2s ease;
    cursor: pointer;
    padding: 0;
    margin: 0;
    flex-shrink: 0;
}

.btn-remove-tag:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
    transform: scale(1.1);
}

/* === RESULTADOS === */
.results-section {
    padding: 2rem;
}

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

.results-title {
    color: #667eea;
    font-weight: 600;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
}

.results-count {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.no-results {
    text-align: center;
    padding: 3rem;
    color: #6c757d;
}

.no-results i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #dee2e6;
}

/* === TABLAS === */
.table-container {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 1.5rem;
}

.table {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 0;
    font-size: 0.9rem;
}

.table thead th {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 1rem 0.75rem;
    font-weight: 500;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 10;
}

.table tbody td {
    padding: 0.75rem;
    vertical-align: middle;
    border-color: #e9ecef;
}

.table tbody tr:hover {
    background-color: #f8f9fa;
    transition: background-color 0.2s ease;
}

.content-container table {
    font-size: 0.85rem;
}

.obra-activa {
    background-color: #d4edda;
}

.obra-inactiva {
    background-color: #f8d7da;
    opacity: 0.7;
}

/* === BADGES === */
.badge {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
    border-radius: 12px;
}

.badge-success {
    background: linear-gradient(135deg, #00b894 0%, #00a085 100%);
}

.badge-danger {
    background: linear-gradient(135deg, #fd79a8 0%, #e84393 100%);
}

/* === UTILIDADES === */
.text-right {
    text-align: right;
}

.text-center {
    text-align: center;
}

/* === FOOTER === */
.footer-info {
    text-align: center;
    padding: 1rem;
    color: #6c757d;
    font-size: 0.85rem;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .status-bar {
        font-size: 0.8rem;
        padding: 0.5rem;
    }

    .status-item {
        padding: 0 0.25rem;
        font-size: 0.75rem;
    }

    .status-divider {
        display: none;
    }

    .status-bar .d-flex {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .main-card {
        margin: 1rem;
        border-radius: 12px;
    }

    .header {
        padding: 1.5rem;
    }

    .action-section,
    .filter-section {
        padding: 1.5rem;
    }

    .results-section {
        padding: 1rem;
    }

    .table-container {
        overflow-x: auto;
    }

    .btn-filter,
    .btn-primary {
        margin-top: 1rem;
        width: 100%;
    }
}
/* === SELECT2 - ESTILO FCM UNIFICADO === */
.select2-container--default .select2-selection--single {
    background-color: #ffffff;
    border: 2px solid #e9ecef;
    border-radius: 12px; /* Aumentado a 12px para bordes más redondeados */
    height: 42px;
    padding: 0 12px;
    transition: all 0.3s ease;
    font-family: 'Segoe UI', sans-serif;
    font-size: 1rem;
    color: #212529;
    width: 100% !important; /* Asegura que ocupe el 100% del contenedor */
}

.select2-container--default .select2-selection--single:focus-within,
.select2-container--default.select2-container--focus .select2-selection--single {
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 38px;
    padding-left: 0;
    padding-right: 55px !important; /* Más espacio para la flecha grande */
    color: #495057;
}

.select2-container--default .select2-selection--single .select2-selection__placeholder {
    color: #6c757d;
    font-style: italic;
}

/* FLECHA MEJORADA - MÁS ESPECÍFICA */
.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 42px !important;
    width: 50px !important; /* Más ancho */
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    border-radius: 0 12px 12px 0 !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
    border-color: #ffffff transparent transparent transparent !important;
    border-width: 10px 8px 0 8px !important; /* Flecha mucho más grande */
    margin: 0 !important;
    position: static !important;
    border-style: solid !important;
}

/* SOLUCIÓN NUCLEAR - DROPDOWN CON ANCHO DEL SELECT */
.select2-dropdown {
    border: 2px solid #667eea !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2) !important;
    background: #ffffff !important;
    margin-top: 2px !important;
    overflow: hidden !important;
    z-index: 1000 !important;
    /* FORZAMOS QUE COINCIDA CON EL SELECT */
    width: 100% !important;
    max-width: none !important;
    min-width: auto !important;
    position: absolute !important;
    left: 0 !important;
    right: auto !important;
}

/* FORZAR QUE EL DROPDOWN TENGA EL MISMO ANCHO QUE SU CONTENEDOR */
.select2-container--open .select2-dropdown {
    width: 100% !important;
    left: 0 !important;
    right: auto !important;
}

/* HACK: Usar JavaScript para setear el ancho */
.select2-dropdown[style*="width"] {
    width: auto !important;
    min-width: 100% !important;
    max-width: 100% !important;
}

.select2-container--default .select2-search--dropdown {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%) !important;
    padding: 8px !important;
    border-bottom: 1px solid #e9ecef !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.select2-container--default .select2-search--dropdown .select2-search__field {
    border: 2px solid #e9ecef !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
    width: calc(100% - 16px) !important; /* Resta el padding del contenedor */
    max-width: calc(100% - 16px) !important;
    box-sizing: border-box !important;
    padding: 6px 10px !important;
    font-size: 1rem !important;
    margin: 0 !important;
}

.select2-container--default .select2-search--dropdown .select2-search__field:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
    outline: none;
}

.select2-container--default .select2-results__option {
    padding: 12px !important;
    font-size: 0.875rem !important;
    transition: all 0.3s ease !important;
    border-bottom: 1px solid #f8f9fa !important;
    color: #495057 !important;
    width: 100% !important;
    box-sizing: border-box !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.select2-container--default .select2-results__option:last-child {
    border-bottom: none !important;
}

.select2-container--default .select2-results__option--highlighted {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: #ffffff !important;
}

.select2-container--default .select2-results__option--selected {
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%) !important;
    color: #667eea !important;
    font-weight: 500 !important;
}

/* CONTENEDOR DE RESULTADOS */
.select2-results {
    max-height: 200px !important;
    overflow-y: auto !important;
    width: 100% !important;
    box-sizing: border-box !important;
}
/* Fix para que no se vea solo la flecha y el campo colapsado */
.select2-container {
    width: 100% !important;
    display: block !important;
    max-width: 100% !important; /* Evita expansión excesiva */
}

.select2-selection--single {
    height: 42px !important;
    padding: 0.375rem 0.75rem !important;
    display: flex;
    align-items: center;
    border: 2px solid #e9ecef;
    border-radius: 12px;
}

/* Fuerza el ancho del dropdown y lo alinea correctamente */
.select2-container--default .select2-dropdown {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
    left: 0 !important; /* Alinea correctamente con el select */
}

/* Adicional: Asegura que el dropdown no se expanda más allá de su contenedor */
.select2-container--open .select2-dropdown {
    width: auto !important;
    min-width: 100% !important;
    max-width: 100% !important;
}

/* === CAJAS DE TOTALES === */
.total-box {
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  padding: 1.5rem;
  transition: transform 0.2s ease;
}
.total-box:hover {
  transform: translateY(-2px);
}

.pending-box {
  background: #fff9ec; /* tono cálido, suave */
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(255, 193, 7, 0.15); /* sombra dorada */
  padding: 1.5rem;
  transition: transform 0.2s ease;
  border-left: 4px solid #ffc107; /* línea vertical dorada */
}
.pending-box:hover {
  transform: translateY(-2px);
}

/* Estilos para el nuevo contador de facturas */
.invoices-box {
  background: linear-gradient(135deg, #e3f2fd 0%, #f8f9fa 100%);
  border: 2px solid #17a2b8;
  border-radius: 12px;
  padding: 1.2rem;
  box-shadow: 0 4px 6px rgba(23, 162, 184, 0.1);
  transition: all 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.invoices-box:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(23, 162, 184, 0.15);
}

/* Asegurar consistencia visual entre las tres cajas */
.total-box, .pending-box, .invoices-box {
  min-height: 100px;
}

/* === UTILIDADES ESPECÍFICAS === */
.fila-saldo-a-favor {
    color: gray;
    font-style: italic;
    opacity: 0.85;
}

.bg-light-purple {
    background-color: #f5f0fa !important;
}

/* === RESPONSIVE PARA CAJAS DE TOTALES === */
/* Responsive: en pantallas pequeñas, stack vertical */
@media (max-width: 1199.98px) {
  .row.gx-3.gy-3 .col-xl-4 {
    max-width: 350px;
    margin: 0 auto;
  }
}

/* Para pantallas muy pequeñas */
@media (max-width: 576px) {
  .invoices-box, .total-box, .pending-box {
    min-height: 80px;
    padding: 1rem;
  }

  .fs-4 {
    font-size: 1.1rem !important;
  }
}
/* CONTADOR DE FACTURAS - ESTILO FCM */
.invoice-counter {
    background: linear-gradient(135deg, #00b894 0%, #00a085 100%);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.95rem;
    box-shadow: 0 4px 12px rgba(0, 184, 148, 0.25);
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 180px;
    justify-content: center;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.invoice-counter.has-selection {
    animation: pulse-success 2s infinite;
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 184, 148, 0.4);
}

.invoice-counter.no-selection {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    box-shadow: 0 2px 8px rgba(108, 117, 125, 0.2);
}

@keyframes pulse-success {
    0% { box-shadow: 0 6px 20px rgba(0, 184, 148, 0.4); }
    50% { box-shadow: 0 8px 25px rgba(0, 184, 148, 0.6); }
    100% { box-shadow: 0 6px 20px rgba(0, 184, 148, 0.4); }
}

.counter-icon {
    font-size: 1.1rem;
    animation: bounce 2s infinite;
}

.has-selection .counter-icon {
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-3px); }
    60% { transform: translateY(-2px); }
}

/* Responsive para el contador */
@media (max-width: 768px) {
    .invoice-counter {
        min-width: 150px;
        font-size: 0.85rem;
        padding: 0.6rem 1.2rem;
    }
}
/* === VALORES NEGATIVOS === */
.text-negative {
    color: #e74c3c !important;
    font-weight: 600;
    text-shadow: 0 1px 2px rgba(231, 76, 60, 0.1);
}

.text-negative:hover {
    color: #c0392b !important;
    transform: scale(1.02);
    transition: all 0.2s ease;
}
/* === AGREGAR AL CSS ===*/
/* Botones Editar FCM - Agregar al final de tu archivo CSS */

/* Opción 1: Botón Completo (RECOMENDADO) */
.btn-edit-fcm {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 20px;
    color: white;
    padding: 0.4rem 1rem;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
    min-width: 80px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
}

.btn-edit-fcm:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    color: white;
}

.btn-edit-fcm:active {
    transform: translateY(0);
}

.btn-edit-fcm i {
    font-size: 0.9rem;
}

/* Opción 2: Botón Compacto (Solo ícono) */
.btn-edit-compact {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 50%;
    color: white;
    padding: 0.5rem;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
    width: 35px;
    height: 35px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-edit-compact:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-2px) scale(1.1);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    color: white;
}

/* Opción 3: Botón con Borde */
.btn-edit-outline {
    background: transparent;
    border: 2px solid #667eea;
    border-radius: 20px;
    color: #667eea;
    padding: 0.4rem 1rem;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
    min-width: 80px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
}

.btn-edit-outline:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: transparent;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

/* Responsive para botones */
@media (max-width: 768px) {
    .btn-edit-fcm, .btn-edit-outline {
        min-width: 70px;
        font-size: 0.75rem;
        padding: 0.35rem 0.8rem;
    }

    .btn-edit-compact {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
}
/* Alert mejorado */
.mode-alert {
    background: linear-gradient(135deg, rgba(255, 193, 7, 0.1), rgba(255, 152, 0, 0.1));
    border: 1px solid rgba(255, 193, 7, 0.3);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    margin: 1.5rem 2rem;
    color: #856404;
    position: relative;
    overflow: hidden;
}

.mode-alert::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.mode-alert-content {
    display: flex;
    align-items: center;
    gap: 1rem;
    position: relative;
    z-index: 1;
}

.mode-alert-icon {
    font-size: 1.5rem;
    color: #ffc107;
}

.mode-alert-text {
    flex: 1;
}

.mode-alert-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.mode-alert-description {
    font-size: 0.9rem;
    margin: 0;
    opacity: 0.8;
}
 /* === CONTENEDOR PRINCIPAL === */
        .login-container {
            background: white;
            border-radius: 20px;
            box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
            overflow: hidden;
            max-width: 450px;
            width: 100%;
            position: relative;
        }

        /* === HEADER === */
        .login-header {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            color: white;
            padding: 2.5rem 2rem 2rem;
            text-align: center;
            position: relative;
            overflow: hidden;
        }

        .login-header::before {
            content: '';
            position: absolute;
            top: -50%;
            left: -50%;
            width: 200%;
            height: 200%;
            background: repeating-linear-gradient(
                45deg,
                transparent,
                transparent 20px,
                rgba(255, 255, 255, 0.03) 20px,
                rgba(255, 255, 255, 0.03) 40px
            );
            animation: slide 20s linear infinite;
        }

        @keyframes slide {
            0% { transform: translateX(-50%) translateY(-50%) rotate(0deg); }
            100% { transform: translateX(-50%) translateY(-50%) rotate(360deg); }
        }

        .login-title {
            position: relative;
            z-index: 2;
            margin: 0;
            font-weight: 600;
            font-size: 1.8rem;
            margin-bottom: 0.5rem;
        }

        .login-subtitle {
            position: relative;
            z-index: 2;
            margin: 0;
            opacity: 0.9;
            font-size: 1rem;
        }

        .login-icon {
            position: relative;
            z-index: 2;
            font-size: 3rem;
            margin-bottom: 1rem;
            opacity: 0.9;
            animation: pulse 2s infinite;
        }

        @keyframes pulse {
            0%, 100% { opacity: 0.9; transform: scale(1); }
            50% { opacity: 1; transform: scale(1.05); }
        }

        /* === FORMULARIO === */
        .login-form {
            padding: 2.5rem 2rem;
        }

        .form-group {
            margin-bottom: 1.5rem;
            position: relative;
        }

        .form-label {
            color: #667eea;
            font-weight: 600;
            margin-bottom: 0.5rem;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        .form-control {
            border: 2px solid #e9ecef;
            border-radius: 12px;
            padding: 0.75rem 1rem;
            font-size: 1rem;
            transition: all 0.3s ease;
            background: white;
        }

        .form-control:focus {
            border-color: #667eea;
            box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
            background: white;
        }

        .form-control:focus + .input-icon {
            color: #667eea;
        }

        .input-group {
            position: relative;
        }

        .input-icon {
            position: absolute;
            right: 15px;
            top: 50%;
            transform: translateY(-50%);
            color: #6c757d;
            transition: color 0.3s ease;
            z-index: 3;
        }

        /* === BOTÓN === */
        .btn-login {
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            border: none;
            border-radius: 12px;
            padding: 0.875rem 2rem;
            font-weight: 600;
            font-size: 1.1rem;
            width: 100%;
            color: white;
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
        }

        .btn-login:hover {
            background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
            transform: translateY(-2px);
            box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
            color: white;
        }

        .btn-login:active {
            transform: translateY(0);
        }

        .btn-login::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
            transition: left 0.5s;
        }

        .btn-login:hover::before {
            left: 100%;
        }

        /* === ALERTAS === */
        .alert {
            border: none;
            border-radius: 12px;
            padding: 1rem 1.25rem;
            margin-bottom: 1.5rem;
            font-weight: 500;
            position: relative;
            overflow: hidden;
        }

        .alert-danger {
            background: linear-gradient(135deg, rgba(253, 121, 168, 0.1), rgba(232, 67, 147, 0.1));
            color: #721c24;
            border-left: 4px solid #fd79a8;
        }

        .alert-success {
            background: linear-gradient(135deg, rgba(0, 184, 148, 0.1), rgba(0, 160, 133, 0.1));
            color: #155724;
            border-left: 4px solid #00b894;
        }

        .alert-warning {
            background: linear-gradient(135deg, rgba(255, 193, 7, 0.1), rgba(255, 152, 0, 0.1));
            color: #856404;
            border-left: 4px solid #ffc107;
        }

        /* === FOOTER === */
        .login-footer {
            text-align: center;
            padding: 1.5rem 2rem;
            background: #f8f9fa;
            color: #6c757d;
            font-size: 0.875rem;
            border-top: 1px solid #e9ecef;
        }

        /* === EFECTOS ADICIONALES === */
        .floating-shapes {
            position: absolute;
            width: 100%;
            height: 100%;
            overflow: hidden;
            pointer-events: none;
        }

        .shape {
            position: absolute;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 50%;
            animation: float 6s ease-in-out infinite;
        }

        .shape:nth-child(1) {
            width: 80px;
            height: 80px;
            top: 20%;
            left: 10%;
            animation-delay: 0s;
        }

        .shape:nth-child(2) {
            width: 120px;
            height: 120px;
            top: 60%;
            right: 10%;
            animation-delay: 2s;
        }

        .shape:nth-child(3) {
            width: 60px;
            height: 60px;
            bottom: 20%;
            left: 20%;
            animation-delay: 4s;
        }

        @keyframes float {
            0%, 100% { transform: translateY(0px); }
            50% { transform: translateY(-20px); }
        }

        /* === RESPONSIVE === */
        @media (max-width: 768px) {
            body {
                padding: 10px;
            }

            .login-container {
                max-width: 100%;
                margin: 0;
            }

            .login-header {
                padding: 2rem 1.5rem 1.5rem;
            }

            .login-title {
                font-size: 1.5rem;
            }

            .login-icon {
                font-size: 2.5rem;
            }

            .login-form {
                padding: 2rem 1.5rem;
            }

            .login-footer {
                padding: 1.25rem 1.5rem;
            }
        }

        /* === ANIMACIÓN DE ENTRADA === */
        .login-container {
            animation: slideIn 0.6s ease-out;
        }

        @keyframes slideIn {
            from {
                opacity: 0;
                transform: translateY(30px) scale(0.95);
            }
            to {
                opacity: 1;
                transform: translateY(0) scale(1);
            }
        }