/**
 * Persian Custom Styles - Warm & Rounded Design
 * فونت: ایران‌سنس / Vazir
 * Border Radius: 15px برای المان‌های اصلی
 */

/* Remove Bootstrap's default dropdown-toggle chevron when we use custom icons */
.btn.dropdown-toggle::after {
    display: none !important;
}

/* Fix chevron icon position in sidebar menu for RTL */
/* Hide the default ::after pseudo-element that shows Material Design Icons chevron */
/* Use maximum specificity to override all other styles */
.navbar-nav .nav-link[data-bs-toggle="collapse"]::after,
.navbar-nav .nav-link.menu-link[data-bs-toggle="collapse"]::after,
.app-menu .navbar-nav .nav-link[data-bs-toggle="collapse"]::after,
.app-menu .navbar-nav .menu-link[data-bs-toggle="collapse"]::after,
.app-menu .navbar-nav .nav-link[data-bs-toggle="collapse"]::after,
body .app-menu .navbar-nav .nav-link[data-bs-toggle="collapse"]::after,
body .app-menu .navbar-nav .menu-link[data-bs-toggle="collapse"]::after {
    display: none !important;
    content: none !important;
    visibility: hidden !important;
}

/* Make nav-item full width */
.navbar-nav .nav-item,
.app-menu .navbar-nav .nav-item,
body .app-menu .navbar-nav .nav-item {
    width: 100% !important;
}

/* Make nav-link a flex container to enable auto margins */
.navbar-nav .nav-link[data-bs-toggle="collapse"],
.navbar-nav .nav-link.menu-link[data-bs-toggle="collapse"],
.navbar-nav .menu-link[data-bs-toggle="collapse"],
.app-menu .navbar-nav .nav-link[data-bs-toggle="collapse"],
.app-menu .navbar-nav .menu-link[data-bs-toggle="collapse"],
body .app-menu .navbar-nav .nav-link[data-bs-toggle="collapse"],
body .app-menu .navbar-nav .menu-link[data-bs-toggle="collapse"] {
    display: flex !important;
    align-items: center !important;
    gap: 0.5rem !important;
    width: 100% !important;
}

/* In RTL, margin-right: auto pushes chevron to the left (end) */
/* Use maximum specificity to override SCSS styles from app.rtl.css */
.navbar-nav .nav-link[data-bs-toggle="collapse"] .svg-icon.me-auto,
.navbar-nav .nav-link.menu-link[data-bs-toggle="collapse"] .svg-icon.me-auto,
.navbar-nav .menu-link[data-bs-toggle="collapse"] .svg-icon.me-auto,
.app-menu .navbar-nav .nav-link[data-bs-toggle="collapse"] .svg-icon.me-auto,
.app-menu .navbar-nav .menu-link[data-bs-toggle="collapse"] .svg-icon.me-auto,
body .app-menu .navbar-nav .nav-link[data-bs-toggle="collapse"] .svg-icon.me-auto,
body .app-menu .navbar-nav .menu-link[data-bs-toggle="collapse"] .svg-icon.me-auto {
    margin-right: auto !important;
    margin-left: 0 !important;
    flex-shrink: 0 !important;
    order: 999 !important; /* Move to end (left in RTL) */
    position: relative !important;
}

/* SweetAlert2 RTL Support */
.swal2-toast-rtl {
    direction: rtl !important;
    text-align: right !important;
    font-family: 'IranSans', 'Vazir', 'Tahoma', 'Arial', sans-serif !important;
}

.swal2-title-rtl {
    direction: rtl !important;
    text-align: right !important;
    font-family: 'IranSans', 'Vazir', 'Tahoma', 'Arial', sans-serif !important;
}

.swal2-html-container-rtl {
    direction: rtl !important;
    text-align: right !important;
    font-family: 'IranSans', 'Vazir', 'Tahoma', 'Arial', sans-serif !important;
}

.swal2-popup.swal2-toast {
    direction: rtl !important;
    font-family: 'IranSans', 'Vazir', 'Tahoma', 'Arial', sans-serif !important;
}

.swal2-popup.swal2-toast .swal2-title {
    direction: rtl !important;
    text-align: right !important;
    margin-right: 0.5em !important;
    margin-left: 0 !important;
}

.swal2-popup.swal2-toast .swal2-html-container {
    direction: rtl !important;
    text-align: right !important;
}

/* کوچک کردن سایز toast */
.swal2-popup.swal2-toast {
    padding: 0.75em 1em !important;
    min-width: 250px !important;
    max-width: 350px !important;
    font-size: 0.875rem !important;
    border-radius: 15px !important;
    backdrop-filter: blur(1px) !important;
    background: #ffffffd6;
}

.swal2-popup.swal2-toast .swal2-title {
    font-size: 0.875rem !important;
    margin-bottom: 0.25em !important;
    padding: 0 !important;
}

.swal2-popup.swal2-toast .swal2-html-container {
    font-size: 0.8125rem !important;
    margin: 0.5em 0 0 0 !important;
    padding: 0 !important;
}

.swal2-popup.swal2-toast .swal2-icon {
    width: 1.5em !important;
    height: 1.5em !important;
    margin: 0 0.5em 0 0 !important;
}

.swal2-popup.swal2-toast .swal2-icon-content {
    font-size: 1.2em !important;
    line-height: 1.5em !important;
}

/* تنظیم فونت ایران‌سنس برای کل صفحه */
body,
html {
    font-family: 'IranSans', 'Vazir', 'Tahoma', 'Arial', sans-serif !important;
}

/* رادیوس اینپوت‌ها در فرم‌های لاگین و ثبت‌نام */
.form-control,
.input-group-text,
.form-select {
    border-radius: 15px !important;
}

.input-group .form-control:first-child {
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

.input-group .input-group-text:first-child {
    border-top-right-radius: 12px !important;
    border-bottom-right-radius: 12px !important;
}

.input-group .form-control:last-child {
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

.input-group .input-group-text:last-child {
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

/* کارت‌ها - گردتر و گرم‌تر */
.card {
    border-radius: 15px !important;
    border: none !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
    transition: box-shadow 0.3s ease !important;
    overflow: hidden;
    transform: none !important;
}

.card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12) !important;
    transform: none !important;
}

.card-header {
    border-radius: 15px 15px 0 0 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
    padding: 1.25rem 1.5rem !important;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%) !important;
}

.card-body {
    padding: 1.5rem !important;
}

/* دکمه‌ها - گردتر و گرم‌تر */
.btn {
    border-radius: 15px !important;
    padding: 0.6rem 1.5rem !important;
    font-weight: 500 !important;
    transition: all 0.3s ease !important;
    border: none !important;
}

/* استثنا: دکمه‌های خاص نباید گرد باشند */
.btn.p-0,
.btn.btn-icon,
.btn-topbar,
.btn-ghost-secondary,
#vertical-hover,
.btn-vertical-sm-hover,
.topnav-hamburger,
#topnav-hamburger-icon,
.vertical-menu-btn {
    border-radius: 0 ;
}

.rounded{
    border-radius: 12px !important;
}

/* دکمه‌های rounded-circle باید دایره بمانند */
.btn.rounded-circle {
    border-radius: 50% !important;
}

.btn:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
}

.btn:active {
    transform: translateY(0) !important;
}

.btn-sm {
    border-radius: 12px !important;
    padding: 0.4rem 1rem !important;
}

.btn-lg {
    border-radius: 18px !important;
    padding: 0.8rem 2rem !important;
}

/* دکمه‌های رنگی با گرادیانت گرم */
.btn-primary {
    background: linear-gradient(135deg, #29365d 0%, #764ba2 100%) !important;
    color: #fff !important;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #764ba2 0%, #29365d 100%) !important;
}

.btn-success {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%) !important;
    color: #fff !important;
}

.btn-success:hover {
    background: linear-gradient(135deg, #38ef7d 0%, #11998e 100%) !important;
}

.btn-danger {
    background: linear-gradient(135deg, #eb3349 0%, #f45c43 100%) !important;
    color: #fff !important;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #f45c43 0%, #eb3349 100%) !important;
}

.btn-warning {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%) !important;
    color: #fff !important;
}

.btn-warning:hover {
    background: linear-gradient(135deg, #f5576c 0%, #f093fb 100%) !important;
}

.btn-info {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%) !important;
    color: #fff !important;
}

.btn-info:hover {
    background: linear-gradient(135deg, #00f2fe 0%, #4facfe 100%) !important;
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%) !important;
    color: #fff !important;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #495057 0%, #6c757d 100%) !important;
}

/* فرم‌ها - گردتر */
.y-control,
.form-select {
    border-radius: 12px !important;
    border: 1.5px solid #e0e0e0 !important;
    padding: 0.65rem 1rem !important;
    transition: all 0.3s ease !important;
}

.form-control:focus,
.form-select:focus {
    border-color: #29365d !important;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.15) !important;
    transform: translateY(-1px);
}

.form-check-input {
    border-radius: 8px !important;
    width: 1.25rem !important;
    height: 1.25rem !important;
}

.form-check-input:checked {
    background-color: #29365d !important;
    border-color: #29365d !important;
}

.form-switch .form-check-input {
    border-radius: 2rem !important;
    width: 2.5rem !important;
    height: 1.25rem !important;
}

/* جداول - گردتر */
.table {
    border-radius: 15px !important;
    overflow: hidden;
}

.table thead th {
    border-radius: 0 !important;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%) !important;
    border: none !important;
    padding: 1rem !important;
    font-weight: 600 !important;
}

.table tbody td {
    padding: 1rem !important;
    border-color: rgba(0, 0, 0, 0.05) !important;
}

.table tbody tr:hover {
    background-color: rgba(102, 126, 234, 0.05) !important;
    transition: background-color 0.3s ease !important;
}

/* Remove translate from table rows */
.table tbody tr {
    transform: none !important;
}

.table tbody tr:hover {
    transform: none !important;
}

/* Fix for numbers - should be LTR */
code,
.mobile-number,
[data-mobile],
td code,
th code,
.table code {
    direction: ltr !important;
    text-align: left !important;
    display: inline-block;
    unicode-bidi: embed;
}

/* Badge - گردتر */
.badge {
    padding: 0.03rem 0.6rem !important;
    font-weight: 500 !important;
}

.app-search span.search-widget-icon{
    right: auto !important;
    left: 13px !important;
    top: 3px !important;
}
#topnav-hamburger-icon{
    box-shadow: none !important;
}
.alert {
    border-radius: 15px !important;
    border: none !important;
    padding: 1rem 1.5rem !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

.alert-success {
    background: linear-gradient(135deg, rgba(17, 153, 142, 0.1) 0%, rgba(56, 239, 125, 0.1) 100%) !important;
    color: #11998e !important;
    border-right: 4px solid #11998e !important;
}

.alert-danger {
    background: linear-gradient(135deg, rgba(235, 51, 73, 0.1) 0%, rgba(244, 92, 67, 0.1) 100%) !important;
    color: #eb3349 !important;
    border-right: 4px solid #eb3349 !important;
}

.alert-warning {
    background: linear-gradient(135deg, rgba(240, 147, 251, 0.1) 0%, rgba(245, 87, 108, 0.1) 100%) !important;
    color: #f5576c !important;
    border-right: 4px solid #f5576c !important;
}

.alert-info {
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.1) 0%, rgba(0, 242, 254, 0.1) 100%) !important;
    color: #4facfe !important;
    border-right: 4px solid #4facfe !important;
}

/* Input Group - گردتر */
.input-group .form-control {
    border-radius: 12px 0 0 12px !important;
}

.input-group .input-group-text {
    border-radius: 0 12px 12px 0 !important;
    border: 1.5px solid #e0e0e0 !important;
}

.input-group .form-control:first-child {
    border-radius: 12px 0 0 12px !important;
}

.input-group .form-control:last-child {
    border-radius: 12px 0 0 12px !important;
}

/* Modal - گردتر */
.modal-content {
    border-radius: 20px !important;
    border: none !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2) !important;
}

.modal-header {
    border-radius: 20px 20px 0 0 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%) !important;
}

.modal-footer {
    border-radius: 0 0 20px 20px !important;
    border-top: 1px solid rgba(0, 0, 0, 0.08) !important;
}

/* Dropdown - گردتر */
.dropdown-menu {
    border-radius: 15px !important;
    border: none !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15) !important;
    padding: 0.5rem !important;
}

.dropdown-item {
    border-radius: 10px !important;
    padding: 0.6rem 1rem !important;
    margin: 0.2rem 0 !important;
    transition: all 0.2s ease !important;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%) !important;
    transform: translateX(-3px);
}

/* Navbar - بدون تغییر border-radius */
.navbar {
    /* border-radius حذف شد - نباید گرد باشد */
}

.nav-link {
    border-radius: 10px !important;
    padding: 0.5rem 1rem !important;
    transition: all 0.3s ease !important;
}

.nav-link:hover {
    background: rgba(102, 126, 234, 0.1) !important;
    transform: translateY(-1px);
}

/* Sidebar - بدون تغییر border-radius */
.app-menu {
    /* border-radius حذف شد - نباید گرد باشد */
}

.menu-link {
    border-radius: 12px !important;
    margin: 0.2rem 0 !important;
    transition: all 0.3s ease !important;
}

.menu-link:hover {
    background: rgba(102, 126, 234, 0.1) !important;
    transform: translateX(-3px);
}
.dropdown-head{
    border-radius:  12px !important;
}
.menu-link.active {
    background: linear-gradient(135deg, #2a385f 10%, #ffffff1a 100%) !important;
    color: #fff !important;
}
.app-menu .navbar-nav .nav-link.active, .app-menu .navbar-nav .sub-menu .nav-link.active {
    color: var(--sidebar-text-color) !important;
    background: linear-gradient(135deg, #2a385f 10%, #ffffff1a 100%) !important;
}

.navbar-nav{
    margin-right: 5px !important;
}

/* Avatar - گردتر */
.avatar-sm,
.avatar-md,
.avatar-lg {
    border-radius: 15px !important;
}

.avatar-title {
    border-radius: 12px !important;
}

/* Pagination - گردتر و استایل قالب */
.pagination {
    margin-bottom: 0 !important;
    justify-content: center !important;
    direction: ltr !important;
}

.pagination .page-link {
    border-radius: 12px !important;
    margin: 0 0.2rem !important;
    border: 1.5px solid #e0e0e0 !important;
    transition: all 0.3s ease !important;
    padding: 0.5rem 0.75rem !important;
    color: var(--vz-link-color, #29365d) !important;
    background-color: var(--vz-secondary-bg, #fff) !important;
    min-width: 38px;
    text-align: center;
}

.pagination .page-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
    color: var(--vz-link-hover-color, #29365d) !important;
    background-color: var(--vz-tertiary-bg, #f8f9fa) !important;
}

.pagination .page-item.active .page-link {
    background: linear-gradient(135deg, #29365d 0%, #764ba2 100%) !important;
    border-color: #29365d !important;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3) !important;
    color: #fff !important;
    font-weight: 600;
}

.pagination .page-item.disabled .page-link {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Pagination Separated - استایل قالب */
.pagination-separated .page-item .page-link {
    margin-left: 0.35rem !important;
    margin-right: 0 !important;
}

.pagination-separated .page-item:first-child .page-link {
    margin-left: 0 !important;
}

/* بهبود استایل pagination برای RTL */
[dir="rtl"] .pagination-separated .page-item .page-link {
    margin-left: 0 !important;
    margin-right: 0.35rem !important;
}

[dir="rtl"] .pagination-separated .page-item:last-child .page-link {
    margin-right: 0 !important;
}

/* استایل SVG و img در pagination */
.pagination img,
.pagination svg {
    vertical-align: middle;
    width: 20px !important;
    height: auto;
}

.pagination .page-link {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.25rem;
}

/* استایل برای container pagination با کلاس‌های Tailwind */
.relative.z-0.inline-flex.rtl\:flex-row-reverse.shadow-sm.rounded-md,
.relative.z-0.inline-flex.rtl\:flex-row-reverse.rounded-md {
    direction: ltr !important;
    display: block !important;
    margin: auto !important;
    text-align: center !important;
    background: #f3f3f9 !important;
    border-radius: 10px !important;
    width: fit-content !important;
    box-shadow: none !important;
    -webkit-box-shadow: none !important;
}

/* حذف shadow-sm از pagination */
.relative.z-0.inline-flex.rtl\:flex-row-reverse.shadow-sm.rounded-md .shadow-sm,
.pagination .shadow-sm,
.pagination.shadow-sm {
    box-shadow: none !important;
    -webkit-box-shadow: none !important;
}

/* Progress Bar - گردتر */
.progress {
    border-radius: 15px !important;
    height: 1rem !important;
    overflow: hidden;
}

.progress-bar {
    border-radius: 15px !important;
}

/* Tooltip - گردتر */
.tooltip-inner {
    border-radius: 10px !important;
}

/* Popover - گردتر */
.popover {
    border-radius: 15px !important;
    border: none !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15) !important;
}

/* Accordion - گردتر */
.accordion-item {
    border-radius: 15px !important;
    margin-bottom: 1rem !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    overflow: hidden;
}

.accordion-button {
    border-radius: 15px !important;
    transition: all 0.3s ease !important;
}

.accordion-button:not(.collapsed) {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%) !important;
    color: #29365d !important;
}

/* Card با border رنگی - گرم‌تر */
.card.border-primary {
    border: 2px solid #29365d !important;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, rgba(118, 75, 162, 0.05) 100%) !important;
}

.card.border-success {
    border: 2px solid #11998e !important;
    background: linear-gradient(135deg, rgba(17, 153, 142, 0.05) 0%, rgba(56, 239, 125, 0.05) 100%) !important;
}

.card.border-danger {
    border: 2px solid #eb3349 !important;
    background: linear-gradient(135deg, rgba(235, 51, 73, 0.05) 0%, rgba(244, 92, 67, 0.05) 100%) !important;
}

.card.border-warning {
    border: 2px solid #f5576c !important;
    background: linear-gradient(135deg, rgba(245, 87, 108, 0.05) 0%, rgba(240, 147, 251, 0.05) 100%) !important;
}

.card.border-info {
    border: 2px solid #4facfe !important;
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.05) 0%, rgba(0, 242, 254, 0.05) 100%) !important;
}

/* Plan Cards - گرم‌تر و جذاب‌تر */
.plan-card {
    transition: box-shadow 0.3s ease !important;
    border: 2px solid transparent !important;
    transform: none !important;
}

.plan-card:hover {
    transform: none !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15) !important;
}

.plan-card.border-primary {
    border-color: #29365d !important;
}

.plan-card.border-primary:hover {
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3) !important;
}

/* Table Card - گرم‌تر */
.table-responsive {
    border-radius: 15px !important;
    overflow: hidden;
}

/* Custom Scrollbar - مخفی ولی فعال */
/* برای Chrome, Safari, Edge */
::-webkit-scrollbar {
    width: 0px;
    height: 0px;
    background: transparent;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: transparent;
}

::-webkit-scrollbar-thumb:hover {
    background: transparent;
}

/* برای Firefox */
* {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

/* برای IE و Edge قدیمی */
* {
    -ms-overflow-style: none;
}

/* Breadcrumb - گردتر */
.breadcrumb {
    border-radius: 12px !important;
    padding: 0.75rem 1rem !important;
    background: rgba(102, 126, 234, 0.05) !important;
}

.breadcrumb-item a {
    color: #29365d !important;
    text-decoration: none !important;
    transition: all 0.2s ease !important;
}

.breadcrumb-item a:hover {
    color: #764ba2 !important;
    transform: translateX(-2px);
}

/* Switch - گردتر */
.form-switch .form-check-input {
    border-radius: 2rem !important;
    width: 3rem !important;
    height: 1.5rem !important;
    cursor: pointer;
}

.form-switch .form-check-input:checked {
    background-color: #29365d !important;
    border-color: #29365d !important;
}

/* Textarea - گردتر */
textarea.form-control {
    border-radius: 12px !important;
    min-height: 100px !important;
}

/* Code - گرم‌تر */
code {
    background: #ebeef066;
    padding: 0.2rem 0.5rem !important;
    border-radius: 6px !important;
    color: #29365d !important;
    font-weight: bold !important;
}
bg-light{
    background: #ebeef066 !important;
}

/* Pre - گردتر */
pre {
    border-radius: 12px !important;
    padding: 1rem !important;
    background: #f8f9fa !important;
    border: 1px solid #e0e0e0 !important;
}

/* List Group - گردتر */
.list-group-item {
    border-radius: 12px !important;
    margin-bottom: 0.5rem !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    transition: all 0.3s ease !important;
}

.list-group-item:hover {
    background: rgba(102, 126, 234, 0.05) !important;
    transform: translateX(-3px);
    border-color: #29365d !important;
}

/* Spinner - گرم‌تر */
.spinner-border {
    border-width: 0.2em !important;
}

/* Toast - گردتر */
.toast {
    border-radius: 15px !important;
    border: none !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15) !important;
}

.toast-header {
    border-radius: 15px 15px 0 0 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08) !important;
}

/* Topbar - بدون تغییر border-radius */
.navbar-brand-box {
    /* border-radius حذف شد - نباید گرد باشد */
}

/* Footer - بدون تغییر border-radius */
footer {
    /* border-radius حذف شد - نباید گرد باشد */
}

/* User Dropdown Button - بدون border-radius و shadow */
#page-header-user-dropdown {
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #fff !important;
    height: 100% !important;
}

/* Animation برای المان‌های تعاملی - غیرفعال برای کارت‌ها */
@keyframes warmPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.02);
    }
}

.card-animate:hover {
    /* Animation disabled - only shadow change */
    animation: none !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12) !important;
    transform: none !important;
}

/* بهبود فونت برای فارسی */
body,
h1, h2, h3, h4, h5, h6,
p, span, div, a, button,
input, textarea, select,
label, th, td {
    font-family: 'IranSans', 'Vazir', 'Tahoma', 'Arial', sans-serif !important;
}

/* بهبود خوانایی برای متن فارسی */
p, span, div {
    line-height: 1.8 !important;
}

/* بهبود فاصله‌گذاری */
.mb-3 {
    margin-bottom: 1.25rem !important;
}

.mb-4 {
    margin-bottom: 1.5rem !important;
}

.mt-3 {
    margin-top: 1.25rem !important;
}

.mt-4 {
    margin-top: 1.5rem !important;
}

/* بهبود رنگ‌های گرم */
:root {
    --warm-primary: #29365d;
    --warm-secondary: #764ba2;
    --warm-success: #11998e;
    --warm-danger: #eb3349;
    --warm-warning: #f5576c;
    --warm-info: #4facfe;
}

/* بهبود سایه‌ها برای حس عمق */
.card,
.alert,
.modal-content {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

.card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12) !important;
    transform: none !important;
}

.btn:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12) !important;
}

/* Sidebar Sub-menu Styles */
.navbar-nav .sub-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    padding-right: 1.5rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.navbar-nav .sub-menu .nav-item {
    margin-bottom: 0.25rem;
}

.navbar-nav .sub-menu .nav-link {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    color: var(--bs-body-color);
    display: flex;
    align-items: center;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.navbar-nav .sub-menu .nav-link:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.1);
    color: var(--bs-primary);
    padding-right: 1.25rem;
}

.navbar-nav .sub-menu .nav-link i {
    margin-left: 0.5rem;
    font-size: 1rem;
}

.navbar-nav .nav-link[data-bs-toggle="collapse"] {
    position: relative;
}

/* Removed old RemixIcon CSS - now using SVG icons */

/* Collapse animation */
.collapse {
    transition: height 0.35s ease;
}

.collapsing {
    transition: height 0.35s ease;
}

/* Active sub-menu item */
.navbar-nav .sub-menu .nav-link.active {
    background-color: rgba(var(--bs-primary-rgb), 0.15);
    color: var(--bs-primary);
    font-weight: 500;
}

/* Center align all table content */
.table th,
.table td {
    text-align: center !important;
    vertical-align: middle !important;
}

.table thead th {
    text-align: center !important;
    vertical-align: middle !important;
}

/* Context Menu Styles */
#contextMenu {
    z-index: 9999;
    min-width: 200px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-radius: 10px;
    padding: 0.5rem 0;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

#contextMenu .dropdown-item {
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

#contextMenu .dropdown-item:hover {
    background-color: rgba(var(--bs-primary-rgb), 0.1);
    color: var(--bs-primary);
}

/* Table row hover effect for context menu */
.table-row-context {
    cursor: context-menu;
    user-select: none;
}

.table-row-context:hover {
    background-color: rgba(102, 126, 234, 0.05) !important;
}

/* Sortable handle */
.handle {
    cursor: move;
    user-select: none;
}

.handle:hover {
    color: var(--bs-primary) !important;
}

/* Sortable ghost element */
.sortable-ghost {
    opacity: 0.4;
    background-color: rgba(102, 126, 234, 0.1) !important;
}

/* Sortable drag element */
.sortable-drag {
    opacity: 0.8;
}

/* Setting Cards Hover Effects */
.setting-card {
    transition: all 0.2s ease !important;
    cursor: pointer;
    aspect-ratio: 1 !important;
    width: 100% !important;
    height: 0 !important;
    padding-bottom: 100% !important;
    position: relative !important;
}

.setting-card-body {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    padding: 0.75rem !important;
}

.setting-card-body h6 {
    white-space: normal !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
}

.setting-card-body p {
    white-space: normal !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    hyphens: auto !important;
}

.setting-card:hover {
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2) !important;
    transform: translateY(-2px) !important;
    border-color: var(--bs-primary) !important;
}

.setting-category-btn {
    transition: all 0.2s ease !important;
    font-size: 0.85rem !important;
    padding: 0.35rem 0.75rem !important;
}

.setting-category-btn:hover {
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.2) !important;
    transform: translateY(-1px) !important;
}

.setting-category-btn.active {
    background-color: rgba(102, 126, 234, 0.15) !important;
    color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
    border-width: 2px !important;
    font-weight: 600 !important;
}

.setting-category-btn.active .badge {
    background-color: var(--bs-primary) !important;
    color: var(--bs-primary) !important;
}

.setting-category-btn .badge {
    background-color: rgba(102, 126, 234, 0.1) !important;
    color: var(--bs-primary) !important;
}

/* Modal hover effects */
.modal-content .form-control:hover,
.modal-content .form-select:hover {
    border-color: var(--bs-primary) !important;
}

.modal-content .btn:hover {
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3) !important;
}

/* Alert close button center alignment */
.alert .btn-close {
    margin-top: auto !important;
    margin-bottom: auto !important;
    align-self: center !important;
}

/* Registration field icon for national_id */
.field-icon-national_id::before {
    content: "\ea6b"; /* ri-id-card-line */
    font-family: "remixicon" !important;
}

/* ============================================
   Shop Categories Tree - Minimal & Professional
   ============================================ */

/* Root categories container */
#categories-tree {
    position: relative;
}

/* Category item base styles */
.category-item {
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    background: #ffffff;
    border-radius: 12px;
    margin-bottom: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.category-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
    border-color: rgba(13, 110, 253, 0.2) !important;
}

/* Drag handle styling */
.category-item .drag-handle {
    color: #6c757d;
    opacity: 0.6;
    transition: all 0.2s;
    padding: 0.25rem;
    border-radius: 6px;
}

.category-item:hover .drag-handle {
    opacity: 1;
    color: #0d6efd;
    background: rgba(13, 110, 253, 0.08);
}

/* Children container - elegant nested styling */
.category-children {
    position: relative;
    margin-top: 0.75rem;
    margin-right: 0;
    padding-right: 1.5rem;
    border-right: 2px solid rgba(13, 110, 253, 0.12);
}

/* Visual connector line for nested items */
.category-children::before {
    content: '';
    position: absolute;
    right: -2px;
    top: -0.75rem;
    width: 2px;
    height: 0.75rem;
    background: linear-gradient(to bottom, rgba(13, 110, 253, 0.12), transparent);
}

/* Nested category items - subtle indentation with visual hierarchy */
.category-children > .category-item {
    background: linear-gradient(90deg, rgba(13, 110, 253, 0.02) 0%, #ffffff 3%);
    border-right: 3px solid rgba(13, 110, 253, 0.15);
    border-radius: 10px;
    margin-bottom: 0.5rem;
    padding: 0.75rem 1rem;
    position: relative;
}

/* Second level nested items */
.category-children .category-children > .category-item {
    background: linear-gradient(90deg, rgba(13, 110, 253, 0.04) 0%, #ffffff 3%);
    border-right-color: rgba(13, 110, 253, 0.2);
    border-radius: 8px;
    padding: 0.65rem 0.9rem;
}

/* Third level and deeper */
.category-children .category-children .category-children > .category-item {
    background: linear-gradient(90deg, rgba(13, 110, 253, 0.06) 0%, #ffffff 3%);
    border-right-color: rgba(13, 110, 253, 0.25);
    border-radius: 6px;
    padding: 0.55rem 0.8rem;
}

/* Hover effect for nested items */
.category-children > .category-item:hover {
    background: linear-gradient(90deg, rgba(13, 110, 253, 0.08) 0%, rgba(255, 255, 255, 0.98) 3%);
    border-right-color: rgba(13, 110, 253, 0.3);
    box-shadow: 0 2px 8px rgba(13, 110, 253, 0.1);
}

/* Category name styling for nested items */
.category-children .category-item strong {
    font-size: 0.95rem;
    font-weight: 500;
    color: #495057;
}

.category-children .category-children .category-item strong {
    font-size: 0.9rem;
    font-weight: 500;
}

/* Description styling for nested items */
.category-children .category-item small {
    font-size: 0.8rem;
    color: #6c757d;
    margin-top: 0.25rem;
}

/* Badge styling for nested items */
.category-children .category-item .badge {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
}

/* Button sizing for nested items */
.category-children .category-item .btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
}

/* Image sizing for nested items */
.category-children .category-item img {
    max-width: 32px !important;
    max-height: 32px !important;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Smooth transitions */
.category-item,
.category-children,
.category-children > .category-item {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Active state for drag */
.category-item.sortable-ghost {
    opacity: 0.5;
    background: rgba(13, 110, 253, 0.1);
    border-color: rgba(13, 110, 253, 0.3) !important;
}

.category-item.sortable-drag {
    opacity: 0.8;
    transform: scale(1.02);
    box-shadow: 0 8px 24px rgba(13, 110, 253, 0.2);
}

/* Dark mode support */
[data-bs-theme="dark"] .category-item {
    background: #1e1e1e;
}

/* Custom Sidebar Images Support */
/* For custom uploaded images (not img-1 to img-4) */
[data-sidebar-image]:not([data-sidebar-image="none"]):not([data-sidebar-image="img-1"]):not([data-sidebar-image="img-2"]):not([data-sidebar-image="img-3"]):not([data-sidebar-image="img-4"]) .sidebar-background {
    background-image: var(--custom-sidebar-image-url, none) !important;
}

/* RTL Sidebar Menu Styling */
[data-layout=vertical][data-sidebar=dark] .navbar-menu {
    background: var(--vz-vertical-menu-bg-dark);
    border-left: 1px solid #29365d;
    padding-left: 10px;
}

/* Cursor pointer utility */
.cursor-pointer {
    cursor: pointer !important;
}

[data-bs-theme="dark"] .category-children > .category-item {
    background: linear-gradient(90deg, rgba(13, 110, 253, 0.08) 0%, #1e1e1e 3%);
    border-right-color: rgba(13, 110, 253, 0.2);
}

[data-bs-theme="dark"] .category-children {
    border-right-color: rgba(13, 110, 253, 0.2);
}

[data-bs-theme="dark"] .category-item:hover {
    border-color: rgba(13, 110, 253, 0.3) !important;
    background: #252525;
}

/* Role Badge Styling */
.role-badge {
    display: inline-block;
    vertical-align: middle;
    transition: transform 0.2s ease;
    cursor: pointer;
}

.role-badge:hover {
    transform: scale(1.15);
}

.role-badge-item {
    border: none !important;
    background: none !important;
    transition: all 0.3s ease;
}

.role-badge-item:hover {
    transform: scale(1.1);
}

.role-badge-large {
    transition: transform 0.3s ease;
}

.role-badge-item:hover .role-badge-large {
    transform: scale(1.1);
}
.profile-wrapper div {
    align-items: center !important;
}