/* Dashboard Base Styles */
.dashboard-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: #f5f7fa;
}

.dashboard-header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.branding {
    display: flex;
    align-items: center;
    gap: 15px;
}

.portal-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--secondary-color);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 20px;
}

.user-greeting {
    text-align: right;
}

.user-greeting span {
    display: block;
    font-size: 0.9rem;
    color: #666;
}

.user-greeting strong {
    font-size: 1rem;
    color: var(--dark-color);
}

.company-info {
    text-align: right;
}

.company-info span {
    display: block;
    font-weight: 600;
}

.company-info small {
    font-size: 0.8rem;
    color: #666;
}

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-toggle {
    background: none;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: var(--dark-color);
    font-size: 0.9rem;
}

.dropdown-toggle i.fa-user-circle {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.dropdown-toggle i.fa-chevron-down {
    font-size: 0.7rem;
    transition: transform 0.3s ease;
}

.dropdown-menu {
    position: absolute;
    right: 0;
    top: 100%;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    padding: 10px 0;
    min-width: 200px;
    display: none;
    z-index: 1000;
}

.dropdown-menu.show {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 8px 20px;
    color: var(--dark-color);
    text-decoration: none;
    transition: all 0.2s ease;
}

.dropdown-menu a:hover {
    background-color: #f8f9fa;
    color: var(--primary-color);
}

.dropdown-menu a i {
    margin-right: 10px;
    width: 20px;
    text-align: center;
}

.dropdown-divider {
    height: 1px;
    background-color: #eee;
    margin: 10px 0;
}

/* Dashboard Navigation */
.dashboard-nav {
    border-top: 1px solid #eee;
}

.dashboard-nav ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.dashboard-nav li {
    margin-right: 30px;
}

.dashboard-nav a {
    display: block;
    padding: 15px 0;
    color: #666;
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.dashboard-nav a:hover {
    color: var(--primary-color);
}

.dashboard-nav a i {
    margin-right: 8px;
}

.dashboard-nav li.active a {
    color: var(--primary-color);
}

.dashboard-nav li.active a:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 3px 3px 0 0;
}

/* Dashboard Main Content */
.dashboard-main {
    flex: 1;
    padding: 30px 0;
}

.dashboard-alerts {
    margin-bottom: 30px;
}

.alert {
    display: flex;
    padding: 15px;
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    align-items: center;
}

.alert i {
    font-size: 1.5rem;
    margin-right: 15px;
}

.alert-content {
    flex: 1;
}

.alert-link {
    margin-left: 10px;
    font-weight: 600;
    color: inherit;
    text-decoration: underline;
}

.alert-warning {
    background-color: #fff3cd;
    color: #856404;
}

.alert-info {
    background-color: #d1ecf1;
    color: #0c5460;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
}

.dashboard-welcome {
    margin-bottom: 30px;
}

.dashboard-welcome h1 {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.dashboard-welcome .lead {
    color: #666;
    margin-bottom: 0;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 20px;
    display: flex;
    align-items: center;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: white;
    font-size: 1.5rem;
}

.stat-icon.bg-primary {
    background-color: var(--primary-color);
}

.stat-icon.bg-success {
    background-color: var(--success-color);
}

.stat-icon.bg-warning {
    background-color: var(--warning-color);
}

.stat-icon.bg-info {
    background-color: var(--info-color);
}

.stat-icon.bg-danger {
    background-color: var(--danger-color);
}

.stat-content h3 {
    font-size: 1rem;
    margin-bottom: 5px;
    color: #666;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--dark-color);
}

.stat-link {
    font-size: 0.9rem;
    color: var(--primary-color);
    text-decoration: none;
}

.stat-link:hover {
    text-decoration: underline;
}

/* Section Cards */
.dashboard-sections {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

.section-card {
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-bottom: 20px;
}

.section-header {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.section-header h2 {
    font-size: 1.2rem;
    margin: 0;
    display: flex;
    align-items: center;
}

.section-header h2 i {
    margin-right: 10px;
    color: var(--primary-color);
}

.section-body {
    padding: 20px;
}

/* Data Tables */
.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th, .data-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.data-table th {
    font-weight: 600;
    color: #666;
    font-size: 0.9rem;
    text-transform: uppercase;
}

.data-table tr:hover td {
    background-color: #f9f9f9;
}

.badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-success {
    background-color: #d4edda;
    color: #155724;
}

.badge-warning {
    background-color: #fff3cd;
    color: #856404;
}

.badge-danger {
    background-color: #f8d7da;
    color: #721c24;
}

.btn-icon {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    margin-right: 10px;
    font-size: 1rem;
}

.btn-icon:hover {
    color: var(--primary-color);
}

/* Action Lists */
.action-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.action-item {
    display: flex;
    align-items: center;
    padding: 15px;
    background-color: #f9f9f9;
    border-radius: var(--border-radius);
}

.action-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: white;
    font-size: 1rem;
}

.action-content {
    flex: 1;
}

.action-content h3 {
    font-size: 1rem;
    margin-bottom: 5px;
}

.action-content p {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 10px;
}

.action-buttons {
    display: flex;
    gap: 10px;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 0.8rem;
}

/* Activity Feed */
.activity-feed {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.activity-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.activity-icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.activity-content p {
    margin-bottom: 5px;
}

.text-muted {
    color: #999;
    font-size: 0.8rem;
}

/* Chart Container */
.chart-container {
    height: 250px;
    margin-bottom: 20px;
}

.fleet-summary {
    display: flex;
    justify-content: space-around;
    text-align: center;
}

.summary-item {
    padding: 10px;
}

.summary-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-color);
}

.summary-label {
    font-size: 0.9rem;
    color: #666;
}

/* Dashboard Footer */
.dashboard-footer {
    background-color: white;
    padding: 20px 0;
    border-top: 1px solid #eee;
    margin-top: 30px;
}

.dashboard-footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dashboard-footer p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: #666;
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--primary-color);
}

/* Corporate Dashboard Specific Styles */
.corporate-dashboard .stat-icon {
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
}

.corporate-dashboard .section-card {
    margin-bottom: 0;
}

/* Responsive Design */
@media (max-width: 992px) {
    .dashboard-sections {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .user-info {
        margin-top: 15px;
        width: 100%;
        justify-content: space-between;
    }

    .dashboard-nav ul {
        overflow-x: auto;
        padding-bottom: 10px;
    }

    .dashboard-nav li {
        margin-right: 15px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 576px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .action-item {
        flex-direction: column;
    }

    .action-icon {
        margin-right: 0;
        margin-bottom: 10px;
    }

    .action-buttons {
        flex-direction: column;
        gap: 5px;
    }

    .action-buttons .btn {
        width: 100%;
    }
}
