/* 스튜디오엑스 홈페이지 공통 스타일 (Wix 사이트를 정적 HTML로 옮긴 것) */
:root {
  --bg: #000;
  --text: #bfbfbf;
  --text-dim: #959595;
  --white: #fff;
  --yellow: #f0c400;
  --pink: #ff7fe8;
  --footer: #7a7a7a;
  /* 10/13 대표: 브랜드 글꼴 — 영문 Montserrat, 한글 나눔스퀘어 네오 (/assets/brand/brand.css) */
  --font-en: 'Montserrat', 'NanumSquareNeo', 'Malgun Gothic', '맑은 고딕', 'Apple SD Gothic Neo', sans-serif;
  --font-ko: 'Montserrat', 'NanumSquareNeo', 'Malgun Gothic', '맑은 고딕', 'Apple SD Gothic Neo', sans-serif;
  --header-h: 120px;
  /* Wix 원본: We Are X 큰 문구·Contact 안내 문구 = American Typewriter (한글은 기본 명조로 보임) */
  --font-type: 'American Typewriter', serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-en);
  font-size: 15px;
  line-height: 1.6;
}
a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Header ---------- */
.site-header {
  position: relative;
  z-index: 20;
  height: var(--header-h);
  display: flex;
  justify-content: center;
}
.site-header .inner {
  width: 100%;
  max-width: 980px;
  position: relative;
  padding: 0 16px;
}
.main-nav {
  display: flex;
  justify-content: center;
  gap: 0;
  padding-top: 58px;
  padding-right: 60px;
}
.main-nav a {
  font-family: 'Montserrat', sans-serif;
  font-size: 20px;
  line-height: 1;
  letter-spacing: 0.5em;
  color: var(--white);
  text-decoration: none;
  white-space: nowrap;
  padding: 4px 0;
  margin: 0 49px;
  transition: color .2s;
}
.main-nav a b { font-weight: 700; }
/* 메뉴가 5개 이상이면 PC에서 간격·자간을 줄이고, 그래도 넘치면 두 줄로 */
.main-nav.many { flex-wrap: wrap; row-gap: 14px; }
.main-nav.many a { margin: 0 22px; letter-spacing: .35em; }
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--yellow); }
.header-logo {
  position: absolute;
  right: 4px;
  top: 30px;
  width: 42px;
}
.header-logo img { width: 42px; height: 42px; }
.menu-btn {
  position: absolute;
  right: 4px;
  top: 80px;
  width: 42px;
  height: 30px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.menu-btn span {
  display: block;
  height: 3px;
  background: var(--yellow);
  margin: 0 3px 8px;
}
.menu-btn span:last-child { margin-bottom: 0; }

/* ---------- Menu popup (햄버거 메뉴) ---------- */
.menu-popup {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, .92);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity .25s, visibility .25s;
}
.menu-popup.open { opacity: 1; visibility: visible; }
.menu-popup ul { list-style: none; margin: 0; padding: 0; text-align: center; }
.menu-popup li a {
  display: block;
  padding: 14px 24px;
  font-size: 26px;
  letter-spacing: .3em;
  color: var(--white);
  text-decoration: none;
}
.menu-popup li a:hover, .menu-popup li a[aria-current="page"] { color: var(--yellow); }
.menu-close {
  position: absolute;
  top: 28px;
  right: 28px;
  width: 44px;
  height: 44px;
  border: 0;
  background: none;
  color: var(--white);
  font-size: 40px;
  line-height: 1;
  cursor: pointer;
}

/* ---------- Footer ---------- */
.site-footer {
  text-align: center;
  font-size: 15px;
  line-height: 1.6;
  color: var(--footer);
  padding: 22px 16px 40px;
}
.site-footer p { margin: 0; }

/* ---------- Home ---------- */
.page-home .site-header { position: absolute; top: 0; left: 0; right: 0; }
.hero {
  position: relative;
  height: max(560px, 55vw);
  max-height: 100vh;
  background: #0b1018 url(../img/hero-bg.jpg) center / cover no-repeat;
}
.hero-insta {
  position: absolute;
  top: 166px;
  right: calc(50% - 490px + 10px);
  width: 30px;
}
.hero-insta img { width: 30px; height: 30px; }

/* ---------- About (We Are X) ---------- */
.about {
  max-width: 980px;
  margin: 0 auto;
  padding: 80px 16px 0;
  text-align: center;
}
.about-lead {
  font-family: var(--font-type);
  font-weight: 400;
  font-size: 44px;
  line-height: 1.5;
  color: var(--text);
  margin: 0 0 70px;
}
.client-title {
  font-size: 29px;
  color: var(--white);
  margin: 0 0 18px;
  font-weight: 400;
}
.client-types {
  display: inline-block;
  text-align: left;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  margin: 0 0 40px;
  padding: 0;
  list-style: none;
}
/* 로고 너비(px)는 관리 화면에서 정함. 602px 줄에 원본처럼 5개씩 들어감 */
.client-logos {
  width: 100%;
  max-width: 602px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 11px 11px;
}
.client-logos img {
  max-width: calc(33% - 8px);
  height: auto;
}
.client-names {
  max-width: 602px;
  margin: 18px auto 0;
  text-align: left;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
}
.client-names p { margin: 0; }
.client-names .ad { color: #6fa8d6; }

/* ---------- Project ---------- */
.projects { padding: 0 0 40px; }
.project {
  margin: 0;
}
.project h2 {
  font-size: 20px;
  font-weight: 400;
  line-height: 1.35;
  color: var(--white);
  margin: 0 0 14px;
  padding: 0 12px;
  min-height: 2.7em;
}
.project-featured {
  max-width: 474px;
  margin: 0 auto 50px;
}
.project-featured h2 { padding: 0; min-height: 0; }
.project-grid {
  /* 영상 3칸, 칸 너비 최대 474px. 화면이 넓어져도 벌어지지 않고 가운데 모임 */
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 474px));
  justify-content: center;
  gap: 56px 40px;
  padding: 0 24px;
}
.yt {
  position: relative;
  width: 100%;
  max-width: 474px;
  aspect-ratio: 16 / 9;
  background: #111 center / cover no-repeat;
  border: 0;
  padding: 0;
  cursor: pointer;
  display: block;
}
.yt::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 68px;
  height: 48px;
  transform: translate(-50%, -50%);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 68 48'%3E%3Cpath d='M66.5 7.7c-.8-2.9-3-5.2-5.9-6C55.3.3 34 .3 34 .3S12.7.3 7.4 1.7c-2.9.8-5.1 3.1-5.9 6C.1 13 .1 24 .1 24s0 11 1.4 16.3c.8 2.9 3 5.2 5.9 6C12.7 47.7 34 47.7 34 47.7s21.3 0 26.6-1.4c2.9-.8 5.1-3.1 5.9-6C67.9 35 67.9 24 67.9 24s0-11-1.4-16.3z' fill='%23212121' fill-opacity='.8'/%3E%3Cpath d='M45 24 27 14v20z' fill='%23fff'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: opacity .2s;
}
.yt:hover::after {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 68 48'%3E%3Cpath d='M66.5 7.7c-.8-2.9-3-5.2-5.9-6C55.3.3 34 .3 34 .3S12.7.3 7.4 1.7c-2.9.8-5.1 3.1-5.9 6C.1 13 .1 24 .1 24s0 11 1.4 16.3c.8 2.9 3 5.2 5.9 6C12.7 47.7 34 47.7 34 47.7s21.3 0 26.6-1.4c2.9-.8 5.1-3.1 5.9-6C67.9 35 67.9 24 67.9 24s0-11-1.4-16.3z' fill='%23f00'/%3E%3Cpath d='M45 24 27 14v20z' fill='%23fff'/%3E%3C/svg%3E");
}
.yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.yt.playing::after { display: none; }
.project-grid h2 { padding: 0; }

/* 공개 시기 탭 (2026 하반기 / 2026 상반기 …) */
.period-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 34px;
  margin: 0 auto 46px;
  padding: 0 16px;
}
.period-tabs button {
  font-family: 'Montserrat', 'NanumSquareNeo', 'Malgun Gothic', '맑은 고딕', 'Apple SD Gothic Neo', sans-serif;
  font-size: 15px;
  letter-spacing: .12em;
  color: var(--text-dim);
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 6px 2px;
  cursor: pointer;
}
.period-tabs button:hover { color: var(--white); }
.period-tabs button[aria-selected="true"] { color: var(--white); border-bottom-color: var(--yellow); }
.period-tabs button:focus-visible { outline: 2px solid var(--yellow); outline-offset: 3px; }
.js-tabs .period[hidden] { display: none; }
.period + .period { margin-top: 70px; }
.js-tabs .period + .period { margin-top: 0; }

.project-desc {
  max-width: 474px;
  margin: 12px 0 0;
  padding: 0 12px;
  font-family: var(--font-ko);
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-dim);
}
.project-featured .project-desc { padding: 0; }
.project-grid .project:nth-child(3n+2) .project-desc { margin-left: auto; margin-right: auto; }
.project-grid .project:nth-child(3n) .project-desc { margin-left: auto; margin-right: 0; }

/* ---------- Studio ---------- */
.studio-index {
  width: fit-content;
  max-width: 100%;
  margin: 0 auto;
  padding: 0 16px 30px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
/* 한 줄 = 왼쪽 큰 버튼(스튜디오, 너비 고정) + 동 버튼들 → 줄마다 동 버튼이 같은 자리에서 시작. 묶음 전체는 가운데 */
.studio-row { display: flex; flex-wrap: wrap; gap: 4px 6px; }
.studio-row .studio-btn.main { flex: 0 0 150px; justify-content: flex-start; }
/* 상자 없이 글자만 (10/14 대표: 위 메뉴보다 작게, 사각박스 필요없음) */
.studio-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  padding: 4px 8px;
  white-space: nowrap;
  font-family: var(--font-ko);
  font-size: 14px;
  line-height: 1.4;
  color: var(--white);
  text-decoration: none;
  transition: color .2s;
}
.studio-btn.main { font-weight: 600; letter-spacing: .03em; }
.studio-btn:hover, .studio-btn:focus-visible { color: var(--yellow); outline: 0; }
.studio-divider {
  max-width: 1300px;
  margin: 0 auto;
  border: 0;
  border-top: 1px solid var(--pink);
  opacity: .7;
}
.studio-room {
  text-align: center;
  padding: 26px 16px 22px;
  border-bottom: 2px solid var(--white);
  scroll-margin-top: 10px;
}
.studio-room:last-of-type { border-bottom: 0; }
.studio-room h2 {
  display: inline-block;
  margin: 0 0 34px;
  padding: 0 4px 8px;
  border-bottom: 1px solid var(--pink);
  font-family: var(--font-ko);
  font-size: 20px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: .45em;
  color: var(--white);
}
/* 스튜디오 사진 넘겨보기: 사진을 한 칸에 겹쳐 두고 한 장만 보임 (높이 = 가장 큰 사진, 넘길 때 아래 글이 안 흔들림) */
.studio-slider { position: relative; width: 600px; max-width: 100%; margin: 0 auto 26px; }
.studio-slider .slides { display: grid; }
.studio-photo { margin: 0 auto 26px; width: 600px; max-width: 100%; }   /* 직접 만든 페이지(옛 형식) 사진 */
.studio-slider .studio-photo {
  grid-area: 1 / 1;
  align-self: start;
  width: auto;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity .35s, visibility .35s;
}
.studio-slider .studio-photo.active { opacity: 1; visibility: visible; }
.studio-room img {
  margin: 0 auto;
  width: 600px;
}
/* 여러 장이면 모든 사진을 같은 16:9 틀 안에 (세로 사진은 양옆 검정) → 틀 높이가 늘 같아 빈자리 없음 (10/14) */
.studio-slider.multi img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  background: #000;
  cursor: pointer;
  user-select: none;
  -webkit-user-drag: none;
}
.studio-photo figcaption {
  margin-top: 10px;
  font-family: var(--font-ko);
  font-size: 15px;
  line-height: 1.5;
  letter-spacing: .08em;
  color: var(--white);
}
.slide-btn {
  position: absolute;
  top: 0;
  width: 44px;
  height: 44px;
  margin-top: calc(28.125% - 22px);  /* 넓이 기준 % → 16:9 틀의 정확히 가운데 */
  border: 0;
  border-radius: 50%;
  background: rgba(16, 24, 32, .55);
  color: #fff;
  font-size: 30px;
  line-height: 40px;
  cursor: pointer;
  transition: background .2s;
}
.slide-btn:hover { background: rgba(16, 24, 32, .85); color: var(--yellow); }
.slide-btn:focus-visible { outline: 2px solid var(--yellow); outline-offset: 2px; }
.slide-btn.prev { left: 10px; }
.slide-btn.next { right: 10px; }
.slide-count { margin: 6px 0 0; font-size: 12px; letter-spacing: .1em; color: var(--text-dim); }
.studio-room .geomsan { border: 2px solid #ddd; }
.spec {
  font-family: var(--font-ko);
  font-size: 15px;
  line-height: 1.6;
  color: var(--text);
  margin: 0;
}
.spec + .spec { margin-top: 24px; }
.spec b { color: var(--white); font-weight: 500; text-decoration: underline; }

/* 관리 화면에서 추가한 페이지 (제목 + 본문 + 사진) */
.custom-page { padding-top: 40px; padding-bottom: 60px; }
.custom-page .spec { max-width: 760px; margin: 0 auto 34px; }

/* ---------- Contact ---------- */
.contact {
  max-width: 980px;
  margin: 0 auto;
  padding: 50px 16px 0;
}
.contact-text { padding-left: 2px; }
.contact h1 {
  margin: 0 0 6px;
  font-size: 32px;
  font-weight: 400;
  color: var(--white);
  line-height: 1.2;
}
.contact h1 b { font-weight: 700; }
.contact .lead {
  font-family: var(--font-type);
  font-size: 15px;
  font-weight: 400;
  color: var(--white);
  margin: 0 0 14px;
  line-height: 2.2;
}
.contact .lead span { display: block; }
.phones { margin: 26px 0 14px; padding: 0; list-style: none; }
.phones li {
  font-family: var(--font-ko);
  font-size: 20px;
  letter-spacing: .1em;
  color: var(--text);
  margin: 0 0 14px;
}
.phones a { text-decoration: none; }
.phones a:hover { color: var(--yellow); }
.addresses { margin: 0 0 30px; padding: 0; list-style: none; }
.addresses li { margin: 0 0 10px; }
.addresses button {
  font-family: var(--font-ko);
  font-size: 14px;
  letter-spacing: .03em;
  color: var(--text);
  background: none;
  border: 0;
  padding: 2px 0;
  cursor: pointer;
  text-align: left;
}
.addresses button:hover, .addresses button[aria-pressed="true"] { color: var(--white); }
.map {
  width: 100%;
  height: 595px;
  border: 0;
  display: block;
  background: #222;
}

/* ---------- Simple pages (404 등) ---------- */
.simple {
  text-align: center;
  padding: 120px 16px;
  color: var(--text);
}
.simple h1 { color: var(--white); font-weight: 400; }

/* ---------- Mobile ---------- */
@media (max-width: 900px) {
  /* 머리글: Wix 모바일처럼 메뉴 4줄을 지그재그로 (1·3번째 왼쪽, 2·4번째 들여쓰기), 오른쪽에 큰 로고 + 햄버거 */
  .site-header { height: auto; }
  .site-header .inner { padding: 34px 20px 40px; }
  .main-nav { flex-direction: column; align-items: flex-start; gap: 22px; padding: 0; }
  .main-nav a { margin: 0; font-size: 24px; letter-spacing: .55em; }
  .main-nav a:nth-child(even) { margin-left: 46px; }
  .header-logo { right: 20px; top: 44px; width: 66px; }
  .header-logo img { width: 66px; height: 66px; }
  .menu-btn { right: 24px; top: 140px; width: 34px; }
  .menu-btn span { background: var(--white); margin: 0 0 7px; }
  /* 홈: 머리글 아래에 배경 그림 띠, 그 아래 인스타 아이콘 */
  .page-home .site-header { position: relative; }
  .hero { height: 58vw; max-height: none; margin-bottom: 90px; }
  .hero-insta { top: calc(100% + 24px); right: 50%; transform: translateX(50%); width: 44px; }
  .hero-insta img { width: 44px; height: 44px; }
  .about { padding-top: 30px; }
  .about-lead { font-size: 26px; margin-bottom: 50px; }
  .client-logos { justify-content: center; }
  .project-grid { grid-template-columns: 1fr; gap: 40px; padding: 0 16px; }
  .project h2 { padding: 0; min-height: 0; font-size: 16px; }
  .project-desc, .project-grid .project .project-desc { max-width: none; margin-left: 0; margin-right: 0; padding: 0; }
  .project-featured { padding: 0 16px; max-width: none; }
  .period-tabs { gap: 4px 18px; margin-bottom: 30px; }
  .period-tabs button { font-size: 13px; letter-spacing: .05em; }
  .yt { max-width: none; }
  .studio-row .studio-btn.main { flex-basis: 130px; }
  .studio-btn { font-size: 13px; padding: 6px 6px; }
  .studio-room h2 { font-size: 17px; letter-spacing: .3em; }
  .spec { font-size: 14px; }
  .phones li { font-size: 18px; }
  .map { height: 420px; }
  .site-footer { font-size: 12px; }
}

/* Contact 글도 다른 페이지(We Are X, Studio, 에디터 페이지)처럼 가운데 정렬 */
.contact-text { text-align: center; padding-left: 0; }
.addresses button { text-align: center; }
