/* ====== ریست ساده و فونت ====== */
@import url(fontiran.css);

body,
h1,
h2,
h3,
p,
ul,
li,
input,
textarea,
select,
button,
a {
    margin: 0;
    padding: 0;
    font-family: IRANSansX !important;
    box-sizing: border-box;
}

/* ====== ساختار صفحه و فوتر چسبیده ====== */
html,
body {
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: #e5e5fc;
    padding: 20px;
    direction: rtl;
    max-width: 1170px;
    margin: 0 auto;
}

main {
    flex: 1;
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    margin-bottom: 25px;
}

/* ====== لینک‌ها ====== */
a {
    text-decoration: none;
    color: #0070c9;
}

a:hover {
    color: #1b0179;
}

/* ====== هدر ====== */
header {
    background: #0a483c;
    padding: 25px;
    margin-bottom: 25px;
    border-radius: 15px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

nav a {
    margin-left: 12px;
    font-weight: bold;
    color: #fff;
}

nav a:hover {
    color: #e6e6e6;
}

/* ====== فرم‌ها ====== */
form1,
messages1 {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
    max-width: 1100px;
    margin-bottom: 35px;
    margin-top: 20px;
}

label {
    display: block;
    margin: 10px 0 5px;
    font-weight: bold;
}

order-card {
    background: #fdfdfd;
    border-radius: 15px;
    padding: 15px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.26);
    transition: all 0.3s ease;
    margin-top: 15px;
}

input[type=text],
input[type=email],
input[type=password],
input[type=number],
select,
textarea {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
}

/* ====== دکمه‌ها ====== */
button,
.btn-view,
.btn-edit,
.btn-delete,
.btn-toggle,
.btn-filter {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 700;
    transition: all 0.3s ease;
    text-align: center;
}

/* دکمه‌های جدول */
.btn-view {
    background: #20ae51;
    color: #fff;
}

.btn-view:hover {
    background: #1a9445;
}

.btn-edit {
    background: #3498db;
    color: #fff;
}

.btn-edit:hover {
    background: #217dbb;
}

.btn-delete {
    background: #e74c3c;
    color: #fff;
}

.btn-delete:hover {
    background: #c0392b;
}

.btn-toggle {
    background: #ffb464;
    color: #323232;
}

.btn-toggle:hover {
    background: #e01e17;
    color: #fff;
}

/* دکمه اعمال فیلتر */
.btn-filter {
    background: #3498db;
    color: #fff;
}

.btn-filter:hover {
    background: #217dbb;
}



/* ====== Bootstrap-Like Grid برای فرم ====== */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 15px;
}

[class^="col-"] {
    padding: 5px;
}

.col-md-3 {
    width: 25%;
}

.col-md-4 {
    width: 33.333333%;
}

.col-md-6 {
    width: 50%;
}

.col-md-12 {
    width: 100%;
}

.form-group {
    display: flex;
    flex-direction: column;
}

/* ریسپانسیو موبایل */
@media (max-width: 768px) {

    .col-md-4,
    .col-md-6 {
        width: 100%;
    }
}


/* ====== پیام‌ها ====== */
.flash-success {
    background: #d4f8d4;
    padding: 10px 15px;
    border-right: 4px solid #2fa62f;
    border-radius: 8px;
    margin-bottom: 15px;
    color: #155d15;
}

.errors {
    background: #ffe1e1;
    padding: 10px 15px;
    border-right: 4px solid #d12c2c;
    border-radius: 8px;
}

/* ====== فرم فیلتر ====== */
.filter-form {
    margin-bottom: 20px;
    padding: 10px;
    background: #f7f7f7;
    border-radius: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

/* ====== جدول ریسپانسیو ====== */
.table-responsive {
    width: 100%;
    overflow-x: auto;
}

.table-responsive table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    font-size: 0.95rem;
}

.table-responsive thead tr {
    background: linear-gradient(135deg, #0a483c, #1096a4);
    color: #fff;
}

.table-responsive th {
    background: transparent;
    font-weight: 600;
    text-transform: uppercase;
    padding: 12px 15px;
    text-align: center;
}

.table-responsive td {
    background: #f9f9f9;
    border-bottom: 1px solid #e0e0e0;
    padding: 8px 15px;
    text-align: center;
    transition: all 0.3s ease;
}

.table-responsive tr:last-child td {
    border-bottom: none;
}

.table-responsive tr:hover td {
    background: #e0f7ff;
    transform: translateY(-1px);
}

/* ====== صفحه‌بندی ====== */
.pagination {
    margin-top: 20px;
    text-align: center;
}

.btn-page,
.btn-active {
    display: inline-block;
    padding: 5px 10px;
    margin: 2px;
    border-radius: 4px;
    text-decoration: none;
    background: #ddd;
    color: #333;
}

.btn-active {
    background: #333;
    color: #fff;
}

/* ====== متن "هیچ داده‌ای یافت نشد" ====== */
.no-data {
    padding: 20px;
    text-align: center;
    color: #888;
}

/* ====== ردیف‌های جدول زوج ====== */
.table-responsive tbody tr:nth-child(even) {
    background: #f9f9f9;
}

/* ====== گرید حرفه‌ای فرم ثبت‌نام ====== */

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

.form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

/* تراز بهتر دکمه */
form button {
    margin-top: 20px;
}

/* ====== ریسپانسیو مخصوص موبایل ====== */
@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}