﻿@font-face {
    font-family: Vejin;
    src: url('fonts/vejin-WOL.woff2') format('woff2');
    font-weight: normal;
}

@font-face {
    font-family: Vazir;
    src: url('fonts/Vazir-WOL.woff2') format('woff2');
    font-weight: normal;
}

@font-face {
    font-family: Sahel;
    src: url('fonts/Sahel-WOL.woff2') format('woff2');
    font-weight: normal;
}

@font-face {
    font-family: Sahel;
    src: url('fonts/Sahel-SemiBold-WOL.woff2') format('woff2');
    font-weight: 700;
}

@font-face {
    font-family: Sahel;
    src: url('fonts/Sahel-Light-WOL.woff2') format('woff2');
    font-weight: 300;
}

:root {
    --maxWidth: 700px;
    --cSite: #6435c9;
    --cSiteLite: #a286df;
    --cLink: #4183c4;
    --cW1: #fafafa;
    --cSuccess: #2c662d;
    --cSuccessBG: #fcfff5;
    --cSuccessBR: #a3c293;
    --cNegative: #9f3a38;
    --cNegativeBG: #fff6f6;
    --cNegativeBR: #e0b4b4;
    --cInfo: #276f86;
    --cInfoBG: #f8ffff;
    --cInfoBR: #a9d5de;
    --cWarning: #ccb200;
    --cWarningBG: #fffaf3;
    --cWarningBR: #c9ba9b;
}

html {
    scroll-behavior: smooth;
}

body,
button,
input,
optgroup,
select,
textarea {
    font-family: sahel, 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    font-size: 16px;
}

a {
    text-decoration: none;
    color: var(--cLink);
}

h1 {
    text-align: center;
    font-size: 24px;
    margin: 10px 0 5px;
}

h2 {
    margin: 15px 0 0;
}

h3 {
    margin: 15px 0 0;
}

h2.header {
    text-align: center;
    margin-top: 20px;
    margin-bottom: 5px;
}

ol {
    margin-block-start: 1px;
    margin-block-end: 1px;
}

ul {
    margin-block-start: 1px;
    margin-block-end: 1px;
}

pre {
    padding: 5px;
    white-space: pre-wrap;
    background-color: #f5f5f5;
    margin: 0;
}

button:focus {
    outline: none;
}

body {
    display: grid;
    height: 100vh;
    grid-template-areas: "header" "content" "footer";
    grid-template-rows: 45px auto auto;
}

header {
    grid-area: header;
    background-color: var(--cSite);
}

.homepageNews {
    text-align: center;
    list-style-type: none;
    line-height: 2.5;
}

.logo {
    padding: 10px 20px;
}

    .logo a {
        color: #fff;
        font-size: 20px;
    }

.navbar-contents {
    max-width: var(--maxWidth);
    display: grid;
    grid-template-columns: auto 1fr;
    margin: auto;
    align-items: center;
}

.navLinks {
    justify-self: end;
}

    .navLinks a {
        padding: 10px 20px;
        color: #fff;
    }

main {
    grid-area: content;
    width: 100%;
    max-width: var(--maxWidth);
    justify-self: center;
}

footer {
    grid-area: footer;
    color: #ccc;
    background-color: #777;
    direction: ltr;
    text-align: center;
    margin-top: 30px;
    padding-top: 10px;
}

    footer a {
        color: #fff;
    }

.footer-link {
    margin: 10px 0;
}

    .footer-link > a {
        padding: 5px 8px;
    }

        .footer-link > a:hover {
            color: var(--cSite);
        }

.donate {
    padding: 10px 0;
}

.socialmedia {
    padding: 5px;
}

    .socialmedia > a, .share-buttons > a {
        padding: 5px;
        font-size: 24px;
        margin: 10px;
    }

.homepage {
    text-align: center;
    padding: 10px;
}

    .homepage h1 {
        font-size: 48px;
        margin-bottom: 10px;
    }

    .homepage h2 {
        font-size: 20px;
        color: #777;
        margin-top: 0;
        margin-bottom: 20px;
    }


.image-fluid {
    width: 100%;
    height: auto;
}
/*logs*/
.logs {
    font-size: 14px;
}

ul.logs {
    padding-inline-start: 10px;
}

.log {
    padding: 5px 0;
}

    .log > span {
        color: #777;
        font-size: 12px;
    }

    .log:hover {
        background-color: #eee;
    }
/*news*/
.news-content {
    padding: 10px;
}

    .news-content > p, .news-content > ul {
        text-align: justify;
    }

.news-cards {
    display: flex;
    flex-direction: column;
}

.news-card {
    display: grid;
    min-height: 100px;
    grid-template-columns: auto 1fr;
    margin: 5px;
    padding: 5px;
    border: 1px solid #eee;
    border-radius: 5px;
}

.card-image {
    align-self: center;
}

    .card-image img {
        border-radius: 5px;
        margin-inline-end: 10px;
        border: 1px solid var(--cW2);
        vertical-align: bottom;
        width: 100px;
    }

.card-desc {
    color: #777;
}

.card-meta {
    color: #ccc;
}

.prev-next {
    display: flex;
    justify-content: space-between;
    margin: 10px 5px;
}

/*dropdown*/
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdownb {
    cursor: pointer;
    padding: 0 5px;
    user-select: none;
}

.dropdown.popup > .dropdownb {
    color: var(--cInfo);
    border: 1px solid var(--cInfoBR);
    background-color: var(--cInfoBG);
    margin: 0 5px;
    border-radius: 5px;
}

    .dropdown.popup > .dropdownb::after {
        content: " ?"
    }

.navLinks > .dropdown > .dropdownb {
    color: #fff;
    padding: 7px 10px;
}

.dropdownm {
    opacity: 0;
    visibility: hidden;
    position: absolute;
    z-index: 999;
    background-color: #fff;
    border-radius: 5px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    text-align: start;
    white-space: nowrap;
    user-select: none;
    transition-delay: .3s;
}

    .dropdownm.rtl {
        right: auto;
        left: 0;
    }

    .dropdownm.ltr {
        right: 0;
        left: auto;
    }

.dropdown:hover .dropdownm {
    visibility: visible;
    opacity: 1;
}

.dropdownm a {
    color: #777;
    display: block;
    cursor: pointer;
    background-color: #fff;
    padding: 5px 15px;
    text-decoration: none;
    transition: all 0.2s ease;
    user-select: none;
}

.dropdownm div {
    padding: 5px 15px;
}

.dropdownm a:hover {
    background-color: #eee;
}

/* fields */
.fields {
    padding: 5px;
}

    .fields > .field {
        margin: 2px;
        display: flex;
        align-items: center;
    }

    .fields > .field-block {
        margin: 5px;
    }

.field-block textarea, .field-block input, .field-block label {
    width: 100%;
    display: block;
}

.field input[type="text"] {
    width: 100%;
    box-sizing: border-box;
}

.fields > .field > label {
    padding: 0 5px;
}

.fields-inline {
    display: flex;
    flex-wrap: wrap;
    justify-content: center
}

    .fields-inline > .field {
        display: flex;
        align-items: center;
        margin: 2px;
    }

        .fields-inline > .field > label {
            min-width: 70px;
            text-align: end;
            padding: 0 5px;
        }

.required:after {
    content: " *";
    color: red;
}

select, input, textarea {
    border: 1px solid #ccc;
    border-radius: 5px;
    line-height: 2;
    padding: 0 5px;
    outline: none;
    unicode-bidi: plaintext;
}

select {
    width: 100%
}

    select:focus, input:focus, textarea:focus {
        border: 1px solid var(--cLink);
    }

textarea {
    width: 100%;
    box-sizing: border-box;
}

select, input[type="text"], input[type="password"] {
    flex: 1;
    box-sizing: border-box;
}

button {
    background-color: var(--cSite);
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    border: none;
    cursor: pointer;
}
/* index */
.container {
    padding: 5px 10px;
}

.index-section {
    text-align: center;
    padding: 5px 10px;
}

    .index-section > h1 {
        font-size: 40px;
    }

    .index-section > h2 {
        font-size: 24px;
        text-align: center;
    }

ul.latestNews {
    text-align: center;
    list-style-type: none;
    line-height: 2;
    padding: 0;
}

.dictsList {
    display: flex;
    flex-wrap: wrap;
}

.card {
    display: flex;
    flex: 1 1 33%;
    min-width: 200px;
    padding: 2px 0;
    clear: both;
    position: relative;
    margin: 0 10px;
}

    .card:hover {
        background-color: #fafafa;
    }

    .card > .image {
    }

        .card > .image > img {
            max-width: 80px;
            margin-inline-end: 1em;
            margin-top: 0.25em;
            box-shadow: 3px 3px 10px 0 rgb(0 0 0 / 38%);
            border-radius: 3%;
        }

    .card > .content > .title {
        font-size: 18px;
        padding-top: 10px;
    }

    .card > .content > .details {
        font-size: 14px;
        color: #777;
    }

/* virtual keyboard */
div.keyboard {
    width: 100%;
    text-align: center;
    direction: ltr;
    margin: 0 auto 20px;
}

.keyGroup {
    display: inline-block;
    padding: 5px;
}

.key {
    user-select: none;
    display: inline-block;
    background-color: #f4f4f4;
    border-color: #e2e2e2;
    border-radius: 2px;
    min-width: 21px;
    margin: 1px;
    height: 24px;
    padding: 3px;
    cursor: pointer;
}

    .key:hover {
        box-shadow: 0 0 2px #888;
    }

    .key.func {
        background-color: #ddd;
        cursor: default;
    }
/*breadcrumb*/
.breadcrumb {
    font-size: 12px;
    margin: 20px 5px;
}

    .breadcrumb span {
        padding: 3px;
    }
/*imageCard*/
.imageCards {
    display: flex;
    flex-wrap: wrap;
    justify-content: center
}

.imageCard {
    display: grid;
    grid-template-rows: auto 1fr;
    margin: 5px;
    border: 1px solid #ccc;
    border-radius: 5px;
    width: 110px;
    text-align: center;
    box-shadow: 1px 1px 8px 1px #eee;
    overflow: hidden;
}

    .imageCard:hover {
        box-shadow: 1px 1px 8px 1px #ccc;
    }

    .imageCard img {
        vertical-align: bottom;
        max-height: 130px;
        display: block;
        margin: 0 auto;
        width: 100%;
    }

i.thumb {
    width: 100px;
    font-size: 40px;
    text-align: center;
    color: var(--cSite);
}

.imageCard .meta {
    font-size: 12px;
    color: #777;
}

.imageCard .content {
    padding: 3px;
}
/*messages*/
.messages {
    display: flex;
    flex-direction: column;
    grid-gap: 10px;
    padding: 5px;
}

.message {
    border: 1px solid var(--cW2);
    border-radius: 5px;
    padding: 5px;
}

    .message > .info {
        display: grid;
        grid-template-columns: 80px 1fr;
        margin-bottom: 10px;
        line-height: 1.4;
    }

        .message > .info > .answer {
            background-color: var(--cSiteLite);
            padding: 5px;
        }
/*Pages*/
.page-desc {
    text-align: center;
}

    .page-desc > span {
        color: var(--cW4);
        margin: 0 5px;
        padding: 5px;
    }

.page-body {
    padding: 10px;
    border-bottom: 1px solid var(--cW3);
}

    .page-body img {
        display: block;
        margin: 10px auto;
        border: 1px solid var(--cW3);
        border-radius: 5px;
        max-width: 90%;
    }

.pages-list {
    border-radius: 5px;
    max-width: 300px;
    margin: 20px auto;
    text-align: center;
}

    .pages-list .header {
        font-weight: 700;
    }

    .pages-list > ul {
        padding: 0;
    }



/* infobox */
.infobox {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 5px;
    margin: 10px;
}

.infobox-image img {
    border-radius: 5px;
    margin-inline-end: 15px;
    border: 1px solid #eee;
    width: 150px;
}

.infobox-contenet {
    padding: 5px;
}

    .infobox-contenet h1 {
        margin: 10px 0;
    }

.info {
    margin: 3px 0;
    display: flex;
    flex-wrap: wrap;
}

    .info .title {
        font-weight: bold;
        display: inline-block;
        padding-inline-end: 5px;
    }

    .info .data {
        display: inline-block;
    }

.section {
    padding: 5px;
    margin: 10px;
    border: 1px solid #eee;
    border-radius: 5px;
}

    .section h2 {
        margin: 0;
        font-size: 18px;
    }

.toc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0 5px;
}

.toc {
    display: grid;
    grid-gap: 2px;
    padding: 2px 0;
}

    .toc a {
        color: var(--cLink);
    }

h3.toc-title {
    padding: 5px 10px;
    font-size: 16px;
    margin: 0;
    font-weight: 700;
}
/* texts */
.text-container {
    margin: 0 10px;
}

.header-info {
    display: flex;
    justify-content: center;
    font-size: 15px;
}

.header-info-title {
    color: #777;
    padding-inline-end: 5px;
}

.header-info-data > span {
    font-size: 13px;
}

.time-views {
    margin-top: 5px;
    font-size: 12px;
    color: #777;
    user-select: none;
    text-align: center;
}

    .time-views > span {
        margin: 0 10px;
        white-space: nowrap;
    }

.text-header {
    margin: 10px;
    text-align: center;
}

    .text-header > .title {
        margin-bottom: 0;
    }

    .text-header > .subtitle {
        font-size: 18px;
    }

.header-menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

    .header-menu > .menu-item {
        color: #777;
        padding: 5px;
        margin: 5px 10px;
    }

.menu-item.buttons {
    font-size: 18px;
    border: 1px solid var(--cSite);
    border-radius: 5px;
}

    .menu-item.buttons > a {
        color: var(--cSite);
    }

.textcontent {
    margin: auto;
    padding: 10px;
    text-align: justify;
    line-height: 2;
}

.text-nav {
    margin-top: 10px;
    text-align: center;
}

    .text-nav > .next {
        text-align: end;
        padding: 10px 5px;
    }

    .text-nav > .prev {
        text-align: start;
        padding: 10px 5px;
    }

.gotoTop {
    cursor: pointer;
    padding: 10px 20px;
}
/*popdown*/
.popdown {
    position: relative;
    display: inline-block;
}

.popdownb {
    cursor: pointer;
    padding: 0 5px;
}

.popdownm {
    display: none;
    position: absolute;
    z-index: 999;
    width: 200px;
    background-color: #fafafa;
    border-radius: 5px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    text-align: center;
    user-select: none;
    padding: 10px 15px;
}

    .popdownm.rtl {
        left: -100px;
    }

    .popdownm.ltr {
        right: -100px;
    }

.popdown:hover .popdownm {
    display: block;
}
/*Search Page*/
.form {
    padding: 5px 10px;
}

.search-input {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: center;
    position: relative;
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 5px;
    margin-top: 5px;
}

    .search-input > button {
        padding: 0 20px;
        background-color: #fff;
        color: #333;
    }

    .search-input > .toggleKeyboard {
        cursor: pointer;
        padding: 1px;
    }

.toggleKeyboard > i {
    font-size: 20px;
}

input.search {
    font-size: 18px;
    border-radius: 5px;
    background-color: #fff;
    border: none;
    margin: 0;
    padding: 5px;
    word-wrap: break-word;
    outline: none;
}

ul#autocomplete {
    grid-column: 1;
    min-width: 100px;
    position: absolute;
    top: 100%;
    z-index: 3;
    background-color: #fff;
    box-shadow: 0 0 40px rgb(0 0 0 / 10%);
    padding-inline-start: 0;
}

    ul#autocomplete li {
        list-style: none;
        cursor: pointer;
        display: block;
        overflow: hidden;
        padding: 5px;
        color: rgba(0,0,0,.87);
        line-height: 1.33;
    }

        ul#autocomplete li:hover {
            background-color: #eee;
        }

    ul#autocomplete a {
        padding: 4px;
        font-size: 14px;
        display: block;
    }

.searchSettings {
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 10px;
    margin: 10px 0;
    max-height: 300px;
    overflow: auto;
}

.options {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.option {
    display: flex;
    flex-wrap: wrap;
}

    .option > div {
        padding-inline-end: 15px;
    }

.openNewTab {
    white-space: nowrap;
}

.checkboxGroup {
    padding: 5px 0;
}

.checkboxItem {
    font-size: 14px;
}

.fromDict {
    display: inline-block;
    font-size: 12px;
    padding: 0 5px;
    margin: 0 5px;
    color: #666;
    background-color: #eee;
    border-radius: 3px;
}

.dictTag {
    display: inline-block;
    font-size: 11px;
    padding: 0 4px;
    margin: 0 4px;
    border-radius: 2px;
}

    .dictTag.from {
        background-color: #e8e8e8;
    }

    .dictTag.to {
        background-color: #e8e8e8;
    }

.suggestions {
}

.suggestion {
    display: inline-block;
    background-color: #fff;
    border: 1px solid #dadce0;
    cursor: pointer;
    border-radius: 32px;
    white-space: nowrap;
    margin: 5px;
    padding: 0 12px;
}

.noResults {
    line-height: 1;
    color: var(--cNegative);
    border: 1px solid var(--cNegativeBR);
    background-color: var(--cNegativeBG);
    padding: 5px 10px;
    text-align: center;
    font-size: 14px;
    border-radius: 5px;
}

.haveResults {
    line-height: 1;
    color: var(--cSuccess);
    border: 1px solid var(--cSuccessBR);
    background-color: var(--cSuccessBG);
    padding: 5px 10px;
    text-align: center;
    font-size: 14px;
    line-height: 1.5;
    border-radius: 5px;
}

.results {
    display: flex;
    flex-direction: column;
    padding: 0 10px;
}

    .results > .result {
        padding-bottom: 15px;
        padding-top: 5px;
        border-bottom: 1px solid #eee;
    }

sup.senseNo {
    color: #444;
}

.resultHead {
    font-size: 20px;
    font-weight: bold;
    color: #000;
}

/* defDictCard */
.defIntro {
    padding: 5px;
    border-bottom:1px solid #eee;
}

.defLinks {
    display: flex;
    justify-content: space-between;
    padding: 30px 20px 0;
    border-radius: 5px;
}

.defDictCard {
    display: flex;
    align-items: center;
    padding: 10px;
    margin: 10px;
    font-size: 14px;
    border-radius: 5px;
    border: 1px solid #eee;
}

    .defDictCard .cover {
        align-self: center;
    }

        .defDictCard .cover img {
            border-radius: 5px;
            margin-inline-end: 15px;
            border: 1px solid #eee;
            width: 80px;
            vertical-align: bottom;
        }

    .defDictCard .contenet {
        padding: 5px;
    }

.defDictCard-contenet > .title {
    font-weight: bold;
    font-size: 16px;
}

/* ==definitions== */
.rtl {
    direction: rtl;
}

    .rtl ol {
        list-style: arabic-indic;
    }

.ltr {
    direction: ltr;
}

.wah {
    font-style: italic;
    color: #888;
}

.wah-en {
    font-style: normal;
    color: #000;
}

.wah-ku {
    font-weight: 500;
    font-style: normal;
    color: #0ab;
}

a.wah-ku {
    font-weight: bold;
    font-style: normal;
    color: var(--cLink);
}

.wah-se {
    padding-inline-start: 10px;
    padding-block-start: 10px;
}

.wah-ex {
    padding-inline-start: 20px;
}

.wah-st {
    font-weight: bold;
    color: #09b;
}

.wah-as {
    cursor: help;
    color: red;
    position: relative;
    display: inline-block;
    border-bottom: 1px dotted black;
}

span.hover {
    position: absolute;
    z-index: 1;
    bottom: 100%;
    left: 50%;
    margin-left: -80px;
    width: 160px;
    font-size: 14px;
    background-color: var(--cInfoBG);
    border: 1px solid var(--cInfoBR);
    color: var(--cInfo);
    text-align: center;
    border-radius: 5px;
    padding: 5px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
}

.example {
    color: #70757a;
    margin-bottom: 5px;
    font-size: 14px;
    font-style: normal;
}

.redirect {
    background-color: #fff;
    border: 1px solid #dadce0;
    cursor: pointer;
    border-radius: 32px;
    white-space: nowrap;
    margin-top: 6px;
    padding: 0 12px;
}

.compound {
    margin-right: 15px;
}

.senses {
}

    .senses.rtl {
        margin-right: 15px;
    }

    .senses.ltr {
        margin-left: 15px;
    }

.sense {
    margin-bottom: 4px;
    padding: 1px;
}

.sensenum {
    font-weight: bold;
    display: table-cell;
}

.sensedef {
    padding: 0 10px;
    display: table-cell;
}

.langTitle {
    color: #2185d0;
    padding-right: 15px;
    font-weight: bold;
}

.twocol {
    display: grid;
}

.defcol {
    padding: 0 5px;
}

@media screen and (min-width: 550px) {
    .twocol {
        grid-template-columns: 0.5fr 0.5fr;
    }
}

.pr {
    font-family: 'Times New Roman', 'times', Tahoma, Geneva, Verdana, sans-serif;
    word-break: keep-all;
    color: #70757a;
}

.synonymes {
    color: #555;
    margin-bottom: 10px;
    font-style: italic;
}

.verbforms {
    font-weight: 500;
    font-style: italic;
    color: #16e;
}
/* ==== tags ==== */
.tag {
    font-size: 11px;
    display: inline-block;
    padding: 0 6px;
    border-radius: 2px;
    line-height: 18px;
    font-style: normal;
}

    .tag.etymology {
        background-color: #679d46;
        color: #fff;
    }

    .tag.pos {
        background-color: #8464a8;
        color: #fff;
    }

    .tag.field {
        background-color: #f18500;
        color: #fff;
    }

    .tag.stress {
        background-color: #d53838;
        color: #fff;
    }

    .tag.note {
        background-color: #f18500;
        color: #fff;
    }

/*alerts*/
.alert {
    padding: 5px;
    margin: 5px;
    border-radius: 5px;
    text-align: center;
}

    .alert > .header {
        font-weight: 700;
    }

    .alert.success {
        color: var(--cSuccess);
        border: 1px solid var(--cSuccessBR);
        background-color: var(--cSuccessBG);
    }

    .alert.negative {
        color: var(--cNegative);
        border: 1px solid var(--cNegativeBR);
        background-color: var(--cNegativeBG);
    }

    .alert.info {
        color: var(--cInfo);
        border: 1px solid var(--cInfoBR);
        background-color: var(--cInfoBG);
    }

    .alert.warning {
        color: var(--cWarning);
        border: 1px solid var(--cWarningBR);
        background-color: var(--cWarningBG);
    }
