
/* ============================================================
   تعریف فونت‌ها از پوشه fonts
   مسیر نسبت به: public_html/style/dynamic_style.php
   ============================================================ */

@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn-Regular.woff2') format('woff2'),
         url('../fonts/Vazirmatn-Regular.woff') format('woff'),
         url('../fonts/Vazirmatn-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn-Bold.woff2') format('woff2'),
         url('../fonts/Vazirmatn-Bold.woff') format('woff'),
         url('../fonts/Vazirmatn-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Shabnam';
    src: url('../fonts/Shabnam-FD.woff2') format('woff2'),
         url('../fonts/Shabnam-FD.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* ============================================================
   تنظیمات عمومی
   ============================================================ */

* {
    box-sizing: border-box;
}

body {
    direction: rtl;
    margin: 0;
    padding: 0;
    background: #f5f7fa;
    color: #2c3e50;
    font-family: 'Vazirmatn', Tahoma, Arial, sans-serif;
    font-size: 14px;
}

h1, h2, h3, h4 {
    color: #2c3e50;
    margin-top: 0;
}

a {
    color: #27ae60;
    text-decoration: none;
}

/* ============================================================
   فرم‌ها
   ============================================================ */

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 700;
}

.form-control {
    width: 100%;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid #ccd1d9;
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    background: #fff;
}

.form-control:focus {
    outline: none;
    border-color: #27ae60;
    box-shadow: 0 0 0 3px rgba(39, 174, 96, 0.12);
}

/* ============================================================
   دکمه‌ها
   ============================================================ */

.btn-custom,
button,
input[type="submit"] {
    display: inline-block;
    min-height: 38px;
    padding: 8px 18px;
    border: none;
    border-radius: 8px;
    background: #27ae60;
    color: #fff;
    font-family: inherit;
    font-size: 14px;
    cursor: pointer;
}

.btn-custom:hover,
button:hover,
input[type="submit"]:hover {
    opacity: 0.9;
}

/* ============================================================
   گرید
   ============================================================ */

.grid-wrapper {
    width: 100%;
    overflow-x: auto;
    background: #fff;
    border: 1px solid #dfe4ea;
    border-radius: 8px;
}

.grid-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
}

.grid-table th {
    padding: 11px 10px;
    background: #eef2f7;
    color: #2c3e50;
    border-bottom: 1px solid #dfe4ea;
    font-weight: 700;
    white-space: nowrap;
}

.grid-table td {
    padding: 9px 10px;
    border-bottom: 1px solid #edf0f2;
}

.grid-table tr:hover td {
    background: #f8fafc;
}

.empty-grid {
    text-align: center;
    padding: 20px !important;
    color: #7f8c8d;
}

/* ============================================================
   پیام‌ها
   ============================================================ */

.alert-success,
.alert-error,
.alert-warning {
    margin: 15px 0;
    padding: 10px 12px;
    border-radius: 8px;
    font-weight: 700;
}

.alert-success {
    background: #eafaf1;
    color: #1e8449;
    border: 1px solid #abebc6;
}

.alert-error {
    background: #fdecea;
    color: #c0392b;
    border: 1px solid #f5b7b1;
}

.alert-warning {
    background: #fff8e1;
    color: #9a6b00;
    border: 1px solid #ffe082;
}

/* ============================================================
   ساختار پنل ادمین
   ============================================================ */

.admin-layout {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 260px;
    background: #2c3e50;
    color: #fff;
    padding: 20px 0;
}

.admin-sidebar-title {
    padding: 0 20px 20px 20px;
    font-size: 18px;
    font-weight: 700;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.admin-menu {
    list-style: none;
    padding: 0;
    margin: 15px 0 0 0;
}

.admin-menu li {
    margin: 0;
}

.admin-menu a {
    display: block;
    padding: 11px 20px;
    color: #ecf0f1;
}

.admin-menu a:hover,
.admin-menu a.active {
    background: rgba(255,255,255,0.1);
    color: #fff;
}

.admin-content {
    flex: 1;
    padding: 25px;
}

.admin-card {
    background: #fff;
    border: 1px solid #dfe4ea;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}
