@font-face {
    font-family: 'maghribi';
    src: url('/fonts/samir-khouaja-maghribi-bold.ttf') format('truetype');
}

/* arabic */
@font-face {
    font-family: 'classic';
    font-style: normal;
    font-weight: 400;
    src: url('/fonts/noto-google-arabic.woff2') format('woff2');
    unicode-range: U+0600-06FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE80-FEFC;
}

/* latin-ext */
@font-face {
    font-family: 'classic';
    font-style: normal;
    font-weight: 400;
    src: url('/fonts/noto-google-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* latin */
@font-face {
    font-family: 'classic';
    font-style: normal;
    font-weight: 400;
    src: url('/fonts/noto-google-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
    --light-color: rgb(253, 240, 240);
    --dark-color: rgb(189, 126, 150);
}

* {
    text-align: right;
    direction: rtl;
    margin: 0 0 0 0;
    caret-color: transparent;
    scroll-margin-top: 80px;
}

body {
    padding-top: 80px;
    background-image: url('/images/zellige_pattern.png');
    background-attachment: fixed;
    overflow: scroll;
    background-color: white;
}

/* chrome and opera */
body::-webkit-scrollbar {
    display: fixed;
}

.header {
    height: 80px;
    width: 100%;
    position: fixed;
    top: 0;
    background: url('/images/zellige_pattern.png'),
        linear-gradient(to left, var(--light-color), var(--dark-color) 150%);
    font-size: 16px;
    text-decoration: none;
    color: black;
    z-index: 100;
}

.header * {
    font-family: 'maghribi';
    font-weight: normal;
    position: fixed;
    top: 0;
    left: 0;
}

.header .title {
    top: 5px;
    right: 0;
    padding-right: 10px;
    font-size: 26px;
    text-shadow: 2px 2px 5px #505050;
    white-space: nowrap;
}

#subtitle,
#subtitle * {
    top: 52px;
    right: 0;
    padding-right: 10px;
}

.header .counter {
    top: 40px;
    padding-left: 10px;
}

.header .counter * {
    position: relative;
    display: inline-block;
}

.footer_open,
.footer_close {
    height: 20px;
    width: 100%;
    background: url('/images/zellige_pattern.png'),
        linear-gradient(to left, var(--light-color), var(--dark-color) 120%);
    background-position-y: 10px;
}

.footer_open {
    position: sticky;
    bottom: 45px;
}
.footer_links {
    display: flex;
    position: sticky;
    bottom: 0;
    margin: -2px 0;
}

.link_footer {
    color: black;
    background-color: white;
    border-left: 1px solid rgb(220, 220, 220);
    height: 35px;
    padding: 5px 0;
    width: 20%;
    text-align: center;
}

.link_footer:hover {
    background-color: var(--light-color);
}

.link_footer:visited {
    color: inherit;
}

#princ {
    font-family: "maghribi";
    font-weight: bold;
    font-size: 24px;    
    width: 100%;
}

#back {
    display: none;
}

@media screen and (max-height: 30em) and (orientation:landscape) {
    * {
        scroll-margin-top: 50px;
    }

    body {
        padding-top: 50px;
    }

    .header {
        height: 50px;
    }

    .header .counter {
        top: 10px
    }

    #subtitle {
        display: none
    }

    .footer_open,
    .footer_links {
        position: static;
    }
}

.item {
    background-color: white;
    margin: -1px 0;
    display: block;
    padding: 5px 15px 5px 80px;
    border: none;

    font-family: 'classic';
    font-weight: normal;
    font-size: 23px;
    text-decoration: none;
    color: black;
}

.item_b {
    padding: 5px 40px 5px 80px;
    font-size: 21px;
}

.item:hover {
    background: var(--light-color);
}

.item_diff {
    background: linear-gradient(to right, var(--light-color), white 110%);
}

.item_selected {
    background: var(--light-color);
    text-shadow: 1px 1px 1px #505050;
}

.has_record {
    width: 24px;
    height: 24px;
    margin: 15px 0 0 40px;
    position: absolute;
    left: 0;
}

.cnt_record {
    margin: 22px 0 0 63px;
    position: absolute;
    left: 0;
    font-size: 12px;
    color: #969696;
}

.or {
    display: flex;
    align-items: center;
    height: 0;
    padding-right: 10px;
}

.or::after {
    content: '';
    border-bottom: 1px dashed rgb(220, 220, 220);
    margin: 0 5px 0 0;
}

.or::after {
    flex-grow: 5;
}

.nb {
    display: flex;
    height: 0;
    padding-left: 10px;
    color: rgb(150, 150, 150);
}

.nb::before {
    content: '';
    border-bottom: 1px solid rgb(220, 220, 220);
    margin: 0 0 0 5px;
}

.nb::before {
    flex-grow: 5;
}

hr {
    border: 1px solid rgb(220, 220, 220);
    opacity: 1;
}

#endpage {
    height: 5vh;
    position: static;
}

#message {
    background-color: white;
    border: none;

    position: fixed;
    bottom: 0;
    display: none;
    width: 100%;
    height: 65px;
    text-align: center;

    z-index: 100;
}

#message img {
    margin-bottom: -5px;
    padding-left: 10px;
}

#message span {
    font-family: 'classic';
    font-weight: normal;
    font-size: 20px;
    color: crimson;
}

