/* ==================================
   NAVIGATION CATEGORIES
   ================================== */
.nav-category {
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.nav-category:first-child {
    margin-top: 1rem;
}

.nav-category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    cursor: pointer;
    user-select: none;
    transition: all 0.2s ease;
    border-radius: 0.25rem;
}

.nav-category-header:hover {
    background-color: rgba(171, 5, 52, 0.05);
}

.nav-category-title {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-category-title i {
    font-size: 0.875rem;
    width: 16px;
    text-align: center;
}

.nav-category-toggle {
    font-size: 0.75rem;
    color: #6c757d;
    transition: transform 0.2s ease;
}

.nav-category.collapsed .nav-category-toggle {
    transform: rotate(-90deg);
}

.nav-category-items {
    margin-top: 0.25rem;
    transition: all 0.3s ease;
    overflow: hidden;
}

.nav-category.collapsed .nav-category-items {
    max-height: 0 !important;
    opacity: 0;
    margin-top: 0;
}

/* Navigation Items within Categories */
.nav-category .nav-item {
    margin-bottom: 0.125rem;
}

.nav-category .nav-link {
    padding: 0.625rem 1rem;
    margin: 0 0.5rem;
    border-radius: 0.25rem;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nav-category .nav-link i {
    width: 20px;
    text-align: center;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.nav-category .nav-link span {
    flex: 1;
}

/* Dashboard link at the top */
.nav-item .nav-link {
    transition: all 0.2s ease;
}

.nav-item .nav-link:hover:not(.active) {
    background-color: #ab0534;
    color: white !important;
}

.nav-item .nav-link:hover:not(.active) i {
    color: white !important;
}

.nav-item .nav-link.active i {
    color: white !important;
}

.nav-category .nav-link.active {
    background-color: #ab0534;
    color: white !important;
}

.nav-category .nav-link.active i {
    color: white !important;
}

.nav-category .nav-link:hover:not(.active) {
    background-color: #ab0534;
    color: white !important;
}

.nav-category .nav-link:hover:not(.active) i {
    color: white !important;
}

/* Dropdown within categories */
.nav-category .nav-item.dropdown .dropdown-toggle::after {
    margin-left: auto;
}

.nav-category .dropdown-menu {
    margin-left: 1rem;
    border: none;
    box-shadow: none;
    background: transparent;
    padding: 0;
}

.nav-category .dropdown-item {
    padding: 0.5rem 1rem 0.5rem 2.75rem;
    border-radius: 0.25rem;
    margin: 0.125rem 0.5rem;
    transition: all 0.2s ease;
}

.nav-category .dropdown-item:hover {
    background-color: rgba(171, 5, 52, 0.08);
    color: #ab0534 !important;
}

.nav-category .dropdown-item.active {
    background-color: rgba(171, 5, 52, 0.15);
    color: #ab0534 !important;
    font-weight: 500;
}

.nav-category .dropdown-item i {
    width: 20px;
    text-align: center;
    margin-right: 0.5rem;
}

/* Badge in navigation */
.nav-link .badge {
    margin-left: auto;
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
}

.sortable {
    cursor: pointer;
    user-select: none;
}

.sortable i.fa-sort-up,
.sortable i.fa-sort-down {
    color: #ab0534;
}

.sortable:hover {
    background-color: rgba(0,0,0,0.05);
}

/* Dropdown menu styles */
.dropdown-item.active {
    background-color: #ab0534 !important;
    color: white !important;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
}

.dropdown-item i {
    width: 20px;
    text-align: center;
    margin-right: 0.5rem;
}

/* Active navigation link */
.nav-link.active {
    background-color: rgba(0, 0, 0, 0.05);
    border-radius: 0.25rem;
}

/* Navigation icons */
.nav-link i {
    width: 20px;
    text-align: center;
}

/* Custom button style */
.btn-ninatrans {
    background-color: #ab0534;
    border-color: #ab0534;
    color: white;
}

.btn-ninatrans:hover {
    background-color: #8f042c;
    border-color: #8f042c;
    color: white;
}

.btn-ninatrans:focus {
    background-color: #8f042c;
    border-color: #8f042c;
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(171, 5, 52, 0.25);
}

.btn-ninatrans:active {
    background-color: #8f042c;
    border-color: #8f042c;
    color: white;
}

.bg-ninatrans {
    background-color: #8f042c;
    color: white;
}

.text-ninatrans {
    color: #8f042c;
}

.nav-link {
    color: #8f042c;
}

.navbar-logo {
    height: 40px;  /* Adjust this value to match your navbar height */
    width: auto;
    object-fit: contain;
}

/* Optional: Add some padding around the logo */
.navbar-brand {
    padding: 5px 0;
}

/* For normal state of nav links */
.nav-item .nav-link {
    color: #aa0a2f !important;  /* Ninatrans red color */
}

/* For hover state */
.nav-item .nav-link:hover {
    color: #d0244c !important;  /* Lighter shade of Ninatrans red */
}

/* For active state */
.nav-item .nav-link.active {
    color: #8c0826 !important;  /* Darker shade of Ninatrans red */
}

/* For the icon */
.nav-item .nav-link i {
    color: #aa0a2f !important;  /* Match the text color or use a different color */
}

.dropdown-item {
    color: #aa0a2f !important;
}

.bg-navbar {
    padding: 1.5rem;
    border-bottom: 1px solid #f0f0f0e3;
    background-color: #f0f0f0f0 !important;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

body {
    /* f4f6fc; */ 
    /* background: #ffffff;
    /* font-family: 'Inter', sans-serif; */
    background-color: #ffffff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='12' viewBox='0 0 20 12'%3E%3Cg fill-rule='evenodd'%3E%3Cg id='charlie-brown' fill='%23918e95' fill-opacity='0.09'%3E%3Cpath d='M9.8 12L0 2.2V.8l10 10 10-10v1.4L10.2 12h-.4zm-4 0L0 6.2V4.8L7.2 12H5.8zm8.4 0L20 6.2V4.8L12.8 12h1.4zM9.8 0l.2.2.2-.2h-.4zm-4 0L10 4.2 14.2 0h-1.4L10 2.8 7.2 0H5.8z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");

    font-family: 'Proxima Nova', Verdana, Arial, sans-serif;
    color: #333;
}


@font-face {
    font-family: 'Proxima Nova';
    src: url('/static/font/Proxima-Nova-Regular.woff2') format('woff2'),
         url('/static/font/Proxima-Nova-Regular.woff') format('woff'),
         url('/static/font/Proxima-Nova-Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Proxima Nova';
    src: url('/static/font/Proxima-Nova-Bold.woff2') format('woff2'),
         url('/static/font/Proxima-Nova-Bold.woff') format('woff'),
         url('/static/font/Proxima-Nova-Bold.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}

body {
    font-family: 'Proxima Nova', Arial, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Proxima Nova', Arial, sans-serif;
}

/* Vehicle Status Badges */
.badge {
    font-size: 0.85em;
    padding: 0.5em 0.75em;
    border-radius: 0.25rem;
    background-color: #17a2b8;
}

.badge.bg-success {
    background-color: #28a745 !important;
    color: white;
}

.badge.bg-danger {
    background-color: #dc3545 !important;
    color: white;
}

.badge.bg-warning {
    background-color: #ffc107 !important;
    color: #212529;
}

.badge.bg-info {
    background-color: #17a2b8 !important;
    color: white;
}

/* User Avatar Styles */
.sidebar-user-avatar {
    width: 50px;
    height: 50px;
    background-color: #ab0534;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    flex-shrink: 0;
}

.sidebar-user-avatar .avatar-letter {
    color: white;
    font-size: 18px;
    font-weight: bold;
    text-transform: uppercase;
}

/* Modern Dashboard Styles */
.modern-dashboard {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    min-height: 100vh;
    padding: 0;
}

.dashboard-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-bottom: 1px solid #e2e8f0;
    padding: 2rem 0;
    margin-bottom: 2rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.dashboard-title {
    font-size: 2rem;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
    letter-spacing: -0.025em;
}

.dashboard-subtitle {
    color: #64748b;
    font-size: 1rem;
    margin: 0.5rem 0 0 0;
    font-weight: 400;
}

.date-badge {
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(171, 5, 52, 0.25);
}

/* Modern Metric Cards */
.metric-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.metric-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.metric-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #ab0534, #d63447);
}

.vehicles-card::before {
    background: linear-gradient(90deg, #3b82f6, #1d4ed8);
}

.tasks-card::before {
    background: linear-gradient(90deg, #10b981, #059669);
}

.urgent-card::before {
    background: linear-gradient(90deg, #f59e0b, #d97706);
}

.efficiency-card::before {
    background: linear-gradient(90deg, #8b5cf6, #7c3aed);
}

.planned-card::before {
    background: linear-gradient(90deg, #10b981, #059669);
}

.metric-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.metric-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(171, 5, 52, 0.1);
    color: #ab0534;
    font-size: 1.5rem;
}

.vehicles-card .metric-icon {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.tasks-card .metric-icon {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.urgent-card .metric-icon {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.efficiency-card .metric-icon {
    background: rgba(139, 92, 246, 0.1);
    color: #8b5cf6;
}

.planned-card .metric-icon {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.metric-details {
    flex: 1;
}

.metric-value {
    font-size: 2rem;
    font-weight: 700;
    color: #1a202c;
    line-height: 1;
    margin-bottom: 0.25rem;
}

.metric-label {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.metric-trend {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #10b981;
}

.metric-trend.urgent {
    color: #f59e0b;
}

.metric-trend i {
    font-size: 0.75rem;
}

/* Modern Cards */
.modern-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.modern-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

/* Card Sections for Forms */
.card-section {
    padding: 2rem;
    border-bottom: 1px solid #e5e7eb;
}

.card-section:last-child {
    border-bottom: none;
}

.section-title {
    color: #1f2937;
    font-weight: 600;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
}

.section-title i {
    color: #ab0534;
}

.card-header-modern {
    padding: 1rem 1.25rem 0.75rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
}

.card-title-modern {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a202c;
    margin: 0;
}

.card-subtitle-modern {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0.25rem 0 0 0;
}

.card-body-modern {
    padding: 1.25rem;
}

.btn-primary-modern {
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(171, 5, 52, 0.25);
}

.btn-primary-modern:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(171, 5, 52, 0.35);
    color: white;
    text-decoration: none;
}

/* Chart Actions */
.chart-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-action {
    background: transparent;
    border: 1px solid #e2e8f0;
    color: #64748b;
    border-radius: 6px;
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-action:hover,
.btn-action.active {
    background: #ab0534;
    border-color: #ab0534;
    color: white;
}

/* Vehicle Types List */
.vehicle-types-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.vehicle-type-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.vehicle-type-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.vehicle-type-name {
    font-weight: 600;
    color: #1a202c;
    font-size: 0.9rem;
}

.vehicle-type-percentage {
    font-size: 0.8rem;
    color: #64748b;
}

.vehicle-type-count {
    font-weight: 700;
    color: #ab0534;
    font-size: 1.1rem;
}

.progress-modern {
    height: 6px;
    background: #f1f5f9;
    border-radius: 3px;
    overflow: hidden;
}

.progress-modern.large {
    height: 8px;
}

.progress-bar-modern {
    height: 100%;
    background: linear-gradient(90deg, #ab0534, #d63447);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.progress-bar-modern.success {
    background: linear-gradient(90deg, #10b981, #059669);
}

.progress-bar-modern.warning {
    background: linear-gradient(90deg, #f59e0b, #d97706);
}

/* Status List */
.status-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.status-item {
    padding: 1rem;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #f1f5f9;
}

.status-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.status-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-indicator.status-need-planning {
    background: #f59e0b;
}

.status-indicator.status-planned {
    background: #06b6d4;
}

.status-indicator.status-in-progress {
    background: #3b82f6;
}

.status-indicator.status-completed {
    background: #10b981;
}

.status-indicator.status-on-hold {
    background: #6b7280;
}

.status-indicator.status-cancelled {
    background: #ef4444;
}

.status-name {
    font-weight: 500;
    color: #1a202c;
    font-size: 0.9rem;
}

.status-count {
    font-weight: 700;
    color: #ab0534;
    font-size: 1.1rem;
}

/* Performance Metrics */
.performance-metrics {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.performance-stat {
    text-align: center;
    padding: 1rem;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #f1f5f9;
}

.performance-stat.on-time {
    border-left: 4px solid #10b981;
}

.performance-stat.over-time {
    border-left: 4px solid #f59e0b;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 0.125rem;
}

.stat-subtitle {
    font-size: 0.8rem;
    color: #9ca3af;
}

.performance-progress {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.progress-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: #1a202c;
}

.progress-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
}

.progress-labels .success {
    color: #10b981;
    font-weight: 500;
}

.progress-labels .warning {
    color: #f59e0b;
    font-weight: 500;
}

.performance-summary {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

.summary-item {
    text-align: center;
    flex: 1;
}

.summary-label {
    font-size: 0.8rem;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.summary-value {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1a202c;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
}

.empty-icon {
    font-size: 3rem;
    color: #d1d5db;
    margin-bottom: 1rem;
}

.empty-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.empty-subtitle {
    font-size: 0.9rem;
    color: #9ca3af;
    line-height: 1.5;
}

/* Modern Sidebar Styles */
.modern-sidebar {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-right: 1px solid #e2e8f0;
    box-shadow: 2px 0 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.modern-sidebar .navbar-brand {
    padding: 1.5rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    margin-bottom: 1rem;
}

.modern-sidebar .nav-link {
    color: #64748b !important;
    padding: 0.75rem 1rem;
    margin: 0.25rem 0.5rem;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.modern-sidebar .nav-link:hover {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    color: #1a202c !important;
    transform: translateX(2px);
}

.modern-sidebar .nav-link.active {
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    color: white !important;
    box-shadow: 0 4px 12px rgba(171, 5, 52, 0.25);
}

.modern-sidebar .nav-link i {
    color: inherit !important;
    width: 20px;
    text-align: center;
    margin-right: 0.75rem;
}

.modern-sidebar .dropdown-menu {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    margin: 0.25rem 0;
}

.modern-sidebar .dropdown-item {
    color: #64748b !important;
    padding: 0.5rem 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.modern-sidebar .dropdown-item:hover {
    background: #f8fafc;
    color: #1a202c !important;
}

.modern-sidebar .sidebar-user-card {
    margin: 1rem 0.5rem;
    padding: 1rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.modern-sidebar .modern-env-btn {
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(171, 5, 52, 0.25);
    width: 100%;
    margin-top: 0.5rem;
}

.modern-sidebar .modern-env-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(171, 5, 52, 0.35);
}

.modern-sidebar .sidebar-toggle {
    display: none;
}

@media (max-width: 768px) {
    .modern-sidebar.collapsed {
        margin-left: -250px;
    }
    
    .modern-sidebar .sidebar-toggle {
        display: block;
        position: absolute;
        top: 1rem;
        right: 1rem;
        background: transparent;
        border: none;
        color: #64748b;
        font-size: 1.2rem;
    }
}

/* Modern Admin Styles */
.admin-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-bottom: 1px solid #e2e8f0;
    padding: 1.25rem 0;
    margin-bottom: 1.25rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.admin-title {
    font-size: 2rem;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
    letter-spacing: -0.025em;
}

.admin-subtitle {
    color: #64748b;
    font-size: 1rem;
    margin: 0.5rem 0 0 0;
    font-weight: 400;
}

/* Modern Tabs */
.modern-tabs-container {
    background: white;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    margin-bottom: 1.25rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.modern-tabs {
    background: #f8fafc;
    padding: 0.5rem;
    display: flex;
    gap: 0.5rem;
}

.modern-tab {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: #64748b;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.modern-tab:hover {
    background: rgba(171, 5, 52, 0.1);
    color: #ab0534;
    text-decoration: none;
}

.modern-tab.active {
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(171, 5, 52, 0.25);
}

/* Modern Table Styles */
.table-stats {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.stat-badge {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    color: #64748b;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid #e2e8f0;
}

.modern-table-container {
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    background: white;
}

.modern-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    background: white;
}

.modern-table thead {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.modern-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 2px solid #e2e8f0;
}

.modern-table td {
    padding: 1rem;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.875rem;
    color: #374151;
}

.modern-table tbody tr {
    transition: all 0.3s ease;
}

.modern-table tbody tr:hover {
    background: #f8fafc;
}

.th-content {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.role-name-cell {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.role-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    color: white;
    font-size: 1rem;
    flex-shrink: 0;
}

.role-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.role-id {
    font-size: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
}

.description-cell {
    max-width: 300px;
    color: #64748b;
    line-height: 1.4;
}

.permissions-cell {
    max-width: 400px;
}

.permission-badge {
    display: inline-block;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: #0369a1;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 500;
    margin: 0.125rem;
    border: 1px solid #bae6fd;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.action-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    background: white;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
}

.action-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.action-btn.disabled:hover {
    transform: none;
    box-shadow: none;
    background: white;
    border-color: #e2e8f0;
    color: #64748b;
}

.edit-btn:hover {
    background: #3b82f6;
    border-color: #3b82f6;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.25);
}

.delete-btn:hover {
    background: #ef4444;
    border-color: #ef4444;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.25);
}

/* Modern Modal Styles */
.modern-modal .modal-content {
    border: none;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.modal-header-modern {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid #e2e8f0;
    padding: 1.5rem;
    position: relative;
}

.modal-title-section {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.modal-title-modern {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a202c;
    margin: 0;
}

.modal-subtitle-modern {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0;
}

.btn-close-modern {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: transparent;
    border: none;
    color: #64748b;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-close-modern:hover {
    background: #f1f5f9;
    color: #374151;
}

.modal-body-modern {
    padding: 2rem;
    background: white;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.form-group-modern {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label-modern {
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
}

.form-control-modern {
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    background: white;
}

.form-control-modern:focus {
    outline: none;
    border-color: #ab0534;
    box-shadow: 0 0 0 3px rgba(171, 5, 52, 0.1);
}

.permissions-section {
    border-top: 1px solid #f1f5f9;
    padding-top: 2rem;
}

.permissions-header {
    margin-bottom: 1.5rem;
}

.permissions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.permission-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.permission-item:hover {
    background: #f1f5f9;
}

.form-check-input-modern {
    width: 18px;
    height: 18px;
    margin-right: 0.75rem;
    border: 2px solid #d1d5db;
    border-radius: 4px;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.form-check-input-modern:checked {
    background: #ab0534;
    border-color: #ab0534;
}

.form-check-label-modern {
    font-weight: 500;
    color: #374151;
    cursor: pointer;
    display: flex;
    align-items: center;
}

.modal-footer-modern {
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    padding: 1.5rem;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

.btn-secondary-modern {
    background: white;
    color: #64748b;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.btn-secondary-modern:hover {
    background: #f8fafc;
    border-color: #9ca3af;
}

/* User-specific table styles */
.user-name-cell {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #d55e7f 0%, #ab0534 100%);
    color: white;
    font-size: 1rem;
    font-weight: 600;
    flex-shrink: 0;
}

.user-info {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.user-id {
    font-size: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
}

.email-cell {
    color: #64748b;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.85rem;
}

.role-badge {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: #0369a1;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #bae6fd;
}

.auth-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid;
}

.auth-badge.local {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    border-color: #fbbf24;
}

.auth-badge.cloud {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
    border-color: #60a5fa;
}

.auth-badge i {
    font-size: 0.75rem;
}

@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
    
    .permissions-grid {
        grid-template-columns: 1fr;
    }
    
    .table-stats {
        flex-direction: column;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .user-name-cell {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .email-cell {
        font-size: 0.8rem;
        word-break: break-all;
    }
}

/* Logs-specific styles */
.logs-filter-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.filter-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 1.5rem;
    align-items: end;
}

.search-input-group {
    position: relative;
    display: flex;
}

.search-input-group .form-control-modern {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border-right: none;
}

.search-btn {
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    color: white;
    border: 1px solid #ab0534;
    border-left: none;
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-top-right-radius: 8px;
    border-bottom-right-radius: 8px;
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-btn:hover {
    background: linear-gradient(135deg, #8f042c 0%, #b91c3c 100%);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(171, 5, 52, 0.25);
}

.filter-actions {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

.timestamp-cell {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.user-cell {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 600;
    flex-shrink: 0;
}

.system-badge {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #6b7280;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #d1d5db;
}

.action-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid;
}

.action-badge.action-create {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #065f46;
    border-color: #10b981;
}

.action-badge.action-update {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    border-color: #f59e0b;
}

.action-badge.action-delete {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    color: #991b1b;
    border-color: #ef4444;
}

.action-badge.action-view {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
    border-color: #3b82f6;
}

.action-badge.action-upload {
    background: linear-gradient(135deg, #e0e7ff 0%, #c7d2fe 100%);
    color: #5b21b6;
    border-color: #8b5cf6;
}

.action-badge.action-download {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #047857;
    border-color: #10b981;
}

.entity-badge {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: #0369a1;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #bae6fd;
}

.details-cell {
    color: #64748b;
    line-height: 1.4;
    max-width: 300px;
}

.modern-pagination {
    display: flex;
    justify-content: between;
    align-items: center;
    padding: 1.5rem;
    border-top: 1px solid #f1f5f9;
    background: #f8fafc;
}

.pagination-info {
    flex: 1;
}

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

.page-item-modern {
    display: flex;
}

.page-link-modern {
    padding: 0.5rem 0.75rem;
    color: #64748b;
    text-decoration: none;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.page-link-modern:hover {
    background: #f8fafc;
    border-color: #ab0534;
    color: #ab0534;
    text-decoration: none;
}

.page-item-modern.active .page-link-modern {
    background: linear-gradient(135deg, #ab0534 0%, #d63447 100%);
    border-color: #ab0534;
    color: white;
    box-shadow: 0 2px 8px rgba(171, 5, 52, 0.25);
}

.page-item-modern.disabled .page-link-modern {
    color: #9ca3af;
    border-color: #f1f5f9;
    background: #f8fafc;
    cursor: not-allowed;
}

@media (max-width: 992px) {
    .filter-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .filter-grid {
        grid-template-columns: 1fr;
    }
    
    .user-cell {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .modern-pagination {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .pagination-modern {
        justify-content: center;
        flex-wrap: wrap;
    }
}

/* Vehicle-specific filter styles */
.vehicles-filter-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.filter-grid-vehicles {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: end;
}

.advanced-filters-toggle {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
}

@media (max-width: 1200px) {
    .filter-grid-vehicles {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .filter-grid-vehicles {
        grid-template-columns: 1fr;
    }
}

/* Maintenance-specific filter styles */
.maintenance-filter-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.filter-grid-maintenance {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: end;
}

@media (max-width: 1200px) {
    .filter-grid-maintenance {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .filter-grid-maintenance {
        grid-template-columns: 1fr;
    }
}

/* Quotes-specific filter styles */
.quotes-filter-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.filter-grid-quotes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: end;
}

@media (max-width: 1200px) {
    .filter-grid-quotes {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .filter-grid-quotes {
        grid-template-columns: 1fr;
    }
}

/* Van Usage-specific filter styles */
.van-usage-filter-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.filter-grid-van-usage {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: end;
}

@media (max-width: 1200px) {
    .filter-grid-van-usage {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .filter-grid-van-usage {
        grid-template-columns: 1fr;
    }
}

/* Fuel Transactions-specific filter styles */
.fuel-transactions-filter-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.filter-grid-fuel-transactions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: end;
}

@media (max-width: 1200px) {
    .filter-grid-fuel-transactions {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .filter-grid-fuel-transactions {
        grid-template-columns: 1fr;
    }
}

/* Quotes table specific styles */
.quote-number-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-weight: 600;
}

.quote-number {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: #0369a1;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.8rem;
    border: 1px solid #bae6fd;
}

.quote-date-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    color: #374151;
    font-size: 0.85rem;
}

.amount-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-weight: 600;
    text-align: right;
}

.amount-value {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    color: #166534;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.9rem;
    border: 1px solid #86efac;
}

.quote-status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    max-width: fit-content;
}

.status-draft {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #374151;
}

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

.status-approved {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    color: #166534;
}

.status-rejected {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    color: #991b1b;
}

.status-completed {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.status-unknown {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

.custom-plate {
    font-style: italic;
    color: #6b7280 !important;
}

.pdf-btn {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%) !important;
    color: white !important;
}

.pdf-btn:hover {
    background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(220, 38, 38, 0.3);
}

/* Van Usage table specific styles */
.expand-btn {
    background: none !important;
    border: none !important;
    color: #6b7280;
    transition: all 0.2s ease;
}

.expand-btn:hover {
    color: #3b82f6;
    transform: scale(1.1);
}

.license-plate-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-weight: 600;
}

.license-plate {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: #0369a1;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.8rem;
    border: 1px solid #bae6fd;
}

.brand-cell, .model-cell {
    color: #374151;
    font-weight: 500;
}

.user-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.user-name {
    font-weight: 600;
    color: #1f2937;
}

.username {
    font-size: 0.8rem;
    color: #6b7280 !important;
}

.datetime-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    color: #374151;
    font-size: 0.85rem;
}

.datetime-value {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.new-btn {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    color: white !important;
}

.new-btn:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
}

/* History container styles */
.history-container {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin: 1rem;
    overflow: hidden;
}

.history-header {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    color: white;
    padding: 0.75rem 1rem;
}

.history-title {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
}

.history-table-container {
    padding: 1rem;
}

.history-table {
    width: 100%;
    margin: 0;
    background: white;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.history-table th {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    color: #374151;
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.75rem 0.5rem;
    border-bottom: 2px solid #e2e8f0;
}

.history-table td {
    padding: 0.75rem 0.5rem;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.85rem;
}

.history-table tbody tr:hover {
    background-color: #f8fafc;
}

.history-datetime {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.8rem;
    color: #4b5563;
}

.history-user {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.who-field, .reason-field {
    color: #374151;
    font-size: 0.85rem;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    text-align: center;
    max-width: fit-content;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.status-active {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.status-completed {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

.history-action-buttons {
    display: flex;
    gap: 0.25rem;
}

.history-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.8rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.history-action-btn.edit-btn {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.history-action-btn.edit-btn:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(59, 130, 246, 0.3);
}

.history-action-btn.delete-btn {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.history-action-btn.delete-btn:hover {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(239, 68, 68, 0.3);
}

/* Fuel Transactions table specific styles */
.transaction-date-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.transaction-date {
    font-weight: 600;
    color: #1f2937;
    font-size: 0.9rem;
}

.transaction-time {
    color: #6b7280;
    font-size: 0.8rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
}

.truck-info-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.truck-name {
    font-weight: 600;
    color: #1f2937;
    font-size: 0.9rem;
}

.vehicle-info {
    color: #6b7280 !important;
    font-size: 0.8rem;
}

.driver-cell {
    color: #374151;
    font-weight: 500;
}

.fuel-type-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    text-align: center;
    max-width: fit-content;
}

.fuel-type-diesel {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.fuel-type-adblue {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    color: white;
}

.fuel-type-gasolie {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.fuel-type-petrol {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.fuel-type-unknown {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

.company-cell {
    color: #374151;
    font-weight: 500;
    font-size: 0.85rem;
}

.quantity-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-weight: 600;
    text-align: right;
}

.quantity-value {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    color: #166534;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.9rem;
    border: 1px solid #86efac;
}

.mileage-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    color: #374151;
    font-size: 0.85rem;
    text-align: right;
}

.mileage-value {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.trimble-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    color: #374151;
    font-size: 0.85rem;
    text-align: right;
}

.trimble-value {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    border: 1px solid #93c5fd;
}

.trimble-no-data {
    color: #6b7280;
    font-size: 0.8rem;
}

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

.consumption-value {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-block;
}

.consumption-ready,
.consumption-trimble,
.consumption-missing,
.consumption-no-vehicle {
    font-size: 0.8rem;
    color: #6b7280;
}

.supplier-cell,
.location-cell {
    color: #374151;
    font-size: 0.85rem;
}

.taxes-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    max-width: fit-content;
}

.taxes-yes {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.taxes-no {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

.calculate-btn {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%) !important;
    color: white !important;
}

.calculate-btn:hover {
    background: linear-gradient(135deg, #0891b2 0%, #0e7490 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(6, 182, 212, 0.3);
}

/* Summary statistics cards */
.stat-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #3b82f6;
}

.stat-number {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #6b7280;
    font-size: 0.9rem;
    margin: 0;
}

/* Maintenance table specific styles */
.task-number-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-weight: 600;
}

.task-number {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: #0369a1;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.8rem;
    border: 1px solid #bae6fd;
}

.vehicle-info-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.vehicle-license {
    font-weight: 600;
    color: #1f2937;
    font-size: 0.9rem;
}

.workshop-badge {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    max-width: fit-content;
}

.mechanic-info-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.mechanic-name {
    font-size: 0.85rem;
    color: #374151;
}

.urgency-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    text-align: center;
    max-width: fit-content;
}

.urgency-high {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.urgency-medium {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.urgency-low {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.urgency-unknown {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

.code-badge {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    max-width: fit-content;
}

.start-date-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    color: #374151;
    font-size: 0.85rem;
}

.task-status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    text-align: center;
    max-width: fit-content;
}

.status-need-planning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.status-planned {
    background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%);
    color: white;
}

.status-in-progress {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
}

.status-on-hold {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
}

.status-completed {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.status-cancelled {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
}

.status-unknown {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: white;
}

/* Vehicle table specific styles */
.vehicle-fleet-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-weight: 600;
}

.fleet-number {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    color: #0369a1;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.8rem;
    border: 1px solid #bae6fd;
}

.vehicle-plate-cell {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-weight: 600;
}

.license-plate {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #374151;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    font-size: 0.8rem;
    border: 1px solid #d1d5db;
    letter-spacing: 0.5px;
}

.vehicle-brand-cell,
.vehicle-model-cell,
.vehicle-company-cell {
    color: #64748b;
    font-weight: 500;
}

.vehicle-type-badge {
    display: inline-flex;
    align-items: center;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid #fbbf24;
}

.vehicle-status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid;
}

.vehicle-status-badge.status-active {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #065f46;
    border-color: #10b981;
}

.vehicle-status-badge.status-maintenance {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    border-color: #f59e0b;
}

.vehicle-status-badge.status-rented {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
    border-color: #3b82f6;
}

.vehicle-status-badge.status-inactive {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #6b7280;
    border-color: #9ca3af;
}

.vehicle-status-badge.status-sold {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    color: #991b1b;
    border-color: #ef4444;
}

.vehicle-status-badge.status-unknown {
    background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
    color: #991b1b;
    border-color: #d1d5db;
}

.sync-btn {
    background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
    color: #6b7280;
    border-color: #d1d5db;
}

.sync-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #f9fafb 0%, #f3f4f6 100%);
    border-color: #d1d5db;
    color: #991b1b;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.25);
}

.sync-btn:disabled {
    background: #f3f4f6;
    border-color: #e5e7eb;
    color: #9ca3af;
    cursor: not-allowed;
}

.view-btn:hover {
    background: #06b6d4;
    border-color: #06b6d4;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(6, 182, 212, 0.25);
}

@media (max-width: 768px) {
    .vehicle-fleet-cell,
    .vehicle-plate-cell {
        font-size: 0.8rem;
    }
    
    .fleet-number,
    .license-plate {
        font-size: 0.7rem;
        padding: 0.125rem 0.375rem;
    }
    
    .action-buttons {
        flex-direction: column;
        gap: 0.25rem;
    }
    
    .action-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Clickable vehicle table rows */
.vehicle-row-clickable {
    transition: background-color 0.2s ease;
}

.vehicle-row-clickable:hover {
    background-color: #f8f9fa !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.vehicle-row-clickable:active {
    background-color: #e9ecef !important;
}

/* Inline date editing styles */
.editable-date {
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 4px 8px;
    border-radius: 4px;
}

.editable-date:hover {
    background-color: #f0f8ff;
    transform: translateY(-1px);
}

.editable-date .edit-icon,
.editable-date .add-icon {
    opacity: 0;
    margin-left: 8px;
    font-size: 12px;
    color: #6c757d;
    transition: opacity 0.2s ease;
}

.editable-date:hover .edit-icon,
.editable-date:hover .add-icon {
    opacity: 1;
}

.editable-date.editing {
    background-color: #fff3cd;
    border: 2px solid #ffc107;
}

.date-edit-input {
    border: none;
    background: transparent;
    font-size: 14px;
    padding: 2px 4px;
    width: 100px;
    text-align: center;
}

.date-edit-input:focus {
    outline: none;
    background-color: white;
    border: 1px solid #007bff;
    border-radius: 3px;
}

.date-edit-actions {
    margin-left: 8px;
    display: inline-flex;
    gap: 4px;
}

.date-edit-btn {
    background: none;
    border: none;
    padding: 2px 4px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s ease;
}

.date-edit-btn.save {
    color: #28a745;
}

.date-edit-btn.save:hover {
    background-color: #28a745;
    color: white;
}

.date-edit-btn.cancel {
    color: #dc3545;
}

.date-edit-btn.cancel:hover {
    background-color: #dc3545;
    color: white;
}

.no-date {
    font-style: italic;
    color: #6c757d !important;
}

/* Vehicle view page date editing styles */
.editable-date-view {
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
    padding: 6px 10px;
    border-radius: 6px;
    display: inline-block;
    min-width: 120px;
}

.editable-date-view:hover {
    background-color: #f0f8ff;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.editable-date-view .edit-icon-view,
.editable-date-view .add-icon-view {
    opacity: 0;
    margin-left: 10px;
    font-size: 14px;
    color: #6c757d;
    transition: opacity 0.2s ease;
}

.editable-date-view:hover .edit-icon-view,
.editable-date-view:hover .add-icon-view {
    opacity: 1;
}

.editable-date-view.editing {
    background-color: #fff3cd;
    border: 2px solid #ffc107;
    box-shadow: 0 0 0 0.2rem rgba(255, 193, 7, 0.25);
}

.editable-date-view .date-value {
    font-weight: 500;
}

.editable-date-view .date-edit-input {
    border: 1px solid #dee2e6;
    background: white;
    font-size: 14px;
    padding: 4px 8px;
    width: 140px;
    border-radius: 4px;
}

.editable-date-view .date-edit-input:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.editable-date-view .date-edit-actions {
    margin-left: 10px;
    display: inline-flex;
    gap: 6px;
}

.editable-date-view .date-edit-btn {
    background: none;
    border: none;
    padding: 4px 6px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
    min-width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.editable-date-view .date-edit-btn.save {
    color: #28a745;
    border: 1px solid #28a745;
}

.editable-date-view .date-edit-btn.save:hover {
    background-color: #28a745;
    color: white;
}

.editable-date-view .date-edit-btn.cancel {
    color: #dc3545;
    border: 1px solid #dc3545;
}

.editable-date-view .date-edit-btn.cancel:hover {
    background-color: #dc3545;
    color: white;
}