/* License Checker - Avallo Tools Style */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary-red: #dc2626;
    --primary-red-dark: #b91c1c;
    --primary-red-light: #ef4444;
    --secondary-red: #991b1b;
    --accent-red: #fee2e2;
    
    --primary-gradient: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    --red-gradient-light: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    --dark-gradient: linear-gradient(135deg, #1f2937 0%, #374151 100%);
    
    /* Text colors */
    --text-primary: #111827;
    --text-secondary: #374151;
    --text-light: #6b7280;
    --text-muted: #9ca3af;
    
    /* Background colors */
    --bg-primary: #ffffff;
    --bg-secondary: #ffffff;
    --bg-light: #f8fafc;
    --bg-hover: #f1f5f9;
    
    --border-color: #d1d5db;
    --border-light: #e5e7eb;
    
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --border-radius-xl: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    background: var(--bg-light);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Remove old gradient background */
body::before {
    display: none;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

/* Navigation - Avallo Style */
.navbar {
    background: var(--bg-primary) !important;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    padding: 0.75rem 0;
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-weight: 600 !important;
    color: var(--text-primary) !important;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
}

.navbar-brand i {
    color: var(--primary-red);
    font-size: 1.1rem;
}

/* Small Avallo logo in navbar */
.navbar-logo {
    height: 30px;
    width: auto;
    object-fit: contain;
    background: rgba(255, 255, 255, 0.8);
    padding: 3px 6px;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.navbar-logo:hover {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.05);
}

.nav-link {
    color: var(--text-secondary) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.nav-link:hover {
    color: var(--primary-red) !important;
    background-color: var(--bg-hover);
}

.nav-link.active {
    color: var(--primary-red) !important;
    background-color: var(--accent-red);
}

/* Cards - Modern Avallo Style */
.card {
    background: var(--bg-primary);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.card-header {
    background: var(--primary-gradient) !important;
    color: white !important;
    border: none !important;
    padding: 1.5rem;
    font-weight: 600;
}

.card-header h3, .card-header h4, .card-header h5 {
    color: white !important;
    margin-bottom: 0;
}

.card-body {
    padding: 2rem;
}

/* Buttons - Red Theme */
.btn-primary {
    background: var(--primary-gradient);
    border: none;
    border-radius: var(--border-radius);
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    background: var(--primary-red-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--text-secondary);
    border: none;
    border-radius: var(--border-radius);
    font-weight: 500;
}

.btn-secondary:hover {
    background: var(--text-primary);
}

.btn-success {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    border: none;
}

.btn-info {
    background: linear-gradient(135deg, #0891b2 0%, #0e7490 100%);
    border: none;
}

.btn-warning {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%);
    border: none;
}

.btn-danger {
    background: var(--primary-gradient);
    border: none;
}

/* Forms */
.form-control {
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 0.75rem 1rem;
    transition: var(--transition);
    font-weight: 400;
}

.form-control:focus {
    border-color: var(--primary-red);
    box-shadow: 0 0 0 3px rgb(220 38 38 / 0.1);
}

.form-label {
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

/* Alerts */
.alert {
    border: none;
    border-radius: var(--border-radius-lg);
    padding: 1rem 1.5rem;
    font-weight: 500;
}

.alert-success {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #065f46;
}

.alert-danger {
    background: var(--red-gradient-light);
    color: var(--secondary-red);
}

.alert-warning {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
}

.alert-info {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
}

/* Tables */
.table {
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.table thead th {
    background: var(--primary-gradient);
    color: white;
    font-weight: 600;
    border: none;
    padding: 1rem;
}

.table tbody tr {
    transition: var(--transition);
}

.table tbody tr:hover {
    background-color: var(--bg-hover);
}

.table tbody td {
    padding: 0.75rem 1rem;
    border-color: var(--border-light);
}

/* Badges */
.badge {
    font-weight: 500;
    font-size: 0.75rem;
    padding: 0.375rem 0.75rem;
    border-radius: var(--border-radius);
}

.badge.bg-success {
    background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
}

.badge.bg-danger {
    background: var(--primary-gradient) !important;
}

.badge.bg-warning {
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%) !important;
}

.badge.bg-primary {
    background: var(--primary-gradient) !important;
}

/* Pagination */
.pagination .page-link {
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    border-radius: var(--border-radius);
    margin: 0 0.125rem;
}

.pagination .page-link:hover {
    background-color: var(--bg-hover);
    border-color: var(--primary-red);
    color: var(--primary-red);
}

.pagination .page-item.active .page-link {
    background: var(--primary-gradient);
    border-color: var(--primary-red);
}

/* Dropdown */
.dropdown-menu {
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 0.5rem;
}

.dropdown-toggle::after {
    margin-left: 0.5rem;
}

.dropdown-item {
    border-radius: var(--border-radius);
    padding: 0.5rem 1rem;
    transition: var(--transition);
}

.dropdown-item:hover {
    background-color: var(--bg-hover);
    color: var(--primary-red);
}

/* Modal */
.modal-content {
    border: none;
    border-radius: var(--border-radius-xl);
    box-shadow: var(--shadow-xl);
}

.modal-header {
    border-bottom: 1px solid var(--border-light);
    background: var(--bg-light);
    border-radius: var(--border-radius-xl) var(--border-radius-xl) 0 0;
}

.modal-footer {
    border-top: 1px solid var(--border-light);
    background: var(--bg-light);
}

/* Login Page Specific */
.login-container {
    min-height: 100vh;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    max-width: 400px;
    width: 100%;
    margin: 2rem;
}

/* Login Logo Styling - Above red box, full width */
.login-logo-top {
    width: 100%;
    max-width: 380px;
    max-height: 100px;
    height: auto;
    opacity: 1;
    transition: var(--transition);
    background: rgba(255, 255, 255, 0.95);
    padding: 15px 20px;
    border-radius: var(--border-radius-lg);
    object-fit: contain;
    display: block;
    margin: 0 auto 1rem auto;
    box-shadow: var(--shadow-md);
}

.login-logo-top:hover {
    opacity: 1;
    transform: scale(1.02);
    background: rgba(255, 255, 255, 1);
    box-shadow: var(--shadow-lg);
}

/* Legacy login logo styling (kept for compatibility) */
.login-logo {
    max-width: 150px;
    max-height: 60px;
    height: auto;
    width: auto;
    opacity: 1;
    transition: var(--transition);
    background: rgba(255, 255, 255, 0.95);
    padding: 8px 12px;
    border-radius: var(--border-radius);
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

.login-logo:hover {
    opacity: 1;
    transform: scale(1.02);
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* Dashboard Cards */
.dashboard-card {
    border: none;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    overflow: hidden;
}

.dashboard-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.dashboard-card .card-body {
    text-align: center;
    padding: 2rem;
}

.dashboard-card i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--primary-red);
}

/* Status Indicators */
.status-valid {
    color: #059669;
    font-weight: 600;
}

.status-invalid {
    color: var(--primary-red);
    font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
    .card-body {
        padding: 1.5rem;
    }
    
    .card-header {
        padding: 1rem 1.5rem;
    }
    
    .btn {
        font-size: 0.875rem;
        padding: 0.5rem 1rem;
    }
}

/* Animation for page load */
.main-content {
    animation: fadeInUp 0.6s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* FINAL DROPDOWN Z-INDEX FIX */
/* Reset all z-indexes to proper hierarchy */
.main-content,
.container,
.card,
.card-header,
.card-body {
    position: relative;
    z-index: auto !important;
}

.alert {
    position: relative;
    z-index: 100;
}

/* Navbar should be high but not highest */
.navbar {
    position: relative;
    z-index: 1000;
}

/* Dropdown menus should be the highest */
.dropdown-menu {
    z-index: 9999 !important;
    position: absolute !important;
}

.dropdown-menu.show {
    z-index: 9999 !important;
    position: absolute !important;
}

/* Force dropdown in navbar to be on top */
.navbar .dropdown-menu,
.navbar-nav .dropdown-menu {
    z-index: 9999 !important;
    position: absolute !important;
}



/* Let Bootstrap handle dropdowns naturally */
