/* list  */
.portfolio-list > picture {margin-bottom: 100px; text-align: center;}
.portfolio-list > picture img {width: 100%; max-width: 1920px;}
.portfolio-list .filter-area {max-width: 830px; margin: 0 auto 80px;}
.portfolio-list .filter-area h2 {font-family: "Paperlogy"; font-size: 40px; font-weight: 500; color: #000; margin-bottom: 80px; text-align: center;}
.portfolio-list .filter-area .search-wrap .search-bar {display: flex; gap: 0 14px; align-items: center; margin-bottom: 45px;}
.portfolio-list .filter-area .search-wrap .search-bar input {flex: 1 1 0; min-width: 0; padding: 0 25px; border: 1px solid #3a9286; border-radius: 24px; line-height: 46px; font-size: 16px; font-weight: 500; color: #222; outline: none;}
.portfolio-list .filter-area .search-wrap .search-bar input::placeholder {color: #9d9d9d;}
.portfolio-list .filter-area .search-wrap .search-bar button {background: url('/work/img/btn_search.svg') no-repeat center; width: 48px; height: 48px;}
.portfolio-list .filter-area > ul {display: flex; gap: 0 8px; margin-bottom: 20px;}
.portfolio-list .filter-area > ul li {flex: 1; border-radius: 24px; transition: background-color .2s ease; background-repeat: no-repeat; background-position: left 12px center;}
.portfolio-list .filter-area > ul li:nth-child(1) {background-image: url('/work/img/ico_public.svg');}
.portfolio-list .filter-area > ul li:nth-child(2) {background-image: url('/work/img/ico_school.svg');}
.portfolio-list .filter-area > ul li:nth-child(3) {background-image: url('/work/img/ico_commercial.svg');}
.portfolio-list .filter-area > ul li:nth-child(4) {background-image: url('/work/img/ico_partial.svg');}
.portfolio-list .filter-area > ul li:nth-child(5) {background-image: url('/work/img/ico_board.svg');}
.portfolio-list .filter-area > ul li button {width: 100%; border: 1px solid #3a9286; padding: 0 12px 0 40px; text-align: left; border-radius: 24px; font-size: 16px; font-weight: 600; line-height: 46px; color: #3a9286; background: url('/work/img/btn_arrow_green.svg') no-repeat right 20px center;}
.portfolio-list .filter-area > ul li:has(button.active) {background-color: #E9F7F5;}
.portfolio-list .filter-area .filter-box {margin-bottom: 20px; padding: 17px 22px; border: 1px solid #3a9286; border-radius: 8px;}
.portfolio-list .filter-area .filter-box ul {display: none; flex-wrap: wrap; justify-content: center; gap: 12px 8px; }
.portfolio-list .filter-area .filter-box ul.active {display: flex;}
.portfolio-list .filter-area .filter-box ul li a {display: block; border: 1px solid #eee; border-radius: 20px; padding: 0 24px; font-size: 16px; font-weight: 500; line-height: 38px; color: #9d9d9d; text-align: center; transition: color .2s ease, border-color .2s ease;}
.portfolio-list .filter-area .filter-box ul li a.active {color: #3a9286; font-weight: 700; border-color: #75b3aa;}
.portfolio-list .filter-area .selected-filter-list {display: flex; flex-wrap: wrap; gap: 8px;}
.portfolio-list .filter-area .selected-filter-list li {display: flex; align-items: center; padding: 0 24px; font-size: 16px; font-weight: 500; color: #444; line-height: 40px; background-color: #eee; border-radius: 20px;}
.portfolio-list .filter-area .selected-filter-list button {position: relative; width: 1px; height: 14px; margin-left: 14px;}
.portfolio-list .filter-area .selected-filter-list button::before,
.portfolio-list .filter-area .selected-filter-list button::after {position: absolute; top: 0; content: ''; width: 100%; height: 100%; background-color: #000;}
.portfolio-list .filter-area .selected-filter-list button::before {transform: rotateZ(45deg); left: 0;}
.portfolio-list .filter-area .selected-filter-list button::after {transform: rotateZ(-45deg); right: 0;}
.portfolio-list .portfolio-gall .gall-btn-wrap {display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px;}
.portfolio-list .portfolio-gall .gall-btn-wrap #gall_allchk label {display: flex; align-items: center; gap: 0 5px; cursor: pointer;}
.portfolio-list .portfolio-gall .gall-btn-wrap .gall-btn-box {display: flex; gap: 0 10px;}
.portfolio-list .portfolio-gall .gall-btn-wrap .gall-btn-box * {font-family: inherit; display: block; background-color: #222; color: #fff; padding: 0 20px; line-height: 40px; border-radius: 5px; font-size: 14px; font-weight: 400;}
.portfolio-list .portfolio-gall {max-width: 1360px; margin: 0 auto; padding: 0 15px;}
.portfolio-list .portfolio-gall #gall_ul {display: grid; grid-template-columns: repeat(auto-fill, minmax(256px, 1fr)); gap: 78px 12.5px; margin: 0 auto 220px;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box {display: flex; flex-direction: column; gap: 10px 0;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con .gall_img {margin-bottom: 15px;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con .gall_img a {display: flex; justify-content: center; overflow: hidden;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con .gall_img a img {height: 300px; flex: 1;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con h3 {font-size: 18px; font-weight: 600; color: #222; margin-bottom: 7px;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con > ul {display: flex; flex-wrap: wrap; gap: 5px;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con > ul li:not(:first-child)::before {content: ''; margin-right: 5px; width: 1px; height: 14px; background-color: #777;}
.portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con > ul li {display: flex; align-items: center; font-size: 15px; font-weight: 300; color: #777; line-height: 16px;}
.portfolio-list .portfolio-gall .pg_wrap {margin-bottom: 390px;}
html:has(.modal-wrap.active) {overflow-y: hidden;}
.portfolio-list .modal-wrap {display: none; position: fixed; z-index: 101; width: 100%; height: 100%; left: 0; top: 0;}
.portfolio-list .modal-wrap .modal-dim {position: absolute; width: 100%; height: 100%; left: 0; top: 0; background-color: rgba(17, 17, 17, 0.8);}
.portfolio-list .modal-wrap .modal-box {position: absolute; width: 100%; max-width: 1280px; height: 100%; max-height: calc(100vh - 100px); left: 50%; top: 50px; transform: translateX(-50%); overflow-y: auto; background-color: #fff; padding: 40px 45px 90px;}
.portfolio-list .modal-wrap .modal-box::-webkit-scrollbar {display: none;}
.portfolio-list .modal-wrap .modal-box h3 {font-size: 34px; font-weight: 700; color: #000; margin-bottom: 15px; text-align: center; line-height: 44px;}
.portfolio-list .modal-wrap .modal-box > ul {display: flex; flex-wrap: wrap; justify-content: center; gap: 5px; margin-bottom: 60px;}
.portfolio-list .modal-wrap .modal-box > ul li {display: flex; align-items: center; font-size: 13px; font-weight: 600; color: #b6b6b6;}
.portfolio-list .modal-wrap .modal-box > ul li:not(:first-child)::before {content: ''; margin-right: 5px; width: 1px; height: 14px; background-color: #b6b6b6;}
.portfolio-list .modal-wrap .modal-box .modal-close {position: absolute; top: 40px; right: 45px;}
.portfolio-list .modal-wrap .modal-box .modal-body p {text-align: center;}
.portfolio-list .modal-wrap .modal-box .modal-body p:not(:last-of-type) {margin-bottom: 50px;}
.portfolio-list .modal-wrap .modal-box .modal-body p img {max-width: 100%;}

/* write */
.portfolio-write {max-width: 1400px; margin: 0 auto; padding: 100px 0;}
.portfolio-write .filter-wrap h2 {font-size: 18px; font-weight: 500; text-align: center; margin-bottom: 15px; color: #222;}
.portfolio-write .filter-wrap > p {font-size: 16px; font-weight: 400; text-align: center; margin-bottom: 15px; color: #4b4b49;}
.portfolio-write .filter-wrap .filter-list {margin-bottom: 20px; padding: 0 10px;}
.portfolio-write .filter-wrap .filter-list strong {display: block; font-size: 16px; font-weight: 500; margin-bottom: 10px; color: #167343;}
.portfolio-write .filter-wrap .filter-list ul {display: flex; flex-wrap: wrap; gap: 10px;}
.portfolio-write .image-drop-zone {border: 2px dashed #aaa; padding: 50px 20px; text-align: center; margin-bottom: 20px; cursor: pointer;}
.portfolio-write .image-drop-zone.dragover {border-color: #333;background: #f5f5f5;}
.portfolio-write .image-list {display: flex; gap: 0 20px; padding: 0 15px;}
.portfolio-write .image-list .image-item .remove-btn {position: absolute; top: 0; right: 0; background-color: rgba(0,0,0,.6); color: #fff; border: none; font-size: 15px; width: 20px; height: 20px; cursor: pointer;}
/* 드래그 시 body 직계로 인식 되기 때문에 선택자 가두지 않음 */
.image-item {border: 1px solid #ddd; position: relative; width: 100px; height: 100px; overflow: hidden;}
.image-item img {width: 100%; height: 100%; object-fit: cover; display: block;}

@media screen and (max-width: 1024px){
    /* list */
    .portfolio-list .filter-area,
    .portfolio-list .portfolio-gall {padding: 0 20px;}
    .portfolio-list .filter-area {margin-bottom: 60px;}
    .portfolio-list .filter-area h2 {font-weight: 600; margin-bottom: 50px;}
    .portfolio-list .filter-area .search-wrap .search-bar {margin-bottom: 5px;}
    .portfolio-list .filter-area > ul {padding: 0; margin-bottom: 10px; gap: 0 5px; align-items: flex-start; justify-content: space-between;}
    .portfolio-list .filter-area > ul li {background-position: center top 15px;}
    .portfolio-list .filter-area > ul li button {padding: 45px 15px 40px; background-position: center bottom 15px; line-height: 18px; text-align: center;}
    .portfolio-list .filter-area > ul li:last-child button {padding: 45px 8px 40px;}
    .portfolio-list .filter-area .filter-box {margin-bottom: 8px;}
    .portfolio-list .portfolio-gall .gall-btn-wrap {flex-wrap: wrap; gap: 10px;}
    .portfolio-list .portfolio-gall #gall_ul {grid-template-columns: repeat(auto-fit, minmax(156px, 1fr)); gap: 48px 8px; margin-bottom: 100px;}
    .portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con .gall_img a img {height: 182px;}
    .portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con h3 {font-size: 15px; font-weight: 500; line-height: 22px;}
    .portfolio-list .portfolio-gall #gall_ul > li .gall_box .gall_con > ul li {font-size: 12px;}
    .portfolio-list .portfolio-gall .pg_wrap {margin-bottom: 100px;}
    .portfolio-list .modal-wrap .modal-box .modal-close {top: 20px; right: 25px;}
    .portfolio-list .modal-wrap .modal-box .modal-close img {max-width: 20px;}
}