/* =====================================================================
   ملو فایل — استایل اصلی سایت (RTL, Mobile-First, تم سبز)
   ===================================================================== */

/* --- فونت اختصاصی ---------------------------------------------------- */
@font-face {
    font-family: 'IRANSansX';
    src: url('../fonts/IRANSansXFaNum-Regular.woff2') format('woff2'),
         url('../fonts/IRANSansXFaNum-Regular.woff') format('woff');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* --- متغیرها ---------------------------------------------------------- */
:root {
    --green-900: #064e3b;
    --green-700: #0b7f58;
    --green-600: #0e9f6e;
    --green-500: #10b981;
    --green-100: #d1fae5;
    --green-50:  #ecfdf5;
    --ink-900:   #14231c;
    --ink-700:   #33453c;
    --ink-500:   #5b6b63;
    --ink-300:   #9aa8a1;
    --line:      #e2ece6;
    --bg:        #f4f9f6;
    --card:      #ffffff;
    --danger:    #dc2626;
    --warn:      #d97706;
    --radius:    14px;
    --radius-lg: 20px;
    --shadow:    0 6px 24px rgba(13, 84, 58, .07);
    --shadow-lg: 0 12px 40px rgba(13, 84, 58, .12);
}

/* --- Reset ------------------------------------------------------------ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    font-family: 'IRANSansX', Tahoma, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.9;
    color: var(--ink-900);
    background: var(--bg);
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--green-700); text-decoration: none; }
a:hover { color: var(--green-900); }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; }
input, textarea, select { font-family: inherit; font-size: 15px; }

.container { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 16px; }

/* --- دکمه‌ها ----------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    border: none;
    border-radius: var(--radius);
    font-size: 15px;
    line-height: 1.6;
    transition: background .2s, color .2s, transform .1s, box-shadow .2s;
    -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(.98); }

.btn-primary {
    background: var(--green-600);
    color: #fff !important;
    font-weight: bold;
    box-shadow: 0 4px 14px rgba(14, 159, 110, .3);
}
.btn-primary:hover { background: var(--green-700); box-shadow: 0 6px 18px rgba(14, 159, 110, .35); }

.btn-outline {
    background: transparent;
    color: var(--green-700);
    border: 1.5px solid var(--green-600);
}
.btn-outline:hover { background: var(--green-50); color: var(--green-900); }

.btn-sm { padding: 8px 20px; font-size: 14px; border-radius: 10px; }

/* --- نوار اطلاع بالای سایت (قرمز، غیرقابل بستن، با اسکرول بالا می‌رود) --- */
.notice-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background: var(--danger, #dc2626);
    color: #fff;
    font-size: 13px;
    font-weight: bold;
    padding: 8px 16px;
    text-align: center;
}
.notice-bar a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.notice-bar a:hover { text-decoration: none; opacity: .92; }

/* --- هدر ---------------------------------------------------------------- */
.site-header {
    background: var(--card);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 50;
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 78px;
}
.logo {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: bold;
    font-size: 20px;
    color: var(--green-900);
}
.logo img {
    height: 56px;
    width: auto;
    max-width: 260px;
    object-fit: contain;
}
.logo-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--green-600);
    color: #fff;
    border-radius: 10px;
    font-size: 16px;
}
.main-nav { display: none; }
.main-nav ul { display: flex; align-items: center; gap: 4px; }
.main-nav a {
    display: block;
    padding: 8px 14px;
    border-radius: 10px;
    color: var(--ink-700);
    font-size: 14.5px;
    transition: background .2s, color .2s;
}
.main-nav a:hover { background: var(--green-50); color: var(--green-900); }
.main-nav a.active { background: var(--green-100); color: var(--green-900); font-weight: bold; }

/* دکمه ورود در هدر */
.header-actions { display: flex; align-items: center; gap: 8px; margin-inline-start: auto; }
.btn-login {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 22px;
    border-radius: 10px;
    background: var(--green-600);
    color: #fff;
    font-size: 14.5px;
    font-weight: bold;
    transition: background .2s, transform .15s;
}
.btn-login:hover { background: var(--green-700); }
.btn-login:active { transform: scale(.97); }
.main-nav a.btn-login { color: #fff; }
.main-nav a.btn-login:hover { background: var(--green-700); color: #fff; }
.login-desktop { display: none; }

.hamburger {
    display: inline-flex;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    padding: 8px;
}
.hamburger span {
    width: 24px;
    height: 2.5px;
    border-radius: 2px;
    background: var(--ink-900);
    transition: transform .25s, opacity .2s;
}
.hamburger.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* منوی موبایل — به صورت پنل بازشو زیر هدر */
@media (max-width: 991px) {
    .main-nav {
        display: block;
        position: absolute;
        top: 100%;
        inset-inline: 0;
        background: var(--card);
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-lg);
        max-height: 0;
        overflow: hidden;
        transition: max-height .3s ease;
    }
    .main-nav.open { max-height: 420px; }
    .main-nav ul { flex-direction: column; align-items: stretch; padding: 12px 16px; gap: 2px; }
    .main-nav a { padding: 12px 14px; }
}
@media (min-width: 992px) {
    .hamburger { display: none; }
    .main-nav { display: block; flex: 1; }
    .main-nav ul { justify-content: center; }
    .nav-login-item { display: none; }
    .login-desktop { display: inline-flex; }
}
/* موبایل: دکمه ورود کنار همبرگر هست — پس در منوی بازشو تکرار نمی‌شود */
@media (max-width: 991px) {
    .login-desktop { display: inline-flex; padding: 7px 14px; font-size: 13.5px; }
    .nav-login-item { display: none; }
}

/* --- Hero --------------------------------------------------------------- */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}
.hero {
    background: linear-gradient(160deg, var(--green-900) 0%, var(--green-700) 65%, var(--green-600) 100%);
    color: #fff;
    padding: 48px 0 56px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.hero::after {
    content: '';
    position: absolute;
    inset-inline-start: -80px;
    bottom: -120px;
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .06);
}
.hero-title { font-size: 26px; line-height: 1.6; margin-bottom: 12px; }
.hero-intro {
    max-width: 640px;
    margin: 0 auto 28px;
    color: var(--green-100);
    font-size: 15px;
}
.hero-search {
    display: flex;
    max-width: 620px;
    margin: 0 auto;
    background: #fff;
    border-radius: 16px;
    padding: 6px;
    box-shadow: var(--shadow-lg);
}
.hero-search input {
    flex: 1;
    border: none;
    outline: none;
    padding: 10px 16px;
    border-radius: 12px;
    background: transparent;
    color: var(--ink-900);
    min-width: 0;
}
.hero-search button {
    background: var(--green-600);
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 10px 26px;
    font-size: 15px;
    transition: background .2s;
}
.hero-search button:hover { background: var(--green-700); }

.hero-cats {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 22px;
}
.hero-cats a {
    background: rgba(255, 255, 255, .12);
    color: #fff;
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 13px;
    transition: background .2s;
}
.hero-cats a:hover { background: rgba(255, 255, 255, .24); color: #fff; }

@media (min-width: 768px) {
    .hero { padding: 80px 0 88px; }
    .hero-title { font-size: 34px; }
}

/* --- گرید فایل‌ها -------------------------------------------------------- */
.files-section { padding: 40px 0 56px; }
.files-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}
@media (min-width: 640px)  { .files-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .files-grid { grid-template-columns: repeat(3, 1fr); } }

/* --- فایل‌های مشابه در صفحه فایل ------------------------------------------------ */
.related-files { margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--line); }
.related-title { font-size: 18px; margin: 0 0 14px; color: var(--ink-900); }
.related-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 640px)  { .related-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .related-grid { grid-template-columns: repeat(3, 1fr); } }
/* موبایل: بخش پیشنهادی تمام‌عرض کارت شود تا ابعاد کارت‌ها مثل صفحه اصلی باشد */
@media (max-width: 639.98px) {
    .related-files { margin: 28px -20px 0; padding: 22px 0 0; }
    .related-title { padding: 0 20px; }
}

.load-more { text-align: center; margin-top: 32px; }

/* --- کارت فایل ----------------------------------------------------------- */
/* دیزاین: بدنه flex با ارتفاع هم‌اندازه در گرید؛ عنوان چندخطی ولی فوتر (قیمت+دکمه) همیشه یک خط ثابت */
.files-grid,
.related-grid { align-items: stretch; }
.file-card {
    display: flex;
    gap: 14px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: var(--shadow);
    transition: transform .2s, box-shadow .2s, border-color .2s;
}
.file-card:hover {
    /* بدون transform — جابه‌جایی کارت باعث می‌شد دکمه دانلود هنگام hover از هم‌ردیف‌هایش بالاتر برود؛
       افکت هاور فقط با سایه و قاب اعمال می‌شود تا دکمه همیشه دقیقاً در یک خط باشد */
    box-shadow: var(--shadow-lg);
    border-color: var(--green-500);
}
.file-card-thumb {
    flex: 0 0 84px;
    width: 84px;
    height: 84px;
    margin-top: 2px;
    border-radius: var(--radius);
    background: var(--green-50);
    border: 1px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}
.file-card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.file-card-placeholder { font-size: 30px; color: var(--green-500); display: flex; align-items: center; justify-content: center; }
.file-card-placeholder svg { display: block; }
.file-card-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
/* فوتر کارت: قیمت و دکمه همیشه در یک خط؛ ارتفاع ثابت — هرچه عنوان بلندتر به‌هم نمی‌ریزد */
/* margin-top:auto فوتر را به انتهای کارت می‌چسباند تا دکمه «دانلود» و قیمت در همه کارت‌های یک ردیف هم‌تراز باشند
   حتی زمانی که تعداد خطوط عنوان کارت‌ها متفاوت است */
.file-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 44px;       /* ارتفاع ثابت دکمه دانلود */
    margin-top: auto;       /* فوتر همیشه پایین کارت؛ فاصله حداقلی با عنوان از طریق padding-top */
    padding-top: 12px;
    border-top: 1px dashed var(--line);
}
/* حداقل فاصله فوتر از عنوان وقتی کارت بلند است و فوتر با auto به پایین چسبیده */
.file-card-title { margin-bottom: 12px; }
.file-card-footer .btn { flex: 0 0 auto; white-space: nowrap; }
.file-card-cat {
    align-self: flex-start;
    font-size: 12px;
    background: var(--green-100);
    color: var(--green-900);
    padding: 2px 10px;
    border-radius: 999px;
    margin-bottom: 6px;
}
.file-card-title { font-size: 15.5px; line-height: 1.7; margin-bottom: 4px; }
.file-card-title a { color: var(--ink-900); display: block;
    overflow: hidden; text-overflow: ellipsis; display: -webkit-box;
    -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    /* ارتفاع ثابت ۲ خط — عنوان کوتاه هم جای ۲ خط را می‌گی‌رد تا فوتر (قیمت+دکمه دانلود) در همه کارت‌های یک ردیف دقیقاً هم‌خط باشد,
       چه عنوان کوتاه باشد چه بلند */
    min-height: calc(2 * 1.7em);
}
.file-card-title a:hover { color: var(--green-700); }
.file-card-desc {
    font-size: 13.5px;
    color: var(--ink-500);
    margin-bottom: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.file-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 12.5px;
    color: var(--ink-300);
    margin-bottom: auto;
}
.file-card-price { font-size: 15px; font-weight: bold; color: var(--green-700); white-space: nowrap; }

/* --- Breadcrumb / صفحه‌بندی / حالت خالی ------------------------------------ */
.breadcrumb { padding: 18px 0 6px; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 4px; font-size: 13px; color: var(--ink-300); }
.breadcrumb li:not(:last-child)::after { content: '/'; margin: 0 6px; color: var(--ink-300); }
.breadcrumb a { color: var(--ink-500); }
.breadcrumb a:hover { color: var(--green-700); }

.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin: 36px 0 12px;
}
.pagination .page {
    min-width: 42px;
    padding: 8px 12px;
    text-align: center;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 10px;
    color: var(--ink-700);
    font-size: 14px;
}
.pagination .page:hover { border-color: var(--green-500); color: var(--green-700); }
.pagination .current { background: var(--green-600); border-color: var(--green-600); color: #fff; font-weight: bold; }
.pagination .gap { border: none; background: none; color: var(--ink-400, #888); font-weight: bold; }

.empty-state {
    background: var(--card);
    border: 1px dashed var(--line);
    border-radius: var(--radius-lg);
    padding: 56px 24px;
    text-align: center;
    color: var(--ink-500);
}

/* --- فایل ناموجود ---------------------------------------------------------- */
.unavailable-box {
    background: var(--card);
    border: 1px dashed var(--line);
    border-radius: var(--radius-lg);
    padding: 56px 24px;
    text-align: center;
    margin-top: 20px;
}
.unavailable-icon { font-size: 48px; margin-bottom: 10px; }
.unavailable-title { font-size: 20px; margin-bottom: 10px; }
.unavailable-box p { color: var(--ink-500); font-size: 15px; margin-bottom: 22px; }

/* --- آرشیو و صفحات ثابت -------------------------------------------------- */
.archive-page { padding-bottom: 56px; }
.archive-head { margin: 16px 0 24px; }
.archive-head h1 { font-size: 21px; margin-bottom: 10px; }
.archive-desc { color: var(--ink-500); font-size: 14.5px; }
.archive-search { max-width: 480px; margin: 0; }

.static-page {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    margin: 20px 0;
    box-shadow: var(--shadow);
}
.static-page h1 { font-size: 21px; margin-bottom: 16px; color: var(--green-900); }
.static-page-content { color: var(--ink-700); font-size: 15px; line-height: 2.1; }

/* --- صفحه فایل ------------------------------------------------------------ */
.file-page { padding-bottom: 56px; }
.file-detail {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    margin-top: 12px;
    overflow: hidden;
}
.file-detail-head {
    padding: 24px 20px;
    border-bottom: 1px solid var(--line);
    background: linear-gradient(180deg, var(--green-50), var(--card));
}
.file-detail-head h1 { font-size: 22px; line-height: 1.6; margin-bottom: 10px; }
.file-detail-body { padding: 24px 20px; }

.file-detail-image { margin-bottom: 20px; }
.file-detail-image img {
    width: 100%;
    max-width: 520px;
    border-radius: var(--radius);
    border: 1px solid var(--line);
}
.file-detail-lead {
    font-size: 16px;
    color: var(--ink-700);
    font-weight: bold;
    margin-bottom: 16px;
}
.file-detail-content { color: var(--ink-700); line-height: 2.1; margin-bottom: 24px; }

.file-specs {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 18px 20px;
    margin-bottom: 24px;
}
.file-specs h2 { font-size: 16px; margin-bottom: 12px; color: var(--green-900); }
.file-specs li {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 8px 0;
    border-bottom: 1px dashed var(--line);
    font-size: 14px;
}
.file-specs li:last-child { border-bottom: none; }
.file-specs li span { color: var(--ink-500); }

/* --- چیدمان دو ستونه: عکس (راست) + خرید (چپ) -------------------------------- */
.product-layout {
    display: grid;
    grid-template-columns: minmax(0, 340px) minmax(0, 1fr);
    gap: 28px;
    align-items: start;
    margin-bottom: 28px;
}

/* --- عکس محصول --------------------------------------------------------------- */
.product-figure { margin: 0; }
.product-image-wrap {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--bg);
    text-align: center;
    line-height: 0;
}
.product-image-wrap img { width: 256px; height: 256px; object-fit: cover; display: block; margin: 0 auto; }
@media (max-width: 767px) {
    .product-layout { grid-template-columns: 1fr; }
    .product-image-wrap { max-width: 280px; margin: 0 auto; }
}

/* --- جعبه خرید (CTA) ------------------------------------------------------- */
.buy-box {
    border: 2px solid var(--green-500);
    border-radius: var(--radius-lg);
    padding: 22px 20px;
    background: var(--green-50);
    text-align: center;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 16px;
}
.buy-discount-line {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}
.buy-discount-line .countdown-box { margin-bottom: 0; }
.buy-price-row { display: flex; align-items: baseline; justify-content: center; gap: 10px; flex-wrap: wrap; }
.buy-price { font-size: 28px; color: var(--green-700); font-weight: bold; }
.buy-price-compare { font-size: 17px; color: var(--ink-500); }
.buy-discount-badge {
    background: var(--danger);
    color: #fff;
    font-size: 13px;
    font-weight: bold;
    padding: 4px 12px;
    border-radius: 999px;
}
.countdown-box {
    background: #fee2e2;
    border: 1px solid #fecaca;
    color: var(--danger);
    border-radius: var(--radius);
    padding: 10px 16px;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.countdown-timer { font-weight: bold; font-size: 18px; letter-spacing: 1px; }

/* کادر شماره تلفن */
.buy-form .form-field {
    max-width: 420px;
    margin: 0 auto;
    width: 100%;
}
.buy-form .form-label {
    display: block;
    font-size: 14px;
    font-weight: bold;
    color: var(--ink-700);
    margin-bottom: 8px;
    text-align: right;
}
.buy-form .form-input {
    width: 100%;
    text-align: center;
    letter-spacing: 2px;
    font-size: 18px;
    font-weight: bold;
    padding: 13px 16px;
    border: 2px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    transition: border-color .2s, box-shadow .2s;
}
.buy-form .form-input:focus {
    outline: none;
    border-color: var(--green-500);
    box-shadow: 0 0 0 3px rgba(16, 145, 87, .12);
}
.phone-error {
    display: none;
}
.phone-error:not([hidden]) {
    display: block;
    color: var(--danger);
    font-size: 13px;
    font-weight: bold;
    margin-top: 8px;
    text-align: right;
}
.input-invalid { border-color: var(--danger) !important; background: #fef2f2; box-shadow: 0 0 0 3px rgba(220, 38, 38, .1) !important; }
.shake { animation: shake .45s ease; }
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-8px); }
    40% { transform: translateX(8px); }
    60% { transform: translateX(-6px); }
    80% { transform: translateX(6px); }
}
.btn-buy { width: 100%; max-width: 420px; font-size: 17px; padding: 15px 24px; }
.buy-form .form-field { margin-bottom: 8px; }

/* --- گالری محصول ------------------------------------------------------------ */
.file-gallery { margin-bottom: 24px; }
.gallery-main {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--bg);
    text-align: center;
}
.gallery-main img { max-width: 100%; height: auto; display: inline-block; }
.gallery-thumbs { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.gallery-thumb {
    border: 2px solid var(--line);
    border-radius: var(--radius);
    padding: 0;
    background: none;
    cursor: pointer;
    overflow: hidden;
    transition: border-color .2s;
}
.gallery-thumb img { width: 72px; height: 72px; object-fit: cover; display: block; }
.gallery-thumb.active, .gallery-thumb:hover { border-color: var(--green-600); }

/* --- باکس‌های اعتماد (۴ کارت کنار هم) ------------------------------------------ */
.trust-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 20px;
}
.trust-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
    transition: border-color .2s, box-shadow .2s;
}
.trust-item:hover { border-color: var(--green-600); box-shadow: 0 2px 8px rgba(0, 0, 0, .07); }
.trust-icon { font-size: 26px; line-height: 1; }
.trust-text { font-size: 13.5px; color: var(--ink-700); line-height: 1.6; }
@media (min-width: 992px) {
    .trust-grid { grid-template-columns: repeat(4, 1fr); }
}

/* --- گزارش تخلف — زیر عکس محصول، هم‌تراز کادر خرید ----------------------------- */
.product-figure {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.product-figure .report-toggle {
    align-self: center;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--ink-600);
    font-size: 13.5px;
    cursor: pointer;
    padding: 9px 18px;
    text-decoration: none;
    transition: border-color .2s, color .2s;
}
.product-figure .report-toggle:hover { border-color: var(--danger); color: var(--danger); }

/* --- صفحه گزارش تخلف (صفحه مستقل) -------------------------------------------- */
.report-page { max-width: 680px; }
.report-page-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 32px 28px;
    box-shadow: var(--shadow, 0 4px 18px rgba(0, 0, 0, .05));
}
.report-page-title { font-size: 22px; margin: 0 0 6px; }
.report-page-file { color: var(--ink-500); font-size: 14px; margin: 0 0 20px; }
.report-page-file strong { color: var(--ink-700); }
.report-form .form-label { margin-top: 14px; display: block; font-weight: 700; }
.report-form .form-input { margin-top: 6px; width: 100%; }
.report-form .btn { margin-top: 16px; }

@media (min-width: 768px) {
    .file-detail-head, .file-detail-body { padding: 32px 36px; }
    .file-detail-head h1 { font-size: 26px; }
}

/* --- هشدارها ---------------------------------------------------------------- */
.alert { padding: 12px 16px; border-radius: var(--radius); font-size: 14px; margin-bottom: 20px; }
.alert-error { background: #fef2f2; color: var(--danger); border: 1px solid #fecaca; }

/* --- صفحه تشکر -------------------------------------------------------------- */
.thank-page { padding: 40px 0 72px; max-width: 680px; }
.thank-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 32px 20px;
    text-align: center;
}
.thank-success { border-top: 5px solid var(--green-600); }
.thank-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: var(--green-100);
    color: var(--green-700);
    font-size: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.thank-card h1 { font-size: 20px; margin-bottom: 8px; }
.thank-sub { color: var(--ink-500); font-size: 14.5px; margin-bottom: 24px; }
.thank-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 14px 16px;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    margin-bottom: 12px;
    text-align: right;
}
.thank-label { font-size: 13px; color: var(--ink-500); }
.thank-value { font-size: 16px; color: var(--ink-900); }
.order-number { color: var(--green-700); font-weight: bold; letter-spacing: 1px; }

.password-wrap {
    display: flex;
    gap: 8px;
    align-items: stretch;
}
.password-copy {
    flex: 1;
    font-family: inherit;
    font-size: 17px;
    font-weight: bold;
    letter-spacing: 1.5px;
    color: var(--green-900);
    background: var(--green-100);
    border: 1.5px dashed var(--green-500);
    border-radius: 10px;
    padding: 12px 16px;
    transition: background .2s;
    word-break: break-all;
    cursor: copy;
}
.password-copy:hover { background: var(--green-100); }
.btn-copy-side { flex: 0 0 auto; }

.copy-toast {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    color: var(--green-700);
    opacity: 0;
    transition: opacity .25s;
    min-height: 22px;
}
.copy-toast.visible { opacity: 1; }

.thank-hint { font-size: 13px; color: var(--ink-500); margin-top: 16px; line-height: 2; }
.thank-ref { margin-top: 16px; }
.thank-warn h1, .thank-fail h1 { margin-bottom: 12px; }
.thank-fail h1 { color: var(--danger); }
.thank-warn h1 { color: var(--warn); }
.thank-fail p, .thank-warn p { color: var(--ink-500); margin-bottom: 20px; }

/* --- دانلود و حساب در صفحه تشکر ------------------------------------------ */
.thank-download { margin-top: 20px; }
.btn-download { width: 100%; font-size: 16px; padding: 14px 20px; }

.thank-account {
    margin-top: 20px;
    border-top: 2px solid var(--green-100);
}
.thank-account--ok { border-top: none; background: var(--green-50); }
.thank-account--ok p { color: var(--green-900); line-height: 2; margin: 0; }
.account-title { font-size: 17px; margin-bottom: 8px; color: var(--ink-900); }
.account-sub { font-size: 13.5px; color: var(--ink-500); line-height: 2; margin-bottom: 16px; }
.account-form .form-field { margin-bottom: 10px; }
.account-form .btn { margin-top: 6px; }
.account-error {
    display: none;
    font-size: 12.5px;
    color: var(--danger);
    margin-top: 6px;
}
.account-error:not([hidden]) { display: block; }

/* --- ورود / فایل‌های من ---------------------------------------------------- */
.auth-page {
    max-width: 480px;
    padding: 48px 16px 64px;
}
.auth-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 36px 32px;
    position: relative;
    overflow: hidden;
}
.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--green-600), var(--green-400));
}
.auth-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 14px;
    background: var(--green-50);
    border: 1px solid var(--green-100);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
}
.auth-card h1 {
    font-size: 22px;
    margin-bottom: 6px;
    text-align: center;
    color: var(--ink-900);
}
.auth-sub {
    font-size: 13.5px;
    color: var(--ink-500);
    line-height: 2.1;
    margin-bottom: 24px;
    text-align: center;
}
.auth-form .form-field { margin-bottom: 16px; }
.auth-label {
    display: block;
    font-size: 13.5px;
    font-weight: bold;
    color: var(--ink-700);
    margin-bottom: 6px;
}
.auth-input-wrap { position: relative; }
/* آیکون کنار برچسب (بیرون کادر) */
.auth-label .auth-field-icon {
    font-size: 14px;
    color: var(--ink-400, #9aa8a1);
    margin-inline-end: 2px;
}
.auth-input {
    width: 100%;
    padding: 13px 14px;
    font-size: 15px;
    font-family: inherit;
    color: var(--ink-900);
    background: var(--bg);
    border: 1.5px solid var(--line);
    border-radius: 12px;
    outline: none;
    transition: border-color .2s, box-shadow .2s, background .2s;
}
/* فیلدهای LTR صفحه ورود: متن و placeholder چپ‌چین */
.auth-input-ltr { text-align: left; }
/* آیکون چشم رمز عبور (نمایش با نگه‌داشتن) */
/* چشم سمت راست کادر (input با dir=ltr است؛ right ثابت است) */
.password-eye {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--ink-300);
    cursor: pointer;
    transition: color .2s, background .2s;
}
.password-eye svg.eye-hidden { display: none; }
.password-eye svg[hidden] { display: none; }
.password-eye:hover, .password-eye.active { color: var(--green-500); }
.password-eye:focus-visible { outline: 2px solid var(--green-500); }
/* input با dir=ltr است؛ چشم سمت راست است، پس فاصله از سمت راستِ متن لازم است */
.auth-input-wrap:has(.password-eye) .auth-input { padding-inline-end: 50px; }
.auth-input:focus {
    border-color: var(--green-500);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(22, 163, 74, .1);
}
.auth-input.input-invalid { border-color: var(--danger) !important; background: #fef2f2; }
.auth-hint {
    font-size: 12.5px;
    color: var(--ink-300);
    margin-top: 6px;
    line-height: 1.8;
}
.auth-btn {
    width: 100%;
    padding: 14px;
    font-size: 16px;
    font-weight: bold;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    margin-top: 4px;
    transition: transform .15s, box-shadow .2s, background .2s;
}
.auth-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(22, 163, 74, .3); }
.auth-btn:active { transform: translateY(0); }
.auth-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0 14px;
    color: var(--ink-300);
    font-size: 12.5px;
}
.auth-divider::before, .auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--line);
}
.auth-footnote {
    text-align: center;
    font-size: 12.5px;
    color: var(--ink-300);
    margin: 0;
    line-height: 1.9;
}
@media (max-width: 480px) {
    .auth-card { padding: 28px 20px; }
    .auth-page { padding: 28px 12px 48px; }
}

.flash { padding: 12px 16px; border-radius: var(--radius); font-size: 13.5px; margin-bottom: 14px; line-height: 1.9; }
.flash-ok  { background: var(--green-50); color: var(--green-900); border: 1px solid var(--green-100); }
.flash-err { background: #fdecec; color: var(--danger); border: 1px solid #f5c2c2; }

.my-files-head { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 28px 0 16px; }
.my-files-head h1 { font-size: 22px; }
.my-files-head p { color: var(--ink-500); font-size: 14px; }
.logout-form { margin-inline-start: auto; }
.my-files-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 768px) { .my-files-grid { grid-template-columns: repeat(2, 1fr); } }
.my-file-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.my-file-title { font-size: 16px; color: var(--ink-900); }
.my-file-meta { display: flex; flex-wrap: wrap; gap: 12px; font-size: 13px; color: var(--ink-300); }
.my-file-password { display: flex; align-items: center; gap: 8px; font-size: 13.5px; }
.my-file-password-label { color: var(--ink-500); }
.my-file-card .btn { align-self: flex-start; }

@media (min-width: 640px) {
    .thank-card { padding: 40px 40px; }
    .thank-row { flex-direction: row; align-items: center; justify-content: space-between; }
    .thank-password-row { flex-direction: column; align-items: stretch; }
}

/* --- فوتر -------------------------------------------------------------------- */
.site-footer {
    background: var(--green-900);
    color: var(--green-100);
    margin-top: 40px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 44px 16px 36px;
    text-align: center;
}
.footer-col { text-align: center; }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-title {
    font-size: 15.5px;
    color: #fff;
    margin-bottom: 14px;
    text-align: center;
}
.footer-title::after {
    content: '';
    display: block;
    width: 36px;
    height: 3px;
    margin: 8px auto 0;
    border-radius: 2px;
    background: var(--green-500);
}
.footer-links a, .footer-cats a {
    color: var(--green-100);
    font-size: 14px;
    display: inline-block;
    padding: 4px 0;
    opacity: .85;
}
.footer-links a:hover, .footer-cats a:hover { opacity: 1; color: #fff; }

.contact-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .15);
    color: #fff;
    border-radius: 999px;
    padding: 8px 18px;
    font-size: 14px;
    margin: 0 0 10px;
    transition: background .2s;
}
.contact-pill:hover { background: rgba(255, 255, 255, .16); color: #fff; }

.footer-desc { font-size: 13px; color: var(--green-100); opacity: .75; line-height: 2; margin-top: 12px; max-width: 460px; margin-inline: auto; }
.footer-desc-rtl {
    text-align: right;
    direction: rtl;
    max-width: 420px;
    margin-inline: 0;
    margin-top: 14px;
    line-height: 2.1;
    color: var(--green-100);
    opacity: .95;
    font-size: 13.5px;
}
.footer-desc-rtl strong { color: #fff; }
.footer-desc-justify { text-align: justify; text-align-last: center; }

.trust-badges { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.trust-badges-images { flex-wrap: nowrap; }
.trust-badge {
    width: 92px;
    height: 92px;
    border: 1px dashed rgba(255, 255, 255, .3);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 11.5px;
    line-height: 1.8;
    color: var(--green-100);
    padding: 8px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .12);
    padding: 16px 0;
    text-align: center;
    font-size: 13px;
    color: var(--green-100);
    opacity: .8;
}

@media (min-width: 768px) {
    .footer-grid { grid-template-columns: repeat(2, 1fr); max-width: 900px; margin-inline: auto; }
}
@media (min-width: 1024px) {
    .footer-grid { grid-template-columns: 1fr 1fr 1fr; max-width: 1080px; }
}


/* ============================== صفحه تماس با ما ============================== */
.contact-page { max-width: 860px; }
.contact-hero { text-align: center; margin: 28px 0 8px; }
.contact-hero-icon {
    width: 72px; height: 72px;
    margin: 0 auto 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 34px;
    background: linear-gradient(135deg, var(--green-50, #ecfdf5), #fff);
    border: 1.5px solid var(--green-100, #d1fae5);
    border-radius: 22px;
}
.contact-hero h1 { font-size: 27px; margin: 0 0 10px; color: var(--ink-900); }
.contact-hero-sub {
    max-width: 560px; margin: 0 auto;
    color: var(--ink-500, #6b7280); font-size: 15px; line-height: 1.9;
}
.contact-hours {
    display: inline-flex; align-items: center; gap: 8px;
    margin-top: 16px; padding: 10px 18px;
    background: var(--green-50, #ecfdf5);
    border: 1px solid var(--green-100, #d1fae5);
    border-radius: 999px;
    font-size: 13.5px; color: var(--ink-700);
}
.contact-hours strong { color: var(--green-600, #059669); }

.contact-channels {
    display: grid; gap: 14px;
    margin: 26px 0;
}
@media (min-width: 768px) { .contact-channels { grid-template-columns: repeat(3, 1fr); } }
.contact-channel {
    display: flex; align-items: center; gap: 12px;
    padding: 18px 16px;
    background: #fff;
    border: 1.5px solid var(--line);
    border-radius: 16px;
    text-decoration: none;
    color: inherit;
    transition: transform .15s, box-shadow .15s, border-color .15s;
}
.contact-channel:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, .07);
}
.contact-channel-logo {
    flex: 0 0 auto;
    width: 46px; height: 46px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 13px;
}
.contact-channel-telegram .contact-channel-logo { background: #e8f4fd; color: #229ED9; }
.contact-channel-bale .contact-channel-logo     { background: #eef2ff; color: #5b5fc7; }
.contact-channel-email .contact-channel-logo    { background: var(--green-50, #ecfdf5); color: var(--green-600, #059669); }
.contact-channel-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.contact-channel-title { font-weight: bold; font-size: 14.5px; color: var(--ink-900); }
.contact-channel-id {
    font-size: 13px; color: var(--ink-500, #6b7280);
    direction: ltr; text-align: right;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.contact-channel-id-full {
    font-size: 13.5px;
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    word-break: break-all;
}
.contact-channel-cta {
    flex: 0 0 auto;
    font-size: 12.5px; font-weight: bold;
    padding: 7px 14px; border-radius: 999px;
    background: var(--green-50, #ecfdf5); color: var(--green-600, #059669);
    transition: background .15s, color .15s;
}
.contact-channel:hover .contact-channel-cta { background: var(--green-500); color: #fff; }
.contact-channel-telegram:hover  { border-color: #229ED9; }
.contact-channel-bale:hover      { border-color: #5b5fc7; }
.contact-channel-email:hover     { border-color: var(--green-500); }

.contact-address {
    background: #fff;
    border: 1.5px solid var(--line);
    border-radius: 16px;
    padding: 22px 24px;
    margin-bottom: 32px;
}
.contact-address h2 {
    display: flex; align-items: center; gap: 8px;
    font-size: 17px; margin: 0 0 10px; color: var(--ink-900);
}
.contact-address address {
    font-style: normal;
    font-size: 15px; font-weight: bold;
    color: var(--ink-700);
    line-height: 1.9;
}
.contact-address-note { margin: 10px 0 0; font-size: 13px; color: var(--ink-400, #9ca3af); }

@media (max-width: 480px) {
    .contact-channel { flex-wrap: wrap; }
    .contact-channel-cta { width: 100%; text-align: center; }
}

/* ============================== صفحه نمادهای اعتماد ============================== */
.trust-page { max-width: 860px; }
.trust-hero { text-align: center; margin: 28px 0 10px; }
.trust-hero-icon {
    width: 72px; height: 72px;
    margin: 0 auto 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 34px;
    background: linear-gradient(135deg, var(--green-50, #ecfdf5), #fff);
    border: 1.5px solid var(--green-100, #d1fae5);
    border-radius: 22px;
}
.trust-hero h1 { font-size: 26px; margin: 0 0 10px; color: var(--ink-900); }
.trust-hero-sub {
    max-width: 560px; margin: 0 auto;
    color: var(--ink-500, #6b7280); font-size: 15px; line-height: 1.9;
}
.trust-empty {
    text-align: center;
    background: #fff; border: 1.5px dashed var(--line);
    border-radius: 16px; padding: 36px 24px; margin-bottom: 24px;
    color: var(--ink-500, #6b7280); font-size: 14.5px;
}
.trust-badges-grid {
    display: grid; gap: 16px;
    grid-template-columns: repeat(2, 1fr);
    margin: 26px 0;
}
@media (min-width: 640px) { .trust-badges-grid { grid-template-columns: repeat(3, 1fr); } }
.trust-badge-card {
    display: flex; flex-direction: column; align-items: center; gap: 12px;
    padding: 26px 16px 20px;
    background: #fff;
    border: 1.5px solid var(--line);
    border-radius: 18px;
    text-decoration: none; color: inherit;
    text-align: center;
    transition: transform .15s, box-shadow .15s, border-color .15s;
}
.trust-badge-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, .07);
    border-color: var(--green-500);
}
.trust-badge-media {
    width: 110px; height: 110px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 14px;
    background: var(--green-50, #ecfdf5);
    overflow: hidden;
}
.trust-badge-media img { max-width: 100%; max-height: 100%; object-fit: contain; }
.trust-badge-fallback { font-size: 46px; line-height: 1; }
.trust-badge-title { font-weight: bold; font-size: 14px; color: var(--ink-900); line-height: 1.7; }

.trust-note {
    background: #fff;
    border: 1.5px solid var(--line);
    border-radius: 16px;
    padding: 22px 24px;
    margin-bottom: 32px;
}
.trust-note h2 {
    display: flex; align-items: center; gap: 8px;
    font-size: 17px; margin: 0 0 14px; color: var(--ink-900);
}
.trust-reasons { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.trust-reasons li {
    display: flex; align-items: flex-start; gap: 10px;
    font-size: 14px; color: var(--ink-700); line-height: 1.9;
}
.trust-reasons li > span { flex: 0 0 auto; font-size: 17px; line-height: 1.6; }
.trust-note-link { margin: 16px 0 0; font-size: 13.5px; color: var(--ink-500, #6b7280); }
.trust-note-link a { color: var(--green-600, #059669); font-weight: bold; text-decoration: none; }
.trust-note-link a:hover { text-decoration: underline; }

/* کارت نماد با کد HTML خام (اینماد و...) */
.trust-badge-code { gap: 14px; padding: 20px 16px; }
.trust-badge-code > * { max-width: 100%; }

/* =====================================================================
   نمادهای تصویری فوتر (اینماد / اتحادیه کسب‌وکارهای مجازی و...)
   ===================================================================== */
.trust-badges-images { align-items: center; }
.footer-badge-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 12px;
    padding: 5px;
    min-width: 84px;
    min-height: 84px;
    transition: transform .15s ease, box-shadow .15s ease;
}
.footer-badge-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, .25);
}
.footer-badge-img {
    width: 72px;
    height: 78px;
    object-fit: contain;
    display: block;
}
.footer-badge-etehadie { width: 78px; object-fit: contain; }
.footer-badge-samandehi { width: 76px; object-fit: contain; }

/* پیش‌نمایش کد خام نماد، در لیست نمادهای تنظیمات ادمین */
.trust-list-code {
    display: inline-block;
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    vertical-align: middle;
    font-size: 12px;
    color: var(--ink-500, #5b6b63);
    background: var(--green-50, #ecfdf5);
    border: 1px solid var(--green-100, #d1fae5);
    border-radius: 8px;
    padding: 3px 8px;
}
