/* Base Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 20px;
    background-color: #f4f6f9;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.login_container {
    max-width: 400px;
    margin: 0 auto;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

.navbar {
    background: #2c3e50;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
}

.navbar a {
    color: white;
    text-decoration: none;
    margin-right: 20px;
    padding: 10px;
}

.navbar a:hover {
    background-color: #34495e;
    border-radius: 4px;
}



/* Navbar Styles */
.navbar {
    background: #2c3e50;
    color: white;
    padding: 0 20px;
    position: relative;
    z-index: 1000;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-section {
    display: flex;
    align-items: center;
}

.nav-logo {
    font-size: 1.5em;
    font-weight: bold;
    color: white;
    text-decoration: none;
    margin-right: 30px;
}

.nav-items {
    display: flex;
    gap: 15px;
}

.nav-link, .user-greeting {
    color: white;
    padding: 15px 10px;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.3s;
}

.nav-link:hover, .user-greeting:hover {
    background: #34495e;
}

/* Dropdown Styles */
.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: white;
    min-width: 200px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    z-index: 1;
    top: 100%;
}

.dropdown:hover .dropdown-content {
    display: block;
}

.dropdown-content a {
    color: #2c3e50;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    transition: background 0.3s;
}

.dropdown-content a:hover {
    background: #f8f9fa;
}

.right-aligned {
    right: 0;
}

/* User Controls */
.user-controls {
    margin-left: auto;
}

.user-greeting {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 15px 20px;
}

.user-greeting i {
    font-size: 1.2em;
}

/* Icons */
.fas {
    margin-right: 8px;
}



.form-group {
    margin-bottom: 15px;
}

.form-control {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.btn-primary {
    background-color: #3498db;
    color: white;
}

.btn-danger {
    background-color: #e74c3c;
    color: white;
}

.table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.table th, .table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.table th {
    background-color: #f8f9fa;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
}

/* Transaction Entry */
.entry-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 10px;
    margin-bottom: 10px;
}

/* Transaction Form */
.totals {
    margin: 20px 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.totals strong {
    display: inline-block;
    margin-right: 30px;
    font-size: 1.1em;
}

.entry-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr auto;
    gap: 10px;
    margin-bottom: 10px;
    align-items: center;
}

.entry-row select,
.entry-row input {
    width: 100%;
}

button[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Error Messages */
.error-list {
    color: #dc3545;
    padding: 10px;
    margin-bottom: 20px;
    border: 1px solid #f5c2c7;
    border-radius: 4px;
}

.error-list li {
    list-style: none;
}

/* CoA Tree View */
.account-tree ul.tree {
    list-style-type: none;
    padding-left: 20px;
}

.account-tree li {
    margin: 5px 0;
    position: relative;
}

.account-tree .account-item {
    padding: 8px;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    display: inline-block;
}

.account-tree .btn-sm {
    padding: 3px 8px;
    font-size: 0.8em;
    margin-left: 10px;
}

/* User Management Styles */
.form-section {
    margin-bottom: 40px;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.action-buttons {
    display: flex;
    gap: 10px;
}

.form-section h3 {
    margin-top: 0;
    color: #2c3e50;
    border-bottom: 2px solid #3498db;
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    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;
}

/* Dashboard Styles */
.quick-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    text-align: center;
}

.stat-card h3 {
    margin: 0 0 10px 0;
    color: #666;
    font-size: 1.1em;
}

.stat-card p {
    font-size: 1.4em;
    margin: 0;
    font-weight: bold;
    color: #2c3e50;
}

.chart-container {
    margin: 30px 0;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.recent-activity {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

.quick-actions {
    margin-top: 30px;
    text-align: center;
}

.quick-actions .btn {
    margin: 0 10px;
    min-width: 150px;
}



.inventory-table {
    margin-top: 20px;
    overflow-x: auto;
}

.filter-form {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 4px;
}

.text-danger {
    color: #dc3545;
    font-weight: bold;
}

.text-center {
    text-align: center;
}

.table tfoot th {
    background-color: #e9ecef;
}

.btn {
    padding: 8px 15px;
    border-radius: 4px;
    text-decoration: none;
}

.btn-primary {
    background-color: #007bff;
    color: white;
}




@media (max-width: 768px) {
    .recent-activity {
        grid-template-columns: 1fr;
    }
    
    .quick-stats {
        grid-template-columns: 1fr 1fr;
    }
}

.form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 15px;
}

.invoice-item {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr auto;
    gap: 10px;
    margin-bottom: 15px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.total-section {
    margin: 20px 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.btn {
    padding: 8px 15px;
    margin: 0 5px;
    cursor: pointer;
}

.product-select {
    width: 100%;
}