/* css/style.css */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 20px;
    margin-bottom: 20px;
}

h1, h2, h3 {
    margin-bottom: 16px;
    color: #2c3e50;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.btn {
    padding: 10px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    text-decoration: none;
    display: inline-block;
    transition: background 0.3s;
}

.btn-primary {
    background-color: #3498db;
    color: white;
}
.btn-primary:hover {
    background-color: #2980b9;
}

.btn-danger {
    background-color: #e74c3c;
    color: white;
}
.btn-danger:hover {
    background-color: #c0392b;
}

.btn-warning {
    background-color: #f39c12;
    color: white;
}
.btn-warning:hover {
    background-color: #d35400;
}

.btn-secondary {
    background-color: #95a5a6;
    color: white;
}
.btn-secondary:hover {
    background-color: #7f8c8d;
}

.btn-outline {
    background: transparent;
    border: 1px solid #3498db;
    color: #3498db;
}
.btn-outline:hover {
    background: #3498db;
    color: white;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 14px;
}

.alert {
    padding: 12px;
    margin-bottom: 16px;
    border-radius: 4px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: #f8f9fa;
    font-weight: 600;
}

tr:hover {
    background-color: #f5f5f5;
}

.table-responsive {
    overflow-x: auto;
}

.filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: end;
}

.filter-form input,
.filter-form select {
    padding: 8px;
    font-size: 14px;
}

.mb-20 {
    margin-bottom: 20px;
}

.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: #ecf0f1;
}

.login-body .card {
    width: 100%;
    max-width: 400px;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }

    .filters {
        flex-direction: column;
    }

    .filters .btn {
        width: 100%;
    }
}



/* ========== Dark Mode ========== */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

body.dark-mode .card,
body.dark-mode .filters,
body.dark-mode table,
body.dark-mode th {
    background-color: #1e1e1e;
    color: #f0f0f0;
    border-color: #333;
}

body.dark-mode input,
body.dark-mode select,
body.dark-mode button {
    background-color: #2a2a2a;
    color: #f0f0f0;
    border-color: #444;
}

body.dark-mode input::placeholder {
    color: #aaa;
}

body.dark-mode tr:hover {
    background-color: #252525;
}

body.dark-mode .alert-success {
    background-color: #2c5530;
    border-color: #3a703d;
    color: #d4edda;
}

body.dark-mode .alert-error {
    background-color: #5a2a2a;
    border-color: #703a3a;
    color: #f8d7da;
}

/* Toggle Button Styling */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    background: none;
    border: 1px solid #ddd;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    z-index: 1000;
    transition: background 0.3s;
}

body.dark-mode .theme-toggle {
    border-color: #555;
    background: #2a2a2a;
    color: #f0f0f0;
}

.theme-toggle:hover {
    background: #f0f0f020;
}

body.dark-mode .theme-toggle:hover {
    background: #ffffff10;
}