/* ============================================================
   main.css - 메인 페이지 전용
============================================================ */

/* 콘텐츠 영역 */
.contents.main { }

/* ============================================================
   메인 비주얼
============================================================ */
.main-visual {
    position: relative;
    min-height: 380px;
    background: url('../images/main/main_visual.jpg') no-repeat center center / cover;
    display: flex;
    align-items: center;
    overflow: hidden;
}
.main-visual .container {
    position: relative;
    z-index: 2;
    padding-top: 60px;
    padding-bottom: 70px;
    text-align: center;
}
.main-visual .tit {
    margin-bottom: 36px;
}
.main-visual .tit p {
    font-size: 40px;
    font-family:'Jalnan';
    color: #ffffff;
    line-height: 1.3;
}
.main-visual .tit p.white {
    color: #ffffff;
    font-size: 40px;
}
.main-visual .tit p b {
    display: inline;
    font-size: 40px;
    line-height: 1.2;
}
.main-visual .tit p .green {
    color: #3cc3a2;
}
.main-visual .tit p .purple {
    color: #608ad1;
}
.main-visual .tit .sub-tit {
    display: block;
    margin-top: 12px;
    font-size: 1.1rem;
    color: rgba(255,255,255,0.85);
    font-weight: 300;
    letter-spacing: 0.02em;
}

/* 메인 검색 */
.main-search {
    position: relative;
    display: flex;
    align-items: center;
    max-width: 560px;
    margin: 0 auto;
    width: 80%;
    background: #ffffff;
    border-radius: 50px;
    overflow: hidden;
    border: solid 2px #3cc3a2;
    box-shadow: 0 4px 24px rgba(0,0,0,0.2);
    padding-right: 5px;
}
.main-search::before {
     content: '';
     display: block;
     flex-shrink: 0;
     width: 50px;
     height: 22px;
     margin-left: 15px;
     background: url('../images/main/ico_search.png') no-repeat center / contain;
     padding-right: 25px;
     border-right: solid 1px #ddd;
}
.main-search input {
    flex: 1;
    height: 65px;
    padding: 0 16px;
    border: none;
    outline: none;
    font-size: 1.1rem;
    color: #333333;
    background: transparent;
}
.main-search input::placeholder {
    color: #aaaaaa;
}
.btn-main-search {
    flex-shrink: 0;
    width: 55px;
    height: 55px;
    margin: 1px 1px 1px 0;
    background: url('../images/main/btn_search_white.png') no-repeat center / cover;
    border: none;
    border-radius: 50px;
    font-size: 0;
    cursor: pointer;
    transition: background-color 0.2s;
}
.btn-main-search:hover {
    background-color: #1e5e3c;
}

/* ============================================================
   퀵메뉴
============================================================ */
.quick-menu {
    position: relative;
    background: #3cc3a2;
    padding: 20px 0px;
}
.quick-menu::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 78px;
    height: 39px;
    background: url('../images/main/quick_arrow.png') no-repeat center / contain;
    z-index: 5;
}
.quick-menu .container {
    display: flex;
    align-items: stretch;
}
.quick-menu h2 {
    flex-shrink: 0;
    width: 150px;
    background: url('../images/main/bg_quick.gif') no-repeat left bottom #294d89;
    color: #ffffff;
    font-size: 1.5rem;
    font-family: 'JejuGothic';
    font-weight: 400;
    letter-spacing: 0.04em;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    line-height: 1.3;
    position: relative;
    border-radius: 30px 0px;
}
.quick-menu h2::after {
    content: '';
    background: url('../images/main/ico_quick.png') no-repeat center center;
    display: block;
    width: 52px;
    height: 18px;
    position: absolute;
    right: -10px;
    bottom: 15px;
    margin-top: 8px;
}
.quick-menu ul {
    flex: 1;
    display: flex;
    align-items: flex-start;
    justify-content: space-around;
    width: calc(100% - 200px);
    flex-wrap: wrap;
}
.quick-menu ul::-webkit-scrollbar {
    display: none;
}
.quick-menu ul li {
    display: flex;
    align-items: flex-start;
}
.quick-menu ul li a {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    justify-content: flex-start;
    height: 100%;
    gap: 8px;
    padding: 8px 10px;
    color: #ffffff;
    transition: transform 0.2s;
}
.quick-menu ul li a:hover {
    transform: translateY(-3px);
}
.quick-menu ul li a::before {
    content: '';
    display: block;
    width: 70px;
    height: 70px;
    border-radius: 50%;
}
.quick-menu ul li a span {
    font-size: 0.9rem;
    font-weight: 500;
    line-height: 1.4;
    white-space: nowrap;
    color: #ffffff;
}

/* 퀵메뉴 아이콘 */
.quick-menu ul li a.q01::before { background: url('../images/main/quick01.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q02::before { background: url('../images/main/quick02.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q03::before { background: url('../images/main/quick03.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q04::before { background: url('../images/main/quick04.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q05::before { background: url('../images/main/quick05.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q06::before { background: url('../images/main/quick06.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q07::before { background: url('../images/main/quick07.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q08::before { background: url('../images/main/quick08.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q09::before { background: url('../images/main/quick09.png') no-repeat center center rgba(255,255,255,0.4); }
.quick-menu ul li a.q10::before { background: url('../images/main/quick10.png') no-repeat center center rgba(255,255,255,0.4); }

/* ============================================================
   메인 컨텐츠 3단 구성
============================================================ */
.main-cont {
    padding: 60px 0 50px;
}
.main-cont .container {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 24px;
    align-items: stretch;
}

/* 공통 카드 스타일 */
.main-cont .left,
.main-cont .mid,
.main-cont .right {
    background: #ffffff;
    border-radius: 30px;
    padding: 28px;
}

/* 공통 타이틀 영역 */
.main-cont .title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2px;
}
.main-cont .title h3 {
    font-size: 1.5rem;
    font-family: 'JejuGothic';
    font-weight: 400;
    color: #222222;
    position: relative;
    padding-left: 0;
}
.main-cont .more-wrap {
    position: absolute;
    width: 144px;
    height: 136px;
    bottom: 0px;
    background: url('../images/main/main_object.png') no-repeat right bottom;
    background-size: cover;
    right: 0px;
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
    padding: 0px 15px 15px 0px;
}
.main-cont .view-more {
    background: #2b7a50;
    border-radius: 50%;
    width: 56px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 56px;
    font-size: 0;
    flex-shrink: 0;
    transition: background 0.2s;
}
.main-cont .view-more::after {
    content: '';
    display: block;
    width: 16px;
    height: 16px;
    background: url('../images/main/arrow_white.png') no-repeat center / contain;
}
.main-cont .view-more:hover {
    background: #1e5e3c;
}

/* 왼쪽 - 공지사항 */
.main-cont .left {
    background: #f4f4f4;
}
.main-cont .left .title {
    display: flex;
    justify-content: space-between;
    font-family: 'JejuGothic';
    font-weight: 400;
}
.main-cont .left .title h3 {
    position: relative;
}
.main-cont .left .title h3::after {
    content: '';
    display: block;
    position: absolute;
    background: url('../images/main/ico_main_title.png') no-repeat center center;
    background-size: cover;
    width: 25px;
    right: -15px;
    top: -2px;
    opacity: 0.6;
    height: 25px;
}
.main-cont .left .notice-more {
    display: block;
    width: 30px;
    height: 30px;
    font-size: 0;
    color: #666666;
    background: url('../images/main/notice_more.png') no-repeat center center / 21px;
}
.main-cont .left ul {
    padding-top: 10px;
}
.main-cont .left .notice-info {
    margin: 0;
    padding: 36px 8px;
    color: #707070;
    font-size: 1.40625rem;
    font-weight: 400;
    line-height: 1.8;
    text-align: center;
    word-break: keep-all;
    overflow-wrap: anywhere;
}
.main-cont .left ul li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 2px;
    transition: color 0.15s;
    width: 100%;
}
.main-cont .left ul li a:hover p {
    color: #3cc3a2;
}
.main-cont .left ul li a p {
    flex: 1;
    font-size: 1rem;
    color: #333333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    width: calc(100% - 100px);
    min-width: 0;   /* ← 이 한 줄이 핵심 */
}
.main-cont .left ul li a span {
    display: inline-block;
    flex: 0 0 100px;
    width: 100px;
    white-space: nowrap;
    text-align: right;
    font-variant-numeric: tabular-nums;
    font-size: 1rem;
    color: #aeaeae;
}

/* 중간 - 내 주변 산림정보 */
.main-cont .mid {
    background: #ffedce;
    display: flex;
    flex-direction: column;
    position: relative;
}
.main-cont .mid::before {
    content: '';
    display: block;
    max-width: 244px;
    position: absolute;
    left: 0px;
    bottom: 0px;
    background: url('../images/main/bg01.png') no-repeat top right;
    background-size: cover;
    max-height: 187px;
    width: 60%;
    height: 45%;
}
.main-cont .mid::after {
    content: '';
    display: block;
    max-width: 160px;
    position: absolute;
    right: 0px;
    top: 0px;
    background: url('../images/main/bg02.png') no-repeat top right;
    background-size: cover;
    max-height: 248px;
    width: 45%;
    height: 70%;
}
.main-cont .mid .title h3 {
    color: #c98f1d;
}
.main-cont .mid > p {
    font-size: 1em;
    color: #777777;
    line-height: 1.4;
    margin-top: 15px;
    font-weight: 500;
}
.main-cont .mid .img {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 12px;
    position: relative;
    margin-top: 50px;
}
.main-cont .mid .img img {
    max-width: 180px;
    width: 100%;
    height: auto;
}
.main-cont .mid .view-more {
    align-self: flex-end;
    background: #f7ba50;
}
.main-cont .mid .view-more:hover {
    background: #ebab3d;
}

/* 오른쪽 - API / 자료유통 */
.main-cont .right {
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
    background: transparent;
    box-shadow: none;
}
.main-cont .right .top,
.main-cont .right .btm {
    flex: 1;
    border-radius: 16px;
    padding: 28px;
    display: flex;
    flex-direction: column;
    position: relative;
}
.main-cont .right .top {
    background: #d6e1f2;
    margin-bottom: 16px;
}
.main-cont .right .btm {
    background: #d9f2ec;
}
.main-cont .right .top .title,
.main-cont .right .btm .title {
    margin-bottom: 8px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}
.main-cont .right .top .title h3 {
    color: #1a4fa8;
}
.main-cont .right .btm .title h3 {
    color: #3cc3a2;
}
.main-cont .right .top p,
.main-cont .right .btm p {
    font-size: 1em;
    color: #777777;
    line-height: 1.4;
    margin-top: 4px;
    font-weight: 500;
}
.main-cont .right .top .view-more {
    background: #1d5fa6;
    align-self: flex-end;
}
.main-cont .right .top .view-more:hover {
    background: #294d89;
}
.main-cont .right .btm .view-more {
    background: #3cc3a2;
    align-self: flex-end;
}
.main-cont .right .btm .view-more:hover {
    background: #23b490;
}

/* ============================================================
   관련사이트
============================================================ */
.related {
    margin-bottom: 60px;
}
.related .container {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}
.related h3 {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.6rem;
    font-weight: 400;
    color: #ffffff;
    background: #18a683;
    padding: 0px 30px;
    border-radius: 25px 0px 0px 25px;
    min-width: 270px;
    white-space: nowrap;
    min-height: 90px;
    font-family: 'JejuGothic';
}
.related h3::before {
    content: '';
    display: block;
    width: 27px;
    height: 27px;
    background: url('../images/main/ico_related.png') no-repeat center / contain;
    flex-shrink: 0;
}
.related ul {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-around;
    gap: 12px;
    width:calc(100% - 270px);
    flex-wrap: wrap;
    background: #f4f4f4;
    min-height: 90px;
    border-radius: 0px 25px 25px 0px;
}
.related ul li { 
    width:20%
}
.related ul li a {
    display: flex;
    align-items: center;
    justify-content: center;
}
.related ul li a img {
    width: auto;
}
/* ============================================================
   반응형 - 1500px (PC) 
============================================================ */
@media (max-width:1500px) {
    .main-cont .right .top p, .main-cont .right .btm p {
        font-size:0.85rem;
    }    
}

/* ============================================================
   반응형 - 1150px (small PC)
============================================================ */
@media (max-width: 1150px) {
    .quick-menu .container {
        align-items: flex-start;
        flex-wrap:wrap;
    }
    .quick-menu h2 {
        margin-bottom:20px;
        width:100%;
        height:auto;
        padding:15px;
    }
    .quick-menu h2 br {
        display:none;
    }
    .quick-menu ul {
        width:100%;
        min-
    }
    .related {
        
    }
    .related h3 {
        width:100%;
        min-height:auto;
        padding:15px;
        justify-content: center;
        border-radius: 0px;
        flex-shrink: unset;
        font-size: 1.1rem;
    }
    .related h3::before {
        width:17px;
    }
    .related ul {
        width:100%;
        flex: auto;
        border-radius: 0px;
    }
    .main-cont .more-wrap {
        width:72px;
        height:68px;
        background-size:100%;
    }
}


/* ============================================================
   반응형 - 1024px (태블릿)
============================================================ */
@media (max-width: 1024px) {
    .main-visual {
        min-height: 320px;
    }
    .main-visual .tit p,
    .main-visual .tit p.white,
    .main-visual .tit p b {
        font-size: 2rem;
    }
    .main-cont .container {
        grid-template-columns: 1fr 1fr;
    }
    .main-cont .right {
        grid-column: 1 / -1;
        flex-direction: row;
    }
    .main-cont .right .top {
        margin-bottom: 0;
        margin-right: 16px;
    }
    .quick-menu ul li {
        justify-content: center;
        width:20%;
    }
    .related .container {
        flex-wrap: wrap;
    }
}

/* ============================================================
   반응형 - 768px (모바일)
============================================================ */
@media (max-width: 768px) {
    .main-visual {
        min-height: 260px;
    }
    .main-visual .container {
        padding-top: 40px;
        padding-bottom: 50px;
    }
    .main-visual .tit p,
    .main-visual .tit p.white {
        font-size: 1.5rem;
    }
    .main-visual .tit p b {
        font-size: 1.5rem;
    }
    .main-visual .tit .sub-tit {
        font-size: 0.875rem;
    }
    .main-search {
        width: 100%;
        max-width: 100%;
    }
    .main-search input {
        height: 50px;
    }
    .btn-main-search {
        width: 46px;
        height: 46px;
    }

    /* 퀵메뉴 */
    .quick-menu {
        padding: 0;
    }
    .quick-menu::after {
        display: none;
    }
    .quick-menu .container {
        flex-direction: column;
        padding:15px;
    }
    .quick-menu h2 {
        width: 100%;
        padding: 14px 20px;
        flex-direction: row;
        justify-content: flex-start;
        gap: 10px;
        font-size: 1rem;
        border-radius: 0;
        min-height: auto;
    }
    .quick-menu h2::after {
        display: none;
    }
    .quick-menu ul li a::before {
        width: 52px;
        height: 52px;
    }
    .quick-menu ul li a span {
        font-size: 0.75rem;
        white-space: nowrap;
    }

    /* 메인 컨텐츠 */
    .main-cont {
        padding: 30px 0 24px;
    }
    .main-cont .container {
        grid-template-columns: 1fr;
    }
    .main-cont .left,
    .main-cont .mid,
    .main-cont .right {
        border-radius: 20px;
    }
    .main-cont .left,
    .main-cont .mid{
        
        padding:20px;
    }
    .main-cont .right {
        flex-direction: column;
        grid-column: auto;
    }
    .main-cont .right .top {
        margin-right: 0;
        margin-bottom: 16px;
    }

    /* 관련사이트 */
    .related {
        margin-bottom: 30px;
    }
    .related .container {
        flex-direction: column;
    }
    .related h3 {
        width: 100%;
        border-radius: 20px 20px 0 0;
        min-width: auto;
        padding: 16px 20px;
        min-height: auto;
    }
    .related ul {
        width: 100%;
        border-radius: 0 0 20px 20px;
        padding: 16px 12px;
        justify-content: space-around;
        gap: 8px;
    }
    .related ul li {
        width:calc(50% - 40px);
    }
    .related ul li a img {
        max-width: 200px;
        width: 100%;
    }
}

/* ============================================================
   반응형 - 640px (모바일)
============================================================ */
@media (max-width:640px) {
    
    .quick-menu ul li {
        width:33.333333%;
        margin-bottom:10px;
        justify-content: flex-start;
    }
    .quick-menu ul li a {
        flex-direction: row;
    }
    .quick-menu ul li a span {
        display:block;
        text-align: left;
    }
    .quick-menu ul li a::before {
        background-size:30px !important;
    }
    
}

/* ============================================================
   반응형 - 480px (소형 모바일)
============================================================ */
@media (max-width: 480px) {
    .main-visual .tit p,
    .main-visual .tit p.white,
    .main-visual .tit p b {
        font-size: 1.25rem;
    }
    .main-visual .tit .sub-tit {
        font-size: 0.813rem;
    }
    .main-search input {
        font-size: 0.875rem;
    }
    .quick-menu ul li {
        width:50%;
    }
    .quick-menu ul li a::before {
        width: 44px;
        height: 44px;
    }
    .quick-menu ul li a span {
        font-size: 0.8rem;
    }
    .main-cont .title h3 {
        font-size: 1.2rem;
    }
    .main-cont .left ul li a {
        display:block;
    }
    .main-cont .left ul li a p {
        font-size: 0.975rem;
        width:100%;
        font-weight:500;
    }
    .main-cont .left ul li a span {
        font-size: 0.813rem;
        text-align: left;
    }
    .main-search input {
        width:150px;
    }
    .related ul li {
        width:100%;
    }
    .related ul li a img {
        max-width:150px;
    }
    .main-cont .view-more {
        width:35px;
        height:35px;
    }
}
@media (max-width:360px) {
    .main-search::before {
        display:none;
    }
    .quick-menu ul {
        margin-bottom:20px;
    }
    .quick-menu ul li {
        width:33.333%;
        margin:0;
        
    }
    .quick-menu ul li a {
        align-items: center;
        text-align: center;
        width:100%;
        flex-direction: column;
    }
    .quick-menu ul li a span {
        text-align: center;
    }
}
