/* استایل اصلی سیستم */
body {
    font-family: 'Vazirmatn', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    line-height: 1.6;
}

/* ناوبری */
.navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
}

.navbar-brand {
    font-weight: 700;
}

/* کارت‌ها */
.card {
    border: none;
    box-shadow: 0 0 20px rgba(0,0,0,.08);
    margin-bottom: 20px;
    border-radius: 10px;
}

.card-header {
    border-radius: 10px 10px 0 0 !important;
    font-weight: 600;
}

/* جداول */
.table th {
    background-color: #f1f5fd;
    border-top: none;
    font-weight: 600;
}

.table-hover tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.05);
}

/* دکمه‌ها */
.btn {
    border-radius: 5px;
    padding: 8px 20px;
    font-weight: 500;
}

.btn-primary {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
}

/* فرم‌ها */
.form-control, .form-select {
    border-radius: 5px;
    padding: 10px 15px;
    border: 1px solid #ced4da;
}

.form-control:focus, .form-select:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 8px;
}

.form-text {
    font-size: 0.85rem;
    color: #6c757d;
}

/* وضعیت‌ها */
.badge {
    font-weight: 500;
    padding: 6px 12px;
    border-radius: 20px;
}

/* آیکون‌ها */
.bi {
    vertical-align: -0.125em;
}

/* هدر جداول */
.table-responsive {
    border-radius: 10px;
    overflow: hidden;
}

/* پیام‌ها */
.alert {
    border-radius: 8px;
    border: none;
    padding: 15px 20px;
}

.alert-success {
    background-color: #d1e7dd;
    color: #0f5132;
}

.alert-danger {
    background-color: #f8d7da;
    color: #842029;
}

.alert-warning {
    background-color: #fff3cd;
    color: #664d03;
}

.alert-info {
    background-color: #cff4fc;
    color: #055160;
}

/* صفحه‌بندی */
.pagination {
    justify-content: center;
    margin-top: 20px;
}

.page-link {
    border-radius: 5px;
    margin: 0 3px;
    border: none;
    color: #0d6efd;
}

.page-item.active .page-link {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

/* استایل برای صفحات مختلف */
.login-page {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    max-width: 400px;
    width: 100%;
}

/* مودال */
.modal-content {
    border-radius: 10px;
    border: none;
    box-shadow: 0 10px 30px rgba(0,0,0,.2);
}

.modal-header {
    border-radius: 10px 10px 0 0;
    background-color: #f8f9fa;
}

/* دراپ‌داون */
.dropdown-menu {
    border-radius: 8px;
    border: none;
    box-shadow: 0 5px 15px rgba(0,0,0,.1);
    padding: 10px 0;
}

.dropdown-item {
    padding: 8px 20px;
    border-radius: 5px;
    margin: 2px 10px;
    width: auto;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
}

/* استایل مخصوص تلفن همراه */
@media (max-width: 768px) {
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .card {
        margin-bottom: 15px;
    }
    
    .table-responsive {
        font-size: 0.9rem;
    }
}

/* استایل برای دکمه‌های عملیات */
.btn-group-sm > .btn, .btn-sm {
    padding: 5px 10px;
    font-size: 0.875rem;
}

/* استایل برای فیلدهای الزامی */
.is-invalid {
    border-color: #dc3545 !important;
}

.is-valid {
    border-color: #198754 !important;
}

/* استایل برای نمایش تاریخ شمسی */
.persian-date {
    font-family: 'Vazirmatn', sans-serif;
    direction: rtl;
}

/* استایل برای spinner */
.spinner-border {
    width: 1.5rem;
    height: 1.5rem;
}

/* استایل برای tooltip */
.tooltip {
    font-family: 'Vazirmatn', sans-serif;
}

/* استایل برای بازخورد فرم */
.was-validated .form-control:valid {
    border-color: #198754;
    padding-right: calc(1.5em + 0.75rem);

    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.was-validated .form-control:invalid {
    border-color: #dc3545;
    padding-right: calc(1.5em + 0.75rem);
   
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}