/* ===== فونت ===== */
@font-face {
    font-family: 'Vazirmatn';
    src: url('Vazirmatn/Vazirmatn-Light.woff2') format('woff2');
    font-weight: 300;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('Vazirmatn/Vazirmatn-Regular.woff2') format('woff2');
    font-weight: 400;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('Vazirmatn/Vazirmatn-Medium.woff2') format('woff2');
    font-weight: 500;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('Vazirmatn/Vazirmatn-SemiBold.woff2') format('woff2');
    font-weight: 600;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('Vazirmatn/Vazirmatn-Bold.woff2') format('woff2');
    font-weight: 700;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('Vazirmatn/Vazirmatn-ExtraBold.woff2') format('woff2');
    font-weight: 800;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('Vazirmatn/Vazirmatn-Black.woff2') format('woff2');
    font-weight: 900;
}

/* ===== متغیرها ===== */
:root {
    --primary: #14b8a6;
    --primary-dark: #0d9488;
    --primary-darker: #0f766e;
    --primary-light: #5eead4;
    --primary-lighter: #99f6e4;
    --primary-bg: #f0fdfa;
    --primary-bg-2: #ccfbf1;
    --text: #134e4a;
    --text-light: #64748b;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --white: #ffffff;
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 16px;
    --sidebar-width: 280px;
    --header-height: 70px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== ریست ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html { font-size: 14px; }

body {
    font-family: 'Vazirmatn', Tahoma, sans-serif;
    background: var(--primary-bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    direction: rtl;
}

a { color: var(--primary-dark); text-decoration: none; }
a:hover { color: var(--primary-darker); }

img { max-width: 100%; height: auto; }

button { font-family: inherit; cursor: pointer; border: none; background: none; }

input, select, textarea {
    font-family: inherit;
    font-size: 14px;
}

/* ===== لاگین ===== */
.login-page {
    background: linear-gradient(135deg, #0f766e 0%, #14b8a6 50%, #5eead4 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: 1000px;
    width: 100%;
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    min-height: 550px;
}

.login-card {
    padding: 50px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-header { text-align: center; margin-bottom: 30px; }

.login-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 36px;
    box-shadow: 0 10px 20px rgba(20, 184, 166, 0.3);
}

.login-header h1 { font-size: 24px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.login-header p { color: var(--text-light); font-size: 14px; }

.login-form { display: flex; flex-direction: column; gap: 20px; }

.login-footer {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    color: var(--text-light);
    font-size: 13px;
}

.login-decoration {
    background: linear-gradient(135deg, #0f766e 0%, #14b8a6 100%);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    overflow: hidden;
}

.decoration-circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}
.circle-1 { width: 200px; height: 200px; top: -50px; right: -50px; }
.circle-2 { width: 150px; height: 150px; bottom: -30px; left: -30px; }
.circle-3 { width: 100px; height: 100px; top: 50%; left: 50%; transform: translate(-50%, -50%); }

.decoration-content { text-align: center; padding: 30px; position: relative; z-index: 1; }
.decoration-content i { font-size: 60px; margin-bottom: 20px; opacity: 0.9; }
.decoration-content h2 { font-size: 26px; margin-bottom: 10px; font-weight: 700; }
.decoration-content p { font-size: 14px; opacity: 0.9; }

/* ===== چیدمان اصلی ===== */
.app-wrapper { display: flex; min-height: 100vh; }

.sidebar {
    width: var(--sidebar-width);
    background: linear-gradient(180deg, #0f766e 0%, #115e59 100%);
    color: white;
    position: fixed;
    right: 0;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: var(--transition);
}

.sidebar-header {
    padding: 24px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-logo {
    width: 56px;
    height: 56px;
    margin: 0 auto 12px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    backdrop-filter: blur(10px);
}

.sidebar-header h2 { font-size: 16px; font-weight: 700; }

.user-profile-section {
    padding: 24px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    margin: 0 auto 12px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    object-fit: cover;
    display: block;
    background: white;
}

.profile-name { font-size: 16px; font-weight: 600; margin-bottom: 6px; }

.profile-position {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    backdrop-filter: blur(10px);
}

.sidebar-menu { flex: 1; padding: 20px 12px; overflow-y: auto; }

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 6px;
    transition: var(--transition);
    font-weight: 500;
}

.menu-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.menu-item.active {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.menu-item i { width: 20px; text-align: center; font-size: 16px; }

.sidebar-footer { padding: 20px 12px; border-top: 1px solid rgba(255, 255, 255, 0.1); }

.logout-btn { color: #fca5a5 !important; }
.logout-btn:hover { background: rgba(239, 68, 68, 0.2) !important; color: white !important; }

.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99;
}

.main-content {
    flex: 1;
    margin-right: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.top-header {
    height: var(--header-height);
    background: white;
    padding: 0 30px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 50;
}

.menu-toggle {
    display: none;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    color: var(--text);
    font-size: 18px;
    align-items: center;
    justify-content: center;
}

.menu-toggle:hover { background: var(--primary-bg); }

.page-title { font-size: 20px; font-weight: 700; flex: 1; }

.user-info-mobile {
    display: flex;
    align-items: center;
    gap: 10px;
}

.content { padding: 30px; flex: 1; }

/* ===== کارت ===== */
.card {
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 24px;
}

.card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}

.card-header h2 {
    font-size: 17px;
    font-weight: 700;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-header h2 i { color: var(--primary); }

.card-body { padding: 24px; }

/* ===== دکمه‌ها ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
    cursor: pointer;
    text-decoration: none;
    border: 2px solid transparent;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-darker) 100%);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(20, 184, 166, 0.4);
}

.btn-outline {
    background: white;
    color: var(--text);
    border-color: var(--border);
}

.btn-outline:hover {
    background: var(--primary-bg);
    border-color: var(--primary);
    color: var(--primary-dark);
}

.btn-block { width: 100%; }
.btn-sm { padding: 6px 14px; font-size: 13px; }

.btn-icon {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 14px;
}

.btn-info { background: var(--info); }
.btn-warning { background: var(--warning); }
.btn-danger { background: var(--error); }
.btn-icon:hover { transform: translateY(-2px); opacity: 0.9; }

/* ===== فرم ===== */
.form-group { margin-bottom: 16px; }

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text);
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.required { color: var(--error); }

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 11px 14px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: white;
    transition: var(--transition);
    color: var(--text);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.1);
}

.form-hint { display: block; margin-top: 6px; font-size: 12px; color: var(--text-light); }

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.flex-grow { flex: 1; }

.form-grid { display: flex; flex-direction: column; gap: 24px; }

.form-section {
    background: var(--primary-bg);
    padding: 20px;
    border-radius: var(--radius);
    border: 1px solid var(--primary-bg-2);
}

.form-section h3 {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--primary-bg-2);
}

.form-section h3 i { color: var(--primary); }

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-start;
    padding-top: 10px;
}

.password-wrapper { position: relative; }
.password-wrapper input { padding-left: 45px; }
.toggle-password {
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    border-radius: var(--radius-sm);
}
.toggle-password:hover { background: var(--primary-bg); color: var(--primary); }

/* ===== آپلود تصویر ===== */
.image-upload-wrapper {
    display: flex;
    align-items: center;
    gap: 24px;
}

.image-preview {
    flex-shrink: 0;
}

.image-preview img,
.avatar-xl {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--primary-bg-2);
}

.upload-hint { font-size: 12px; color: var(--text-light); margin-top: 10px; }

/* ===== آواتار ===== */
.avatar-sm {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.avatar-md {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.avatar-placeholder {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.avatar-hero {
    width: 140px;
    height: 140px;
    font-size: 48px;
}

/* ===== جدول ===== */
.table-responsive { overflow-x: auto; border-radius: var(--radius-sm); }

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    background: var(--primary-bg);
    padding: 14px 16px;
    text-align: right;
    font-weight: 700;
    color: var(--text);
    font-size: 13px;
    border-bottom: 2px solid var(--primary-bg-2);
}

.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
    vertical-align: middle;
}

.data-table tbody tr { transition: var(--transition); }
.data-table tbody tr:hover { background: var(--primary-bg); }

.action-buttons { display: flex; gap: 6px; }

/* ===== بج ===== */
.badge {
    display: inline-block;
    padding: 4px 10px;
    background: var(--primary-bg-2);
    color: var(--primary-darker);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.badge-muted { background: #f1f5f9; color: var(--text-light); }

/* ===== جستجو ===== */
.search-form {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.search-box {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

.search-box i {
    position: absolute;
    right: 14px;
    color: var(--text-light);
}

.search-box input {
    width: 100%;
    padding: 11px 40px 11px 40px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: white;
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.1);
}

.clear-search {
    position: absolute;
    left: 10px;
    color: var(--text-light);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}
.clear-search:hover { background: var(--primary-bg); color: var(--error); }

/* ===== هشدار ===== */
.alert {
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    font-weight: 500;
    position: relative;
}

.alert-success { background: #d1fae5; color: #065f46; border-right: 4px solid var(--success); }
.alert-error { background: #fee2e2; color: #991b1b; border-right: 4px solid var(--error); }

.alert-close {
    margin-right: auto;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: inherit;
    border-radius: 50%;
    opacity: 0.6;
}
.alert-close:hover { opacity: 1; background: rgba(0,0,0,0.05); }

/* ===== آمار ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

.stat-card {
    background: white;
    padding: 24px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    background: var(--primary-bg);
    border-radius: 50%;
    transform: translate(30%, -30%);
}

.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    position: relative;
    z-index: 1;
}

.stat-primary .stat-icon { background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%); }
.stat-success .stat-icon { background: linear-gradient(135deg, #10b981 0%, #059669 100%); }
.stat-info .stat-icon { background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%); }

.stat-info { position: relative; z-index: 1; }
.stat-info h3 { font-size: 22px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.stat-info p { color: var(--text-light); font-size: 13px; }

/* ===== لیست کاربران مینی ===== */
.user-list-mini { display: flex; flex-direction: column; gap: 8px; }

.user-mini-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    color: var(--text);
}

.user-mini-item:hover { background: var(--primary-bg); }

.user-mini-info { display: flex; flex-direction: column; gap: 2px; }
.user-mini-info strong { font-size: 14px; }
.user-mini-info span { font-size: 12px; color: var(--text-light); }

/* ===== خالی ===== */
.empty-state {
    text-align: center;
    padding: 50px 20px;
    color: var(--text-light);
}

.empty-state i { font-size: 60px; color: var(--primary-bg-2); margin-bottom: 15px; }
.empty-state p { font-size: 15px; margin-bottom: 20px; }

/* ===== پروفایل ===== */
.profile-page { display: flex; flex-direction: column; gap: 24px; }

.profile-hero {
    position: relative;
    background: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.profile-hero-bg {
    height: 140px;
    background: linear-gradient(135deg, var(--primary-darker) 0%, var(--primary) 100%);
    position: relative;
}

.profile-hero-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='60' height='60' viewBox='0 0 60 60'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.profile-hero-content {
    text-align: center;
    padding: 0 24px 30px;
    margin-top: -70px;
    position: relative;
}

.profile-hero-avatar {
    width: 140px;
    height: 140px;
    margin: 0 auto 16px;
    border: 5px solid white;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    background: white;
}

.profile-hero-avatar img { width: 100%; height: 100%; object-fit: cover; }

.profile-hero-name { font-size: 24px; font-weight: 700; margin-bottom: 8px; color: var(--text); }

.profile-hero-position {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--primary-bg);
    color: var(--primary-darker);
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 20px;
}

.profile-hero-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.profile-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}

.profile-info-card {
    background: white;
    padding: 18px 20px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border-right: 4px solid var(--primary);
}

.profile-info-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }

.info-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-sm);
    background: var(--primary-bg);
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.info-content { display: flex; flex-direction: column; gap: 4px; }
.info-label { font-size: 12px; color: var(--text-light); }
.info-value { font-size: 14px; color: var(--text); }

/* ===== فرم افقی ===== */
.inline-form {
    background: var(--primary-bg);
    padding: 16px;
    border-radius: var(--radius-sm);
}

/* ===== رسپانسیو ===== */
@media (max-width: 1024px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .login-wrapper { grid-template-columns: 1fr; }
    .login-decoration { display: none; }
    .login-card { padding: 30px 24px; }

    .sidebar { transform: translateX(100%); right: -280px; }
    .sidebar.open { transform: translateX(0); right: 0; }
    .sidebar-overlay.active { display: block; }
    .main-content { margin-right: 0; }

    .menu-toggle { display: flex; }
    .content { padding: 20px 15px; }
    .card-body { padding: 18px; }
    .card-header { padding: 16px; }

    .form-row { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr; }
    .search-form { flex-direction: column; }

    .image-upload-wrapper { flex-direction: column; text-align: center; }

    .profile-info-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    html { font-size: 13px; }
    .top-header { padding: 0 15px; }
    .page-title { font-size: 16px; }
    .btn { padding: 8px 14px; font-size: 13px; }
}
/* =============================================
   استایل‌های سیستم مدیریت خودرو
   اضافه شود به انتهای فایل CSS اصلی
   ============================================= */

/* ===== زیرمنو (برند، مدل، تریم، سال) ===== */
.menu-group { position: relative; }
.menu-arrow {
    margin-right: auto;
    font-size: 0.7rem;
    transition: transform 0.3s ease;
}
.menu-item.active .menu-arrow { color: white; }
.menu-arrow.rotate { transform: rotate(180deg); }

.submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
    background: rgba(0, 0, 0, 0.15);
    border-radius: var(--radius-sm);
    margin-bottom: 6px;
}
.submenu.open { max-height: 300px; }

.submenu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px 10px 16px;
    margin-right: 16px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    margin-bottom: 2px;
}
.submenu-item:last-child { margin-bottom: 6px; }
.submenu-item:hover {
    background: rgba(255, 255, 255, 0.08);
    color: white;
}
.submenu-item.active {
    background: rgba(20, 184, 166, 0.25);
    color: white;
}
.submenu-item i {
    width: 16px;
    text-align: center;
    font-size: 12px;
}

/* ===== Page Header + Breadcrumb ===== */
.page-header {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--primary-bg-2);
}
.page-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}
.page-title i { color: var(--primary); }

.breadcrumb { margin-top: 4px; }
.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 6px;
    align-items: center;
}
.breadcrumb li {
    color: var(--text-light);
    font-size: 13px;
    display: flex;
    align-items: center;
}
.breadcrumb li:not(:last-child)::after {
    content: '\f104';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    margin-right: 6px;
    color: var(--text-muted);
    font-size: 11px;
}
.breadcrumb a {
    color: var(--primary-dark);
    text-decoration: none;
    transition: var(--transition);
}
.breadcrumb a:hover { color: var(--primary-darker); text-decoration: underline; }
.breadcrumb .active { color: var(--text); font-weight: 600; }

/* ===== Grid برندها ===== */
.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 16px;
}

.brand-card {
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 16px 16px;
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}
.brand-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary) 0%, var(--primary-dark) 100%);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}
.brand-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-4px);
    border-color: var(--primary);
}
.brand-card:hover::before { transform: scaleX(1); }

.brand-logo {
    width: 90px;
    height: 90px;
    margin: 0 auto 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-bg);
    border-radius: var(--radius);
    overflow: hidden;
    transition: var(--transition);
}
.brand-card:hover .brand-logo { transform: scale(1.05); }
.brand-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 8px;
}

.logo-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    font-size: 2rem;
}
.logo-placeholder.large {
    width: 140px;
    height: 140px;
    font-size: 3.5rem;
    border-radius: var(--radius);
}

.brand-info { margin-bottom: 14px; }
.brand-name {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 4px;
}
.brand-en {
    font-size: 0.8rem;
    color: var(--text-light);
    margin: 0 0 10px;
    direction: ltr;
}
.brand-stats {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    background: var(--primary-bg);
    color: var(--primary-darker);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.brand-actions {
    display: flex;
    justify-content: center;
    gap: 6px;
    padding-top: 14px;
    border-top: 1px dashed var(--border);
}

/* ===== جزئیات برند ===== */
.brand-detail-header {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: 24px;
    flex-wrap: wrap;
}
.brand-detail-logo {
    flex-shrink: 0;
}
.brand-detail-logo img,
.brand-detail-logo .logo-placeholder {
    width: 140px;
    height: 140px;
    border-radius: var(--radius);
    object-fit: contain;
    background: var(--primary-bg);
    padding: 12px;
}
.brand-detail-info { flex: 1; min-width: 250px; }
.brand-detail-info h2 {
    margin: 0 0 6px;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text);
}
.brand-detail-info .text-muted {
    color: var(--text-light);
    margin: 0 0 14px;
    direction: ltr;
    text-align: right;
    font-size: 0.95rem;
}
.brand-detail-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ===== تریم‌ها به صورت تگ ===== */
.trim-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 8px;
}
.trim-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--primary-bg) 0%, var(--primary-bg-2) 100%);
    color: var(--primary-darker);
    padding: 8px 14px;
    border-radius: 30px;
    font-weight: 600;
    border: 1px solid var(--primary-lighter);
    transition: var(--transition);
    font-size: 13px;
}
.trim-tag:hover {
    box-shadow: 0 6px 12px rgba(20, 184, 166, 0.2);
    transform: translateY(-2px);
    border-color: var(--primary);
}
.trim-name { font-size: 0.9rem; }
.trim-actions { display: flex; gap: 4px; }
.trim-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(20, 184, 166, 0.15);
    color: var(--primary-darker);
    text-decoration: none;
    font-size: 0.65rem;
    transition: var(--transition);
}
.trim-action-btn:hover { background: var(--primary); color: white; transform: rotate(90deg); }
.trim-action-btn.danger { background: rgba(239, 68, 68, 0.12); color: var(--error); }
.trim-action-btn.danger:hover { background: var(--error); color: white; transform: rotate(90deg); }

/* ===== افزودن سریع ===== */
.inline-form {
    background: var(--primary-bg);
    padding: 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--primary-bg-2);
    margin-bottom: 20px;
}
.inline-form .form-row {
    display: flex;
    gap: 10px;
    align-items: stretch;
}
.inline-form .form-row input { flex: 1; }
.inline-form .form-row .btn { white-space: nowrap; }

/* ===== سال‌های ساخت ===== */
.year-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 10px;
}
.year-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    border: 1px solid #fcd34d;
    transition: var(--transition);
    font-size: 15px;
}
.year-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(146, 64, 14, 0.18);
    border-color: #f59e0b;
}
.year-text { font-size: 1rem; }
.year-delete {
    color: #92400e;
    text-decoration: none;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(146, 64, 14, 0.15);
    transition: var(--transition);
    font-size: 0.75rem;
}
.year-delete:hover { background: var(--error); color: white; }

/* ===== File Upload عمومی ===== */
.file-upload-area {
    position: relative;
    border: 2px dashed var(--border);
    border-radius: var(--radius);
    padding: 30px;
    text-align: center;
    transition: var(--transition);
    background: var(--primary-bg);
    cursor: pointer;
}
.file-upload-area:hover {
    border-color: var(--primary);
    background: white;
}
.file-upload-area i {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 10px;
    display: block;
}
.file-upload-area p {
    color: var(--text);
    font-weight: 600;
    margin: 0 0 4px;
}
.file-upload-area span {
    color: var(--text-light);
    font-size: 12px;
}
.file-upload-area input[type="file"] {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

/* ===== Grid ردیف‌ها ===== */
.row {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin: 0 -8px;
}
.row > [class*="col-"] { padding: 0 8px; }
.col-12 { flex: 0 0 100%; max-width: 100%; }
.col-md-6 { flex: 0 0 calc(50% - 8px); max-width: calc(50% - 8px); }
.col-md-4 { flex: 0 0 calc(33.333% - 11px); max-width: calc(33.333% - 11px); }
@media (max-width: 768px) {
    .col-md-6, .col-md-4 { flex: 0 0 100%; max-width: 100%; }
}

/* ===== صفحه‌بندی ===== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin-top: 20px;
    flex-wrap: wrap;
}
.pagination a, .pagination span {
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    background: white;
    color: var(--text);
    text-decoration: none;
    border: 1px solid var(--border);
    transition: var(--transition);
    font-weight: 600;
    font-size: 13px;
    min-width: 38px;
    text-align: center;
}
.pagination a:hover {
    background: var(--primary-bg);
    border-color: var(--primary);
    color: var(--primary-dark);
}
.pagination .active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    border-color: var(--primary);
}

/* ===== Modal (اختیاری) ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 118, 110, 0.6);
    backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}
.modal-overlay.active { display: flex; }
.modal {
    background: white;
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    animation: modalIn 0.3s ease;
}
@keyframes modalIn {
    from { opacity: 0; transform: translateY(-20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.modal-header h3 { font-size: 16px; font-weight: 700; color: var(--text); }
.modal-close {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    transition: var(--transition);
}
.modal-close:hover { background: var(--primary-bg); color: var(--error); }
.modal-body { padding: 24px; }
.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

/* ===== بهبود جدول برای دکمه‌ها ===== */
.data-table .btn-icon {
    box-shadow: var(--shadow-sm);
}
.data-table .btn-icon + .btn-icon { margin-right: 0; }

/* ===== فیلد readonly/disabled ===== */
.form-group input:disabled,
.form-group input[readonly] {
    background: var(--primary-bg);
    color: var(--text);
    cursor: not-allowed;
    border-style: dashed;
}

/* ===== استایل Textarea ===== */
.form-group textarea {
    resize: vertical;
    min-height: 80px;
    font-family: inherit;
}

/* ===== رنگ وضعیت ===== */
.status-online {
    width: 10px;
    height: 10px;
    background: var(--success);
    border-radius: 50%;
    display: inline-block;
    margin-left: 6px;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

/* ===== تایمر/Loading ===== */
.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}