/* css/style.css */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    min-height: 100vh;
}

/* Top Navigation */
.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: linear-gradient(135deg, #1a237e 0%, #283593 100%);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}
/* Add to your css/style.css or css/dashboard.css */
.logo {
    max-width: 150px;  /* Adjust as needed */
    height: auto;
    display: block;   /* Ensures it's visible */
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Fallback style if image doesn't load */
.logo-fallback {
    width: 50px;
    height: 50px;
    background-color: #2c3e50;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    border-radius: 5px;

}

.logo-text h1 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: -5px;
}

.logo-text p {
    font-size: 0.8rem;
    opacity: 0.8;
}

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

.username {
    font-weight: 500;
}

.user-dropdown {
    position: relative;
    cursor: pointer;
}

.user-dropdown i {
    font-size: 28px;
    color: white;
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: 100%;
    background: white;
    min-width: 180px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border-radius: 8px;
    overflow: hidden;
    z-index: 1001;
}

.dropdown-content i {
    font-size: 16px;
    color: #4a90e2;
    width: 20px;
    text-align: center;
}

.dropdown-content a {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: background 0.3s;
}

.dropdown-content a:hover {
    background: #f5f5f5;
}

.user-dropdown:hover .dropdown-content {
    display: block;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0;
    top: 70px;
    bottom: 0;
    width: 250px;
    background: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.05);
    overflow-y: auto;
    z-index: 999;
}

.nav-menu {
    list-style: none;
    padding: 20px 0;
}

.nav-menu li {
    margin-bottom: 5px;
}

.nav-menu a {
    display: flex;
    align-items: center;
    padding: 15px 25px;
    color: #555;
    text-decoration: none;
    transition: all 0.3s;
    border-left: 4px solid transparent;
}

.nav-menu a:hover {
    background: #f8f9fa;
    color: #1a237e;
    border-left: 4px solid #1a237e;
}

.nav-menu a.active {
    background: linear-gradient(90deg, rgba(26, 35, 126, 0.1) 0%, transparent 100%);
    color: #1a237e;
    border-left: 4px solid #1a237e;
    font-weight: 500;
}

.nav-menu i {
    width: 24px;
    margin-right: 15px;
    font-size: 1.2rem;
}

.nav-divider {
    height: 1px;
    background: #e0e0e0;
    margin: 20px 25px;
}

.sidebar-footer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 25px;
    border-top: 1px solid #e0e0e0;
    background: white;
}

.system-status {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.status-online {
    color: #4caf50;
    font-size: 0.8rem;
}

.sidebar-time {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: #666;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 250px;
    margin-top: 70px;
    padding: 30px;
    min-height: calc(100vh - 70px);
}

/* Cards */
.card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    margin-bottom: 25px;
    transition: transform 0.3s, box-shadow 0.3s;
}

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

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.card-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #1a237e;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, #1a237e 0%, #283593 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #283593 0%, #1a237e 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 35, 126, 0.2);
}

.btn-success {
    background: linear-gradient(135deg, #4caf50 0%, #2e7d32 100%);
    color: white;
}

.btn-success:hover {
    background: linear-gradient(135deg, #2e7d32 0%, #4caf50 100%);
    transform: translateY(-1px);
}

.btn-danger {
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
    color: white;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #d32f2f 0%, #f44336 100%);
    transform: translateY(-1px);
}

.btn-secondary {
    background: #757575;
    color: white;
}

.btn-secondary:hover {
    background: #616161;
    transform: translateY(-1px);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.875rem;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #555;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #1a237e;
    box-shadow: 0 0 0 3px rgba(26, 35, 126, 0.1);
}

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

.table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.table th {
    background: linear-gradient(135deg, #1a237e 0%, #283593 100%);
    color: white;
    padding: 15px;
    text-align: left;
    font-weight: 500;
}

.table td {
    padding: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.table tr:hover {
    background-color: #f8f9fa;
}

.table-actions {
    display: flex;
    gap: 8px;
}

/* Grid */
.row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

/* Login Page */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #1a237e 0%, #283593 100%);
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
}

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

.login-header h1 {
    color: #1a237e;
    margin-bottom: 10px;
}

.login-header p {
    color: #666;
}

/* Alerts */
.alert {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert-success {
    background: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #c8e6c9;
}

.alert-error {
    background: #ffebee;
    color: #d32f2f;
    border: 1px solid #ffcdd2;
}

.alert-warning {
    background: #fff3e0;
    color: #f57c00;
    border: 1px solid #ffe0b2;
}

/* Responsive */
@media (max-width: 1024px) {
    .sidebar {
        width: 70px;
    }
    
    .sidebar .nav-menu span,
    .sidebar .logo-text,
    .sidebar .system-status span,
    .sidebar .sidebar-time span {
        display: none;
    }
    
    .main-content {
        margin-left: 70px;
    }
    
    .nav-menu a {
        justify-content: center;
        padding: 15px;
    }
    
    .nav-menu i {
        margin-right: 0;
    }
}

@media (max-width: 768px) {
    .top-nav {
        padding: 0 15px;
    }
    
    .main-content {
        padding: 20px;
    }
    
    .card {
        padding: 20px;
    }
    
    .row {
        grid-template-columns: 1fr;
    }
}