/* ========================================
   Fonts
======================================== */


@font-face {
    font-family: "Vazir";
    src: url("../fonts/woff2/Vazir.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Vazir";
    src: url("../fonts/woff2/Vazir-Bold.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}


@font-face {
    font-family: "IRANSansX";
    src: url("../fonts/woff2/IRANSansX-Regular.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}


@font-face {
    font-family: "Amiri";
    src: url("../fonts/ttf/AmiriQuran-Regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "NotoNaskhArabic";
    src: url("../fonts/ttf/NotoNaskhArabic-Regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "NotoNaskhArabic";
    src: url("../fonts/ttf/NotoNaskhArabic-Bold.ttf") format("truetype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Yekan";
    src: url("../fonts/yekan.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}


/* ========================================
   General
======================================== */

html {
    scroll-behavior: smooth;
}

body {
    font-family: "IRANSansX", sans-serif;
    min-height: 100vh;
    margin: 0;
}


/* ========================================
   Header
======================================== */

.nahj-header {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 1030;

    background: var(--bs-body-bg);
    border-bottom: 1px solid var(--bs-border-color);
}


/* ========================================
   Main
======================================== */

.nahj-main {
    padding-top: 270px;
    padding-bottom: 115px;
}


/* ========================================
   Loading
======================================== */

#loading {
    min-height: 300px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}


/* ========================================
   Item heading
======================================== */

#itemTitle {
    line-height: 1.8;
}

.nahj-when-to {
    color: var(--bs-secondary-color);
    line-height: 2;
    font-size: 0.95rem;
}


/* ========================================
   Concepts / Tags
======================================== */

.nahj-concepts {
    line-height: 1;
}

.nahj-concepts .concept-tag {
    display: inline-flex;
    align-items: center;

    padding: 0.35rem 0.7rem;

    border: 1px solid var(--bs-border-color);
    border-radius: 999px;

    color: var(--bs-secondary-color);
    background: var(--bs-tertiary-bg);

    font-size: 0.85rem;
}


/* ========================================
   Text sections
======================================== */

.nahj-section {
    margin-bottom: 2rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;

    margin-bottom: 1rem;

    padding-bottom: 0.5rem;

    border-bottom: 1px solid var(--bs-border-color);

    color: var(--bs-secondary-color);

    font-size: 0.95rem;
    font-weight: 600;
}


/* ========================================
   Arabic
======================================== */

.arabic-text {
    direction: rtl;
    text-align: right;

    font-family: "Amiri", "NotoNaskhArabic", Tahoma, serif;
    font-size: 32px;
    line-height: 2.25;

    white-space: pre-wrap;

    overflow-wrap: anywhere;
}


/* ========================================
   Persian translation
======================================== */

.persian-text {
    direction: rtl;
    text-align: right;

    font-family: "IRANSansX", "Vazir", "Yekan", Tahoma, sans-serif;
    font-size: 18px;
    line-height: 2.1;

    white-space: pre-wrap;

    overflow-wrap: anywhere;
}


/* ========================================
   Bottom navigation
======================================== */

.nahj-navigation {
    position: fixed;

    right: 0;
    bottom: 0;
    left: 0;

    z-index: 1030;

    background: var(--bs-body-bg);
    border-top: 1px solid var(--bs-border-color);

    padding: 0.75rem 1rem;
}


/* ========================================
   Buttons
======================================== */

.category-btn {
    white-space: nowrap;
}

#previousButton,
#nextButton {
    min-height: 42px;
}


/* ========================================
   Responsive
======================================== */

@media (max-width: 767.98px) {

    .nahj-main {
        padding-top: 285px;
        padding-bottom: 105px;
    }

    .arabic-text {
        font-size: 28px;
        line-height: 2.2;
    }

    .persian-text {
        font-size: 17px;
        line-height: 2;
    }

    .nahj-navigation {
        padding: 0.6rem 0.75rem;
    }

    #previousButton,
    #nextButton {
        font-size: 0.9rem;
    }

}


@media (min-width: 768px) {

    .nahj-main {
        padding-top: 270px;
        padding-bottom: 115px;
    }

}