/* FONTS */
@font-face {
    font-family: "iranSans";
    src: url("../fonts/woff/IRANSansWeb\(FaNum\).woff") format("woff"),
        url("../fonts/woff2/IRANSansWeb\(FaNum\).woff2") format("woff2");
}


@font-face {
    font-family: "iranSans-bold";
    src: url("../fonts/woff/IRANSansWeb\(FaNum\)_Bold.woff") format("woff"),
        url("../fonts/woff2/IRANSansWeb\(FaNum\)_Bold.woff2") format("woff2");
}

@font-face {
    font-family: "iranSans-light";
    src: url("../fonts/woff/IRANSansWeb\(FaNum\)_Light.woff") format("woff"),
        url("../fonts/woff2/IRANSansWeb\(FaNum\)_Bold.woff2") format("woff2");
}

/* THEME */
:root {
    --container: 1200px;
    --header-color: #156B87;
    --color-gray: #949698;
    --footer-color: #F2B21B;
    --loading-color: #56c5d0;
    --white-color: #fff
}

/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}


html {
    font-size: 16px
}

body {
    color: var(--color-gray);
    line-height: 1.9;
    background: var(--white-color)
}

img {
    max-width: 100%;
    height: auto;
    display: block
}

/* CONTAINER */
.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: 1rem
}

.info {
    background: var(--color-gray);
    height: 45px;
    position: sticky;
    top: 0;
    z-index: 1
}

.info .container {
    display: flex;
    align-items: center;
    gap: 20px;
    color: var(--white-color);
    padding: 10px;
    flex-wrap: wrap;
}

.info .container * {
    font-size: 16px;
    cursor: pointer
}

.info .container h5 {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    font-weight: normal
}

.info .container h5 a {
    text-decoration: none;
    color: inherit
}

.toggle {
    background: var(--color-gray);
    color: var(--white-color);
    border: none;
    outline: none;

}

/* loading */


#loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--white-color);
    opacity: 1;
    backdrop-filter: blur(6px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

#loading-overlay.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader {
    position: relative;
    width: 150px;
    height: 150px;
}

.loader img {
    width: 100%;
    height: auto;
    animation: pulse 2s infinite ease-in-out;
}

.ring {
    position: absolute;
    top: -15px;
    left: -15px;
    width: 180px;
    height: 180px;
    border: 5px solid var(--loading-color);
    border-top: 5px solid transparent;
    border-radius: 50%;
    animation: spin 2s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

/* HEADER */
header {
    background: var(--header-color);
    height: 420px;
    display: flex;
    justify-content: center;
    align-items: center;
}

header .container {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 2rem;
    padding-block: 2rem;
}

.header-title {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.header-title h2 {
    font-size: clamp(1.6rem, 2.2vw, 2.6rem);
    color: var(--white-color);
    font-family: "iranSans-bold";
    text-align: center !important;
}

.header-logo img {
    width: clamp(160px, 18vw, 230px)
}

/* MAIN */
main {
    padding-block: 2rem
}

.circle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--header-color);
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.circle.show {
    opacity: 1;
    visibility: visible;
    animation: bounce 1.5s infinite;
}

.circle svg {
    width: 28px;
    height: 28px;
    fill: none;
    stroke: white;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* انیمیشن فلش */
@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-6px);
    }
}


main .container {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 2rem;
    align-items: start
}

.main-logo img {

    width: clamp(6px, .6vw, 10px);
    height: clamp(160px, 18vw, 230px);
    position: relative;
    bottom: 34px;
}

.main-article {
    text-align: justify
}

.main-article h4 {
    font-size: clamp(.95rem, 1.1vw, 1rem);
    /* line-height: 2.2; */
    color: var(--color-gray);
    font-weight: normal;
    margin: 50px auto;
}

.second-section {
    opacity: 0;
    height: auto;
    overflow: hidden;
    transition: opacity .5s ease-in-out;
    pointer-events: none;
}

/* حالت باز */
.second-section.active {
    opacity: 1;
    pointer-events: auto;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    width: 100%;
    max-width: var(--container);

}

article {
    opacity: 0;
    visibility: hidden;
    max-height: 0;
    overflow: hidden;
    transition:
        opacity 0.5s ease,
        max-height 0.5s ease,
        visibility 0.5s ease;
}

article.active {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    opacity: 1;
    visibility: visible;
    max-height: max-content;
}


article img {
    width: clamp(160px, 18vw, 230px);
    height: auto;
}



/* FOOTER */
footer {
    padding-block-start: 2rem
}

footer .container {
    display: grid;
    gap: 1.5rem
}

.footer-title {
    background: var(--footer-color);
    color: var(--white-color);
    text-align: center;
    padding: 1rem;
    border-radius: .5rem
}

.footer-title h2 {
    font-size: clamp(1.3rem, 2vw, 2rem);
    font-family: "iranSans-bold";
}

.footer-wrapper {
    display: grid;
    gap: 1rem
}

.footer-first,
.footer-second {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
    gap: 1rem;
    justify-items: center;
    align-items: center
}

.footer-first {
    gap: 15rem
}

.footer-second {
    margin-bottom: 30px
}

.footer-wrapper img {
    width: 100%;
    max-width: 150px;
    cursor: pointer;
    user-select: none;
}

.footer-first #abanImg {
    width: 120%;
    max-width: 270px;
    min-width: 150px;
    position: relative;
    top: 12px;
}

.footer-first #novinImg {
    position: relative;
    bottom: 11px;
}

footer .privacy {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--color-gray);
    color: var(--white-color);
    height: 50px;
}


/* BREAKPOINTS  */
@media (max-width:1500px) {
    :root {
        --container: 1200px
    }

    html {
        font-size: 15px
    }
}

@media (max-width:1200px) {
    :root {
        --container: 992px
    }

    html {
        font-size: 14px
    }

    .footer-first {
        gap: 8rem;
    }
}

@media (max-width:992px) {
    :root {
        --container: 768px
    }

    html {
        font-size: 13px
    }

    header .container {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        align-items: center;
        flex-direction: column-reverse;
    }

    .header-title h2 {
        text-align: center !important
    }

    .header-logo {
        text-align: center;
    }

    main .container {
        grid-template-columns: 1fr
    }

    .main-logo {
        display: none
    }
}

@media (max-width:768px) {
    :root {
        --container: 100%
    }

    html {
        font-size: 12.5px
    }

    .container {
        padding-inline: 1rem
    }

    .footer-first {
        gap: 4rem;
    }
}

@media (max-width:576px) {
    html {
        font-size: 12px
    }

    .footer-first {
        gap: 2rem;
    }

    .info {
        height: fit-content;
    }

    .info .container {
        display: flex;
        flex-direction: column-reverse;
        justify-content: center;
        align-items: center;

    }
}