/* Custom styles for CVE Management System */

body {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
}

/* DASTLab Branding */
.navbar {
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 50%, #2c5aa0 100%) !important;
    border-bottom: 4px solid #ff6b6b;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.navbar-brand img {
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3));
    transition: transform 0.3s ease;
}

.navbar-brand:hover img {
    transform: scale(1.1);
}

.navbar-brand {
    font-weight: bold;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    text-decoration: none;
}

.brand-text {
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
    margin-right: 0.5rem;
    text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.brand-subtitle {
    font-size: 0.7rem;
    color: #e8f4fd;
    font-weight: 400;
    display: block;
    line-height: 1;
    margin-top: -2px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.card {
    border: none;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.card-header {
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
    color: white;
    border-radius: 15px 15px 0 0 !important;
    border: none;
    font-weight: 600;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.nav-link {
    cursor: pointer;
    transition: all 0.3s ease;
}

.nav-link:hover {
    background-color: rgba(255,255,255,0.1);
    border-radius: 5px;
}

.nav-link.active {
    background-color: rgba(255,255,255,0.2);
    border-radius: 5px;
}

/* CVE severity badges */
.severity-critical {
    background-color: #dc3545;
    color: white;
}

.severity-high {
    background-color: #fd7e14;
    color: white;
}

.severity-medium {
    background-color: #ffc107;
    color: black;
}

.severity-low {
    background-color: #28a745;
    color: white;
}

/* CVE list items */
.cve-item {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    background-color: white;
    transition: all 0.3s ease;
}

.cve-item:hover {
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.cve-id {
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: #007bff;
}

.cve-score {
    font-size: 1.2rem;
    font-weight: bold;
}

/* Fingerprint items */
.fingerprint-item {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    background-color: white;
}

.fingerprint-name {
    font-weight: bold;
    color: #495057;
}

.fingerprint-details {
    font-size: 0.9rem;
    color: #6c757d;
}

/* Scan results */
.scan-result {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    background-color: white;
}

.vulnerability-item {
    border-left: 4px solid #dc3545;
    padding: 10px;
    margin-bottom: 10px;
    background-color: #f8f9fa;
}

.vulnerability-item.severity-high {
    border-left-color: #fd7e14;
}

.vulnerability-item.severity-medium {
    border-left-color: #ffc107;
}

.vulnerability-item.severity-low {
    border-left-color: #28a745;
}

/* Loading states */
.loading {
    text-align: center;
    padding: 40px;
    color: #6c757d;
}

/* Status indicators */
.status-online {
    color: #28a745;
}

.status-offline {
    color: #dc3545;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .card-body {
        padding: 15px;
    }
    
    .cve-item {
        padding: 10px;
    }
    
    .navbar-brand {
        font-size: 1.2rem;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Animation for loading */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

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

@keyframes wag {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(5deg); }
    75% { transform: rotate(-5deg); }
}

.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

.bounce {
    animation: bounce 2s infinite;
}

.wag {
    animation: wag 1s ease-in-out infinite;
}

/* Labrador paw print decoration */
.paw-print {
    position: relative;
    display: inline-block;
    width: 20px;
    height: 20px;
    margin: 0 5px;
    opacity: 0.3;
}

.paw-print::before {
    content: "🐾";
    font-size: 16px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Dashboard stats cards enhancement */
.card.bg-primary {
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%) !important;
    border: 2px solid #ff6b6b;
}

.card.bg-danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%) !important;
    border: 2px solid #ff6b6b;
}

.card.bg-warning {
    background: linear-gradient(135deg, #ffc107 0%, #e0a800 100%) !important;
    border: 2px solid #ff6b6b;
}

.card.bg-info {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%) !important;
    border: 2px solid #ff6b6b;
}

/* Button hover effects */
.btn {
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Form styling */
.form-control:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0,123,255,0.25);
}

/* Alert styling */
.alert {
    border: none;
    border-radius: 8px;
}

/* Table styling */
.table {
    margin-bottom: 0;
}

.table th {
    border-top: none;
    font-weight: 600;
    color: #495057;
}

/* Modal styling */
.modal-content {
    border: none;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
}

.modal-header {
    background: linear-gradient(135deg, #4a90e2 0%, #357abd 100%);
    color: white;
    border-radius: 15px 15px 0 0;
    border: none;
}

.modal-header .btn-close {
    filter: invert(1);
}

.modal-footer {
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
    border-radius: 0 0 15px 15px;
}

/* CVE Details Modal specific styling */
#cveDetailsModal .modal-body h6 {
    color: #4a90e2;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

#cveDetailsModal .modal-body p {
    margin-bottom: 1rem;
    line-height: 1.5;
}

#cveDetailsModal .font-monospace {
    background: #f8f9fa;
    padding: 0.5rem;
    border-radius: 5px;
    border: 1px solid #e9ecef;
}

/* Scan Items */
.scan-item {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.scan-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.scan-target {
    font-size: 1.1rem;
    color: #2c3e50;
    margin-bottom: 5px;
}

.scan-timestamp {
    font-size: 0.85rem;
}

/* Scan Details Modal */
#scanDetailsModal .modal-dialog {
    max-width: 1200px;
}

#scanDetailsModal .list-group-item {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    margin-bottom: 8px;
}

#scanDetailsModal .card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Loading States */
.loading {
    text-align: center;
    padding: 40px;
}

.loading .spinner-border {
    width: 3rem;
    height: 3rem;
    border-width: 0.3em;
}

/* Small scan items for dashboard */
.scan-item-small {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.scan-item-small:hover {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.scan-target-small {
    font-size: 0.9rem;
    color: #2c3e50;
}

.scan-stats-small .badge {
    font-size: 0.7rem;
    padding: 0.25em 0.5em;
}
