/* Reset CSS */
html {
  box-sizing: border-box;
  direction: rtl;
}
*, *:before, *:after {
  box-sizing: inherit;
  margin: 0;
  padding: 0;
}

/* General Styles */
body {
  font-family: 'Vazirmatn', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 18px;
  line-height: 1.7;
  background-color: #e6e6e6;
  color: #333333;
  text-align: right;
}

/* Form Container */
.form {
  background-color: #ffffff;
  width: 90%;
  max-width: 500px;
  margin: 50px auto;
  padding: 30px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Forgot Password Link Styling */
.forgot-password {
  text-align: center;
  margin-top: 15px;
}

h1 {
  color: #5b5b5b;
  font-size: 28px;
  margin-bottom: 20px;
  text-align: center;
  margin: 0 auto;
  padding: 20px 0;
}

/* Form Styles */
label {
  display: block;
  margin-top: 10px;
  color: #5b5b5b;
}

input[type=text],
input[type=password],
button {
  width: 100%;
  padding: 15px;
  margin-top: 10px;
  border: none;
  border-radius: 8px;
  box-sizing: border-box;
}

input[type=text],
input[type=password] {
  font-size: 18px;
  background-color: #edf2f7;
}

button {
  background-color: #4caf50;
  color: #ffffff;
  font-size: 20px;
  cursor: pointer;
  margin-top: 30px;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: #45a049;
}

/* Error Message Styles */
.error {
  background-color: #f44336;
  color: white;
  padding: 10px;
  margin: 10px 0;
  border-radius: 5px;
  text-align: center;
}

/* Link to Register Page */
.new-user {
  text-align: center;
  margin-top: 20px;
}

.new-user a {
  color: #5b5b5b;
  text-decoration: none;
  font-size: 16px;
}

.new-user a:hover {
  text-decoration: underline;
}

.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 8px;
  border: 1px solid #ced4da;
  border-radius: 4px;
  line-height: 1.5;
  font-size: 16px;
  background-color: #ffffff;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: #80bdff;
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.form-group button,
.form-group input[type="submit"] {
  padding: 10px 15px;
  font-size: 18px;
  border-radius: 4px;
  cursor: pointer;
  margin-top: 10px;
}

/* Styling for Submit Buttons */
.form-group input[type="submit"],
.form-group button {
  background-color: #007bff;
  color: white;
  border: none;
}

.form-group input[type="submit"]:hover,
.form-group button:hover {
  background-color: #0056b3;
}

.form-control {
  max-width: 300px;
  margin: auto;
}


/* Main Styles for Panel */
body, .navbar-brand, .nav-link, .footer {
  font-family: 'Vazirmatn', Arial, sans-serif;
}



.navbar-nav {
  margin-left: auto;
}
.navbar {
  position: relative; /* تعیین نوع پوزیشن به موقعیت نسبت به ناوبری */
  z-index: 100; /* تنظیم عمق لایه ای در صفحه */
}
.navbar-img {
  max-width: 100px;
  height: 100px;
}

.sidebar {
    position: fixed;
    bottom: 0;
    top: 10px;
    width: 110px; /* طول جانبی (width) منو را تغییر می‌دهد */
    z-index: 1;
    box-shadow: -2px 0 5px rgba(0, 0, 0, 0.1);
    background-color: #f8f9fa;
    margin-top: 50px; /* فاصله بین منو و محتوا را تنظیم می‌کند */
}

.sidebar ul {
    padding: 0; /* حذف padding اضافی */
    margin: 0; /* حذف margin اضافی */
}

.sidebar .nav-link {
    display: block;
    padding: 12px;
    text-align: center;
    color: #343A40;
    text-decoration: none;
}

.sidebar .nav-link:hover {
  background-color: #343A40;
  color: #ffffff;
}

/* content Styles */

.main-content {
  display: flex;
  justify-content: center; /* این خط باعث می‌شود محتوا در مرکز قرار گیرد. */
  align-items: center;
}

#content {
    
  padding: 20px; /* افزودن فاصله داخلی برای همه طرف‌ها */
  margin: auto; /* قرار دادن در وسط صفحه */
  direction: rtl; /* جهت متن برای زبان‌های راست به چپ مانند فارسی */
  background-color: #fff; /* رنگ پس زمینه دایو فرضاً سفید قرار داده شده است */
  border-radius: 5px; /* دایره‌ای کردن گوشه‌های دایو */
  box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1); /* افزودن سایه ملایم برای زیبایی */
  min-height: 100px; /* تعیین حداقل ارتفاع برای دایو */
  width: auto; /* عرض دایو بر اساس محتوا تنظیم می‌شود */
  display: flex;
  justify-content: center; /* وسط‌چین کردن المان‌ها به صورت افقی */
  align-items: center; /* وسط‌چین کردن المان‌ها به صورت عمودی */
  min-height: 100%; /* حداقل ارتفاع دیوی کانتنت برابر با ارتفاع نمایشگر */
  flex-direction: column; /* چیدمان المان‌ها به صورت ستونی */
  text-align: center; /* وسط‌چین کردن متن */
  font-family: 'vazirmatn', sans-serif; /* اضافه کردن فونت‌های مورد نظر شما */
}
button {
  font-family: 'vazirmatn', sans-serif;
  padding: 0.5em 1em; /* اضافه کردن فاصله داخلی به دکمه */
  margin-top: 1em; /* فضای بالای دکمه */
  cursor: pointer; /* تبدیل نشان‌گر به اشاره‌گر دست هنگام عبور موس */
  /* شما می‌توانید استایل‌های بیشتری برای دکمه اضافه نمایید، مانند تغییر بک گراند و رنگ هنگام هاور */
}




/* Footer Styles */
.footer {
  position: fixed;
  bottom: 0;
  width: 100%;
  background-color: #F8F9FA;
  padding: 12px;
  text-align: center;
  z-index: 100;
}



/* این کلاس برای دکمه غیرفعال است */
.button-disabled {
  background-color: #cccccc; /* رنگ خاکستری */
  border: 1px solid #999999; /* حاشیه خاکستری تیره‌تر */
  color: #666666; /* رنگ متن خاکستری */
}

/* این کلاس برای دکمه فعال است */
.button-enabled {
  background-color: #4CAF50; /* رنگ سبز */
  border: 1px solid green; /* حاشیه سبز تیره‌تر */
  color: white; /* رنگ متن سفید */
}

/* مدیا کوئری برای اعمال تنظیمات فقط در صفحات با اندازه‌های کوچکتر */
@media (max-width: 768px) {
    .sidebar {
        right: 0; /* تنظیم موقعیت سایدبار در قسمت راست */
        left: auto; /* حذف موقعیت سایدبار در سمت چپ */
    }
    
    .navbar-nav {
        flex-direction: row; /* منوی ناوبری را به حالت افقی تغییر می‌دهد */
        justify-content: center; /* المان‌ها را در وسط قرار می‌دهد */
        overflow-x: auto; /* امکان اسکرول افقی را فراهم می‌کند */
    }

    .navbar-nav .nav-item {
        width: auto; /* عرض خودکار برای المان‌های منو */
    }
    
    
}


#messages-link .unread-count {
    color: red !important;
}


.message-details {
  border: 1px solid #ddd;
  padding: 15px;
  margin-bottom: 15px;
}

.message-details h3 {
  margin-top: 0;
}

.sender-name {
  font-weight: bold;
}

.read-status.read {
  color: green;
}

.read-status.unread {
  color: red;
}

.message-content {
  margin-top: 10px;
}

.sent-at {
  font-style: italic;
  color: #aaa;
  margin-top: 10px;
}

