@media (min-width: 2000px){
  /* 필요하면 여기 */
}

@media all and (max-width: 812px) and (orientation:portrait){

  .pc-only{ display:none !important; }
  .gs-nav { display: none; }
  /* 섹션1: 프로젝트명 칸 없음 */
  #currentProject{ display:none !important; }
  #aptMenu{
    display:flex;
    gap: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
    scrollbar-width: none;
  }
  #aptMenu::-webkit-scrollbar{ display:none; }

  #aptMenu .apt-btn{
    flex: 0 0 auto;
  }
  /* 모바일은 스와이프만 */
  .hero-nav{ display:none !important; }
  /* HERO: mobile = 1 slide per view (width 강제) */
    #heroSwiper .swiper-slide {
        width: 100% !important;
        display: flex;
        justify-content: center;
    }
  #heroSwiper .swiper-wrapper { align-items: stretch; }
  #heroSwiper { width: 100%; }
  /* WORKS 인덱스: hover/썸네일 없음 */
  .works-thumb{ display:none !important; }

  .work-row{
    grid-template-columns: 1fr 1fr 40px;
  }
  .work-row .c3{ display:none !important; }
    .work-row .c3m {
        display: block !important;
        text-align: right;
    }


/* row + accordion wrapper */
.work-row-wrap{
  display: block; 
}

  /* 모바일 아코디언 */
  .work-row.is-dim{ color:#AAAAAA; }
  .work-row.is-open{ color:#000; }



.work-accordion.is-open{
  display:block;
}

  /* 패널 컬럼: 모바일에서는 쓰지 않음(권장) */
  .works-inner{ display:block; }
  .works-panel{ display:none !important; }

  /* 모바일 이미지 슬라이드 pagination */
  .m-images{ position: relative; margin-top: 14px; }
  .m-img-pagination{
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 6px 10px;
    font-size: 14px;
    line-height: 1;
    background: rgb(194 194 194 / 35%);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2;
            color: #000;
  }

  .m-img-swiper img{
    width: 100%;
    height: auto;
    display: block;
  }

  #contactPanel{
    left: 0;
    right: 0;
    width: auto;

    top: auto !important;
    bottom: 0;
    height: 75vh;
    transform: translateY(105%);
    transition: transform 280ms cubic-bezier(.2,.85,.2,1);
  }

    #contactPanel.is-open {
        transform: translateY(0);
        z-index: 999999;
    }

.contact-dim {
    z-index: 999999;
}

  .m-img-current, .m-img-total {
    font-size: 14px;
  }


  /* 텍스트 모음: 슬라이드 X, 세로 스택 */
  .m-texts .m-text{ margin-top: 24px; }
.m-texts .m-text p {
    margin-bottom: 24px;
    font-size: 15px;
    /* line-height: inherit; */
    line-height: 1.45;
    word-break: keep-all;
}

  /* 모바일: 헤더 메뉴는 항상 전체 노출(hover 없음) */
  body.menu-mobile .apt-btn.is-dim .label{ opacity: .25; } /* 필요하면 */

/* ===== FORCE SHOW MOBILE ACCORDION (KEEP LAST) ===== */
    #worksSection .work-accordion {
        display: block !important;
        height: 70vh;
        margin-top: 0;
        overflow: hidden;
        background: #fff;
        border-top: none;
                margin-bottom: 24px;
    }

#worksSection .work-accordion .work-accordion-inner{
  display: block !important;
  height: 100%;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 12px 0;
}

.work-panel-body {
    padding: 0;
}

.work-panel-top {
    display: none;
}

/* 모바일: 이미지 1장씩 스와이프 */
.m-img-swiper{
  width: 100%;
  overflow: hidden;
  position: relative;
 touch-action: pan-y;      /* 세로 스크롤 허용, 가로는 JS가 처리 */
  overscroll-behavior: contain;
}

.m-img-track{
  display: flex;
  width: 100%;
  transform: translate3d(0,0,0);
}

.m-img-slide{
  flex: 0 0 100%;
}

.m-img-slide img{
  width: 100%;
  height: auto;
  display: block;
}

.info {
    display: flex;
    grid-template-columns: repeat(14, minmax(0, 1fr));
    gap: 24px;
    flex-direction: column;
        padding-bottom: 72px;
}

/* 모바일: aptHeader는 기존 패딩 유지 (텍스트/버튼 정렬용) */
#aptHeader{
  padding-left: var(--apt-pad);
  padding-right: var(--apt-pad);
  width: 100%;
}

/* ✅ 스크롤 영역은 패딩을 상쇄해서 '끝까지 넘치게' */
#aptMenu{
  display:flex;
  gap: 10px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  white-space: nowrap;
  scrollbar-width: none;

  /* 핵심 */
  margin-left: calc(var(--apt-pad) * -1);
  margin-right: calc(var(--apt-pad) * -1);
  padding-left: var(--apt-pad);
  padding-right: var(--apt-pad);
}
#aptMenu::-webkit-scrollbar{ display:none; }

#aptMenu .apt-btn{ flex: 0 0 auto; }

.apt-header {
    left: unset;
    right: unset;
}

.lang-toggle {
    color: #000 !important;
}

#aptHeader[data-mode="works"] #aptMenu.is-collapsed .apt-btn:not([data-key="studio"]):not([data-key="works"]), #aptHeader[data-mode="information"] #aptMenu.is-collapsed .apt-btn:not([data-key="studio"]):not([data-key="information"]) {
    opacity: 1;
    pointer-events: auto;
}

/* 버튼 상태가 레이아웃에 영향 못 주게 */
#aptMenu .apt-btn{
  margin-top: 0 !important;
  margin-bottom: 0 !important;

  transform: none !important;
  letter-spacing: normal !important;

  border: 1px solid transparent !important;
  box-sizing: border-box;
}

/* ✅ 끝 여백은 버튼 margin보다 "컨테이너 padding"이 안정적 */
#aptMenu{
  padding-right: var(--apt-pad, 24px) !important;
  padding-left: 0 !important;
}

/* 첫 버튼만 왼쪽 숨 */
#aptMenu .apt-btn:first-child{
  margin-left: var(--apt-pad, 12px) !important;
}

/* last-child margin-right는 빼도 됨(컨테이너 padding-right가 담당) */
#aptMenu .apt-btn:last-child{
  margin-right: 0 !important;
}

  /* 1) 모바일에서 헤더 transform 때문에 lang 버튼이 같이 사라지는 케이스 차단 */
  #aptHeader{
    transform: none !important;
  }

  /* 2) pc-only라도 언어 버튼은 모바일에서 무조건 보이게 */
  #aptLangBtn,
  #aptLangBtn[hidden]{
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

    .contact-open button#aptLangBtn {
        /* position: fixed !important; */
        /* top: 12px; */
        /* right: 12px; */
        /* z-index: 9999999 !important; */
        /* bottom: unset !important; */
        display: none !important;
    }
  /* 4) 혹시 헤더/메뉴가 overflow로 잘라먹으면 같이 풀어줌 */
  #aptHeader,
  #aptMenu{
    overflow: auto !important;
            z-index: 9999999;
  }

.intro-text p {
    line-height: 1.4;
    word-break: keep-all;
    width: 85%;
}
    button#aptLangBtn {
        right: 12px;
        position: fixed;
        top: 12px;
        bottom: unset;
        display: none !important;
    }
    
.contact-copy p:nth-child(1) {
    width: 85%;
}
.contact-open .apt-header {
    position: fixed;
    left: 0;
    right: 12px;
    bottom: 12px;
    z-index: 9999;
    width: 50%;
    display: flex;
}

button.m-lang-toggle {
    position: absolute;
    right: 12px;
    padding: 6px 10px;
    font-size: 14px;
    line-height: 1;
    background: rgb(194 194 194 / 15%);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 999999;
    border: none;
        color: #000 !important;
}

.contact-email-text {
    color: #000 !important;
}

    body.contact-open button.m-lang-toggle {
        right: 12px;
        padding: 6px 10px;
        font-size: 14px;
        line-height: 1;
        background: rgb(194 194 194 / 15%);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        z-index: 999999;
        border: none;
        top: 12px;
        position: fixed;
    }

  html.lang-kr [data-apt-lang="en"] { display: none !important; }
  html.lang-kr [data-apt-lang="kr"] { display: block !important; }

  html.lang-en [data-apt-lang="kr"] { display: none !important; }
  html.lang-en [data-apt-lang="en"] { display: block !important; }
#contactLangBtn.is-visible {
    opacity: 1;
    bottom: unset;
    position: fixed;
    right: 12px;
    top: 12px;
}
  
  /* 인포메이션 페이지만 보이게 (아래 셀렉터 중 네 구조에 맞는 걸 쓰면 됨) */
  body.template-information #aptLangBtn,
  body.information #aptLangBtn,
  main#information ~ * #aptLangBtn { display: inline-flex !important; } /* 이 줄은 구조 따라 안 먹을 수 있음 */

#worksSection {
    padding-bottom: 20vw;
}

  body.template-information.contact-open #aptLangBtn,
  body.information.contact-open #aptLangBtn { display: none !important; } /* 이 줄은 구조 따라 안 먹을 수 있음 */

  .hero-slide img, .hero-slide video, .hero-media {
    width: auto !important;
    height: 100% !important;
    max-width: none !important;
    display: block;
    object-fit: cover;
    display: flex;
    justify-content: center;
    object-position: center;
}

.studio-top-text {
    display: none; 
}

.studio-top-text.mver {
    display: block; 
}

  #heroSwiper .swiper-wrapper {
    width: 100%;
  }

  /* ✅ slidesPerView:1 이더라도, slide width가 auto면 삐져나옴 방지 */
  #heroSwiper .swiper-slide {
    width: 100% !important;
    flex: 0 0 100% !important;
  }

  /* 이미지/비디오가 들어가는 컨테이너가 있으면 그게 기준 */
  #heroSwiper .hero-slide {
    width: 100%;
    overflow: hidden; /* 잘리는 영역 정리 */
  }

  #heroSwiper .hero-slide img,
  #heroSwiper .hero-slide video {
    width: 100%;
    height: 100%;
    display: block;

    object-fit: cover;
    object-position: 50% 50%; /* ✅ center center 강제 */
  }



}


