
:root {
    --bg-deep: #0f1219; 
    --bg-card: rgba(30, 30, 47, 0.7); 
    --accent-primary: #3b82f6; 
    --accent-secondary: #8b5cf6;
    --accent-success: #10b981;
    --text-main: #ffffff;
    --text-muted: #94a3b8;
    --border-glass: 1px solid rgba(255, 255, 255, 0.08);
}

body {
    background-color: var(--bg-deep);
    background-image: radial-gradient(circle at 10% 20%, rgba(59, 130, 246, 0.1) 0%, transparent 20%),
                      radial-gradient(circle at 90% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 20%);
    color: var(--text-main);
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    min-height: 100vh;
}

.form-control {
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    color: #ffffff !important;
    padding: 12px 15px;
    border-radius: 10px;
}

.form-control:focus {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: var(--accent-primary) !important;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
    color: #ffffff !important;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5) !important;
}

.input-group-text {
    background-color: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    border-right: none !important;
    color: #ffffff !important;
}

h1, h2, h3, h4, h5, h6, .form-label {
    color: #ffffff !important;
}

.login-container {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #1b2038 0%, #0f1219 100%);
}

.login-card {
    background: rgba(25, 28, 45, 0.6);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: var(--border-glass);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    padding: 3rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.login-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(to bottom right, rgba(255,255,255,0.05), transparent, transparent);
    pointer-events: none;
    transform: rotate(30deg);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border: none;
    padding: 12px;
    border-radius: 10px;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: white !important;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
    transition: transform 0.2s;
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.sidebar {
    background: rgba(18, 20, 32, 0.95);
    border-right: var(--border-glass);
    backdrop-filter: blur(10px);
}

.nav-link {
    color: var(--text-muted);
    margin: 8px 0;
    padding: 12px 15px;
    border-radius: 10px;
    font-weight: 500;
    transition: all 0.3s;
}

.nav-link:hover, .nav-link.active {
    background: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.stat-card {
    background: var(--bg-card);
    border: var(--border-glass);
    border-radius: 16px;
    backdrop-filter: blur(5px);
}
.stat-card h3 { color: #fff; font-weight: 800; }

.table-custom {
    background: var(--bg-card);
    border: var(--border-glass);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

table.dataTable {
    border-collapse: separate !important; 
    border-spacing: 0 8px !important;
}

.table-dark {
    background-color: transparent !important;
    --bs-table-bg: transparent;
}

table.dataTable thead th {
    border-bottom: none !important;
    color: var(--text-muted) !important;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1px;
    padding-bottom: 15px !important;
}

table.dataTable tbody tr {
    background-color: rgba(255, 255, 255, 0.03) !important;
    transition: transform 0.2s, background-color 0.2s;
}

table.dataTable tbody tr td:first-child { border-top-left-radius: 10px; border-bottom-left-radius: 10px; }
table.dataTable tbody tr td:last-child { border-top-right-radius: 10px; border-bottom-right-radius: 10px; }

table.dataTable tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.08) !important;
    transform: scale(1.005);
}

table.dataTable td {
    border: none !important;
    vertical-align: middle;
    padding: 15px !important;
    color: #e2e8f0;
}

.dataTables_wrapper .dataTables_length, 
.dataTables_wrapper .dataTables_filter, 
.dataTables_wrapper .dataTables_info, 
.dataTables_wrapper .dataTables_paginate {
    color: var(--text-muted) !important;
    margin-bottom: 15px;
}

.dataTables_wrapper .dataTables_filter input {
    background: rgba(0, 0, 0, 0.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: white !important;
    border-radius: 8px;
    padding: 5px 10px;
}

.page-item .page-link {
    background-color: transparent !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
    color: var(--text-muted) !important;
    border-radius: 6px;
    margin: 0 2px;
}

.page-item.active .page-link {
    background-color: var(--accent-primary) !important;
    border-color: var(--accent-primary) !important;
    color: white !important;
}

.badge {
    padding: 6px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}
.badge-prioridad-3 { background: rgba(239, 68, 68, 0.2); color: #fca5a5; border: 1px solid rgba(239, 68, 68, 0.3); }
.badge-prioridad-2 { background: rgba(245, 158, 11, 0.2); color: #fcd34d; border: 1px solid rgba(245, 158, 11, 0.3); }
.badge-prioridad-1 { background: rgba(16, 185, 129, 0.2); color: #6ee7b7; border: 1px solid rgba(16, 185, 129, 0.3); }

@keyframes rotacion-suave {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.spin-slow {
    animation: rotacion-suave 3s linear infinite; 
    display: inline-block;
}

.timeline {
    position: relative;
    padding-left: 20px;
    border-left: 2px solid rgba(255, 255, 255, 0.1);
    margin-top: 20px;
}
.timeline-item {
    position: relative;
    margin-bottom: 20px;
}
.timeline-dot {
    position: absolute;
    left: -26px;
    top: 5px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--bs-primary);
    border: 2px solid var(--bg-card);
}
.timeline-date {
    font-size: 0.75rem;
    color: #6c757d;
}
.timeline-content {
    background: rgba(255,255,255,0.03);
    padding: 10px;
    border-radius: 8px;
}

.map-container-wrapper {
    height: 400px;
    width: 100%;
    transition: all 0.3s ease-in-out;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    overflow: hidden;
}

#map, #map-edit {
    width: 100%;
    height: 100%;
}

.map-container-wrapper {
    transition: height 0.3s ease-in-out;
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    overflow: hidden;
}
#mapa-nueva, #mapa-picker {
    width: 100%;
    height: 100%;
}
.modal-fullscreen .modal-body {
    display: flex;
    flex-direction: column;
}
.modal-fullscreen .map-container-wrapper {
    height: 70vh !important; 
    flex-grow: 1;
}

@keyframes pulse-red {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

.animate-pulse-red {
    animation: pulse-red 2s infinite ease-in-out;
}

