/* Custom styles for SIMKD */

/* General styles */
body {
    background-color: #f8f9fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow-x: hidden;
}

/* Sidebar styles */
.wrapper {
    display: flex;
    width: 100%;
}

#sidebar {
    width: 250px;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 999;
    background: #0d6efd;
    color: #fff;
    transition: all 0.3s;
}

#sidebar.active {
    margin-left: -250px;
}

#sidebar .sidebar-header {
    padding: 20px;
    background: #0b5ed7;
}

#sidebar ul.components {
    padding: 20px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

#sidebar ul li {
    padding: 0;
    margin: 0;
}

#sidebar ul li a {
    padding: 10px 20px;
    font-size: 1.1em;
    display: block;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s;
}

#sidebar ul li a:hover {
    color: #0d6efd;
    background: #fff;
}

#sidebar ul li.active > a,
a[aria-expanded="true"] {
    color: #fff;
    background: #0b5ed7;
}

#sidebar ul ul a {
    font-size: 0.9em !important;
    padding-left: 40px !important;
    background: rgba(0, 0, 0, 0.1);
}

.sidebar-user-info {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.user-avatar {
    color: white;
}

.user-name {
    font-weight: bold;
    margin-bottom: 5px;
}

.sidebar-footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.1);
}

/* Content Style */
#content {
    width: calc(100% - 250px);
    padding: 20px;
    min-height: 100vh;
    transition: all 0.3s;
    position: absolute;
    top: 0;
    right: 0;
}

#content.active {
    width: 100%;
}

/* Mediaqueries */
@media (max-width: 768px) {
    #sidebar {
        margin-left: -250px;
    }
    #sidebar.active {
        margin-left: 0;
    }
    #content {
        width: 100%;
    }
    #content.active {
        width: calc(100% - 250px);
        position: fixed;
    }
    #sidebarCollapse span {
        display: none;
    }
}

#sidebarCollapse {
    width: 40px;
    height: 40px;
    background: #f8f9fa;
}

#sidebarCollapse span {
    width: 80%;
    height: 2px;
    margin: 0 auto;
    display: block;
    background: #555;
    transition: all 0.8s cubic-bezier(0.810, -0.330, 0.345, 1.375);
}

.sidebar-user-info {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.user-avatar {
    color: white;
}

.user-name {
    font-weight: bold;
    margin-bottom: 5px;
}

/* Responsive sidebar */
@media (max-width: 768px) {
    #sidebar {
        margin-left: -250px;
    }
    #sidebar.active {
        margin-left: 0;
    }
    #content {
        margin-left: 0;
    }
    #content.active {
        margin-left: 250px;
    }
}

.card {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    margin-bottom: 1.5rem;
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid rgba(0, 0, 0, 0.125);
    font-weight: 500;
}

/* Login page */
.login-container {
    max-width: 400px;
    margin: 0 auto;
    padding-top: 100px;
}

.login-logo {
    text-align: center;
    margin-bottom: 30px;
}

.login-logo i {
    font-size: 4rem;
    color: #0d6efd;
}

.login-title {
    text-align: center;
    margin-bottom: 30px;
}

/* Dashboard */
.dashboard-card {
    transition: transform 0.3s;
}

.dashboard-card:hover {
    transform: translateY(-5px);
}

.dashboard-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Tables */
.table-action-buttons .btn {
    margin-right: 5px;
}

.table-action-buttons .btn:last-child {
    margin-right: 0;
}

/* Forms */
.required-field::after {
    content: " *";
    color: red;
}

/* Vehicle status */
.status-good {
    color: #198754;
}

.status-maintenance {
    color: #ffc107;
}

.status-damaged {
    color: #dc3545;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .table-responsive {
        font-size: 0.875rem;
    }
    
    .dashboard-icon {
        font-size: 2rem;
    }
}
