/* ========================================
   Footer2 Section - Light Blue Background
   자동 반응형 (clamp() 기반)
   ======================================== */

.hc-footer2 {
    background: #e6f2ff; /* 옅은 파랑색 배경 */
    color: #333333;
    padding: clamp(1rem, 3vw, 1.875rem) 0 clamp(0.5rem, 1.5vw, 0.9375rem);
    border-top: 1px solid #c0c0c0; /* 상단 은색 실선 - 컨텐츠와 푸터 구분 */
    position: relative;
    z-index: 1; /* 히어로 섹션 아래에 표시 */
    width: 100% !important;
    clear: both !important;
    float: none !important;
    margin: 0 !important;
    box-sizing: border-box;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-height: auto !important;
}

/* 지원 섹션에서 호출되는 푸터 - 전체 너비 사용 */
.mainpage-support ~ .footer-in-support.hc-footer2,
.mainpage-section.mainpage-support ~ .footer-in-support.hc-footer2,
.footer-in-support.hc-footer2,
footer.footer-in-support.hc-footer2,
footer.hc-footer2.footer-in-support {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
    position: relative !important;
    z-index: 1 !important; /* 히어로 섹션 아래에 표시 */
}

.mainpage-support ~ .footer-in-support.hc-footer2 .footer-container-fullwidth,
.mainpage-section.mainpage-support ~ .footer-in-support.hc-footer2 .footer-container-fullwidth,
.footer-in-support.hc-footer2 .footer-container-fullwidth,
.footer-in-support.hc-footer2 .mainpage-container.footer-container-fullwidth,
footer.footer-in-support.hc-footer2 .mainpage-container.footer-container-fullwidth,
footer.hc-footer2.footer-in-support .mainpage-container.footer-container-fullwidth {
    max-width: 100% !important;
    width: 100% !important;
    padding-left: clamp(1rem, 4vw, 1.25rem) !important;
    padding-right: clamp(1rem, 4vw, 1.25rem) !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    box-sizing: border-box !important;
}

/* 지원 섹션 내 푸터의 내부 콘텐츠가 적절한 최대 너비를 가지도록 중앙 정렬 */
.footer-in-support.hc-footer2 .footer-container-fullwidth .footer-top,
.footer-in-support.hc-footer2 .mainpage-container.footer-container-fullwidth .footer-top,
footer.footer-in-support.hc-footer2 .mainpage-container.footer-container-fullwidth .footer-top,
footer.hc-footer2.footer-in-support .mainpage-container.footer-container-fullwidth .footer-top {
    max-width: var(--container-width, 1200px);
    margin-left: auto;
    margin-right: auto;
}

.footer-in-support.hc-footer2 .footer-container-fullwidth .footer-bottom,
.footer-in-support.hc-footer2 .mainpage-container.footer-container-fullwidth .footer-bottom,
footer.footer-in-support.hc-footer2 .mainpage-container.footer-container-fullwidth .footer-bottom,
footer.hc-footer2.footer-in-support .mainpage-container.footer-container-fullwidth .footer-bottom {
    max-width: var(--container-width, 1200px);
    margin-left: auto;
    margin-right: auto;
}

/* Footer Top Section */
.hc-footer2 .footer-top {
    display: grid;
    grid-template-columns: 1.5fr 2.5fr;
    gap: clamp(2rem, 8vw, 5rem);
    margin-bottom: clamp(0.75rem, 2vw, 1.25rem);
    padding-bottom: clamp(0.75rem, 2vw, 1.25rem);
}

@media (max-width: 1024px) {
    .hc-footer2 .footer-top {
        grid-template-columns: 1fr;
    }
}

/* Brand Section */
.hc-footer2 .footer-brand {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hc-footer2 .footer-logo-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.hc-footer2 .footer-logo-text {
    font-size: 18px; /* 평범한 로고 텍스트 크기 */
    font-weight: 600;
    color: #333333;
    letter-spacing: 0.5px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.hc-footer2 .footer-address-wrapper,
.hc-footer2 .footer-business-number-wrapper,
.hc-footer2 .footer-representative-wrapper,
.hc-footer2 .footer-phone-wrapper {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 8px;
}

.hc-footer2 .footer-address,
.hc-footer2 .footer-business-number,
.hc-footer2 .footer-representative,
.hc-footer2 .footer-phone {
    margin: 0;
    color: #333333;
    font-size: 14px; /* 14포인트 글자 */
    line-height: 1.6;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.hc-footer2 .footer-phone a {
    color: #333333 !important;
    font-size: 14px; /* 14포인트 글자 */
    font-weight: 400;
    text-decoration: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    transition: opacity 0.3s ease, color 0.3s ease;
}

.hc-footer2 .footer-phone a:hover {
    color: #0066cc !important;
    opacity: 0.8;
}

.hc-footer2 .footer-phone a:visited {
    color: #333333 !important;
}

.hc-footer2 .footer-phone a:active {
    color: #333333 !important;
}

/* Social Icons */
.hc-footer2 .footer-social-icons {
    display: flex;
    gap: 16px;
    margin-top: 8px;
}

.hc-footer2 .footer-social-icons .social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    color: #333333;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.hc-footer2 .footer-social-icons .social-icon:hover {
    opacity: 0.7;
}

.hc-footer2 .footer-social-icons .social-icon svg {
    width: 20px;
    height: 20px;
}

/* Navigation Section */
.hc-footer2 .footer-navigation {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
}

.hc-footer2 .footer-link-group {
    display: flex;
    flex-direction: column;
}

.hc-footer2 .footer-link-title {
    font-size: 14px; /* 14포인트 글자 */
    font-weight: 700;
    color: #333333;
    margin: 0 0 clamp(1rem, 2.5vw, 1.25rem) 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.hc-footer2 .footer-link-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hc-footer2 .footer-link-list li {
    margin: 0;
    padding: 0;
}

.hc-footer2 .footer-link-list a {
    color: #333333;
    text-decoration: none;
    font-size: 14px; /* 14포인트 글자 */
    line-height: 1.5;
    transition: opacity 0.3s ease, color 0.3s ease;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.hc-footer2 .footer-link-list a:hover {
    color: #0066cc;
    opacity: 0.8;
}

/* Home 링크 스타일 */
.hc-footer2 .footer-home-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.hc-footer2 .footer-link-highlight {
    color: #0066cc !important;
    text-decoration: underline !important;
}

.hc-footer2 .footer-link-highlight:hover {
    opacity: 0.8 !important;
}

/* Footer Bottom Section */
.hc-footer2 .footer-bottom {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.hc-footer2 .footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

/* Legal Links */
.hc-footer2 .footer-legal-links {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    padding-top: 40px;
    flex-wrap: wrap;
}

.hc-footer2 .footer-legal-link {
    color: #333333;
    text-decoration: none;
    font-size: 14px; /* 14포인트 글자 */
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    transition: opacity 0.3s ease, color 0.3s ease;
}

.hc-footer2 .footer-legal-link:hover {
    color: #0066cc;
    opacity: 0.8;
}

.hc-footer2 .footer-legal-separator {
    color: rgba(0, 0, 0, 0.3);
    font-size: 14px; /* 14포인트 글자 */
    margin: 0 4px;
}

.hc-footer2 .footer-copyright {
    color: #333333;
    font-size: 14px; /* 14포인트 글자 */
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Payment Icons */
.hc-footer2 .footer-payment-icons {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.hc-footer2 .payment-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: clamp(1.25rem, 3vw, 1.5rem);
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.hc-footer2 .payment-icon:hover {
    opacity: 1;
}

.hc-footer2 .payment-icon img {
    display: block;
    height: clamp(1.25rem, 3vw, 1.5rem);
    width: auto;
    max-width: clamp(3rem, 8vw, 5rem);
    object-fit: contain;
}

/* ========================================
   최소한의 미디어 쿼리 (레이아웃 구조 변경용만)
   ======================================== */

@media (max-width: 1024px) {
    .hc-footer2 .footer-navigation {
        grid-template-columns: repeat(2, 1fr);
        gap: clamp(1.5rem, 4vw, 2.5rem);
    }
}

/* Joyn Shop 페이지에서도 올바르게 표시되도록 */
.joyn-shop-page .hc-footer2,
body.joyn-shop-page .hc-footer2 {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
}

.joyn-shop-page .hc-footer2 .mainpage-container,
body.joyn-shop-page .hc-footer2 .mainpage-container {
    max-width: var(--container-width, 1200px);
    width: 100%;
    margin: 0 auto;
    padding: 0 clamp(1rem, 4vw, 1.25rem);
    box-sizing: border-box;
}

/* CSS 변수가 없을 경우를 위한 기본값 */
.hc-footer2 .mainpage-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 clamp(1rem, 4vw, 1.25rem);
    box-sizing: border-box;
}

@media (max-width: 768px) {
    /* 모바일에서 푸터2가 정상적으로 표시되도록 */
    .hc-footer2 {
        z-index: 1 !important; /* 히어로 섹션 아래에 표시 */
        position: relative !important;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        padding: clamp(1rem, 3vw, 1.875rem) 0 clamp(0.5rem, 1.5vw, 0.9375rem) !important;
        clear: both !important;
        float: none !important;
        min-height: auto !important;
        height: auto !important;
    }
    
    /* 모바일에서 푸터2 컨테이너도 보이도록 */
    .hc-footer2 .mainpage-container {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        padding: 0 clamp(1rem, 4vw, 1.25rem) !important;
    }
    
    /* 모바일에서 푸터2 내부 요소들도 보이도록 */
    .hc-footer2 .footer-top,
    .hc-footer2 .footer-bottom {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    .hc-footer2 .footer-navigation {
        grid-template-columns: 1fr;
        gap: clamp(1.25rem, 3vw, 1.875rem);
    }
    
    .hc-footer2 .footer-bottom-content {
        flex-direction: column;
        align-items: flex-start;
        gap: clamp(1rem, 2.5vw, 1.25rem);
    }
    
    .hc-footer2 .footer-legal-links {
        width: 100%;
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
    
    .hc-footer2 .footer-bottom .footer-legal-links {
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
    
    .hc-footer2 .mainpage-container .footer-legal-links,
    .hc-footer2 .footer-container-fullwidth .footer-legal-links {
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
    
    .hc-footer2 .footer-payment-icons {
        width: 100%;
        justify-content: flex-start;
    }
    
    .joyn-shop-page .hc-footer2 .mainpage-container,
    body.joyn-shop-page .hc-footer2 .mainpage-container {
        padding: 0 clamp(1rem, 4vw, 1.25rem);
    }
}
