/* 🎨 Root Variables */
:root {
    --background-color: #DBE2EF;
    --main: #F9F7F7;
    --border-color: #b2bac9;
    --primary: #00ADB5;
    --primary-light: #71C9CE;
    --muted: #788189;
    --shadow: 0 0 11px 0 #aaaaaa;
    --shadow-video: 0 0 11px 6px #aaaaaa;
    --text-color: #000000;
    --color: #ffffff;
}

.darkmode {
    --background-color: #18191b;
    --main: #1f1f1f;
    --border-color: #44474d;
    --primary: #00ADB5;
    --primary-light: #71C9CE;
    --muted: #5d646a;
    --shadow: 0 0 11px 0 #101010;
    --shadow-video: 0 0 11px 6px #101010;
    --text-color: #e8e8e8;
    --color: #ffffff;
}

/* فونت‌ها */
@font-face {
    font-family: Estedad;
    src: url(../fonts/Estedad.woff2);
}

@font-face {
    font-family: Mikhak;
    src: url(../fonts/Mikhak.woff2);
}

/* انیمیشن‌ها */
@keyframes logo {
    from {
        transform: translate(300px);
        opacity: 0;
    }

    to {
        transform: translate(0);
        opacity: 1;
    }
}

@keyframes main-menu {
    0% {
        opacity: 0;
        transform: translate(300px);
    }

    100% {
        opacity: 1;
        transform: translate(0);
    }
}

@keyframes nav {
    0% {
        transform: translateY(60px);
        opacity: 0;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes fade {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }

    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes hover {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.07);
    }
}

/* ریست و تنظیمات پایه */
* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: Estedad, tahoma;
    background: var(--background-color);
    margin: 0;
    padding: 0;
    color: var(--text-color);
}


#logo {
    height: 50px;
    width: auto;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    position: fixed;
    top: 15px;
    right: 70px;
    z-index: 110;
}

/* تیتر */
h1 {
    font-family: Mikhak, tahoma;
    color: var(--color);
    border: 2px solid var(--primary);
    border-radius: 10px;
    background-color: var(--primary);
    text-align: center;
    padding: 10px 0;
    width: 90%;
    margin: 35px auto;
}

.headline-2 {
    font-family: Mikhak, tahoma;
    color: var(--color);
    border: 2px solid var(--primary);
    border-radius: 10px;
    background-color: var(--primary);
    text-align: center;
    padding: 10px 0;
    width: 70%;
    margin: 10px auto;
}

figure{
    text-align: center;
}

abbr {
    text-decoration: none;
}

p {
    color: var(--text-color);
}

/* لینک‌ها */
a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    color: var(--muted);
    font-weight: 500;
}

/* گالری */
#gallery {
    width: 90%;
    height: 670px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    margin: 30px auto;
    display: block;
}

#images {
    text-align: center;
}

#images img {
    width: 180px;
    aspect-ratio: 1;
    object-fit: cover;
    transition: 0.3s;
}

#images img:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow);
}

.col-md-4 img {
    display: block;
    width: 100%;
    aspect-ratio: 9/16;
    object-fit: cover;
}

/* Details */
details {
    display: block;
    width: 80%;
    min-width: 80%;
    border-radius: 10px;
    margin: 15px auto;
    background-color: var(--primary);
    color: var(--color);
}

details a {
    color: var(--color);
}

details summary {
    cursor: pointer;
    user-select: none;
    font-weight: 500;
    border-radius: 10px;
    padding: 14px 16px;
    width: 100%;
}

details ol {
    width: 100%;
    padding-left: 20px;
}

details summary:hover {
    background-color: var(--primary-light);
    font-weight: 700;
}

details ol {
    list-style-type: disc;
}

/* ویدیو */
.video {
    width: 90%;
    max-width: 700px;
    aspect-ratio: 16/9;
    border: 2px solid var(--border-color);
    margin: 20px auto;
    display: block;
    border-radius: 10px;
}

/*  تصاویر */
.img {
    display: block;
    margin: 10px auto;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    max-width: 400px;
    width: 80%;
    aspect-ratio: 16/9;
    object-fit: cover;
}

.headline {
    text-align: center;
}

/* دکمه بالا */
#up {
    position: fixed;
    bottom: 30px;
    left: 15px;
    width: 55px;
    height: 55px;
    border: 3px solid var(--main);
    border-radius: 10px;
    background: var(--primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 80;
}

#up::before {
    content: "";
    width: 16px;
    height: 16px;
    border-right: 3px solid var(--color);
    border-top: 3px solid var(--color);
    transform: rotate(-45deg);
    z-index: 80;
}

#up:hover {
    background-color: var(--primary-light);
}

/* دکمه Submit */
.submit {
    width: 200px;
    padding: 10px;
    border-radius: 10px;
    background-color: var(--primary);
    border: 2px solid var(--primary);
    color: var(--color);
    transition: 0.3s;
}

.submit:hover {
    animation: hover 1s forwards;
    background-color: var(--primary-light);
    border: 2px solid var(--primary-light);
}

/* ساختار اصلی */
header,
aside,
article,
footer {
    background-color: var(--main);
    border: 2px solid var(--border-color);
    border-radius: 10px;
}

main {
    display: grid;
    grid-template-columns: auto;
    grid-template-rows: 80px auto 150px;
    gap: 10px;
    grid-template-areas:
        'header'
        'article'
        'footer'
    ;
    width: 100%;
    min-height: 1000px;
    border-radius: 10px;
}

header {
    grid-area: header;
    width: 100%;
    height: 80px;
    position: fixed;
    z-index: 10;
}

article {
    grid-area: article;
    padding: 10px;
    min-height: 100vh;
}

footer {
    min-height: 300px;
    max-height: 700px;
    grid-area: footer;
    direction: ltr;
    text-align: center;
    padding: 10px;
}

/* منو اصلی
#main-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
#main-menu ul li {
    opacity: 0;
    animation: main-menu 2s forwards;
}
#main-menu ul li a {
    padding: 6px 5px;
    margin: 5px 10px;
    display: block;
    background-color: var(--primary);
    color: white;
    border-radius: 20px;
    text-align: center;
    transition: 0.3s;
}
#main-menu ul li a:hover {
    background-color: var(--primary-light);
    padding: 9px 5px;
    box-shadow: var(--shadow);
}

/* Mid Menu 
#mid-menu {
    width: 90%;
    height: 100%;
    display: block;
    padding: 12px 5px;
    margin: 5px 10px;
    background-color: var(--primary-light);
    color: white;
    font-weight: 600;
    border-radius: 20px;
    text-align: center;
    box-shadow: var(--shadow);
}

 Top Menu 
#top-menu {
    color: white;
    background-color: var(--primary-light);
    padding: 10px 5px 7px 5px;
    border-radius: 10px;
    margin-bottom: 5px;
    box-shadow: var(--shadow);
} */

/* Nav */
/* #nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    text-align: center;
    display: none;
}
#nav ul li {
    display: inline-block;
    animation: nav 2s forwards;
}
#nav ul li a {
    padding: 5px;
    border-radius: 10px;
    background-color: var(--primary);
    color: white;
    display: block;
    transition: 0.4s;
    margin-bottom: 7px;

}
#nav ul li a:hover {
    background-color: var(--primary-light);
    padding: 7px 5px;
    margin-bottom: 3px;
    box-shadow: var(--shadow);
} */
/* سایت مپ */
#sitemap ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

#sitemap ul li a,
#sitemap ul ul li a {
    padding: 5px;
    margin: 5px;
    border-radius: 20px;
    display: block;
    background-color: var(--muted);
    color: white;
    width: 150px;
    text-align: center;
}

/* #back{
    display: inline-block;
    margin: 5px 7px 0px 0px;
    color: var(--muted);
    border: var(--muted) 1px solid;
    border-radius: 20px;
    padding: 4px;
} */
/* فرم */
form {
    text-align: center;
}

.form {
    display: block;
    background-color: var(--muted);
    width: 300px;
    color: var(--color);
    border-radius: 20px;
    padding: 15px;
    margin: 5px auto;
}

.off-screen-menu {
    background-color: var(--background-color);
    color: var(--text-color);
    height: 100vh;
    width: 50%;
    padding: 0;
    margin: 0;
    max-width: 300px;
    min-width: 100px;
    position: fixed;
    top: 0;
    right: -450px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* align-items: center;*/
    text-align: center;
    font-size: 17px;
    transition: 0.3s ease;
    border-left: var(--border-color) 2px solid;
    z-index: 109;
}

.off-screen-menu ul {
    padding: 0;
    margin: 0;
}

/* .off-screen-menu ul li {
    border: var(--primary-light)2px solid;
    padding: 8px 5px;
    margin: 5px;
    border-radius: 10px;
    background-color: var(--primary);
    color: white;
    list-style-type: none;
}

.off-screen-menu ul li a {
    text-decoration: none;
    color: white;
} */
/* 
.off-screen-menu ul li :hover {
    transform: scale(1.2);
    transition: 0.3s ease;
} */

.off-screen-menu.active {
    right: 0;
}

.ham-menu {
    height: 50px;
    width: 50px;
    top: 15px;
    right: 15px;
    position: fixed;
    cursor: pointer;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    z-index: 110;
}

.ham-menu span {
    height: 5px;
    width: 80%;
    background-color: var(--primary);
    border-radius: 25px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: 0.3s ease;
}

.ham-menu span:nth-child(1) {
    top: 25%;
}

.ham-menu span:nth-child(3) {
    top: 75%;
}

.ham-menu.active span:nth-child(1) {
    top: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    background-color: var(--primary);
}

.ham-menu.active span:nth-child(2) {
    opacity: 0;
    background-color: var(--primary);
}

.ham-menu.active span:nth-child(3) {
    top: 50%;
    transform: translate(-50%, -50%) rotate(-45deg);
    background-color: var(--primary);
}

/* بک‌دراپ */
.backdrop {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    z-index: 108;
}

.backdrop.active {
    display: block;
}

.off-screen-menu ul {
    margin-top: 20px;
}

.off-screen-menu ul li a {
    padding: 6px 5px;
    margin: 5px 10px;
    display: block;
    background-color: var(--primary);
    color: white;
    border-radius: 10px;
    text-align: center;
    transition: 0.3s;
}

.off-screen-menu ul li a:hover {
    background-color: var(--primary-light);
    box-shadow: var(--shadow);
}

.off-screen-menu ul li b {
    padding: 8px 5px;
    margin: 5px 10px;
    display: block;
    background-color: var(--primary-light);
    color: var(--color);
    border-radius: 10px;
    text-align: center;
    transition: 0.3s;
}

#theme-switch {
    height: 50px;
    width: 50px;
    padding: 0;
    border-radius: 10px;
    background-color: var(--main);
    display: flex;
    justify-content: center;
    align-items: center;
    position: fixed;
    top: 15px;
    left: 15px;
    border: 2px solid var(--border-color);
    cursor: pointer;
}

#theme-switch svg {
    fill: var(--primary);
}

#theme-switch svg:last-child {
    display: none;
}

.darkmode #theme-switch svg:first-child {
    display: none;
}

.darkmode #theme-switch svg:last-child {
    display: block;
}

::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-track {
    background-color: var(--background-color);
    border: 2px solid var(--border-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: var(--primary-light);
}

.card {
    width: 90%;
    max-width: 400px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    margin: 20px auto;
    background-color: var(--main);
}

.card-img {
    width: 100%;
    aspect-ratio: 16/9;
    object-fit: cover;
    border-bottom: 2px solid var(--border-color);
}

.card-body {
    padding: 15px;
    text-align: center;
}

.card-title {
    font-size: 20px;
    margin: 10px 0;
    color: var(--primary);
}

.card-text {
    font-size: 14px;
    color: var(--text-color);
    margin-bottom: 15px;
}

.card-btn {
    display: inline-block;
    padding: 10px 15px;
    background-color: var(--primary);
    color: var(--color);
    border-radius: 10px;
    text-decoration: none;
    transition: 0.3s;
}

.card-btn:hover {
    background-color: var(--primary-light);
}

.podcast {
    border: 2px solid var(--border-color);
    border-radius: 10px;
    min-width: min(90%, 430px);
    height: 150px;
    margin: 5px auto;
    display: block;
    max-width: 700px;
}

@media screen and (max-width: 1024px) {
    main {
        grid-template-rows: 80px auto auto;
        width: 100%;
        grid-template-areas:
            'header'
            'article'
            'footer';
    }

    header {
        max-width: 100%;
        height: 80px;
    }
}

@media screen and (max-width: 991px) {
    .nav-link {
        border-left: #000000 solid 2px;
        border-right: #000000 solid 2px;
        margin: 0;
    }

    .navbar-nav .nav-item span:nth-child(1) {
        border-top: #000000 solid 2px;
    }
}

@media screen and (max-width: 768px) {
    main {
        grid-template-rows: 80px auto auto;
        grid-template-areas:
            'header'
            'article'
            'footer';
    }

    header {
        height: 80px;
    }

    .col-md-4 img {
        display: block;
        width: 100%;
        aspect-ratio: 16/9;
        object-fit: cover;
    }
}

@media screen and (max-width: 600px) {
    main {
        grid-template-rows: 80px auto auto;
    }

    header {
        height: 80px;
    }
}