@charset "UTF-8";

@font-face {
    font-family: "Num_Medium";
    src: url("../fonts/Num_Medium.eot") format('eot'),
         url("../fonts/Num_Medium.woff") format("woff"),
         url("../fonts/Num_Medium.ttf") format("truetype");
    font-weight: normal;
    font-style: normal;
}

/* عمومی و ریست پایه */
* {
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
}

body {
    direction: rtl;
    text-align: right;
    font-family: "Num_Medium", "Vazirmatn", "IRANSans", Tahoma, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.8;
    color: #222;
    background-color: #f3f4f6;
    margin: 0;
    padding: 20px 10px;
}

a {
    text-decoration: none;
    color: #004adf;
}

/* کانتینر صفحه چاپ */
.print-container {
    max-width: 840px;
    margin: 0 auto;
    background: #ffffff;
    padding: 25px 35px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e5e7eb;
}

/* سربرگ و لوگو */
.print-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 15px;
    border-bottom: 2px solid #004adf;
    margin-bottom: 15px;
}

.print-logo img {
    max-height: 60px;
    width: auto;
    max-width: 250px;
    object-fit: contain;
}

.print-site-info {
    text-align: left;
    font-size: 13px;
    color: #666;
}

.print-site-info .site-title {
    display: block;
    font-weight: bold;
    font-size: 16px;
    color: #222;
}

.print-site-info .site-url {
    direction: ltr;
    display: block;
    color: #888;
}

/* نوار ابزار در مانیتور */
.print-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 10px 15px;
    border-radius: 6px;
    margin-bottom: 25px;
    font-size: 13px;
}

.print-toolbar .meta-info span {
    margin-left: 20px;
    color: #475569;
}

.print-toolbar .meta-info strong {
    color: #1e293b;
}

.print-actions {
    display: flex;
    gap: 8px;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 14px;
    border-radius: 5px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    text-decoration: none !important;
}

.btn-print {
    background: #10b981;
    color: #ffffff !important;
}

.btn-print:hover {
    background: #059669;
}

.btn-back {
    background: #3b82f6;
    color: #ffffff !important;
}

.btn-back:hover {
    background: #2563eb;
}

.btn-home {
    background: #e2e8f0;
    color: #334155 !important;
}

.btn-home:hover {
    background: #cbd5e1;
}

.print-only {
    display: none;
}

/* مقالات و تیترها */
.print-article {
    margin-top: 15px;
}

.print-rutitr {
    color: #004adf;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 6px;
}

.print-title {
    font-size: 22px;
    font-weight: bold;
    color: #0f172a;
    line-height: 1.5;
    margin: 0 0 15px 0;
}

.print-featured-image {
    text-align: center;
    margin: 20px 0;
}

.print-featured-image img {
    max-width: 100%;
    height: auto;
    max-height: 420px;
    border-radius: 6px;
    object-fit: cover;
}

.print-lead {
    background: #f1f5f9;
    border-right: 4px solid #004adf;
    padding: 12px 18px;
    margin: 15px 0 20px 0;
    border-radius: 0 6px 6px 0;
    font-size: 14px;
    color: #334155;
    line-height: 1.9;
}

.print-lead p {
    margin: 0;
    font-weight: 600;
}

.print-content-body {
    font-size: 15px;
    line-height: 2;
    color: #1e293b;
    text-align: justify;
}

.print-content-body p {
    margin-bottom: 16px;
}

.print-content-body img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
    margin: 15px auto;
    border-radius: 4px;
}

.print-credits {
    margin-top: 25px;
    padding: 12px;
    background: #f8fafc;
    border-radius: 6px;
    border-right: 3px solid #64748b;
    font-size: 13px;
    color: #475569;
}

.print-credits div {
    margin-bottom: 4px;
}

.print-shortlink {
    margin-top: 15px;
    font-size: 12px;
    color: #64748b;
    direction: ltr;
    text-align: left;
    word-break: break-all;
}

.print-footer {
    margin-top: 30px;
    padding-top: 15px;
    border-top: 1px dashed #cbd5e1;
    text-align: center;
    font-size: 12px;
    color: #64748b;
}

/* مخفی‌سازی عناصر ناخواسته وردپرس */
.post-views,
.share-buttons,
.comments-area,
.advertisement,
.ads {
    display: none !important;
}

/* ========================================================
   استایل‌های اختصاصی هنگام چاپ کاغذی یا PDF (Print Preview)
   ======================================================== */
@media print {
    @page {
        size: A4;
        margin: 1.2cm 1cm;
    }

    body {
        background: #ffffff !important;
        color: #000000 !important;
        font-size: 11pt !important;
        line-height: 1.7 !important;
        padding: 0 !important;
    }

    .print-container {
        max-width: 100% !important;
        width: 100% !important;
        padding: 0 !important;
        box-shadow: none !important;
        border: none !important;
        border-radius: 0 !important;
    }

    .no-print {
        display: none !important;
    }

    .print-only {
        display: flex !important;
        justify-content: space-between;
        background: #f4f4f5 !important;
        padding: 6px 10px !important;
        border-radius: 4px;
        margin-bottom: 15px !important;
        font-size: 9.5pt !important;
        color: #333333 !important;
    }

    .print-header {
        border-bottom: 2px solid #000000 !important;
        padding-bottom: 10px !important;
        margin-bottom: 10px !important;
    }

    .print-title {
        font-size: 16pt !important;
        color: #000000 !important;
        margin-bottom: 10pt !important;
    }

    .print-rutitr {
        color: #333333 !important;
        font-size: 11pt !important;
    }

    .print-lead {
        background: #f9f9f9 !important;
        border-right: 3px solid #333333 !important;
        font-size: 10.5pt !important;
        color: #111111 !important;
        padding: 8px 12px !important;
    }

    .print-content-body {
        font-size: 11pt !important;
        line-height: 1.8 !important;
        color: #000000 !important;
    }

    .print-featured-image img {
        max-height: 280px !important;
    }

    .print-footer {
        border-top: 1px solid #999999 !important;
        color: #333333 !important;
        font-size: 9pt !important;
        margin-top: 20px !important;
    }

    .print-shortlink {
        font-size: 8.5pt !important;
        color: #444444 !important;
    }

    /* جلوگیری از شکستگی نامناسب عناصر بین صفحات */
    .print-header,
    .print-title,
    .print-featured-image,
    .print-lead,
    .print-credits {
        page-break-inside: avoid;
        break-inside: avoid;
    }

    img {
        page-break-inside: avoid;
        break-inside: avoid;
    }
}
