/* ==================================================
   MARKET FOOTER
   مستقل از نوبار و محتوای صفحات
================================================== */

.market-footer {
    --mf-primary: #1976d2;
    --mf-primary-dark: #125ba6;
    --mf-heading: #233950;
    --mf-text: #5f7285;
    --mf-muted: #687c90;
    --mf-border: #e3ebf3;

    position: relative;
    isolation: isolate;

    width: 100%;
    margin-top: 48px;

    border-top: 1px solid var(--mf-border);

    background:
        radial-gradient(
            ellipse at 100% 0,
            rgba(25, 118, 210, 0.065),
            transparent 45%
        ),
        linear-gradient(
            180deg,
            #ffffff 0%,
            #f8fbff 100%
        );

    color: var(--mf-text);

    font-family: "Vazirmatn", sans-serif;
    font-size: 13px;

    direction: rtl;
    text-align: right;
}

.market-footer,
.market-footer *,
.market-footer *::before,
.market-footer *::after {
    box-sizing: border-box;
}

.market-footer::before {
    content: "";

    position: absolute;
    top: -1px;
    inset-inline: 0;

    width: min(220px, 45%);
    height: 3px;
    margin-inline: auto;

    border-radius: 0 0 8px 8px;

    background: linear-gradient(
        90deg,
        #90caf9,
        var(--mf-primary),
        #90caf9
    );
}

.market-footer .market-footer__container {
    width: 100%;
    max-width: 1250px;

    margin-inline: auto;
    padding: 36px 24px 0;
}

.market-footer a {
    font-family: inherit;
    text-decoration: none;
}

.market-footer a:focus-visible,
.market-footer button:focus-visible {
    outline: 3px solid var(--mf-primary);
    outline-offset: 4px;
}


/* ==================================================
   TOP / BRAND
================================================== */

.market-footer .market-footer__top {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 24px;
    margin-bottom: 30px;
}

.market-footer .market-footer__brand {
    display: inline-flex;
    align-items: center;

    gap: 13px;
    min-width: 0;

    color: var(--mf-heading);
}

.market-footer .market-footer__brand-icon {
    display: grid;
    place-items: center;

    width: 51px;
    height: 51px;
    flex: 0 0 51px;

    border: 1px solid rgba(25, 118, 210, 0.12);
    border-radius: 16px;

    background: #eaf4fe;
    color: var(--mf-primary);

    font-size: 25px;
}

.market-footer .market-footer__brand-text {
    display: flex;
    flex-direction: column;

    gap: 5px;
    min-width: 0;
}

.market-footer .market-footer__brand-text strong {
    color: var(--mf-heading);

    font-size: 20px;
    font-weight: 800;
    line-height: 1.6;
}

.market-footer .market-footer__brand-text > span {
    color: var(--mf-muted);

    font-size: 11px;
    line-height: 1.9;
}

.market-footer .market-footer__back-top {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 13px;
    min-height: 44px;
    flex-shrink: 0;

    padding: 10px 15px;

    border: 1px solid #dbe6f0;
    border-radius: 12px;

    background: #ffffff;
    color: var(--mf-text);

    font-family: inherit;
    font-size: 11px;
    font-weight: 500;

    cursor: pointer;

    transition:
        color 0.2s ease,
        border-color 0.2s ease,
        background-color 0.2s ease;
}

.market-footer .market-footer__back-top i {
    font-size: 16px;
}

.market-footer .market-footer__back-top:hover {
    border-color: #a7cbee;
    background: #f0f7ff;
    color: var(--mf-primary);
}


/* ==================================================
   HIGHLIGHTS
================================================== */

.market-footer .market-footer__highlights {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));

    gap: 14px;
    margin-bottom: 36px;
}

.market-footer .market-footer__highlight {
    display: flex;
    align-items: center;

    gap: 12px;
    min-width: 0;

    padding: 18px 16px;

    border: 1px solid var(--mf-border);
    border-radius: 16px;

    background: rgba(255, 255, 255, 0.85);
    color: var(--mf-heading);

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background-color 0.2s ease;
}

.market-footer .market-footer__highlight:hover {
    border-color: #b7d5f2;
    background: #ffffff;

    box-shadow: 0 7px 20px rgba(31, 70, 110, 0.05);
}

.market-footer .market-footer__highlight-icon {
    display: grid;
    place-items: center;

    width: 43px;
    height: 43px;
    flex: 0 0 43px;

    border-radius: 13px;

    background: #eef6ff;
    color: var(--mf-primary);

    font-size: 21px;
}

.market-footer .market-footer__highlight > span:nth-child(2) {
    display: flex;
    flex-direction: column;

    gap: 5px;
    min-width: 0;
}

.market-footer .market-footer__highlight strong {
    color: var(--mf-heading);

    font-size: 12px;
    font-weight: 700;
    line-height: 1.8;
}

.market-footer .market-footer__highlight small {
    color: var(--mf-muted);

    font-size: 10px;
    line-height: 1.9;
}

.market-footer .market-footer__highlight-arrow {
    margin-inline-start: auto;

    color: #7895af;

    font-size: 11px;
}


/* ==================================================
   MAIN GRID
================================================== */

.market-footer .market-footer__grid {
    display: grid;
    grid-template-columns:
        minmax(0, 1.35fr)
        minmax(0, 0.8fr)
        minmax(0, 0.8fr)
        minmax(0, 1.1fr);

    align-items: start;

    gap: 32px;
    padding-bottom: 34px;
}

.market-footer .market-footer__grid > * {
    min-width: 0;
}

.market-footer .market-footer__heading {
    margin: 0 0 17px;

    color: var(--mf-heading);

    font-size: 13px;
    font-weight: 800;
    line-height: 1.9;
}

.market-footer .market-footer__about p,
.market-footer .market-footer__contact p {
    margin: 0;

    color: var(--mf-text);

    font-size: 12px;
    line-height: 2.25;

    overflow-wrap: anywhere;
}

.market-footer .market-footer__explore {
    display: inline-flex;
    align-items: center;

    gap: 9px;
    min-height: 44px;
    margin-top: 12px;

    color: var(--mf-primary);

    font-size: 11px;
    font-weight: 700;
    line-height: 1.9;

    transition: color 0.2s ease;
}

.market-footer .market-footer__explore:hover {
    color: var(--mf-primary-dark);
}

.market-footer .market-footer__explore i {
    font-size: 15px;
}


/* ==================================================
   LINK LISTS
================================================== */

.market-footer .market-footer__links {
    display: flex;
    flex-direction: column;

    gap: 3px;

    margin: 0;
    padding: 0;

    list-style: none;
}

.market-footer .market-footer__links li {
    margin: 0;
    padding: 0;
}

.market-footer .market-footer__links a {
    display: inline-flex;
    align-items: center;

    gap: 8px;
    min-height: 38px;

    color: var(--mf-text);

    font-size: 12px;
    line-height: 1.9;

    transition: color 0.2s ease;
}

.market-footer .market-footer__links a::before {
    content: "";

    width: 5px;
    height: 5px;
    flex: 0 0 5px;

    border-radius: 50%;

    background: #c7d6e4;

    transition: background-color 0.2s ease;
}

.market-footer .market-footer__links a:hover {
    color: var(--mf-primary);
}

.market-footer .market-footer__links a:hover::before {
    background: var(--mf-primary);
}


/* ==================================================
   CONTACT CARD
================================================== */

.market-footer .market-footer__contact {
    position: relative;

    padding: 20px;

    border: 1px solid #dceaf7;
    border-radius: 18px;

    background: #eff6fd;
}

.market-footer .market-footer__contact-icon {
    display: grid;
    place-items: center;

    width: 40px;
    height: 40px;

    margin-bottom: 12px;

    border: 1px solid #e1ecf7;
    border-radius: 12px;

    background: #ffffff;
    color: var(--mf-primary);

    font-size: 20px;
}

.market-footer .market-footer__contact .market-footer__heading {
    margin-bottom: 8px;
}

.market-footer .market-footer__contact p {
    font-size: 11px;
    line-height: 2.1;
}

.market-footer .market-footer__contact-button {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 12px;
    min-height: 44px;
    margin-top: 16px;
    padding: 11px 14px;

    border: 1px solid var(--mf-primary);
    border-radius: 11px;

    background: var(--mf-primary);
    color: #ffffff;

    font-size: 12px;
    font-weight: 600;

    transition:
        background-color 0.2s ease,
        border-color 0.2s ease;
}

.market-footer .market-footer__contact-button:hover {
    border-color: var(--mf-primary-dark);
    background: var(--mf-primary-dark);
    color: #ffffff;
}

.market-footer .market-footer__contact-button i {
    font-size: 16px;
}


/* ==================================================
   BOTTOM
================================================== */

.market-footer .market-footer__bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 16px;
    padding: 20px 0;

    border-top: 1px solid var(--mf-border);
}

.market-footer .market-footer__copyright {
    margin: 0;

    color: var(--mf-muted);

    font-size: 11px;
    line-height: 2;
}

.market-footer .market-footer__copyright strong {
    color: var(--mf-heading);
    font-weight: 700;
}

.market-footer .market-footer__signature {
    display: inline-flex;
    align-items: center;

    gap: 7px;

    color: var(--mf-muted);

    font-size: 10px;
    line-height: 2;
}

.market-footer .market-footer__signature i {
    color: var(--mf-primary);
    font-size: 13px;
}


/* ==================================================
   TABLET
================================================== */

@media (max-width: 1000px) {
    .market-footer .market-footer__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 28px;
    }

    .market-footer .market-footer__about {
        grid-column: 1 / -1;
        max-width: 680px;
    }

    .market-footer .market-footer__highlight {
        gap: 10px;
        padding: 15px 12px;
    }

    .market-footer .market-footer__highlight-icon {
        width: 37px;
        height: 37px;
        flex-basis: 37px;

        font-size: 19px;
    }

    .market-footer .market-footer__highlight-arrow {
        display: none;
    }
}


/* ==================================================
   MOBILE
================================================== */

@media (max-width: 700px) {
    .market-footer {
        margin-top: 32px;
    }

    .market-footer .market-footer__container {
        padding: 28px 18px 0;
    }

    .market-footer .market-footer__top {
        gap: 14px;
        margin-bottom: 24px;
    }

    .market-footer .market-footer__brand {
        gap: 10px;
    }

    .market-footer .market-footer__brand-icon {
        width: 43px;
        height: 43px;
        flex-basis: 43px;

        border-radius: 13px;

        font-size: 22px;
    }

    .market-footer .market-footer__brand-text strong {
        font-size: 17px;
    }

    .market-footer .market-footer__brand-text > span {
        max-width: 175px;

        font-size: 10px;
    }

    .market-footer .market-footer__back-top {
        gap: 8px;
        padding: 9px 11px;

        font-size: 10px;
    }

    .market-footer .market-footer__highlights {
        grid-template-columns: 1fr;

        gap: 10px;
        margin-bottom: 28px;
    }

    .market-footer .market-footer__highlight {
        gap: 13px;
        padding: 13px 15px;
    }

    .market-footer .market-footer__highlight-arrow {
        display: block;
    }

    .market-footer .market-footer__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));

        gap: 26px 20px;
        padding-bottom: 26px;
    }

    .market-footer .market-footer__about,
    .market-footer .market-footer__contact {
        grid-column: 1 / -1;
    }

    .market-footer .market-footer__heading {
        margin-bottom: 12px;
    }

    .market-footer .market-footer__links a {
        min-height: 44px;
        font-size: 11px;
    }

    .market-footer .market-footer__contact {
        padding: 18px;
    }

    .market-footer .market-footer__bottom {
        flex-direction: column;
        align-items: center;

        gap: 7px;
        padding: 18px 0;

        text-align: center;
    }

    .market-footer .market-footer__copyright {
        font-size: 10px;
    }
}


/* ==================================================
   SMALL MOBILE
================================================== */

@media (max-width: 380px) {
    .market-footer .market-footer__top {
        flex-wrap: wrap;
    }

    .market-footer .market-footer__back-top {
        margin-inline-start: auto;
    }
}


/* ==================================================
   REDUCED MOTION
================================================== */

@media (prefers-reduced-motion: reduce) {
    .market-footer *,
    .market-footer *::before,
    .market-footer *::after {
        transition: none !important;
        animation: none !important;
    }
}
