/* ... (تنسيقات CSS السابقة تبقى كما هي) ... */

/* تنسيقات خاصة بإضافة القيد */
fieldset {
    border: 1px solid #ccc;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 6px;
}
legend {
    font-size: 1.1em;
    font-weight: bold;
    color: #555;
}
.entry-header label, .entry-lines label {
    display: block;
    font-weight: 500;
    margin-top: 10px;
}
.entry-header input, .entry-header select, .entry-header textarea {
    width: 100%;
    padding: 8px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    box-sizing: border-box;
}

/* جدول سطور القيد */
#journalLinesTable {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}
#journalLinesTable th, #journalLinesTable td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}
#journalLinesTable select, #journalLinesTable input[type="text"], #journalLinesTable input[type="number"] {
    width: 100%;
    box-sizing: border-box;
    border: none;
    padding: 5px;
}
.totals-row td {
    font-weight: bold;
    background-color: #f9f9f9;
}
.total {
    font-family: monospace;
    font-size: 1.1em;
}

/* حالة التوازن */
#balanceStatus {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 0.9em;
}
.balanced {
    background-color: #d4edda;
    color: #155724;
}
.unbalanced {
    background-color: #f8d7da;
    color: #721c24;
}
.btn-danger { background-color: #dc3545; color: white; border: none; padding: 5px 10px; cursor: pointer; border-radius: 3px; }
.btn-primary { background-color: #007bff; color: white; border: none; padding: 10px 20px; margin-top: 20px; cursor: pointer; }
.btn-primary:disabled { background-color: #6c757d; cursor: not-allowed; }
.alert {
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 4px;
    background-color: #e2e3e5;
    color: #383d41;
    border: 1px solid #d6d8d9;
}


/* --- تنسيق شريط التنقل (Navbar) --- */
.main-header {
    background-color: #0056b3; /* لون أزرق داكن */
    color: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    margin-bottom: 30px; /* مسافة بين شريط التنقل والمحتوى */
}

.navbar {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
}

.logo a {
    color: white;
    text-decoration: none;
    font-size: 1.5em;
    font-weight: bold;
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.nav-links > li {
    position: relative;
    margin-right: 20px; /* المسافة بين العناصر الرئيسية */
}

.nav-links a {
    color: white;
    text-decoration: none;
    padding: 10px 15px;
    display: block;
    transition: background-color 0.3s;
    border-radius: 4px;
}

.nav-links a:hover {
    background-color: #007bff;
}

/* --- تنسيق القوائم المنسدلة (Dropdown) --- */
.dropdown-content {
    display: none;
    position: absolute;
    background-color: white;
    min-width: 200px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
    right: 0; /* لجعل القائمة المنسدلة تظهر من اليمين (لغة عربية) */
    border-radius: 4px;
    overflow: hidden;
}

.dropdown-content a {
    color: #333;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: right;
}

.dropdown-content a:hover {
    background-color: #f1f1f1;
}

.dropdown:hover .dropdown-content {
    display: block;
}

.user-info {
    font-size: 0.9em;
    opacity: 0.8;
}

