/* ==========================================
   FOOTER
========================================== */

.footer {
    width: 100%;
    max-width: 1024px;
    min-width: 320px;

    margin: 30px auto 0;

    padding: 0 10px 20px;
}


/* ==========================================
   1. PARTNER + QUICK LINK
========================================== */

.footer-banner {
    display: flex;

    width: 100%;

    background: #fff;

    border: 1px solid #d8dee8;
    border-radius: 15px;

    overflow: hidden;
}


/* ==========================================
   파트너 영역
   현재 3개 / 최대 6개
========================================== */

.footer-partners {
    flex: 1;
    min-width: 0;

    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));

    padding: 14px 10px;
}


/* 개별 파트너 */
.footer-partner {
    position: relative;

    min-width: 0;
    min-height: 105px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    gap: 12px;

    padding: 16px 12px;

    color: #16243a;
    text-decoration: none;

    transition:
        background .2s ease,
        color .2s ease;
}


.footer-partner:hover {
    color: var(--brand);
}


/* ==========================================
   세로 구분선
   1-2 / 2-3 / 4-5 / 5-6 사이
========================================== */

.footer-partner:not(:nth-child(3n))::after {
    content: "";

    position: absolute;

    right: 0;
    top: 18%;

    width: 1px;
    height: 64%;

    background: #dfe4eb;
}


/* ==========================================
   두 번째 줄이 있을 경우 가로 구분선
   1~3번 항목 아래쪽
========================================== */

.footer-partner:nth-child(-n+3):has(~ .footer-partner:nth-child(4))::before {
    content: "";

    position: absolute;

    left: 10%;
    bottom: 0;

    width: 80%;
    height: 1px;

    background: #dfe4eb;
}


/* 로고 */
.partner-logo {
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;
}


.partner-logo img {
    display: block;

    width: auto;
    height: auto;

    max-width: 145px;
    max-height: 48px;

    object-fit: contain;
}


/* 링크 이름 */
.partner-name {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 6px;

    font-size: 12px;
    font-weight: 500;

    white-space: nowrap;
}


.partner-name i {
    font-size: 10px;
}


/* ------------------------------------------
   주요 바로가기
------------------------------------------ */

.footer-quick {
    flex: 0 0 310px;

    border-left: 1px solid #dfe4eb;
}


.footer-quick-item {
    display: grid;

    grid-template-columns: 48px 1fr 18px;

    align-items: center;

    column-gap: 12px;

    min-height: 72px;

    padding: 10px 16px;

    color: var(--text);
    text-decoration: none;

    border-bottom: 1px solid #e4e8ee;

    transition:
        background .2s ease,
        color .2s ease;
}


.footer-quick-item:last-child {
    border-bottom: 0;
}


.footer-quick-item:hover {
    background: #f8fafc;
}


.quick-icon {
    width: 42px;
    height: 42px;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    font-size: 18px;
}


/* 지원 */

.quick-icon--support {
    color: #0c468b;
    background: #e9f2fd;
}


/* 교육 */

.quick-icon--education {
    color: #16824c;
    background: #e7f7ee;
}


/* 공지 */

.quick-icon--notice {
    color: #a75b13;
    background: #fff0df;
}


.quick-text {
    min-width: 0;

    display: flex;
    flex-direction: column;

    gap: 3px;
}


.quick-text strong {
    font-size: 14px;
    font-weight: 700;

    color: #17243a;
}


.quick-text span {
    font-size: 11px;

    color: var(--text-muted);

    white-space: nowrap;
}


.quick-arrow {
    font-size: 11px;

    color: #8290a3;

    transition: transform .2s ease;
}


.footer-quick-item:hover .quick-arrow {
    transform: translateX(3px);

    color: var(--brand);
}


/* ==========================================
   2. FOOTER MENU
========================================== */

.footer-menu {
    margin-top: 16px;

    padding: 0 4px 14px;

    border-bottom: 1px solid #dfe4ea;
}


.footer-menu-links {
    display: flex;
    align-items: center;

    flex-wrap: wrap;

    gap: 0;
}


.footer-menu-links a {
    position: relative;

    padding: 0 15px;

    color: var(--text-muted);

    text-decoration: none;

    font-size: 12px;

    transition: color .2s ease;
}


.footer-menu-links a:first-child {
    padding-left: 0;
}


.footer-menu-links a:not(:last-child)::after {
    content: "";

    position: absolute;

    right: 0;
    top: 50%;

    width: 1px;
    height: 11px;

    background: #d3d9e1;

    transform: translateY(-50%);
}


.footer-menu-links a:hover {
    color: var(--brand);
}


/* ==========================================
   3. COMPANY INFO
========================================== */

.footer-company {
    display: flex;
    flex-direction: column;

    gap: 7px;

    padding: 16px 0;

    color: var(--text-muted);

    font-size: 11px;

    line-height: 1.5;
}


.footer-company-row {
    display: flex;
    align-items: center;

    flex-wrap: wrap;

    gap: 6px 10px;
}


.footer-company-row > i {
    width: 18px;

    text-align: center;

    color: #193960;

    font-size: 14px;
}


.footer-company-row strong {
    color: #16243a;

    font-size: 12px;
}


.footer-company-title strong {
    font-size: 13px;
}


/* ==========================================
   4. COPYRIGHT BAR
========================================== */

.footer-bottom {
    display: flex;

    align-items: center;
    justify-content: space-between;

    margin-left: -10px;
    margin-right: -10px;

    padding: 15px 18px;

    background: linear-gradient(
        100deg,
        #102b50 0%,
        #0b203e 100%
    );

    color: #d5dfeb;

    font-size: 10px;
}


.footer-slogan {
    color: #b5c4d6;

    font-size: 11px;
}


/* ==========================================
   5. FOOTER MOBILE
========================================== */

@media (max-width: 768px) {

    .footer {
        margin-top: 20px;
    }


    /* 배너 세로 배치 */

    .footer-banner {
        flex-direction: column;
    }


    /* 파트너 */

    .footer-partners {
        width: 100%;

        padding: 20px 10px;
    }


    .footer-partner {
        gap: 10px;
    }


    .footer-partner:not(:last-child)::after {
        top: 10%;

        height: 80%;
    }


    .partner-logo {
        height: 36px;
    }


    .partner-logo img {
        max-width: 90px;
        max-height: 30px;
    }


    .partner-name {
        font-size: 10px;
        line-height: 1.3;

        white-space: normal;
        word-break: keep-all;
        overflow-wrap: break-word;

        text-align: center;
    }


    /* 주요 바로가기 */

    .footer-quick {
        flex: none;

        width: 100%;

        border-left: 0;
        border-top: 1px solid #dfe4eb;
    }


    .footer-quick-item {
        grid-template-columns: 42px 1fr 18px;

        min-height: 66px;
    }


    .quick-icon {
        width: 36px;
        height: 36px;

        font-size: 16px;
    }


    .quick-text strong {
        font-size: 13px;
    }


    .quick-text span {
        font-size: 10px;
    }


    /* Footer 메뉴 */

    .footer-menu-links {
        row-gap: 8px;
    }


    .footer-menu-links a {
        font-size: 11px;

        padding: 0 10px;
    }


    /* 회사정보 */

    .footer-company {
        font-size: 10px;
    }


    .footer-company-row {
        align-items: flex-start;
    }


    /* Copyright */

    .footer-bottom {
        flex-direction: column;

        align-items: flex-start;

        gap: 4px;
    }


    .footer-slogan {
        display: none;
    }

}