@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,400;0,700;1,400&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400..900;1,400..900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@100..900&display=swap');

:root {
  /* 레이아웃 규격 */
  --header-height: 60px;
  --hero-height: 768px;
  --footer-height: 300px;
  --container-width: 1280px;

  /* 색상 */
  --icon-color: #000000;
}

/* 초기화 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100vh;
  font-family: 'Inter', sans-serif;
}

/* --- 언어별 폰트 정책 --- */

/* 1. 국문 모드 (KR) */
/* 전체적으로 Inter를 사용하되, 영문 단어만 Libre Baskerville 적용 */
html[lang="kr"] body,
html[lang="kr"] .hero-title,
html[lang="kr"] .content-title,
html[lang="kr"] .ins-title,
html[lang="kr"] .contents-text,
html[lang="kr"] .ins-text {
  font-family: 'Libre Baskerville', 'Inter', sans-serif;
}

/* 2. 영문 모드 (EN) */
/* 히어로 타이틀: Playfair Display */
html[lang="en"] .hero-title {
  font-family: 'Playfair Display', serif;
}

/* 본문 내 제목들 및 태그라인: Libre Baskerville */
html[lang="en"] .content-title,
html[lang="en"] .ins-title,
html[lang="en"] .footer-tag,
html[lang="en"] h3 {
  font-family: 'Libre Baskerville', serif;
}

/* 일반 텍스트: Inter (이미 기본값이므로 명시적 유지) */
html[lang="en"] .contents-text,
html[lang="en"] .ins-text,
html[lang="en"] p,
html[lang="en"] span {
  font-family: 'Inter', sans-serif;
}

main {
  padding-top: var(--header-height);
  overflow-x: hidden;
}

/* 공통 컨테이너 */
.container {
  width: 90%;
  max-width: var(--container-width);
  margin: 0 auto;
}

/* 공통 여백 */
.mt-space {
  margin-top: 100px !important;
}

/* 헤더 */
#header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1000;
  width: 100%;
  height: var(--header-height);
  background-color: rgba(255, 255, 255, 0.98);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 100%;
  padding: 0 20px;
}


.logo {
  display: flex;
  align-items: center;
}

.logo a {
  display: block;
}

.logo img {
  height: 30px;
  display: block;
}

/* 메뉴 버튼 */
.menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: none;
  background-color: transparent;
  cursor: pointer;
}

.menu-line-wrap {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
}

.menu-line {
  width: 100%;
  height: 2px;
  background-color: var(--icon-color);
}

/* 히어로 섹션 */
#hero,
section[class*="hero-"] {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: var(--hero-height);
  overflow: hidden;
  background-image: url('../assets/images/webp/01_hero_main.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* 추가 워크플로우 배너 섹션 */
section.hero-workflow {
  height: 200px;
  background-position: center calc(50% + 90px);
}

/* 스크롤 감지 애니메이션 상태 */
#hero.active,
section[class*="hero-"].active {
  animation: slideInRight 1s cubic-bezier(0.645, 0.045, 0.355, 1) forwards;
}

/* 초기 상태 숨김 (선택 사항: 자연스러운 등장을 위해) */
.reveal {
  opacity: 0;
  transform: translateX(150px);
  transition: all 1s ease;
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(150px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  width: 100%;
  height: 100%;
  padding-left: 10%;
  padding-right: 10%;
}

.home-hero .hero-content {
  opacity: 0;
  transform: translateX(150px);
}

.home-hero.active .hero-content {
  animation: slideInRight 1s cubic-bezier(0.645, 0.045, 0.355, 1) 0.6s forwards;
}

#hero::before,
section[class*="hero-"]::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 70%;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  background-color: rgba(0, 0, 0, 0.05);
  mask-image: linear-gradient(to left, #000 50%, transparent);
  -webkit-mask-image: linear-gradient(to left, #000 50%, transparent);
  z-index: 0;
  pointer-events: none;
}

#hero.home-hero::before {
  opacity: 0;
  transform: translateX(150px);
}

#hero.home-hero.active::before {
  animation: slideInRight 1s cubic-bezier(0.645, 0.045, 0.355, 1) 0.6s forwards;
}

.hero-title {
  font-optical-sizing: auto;
  font-style: normal;
  position: relative;
  z-index: 1;
  max-width: 50%;
  color: #ffffff;
  text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
  
  font-size: 50px;
  font-weight: 700;
  line-height: 1.2;
  text-align: right;
  word-break: keep-all;
}

.home-hero .hero-title {
  font-size: 43px;
}

.hero-workflow .hero-title {
  font-size: 36px;
}


/* 컨텐츠 섹션 */
#contents,
#contents2,
#contents3 {
  width: 100%;
  padding: 60px 0;
}

.contents-card {
  position: relative;
  isolation: isolate;
  /* 독립적 쌓임 맥락 형성 */
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 40px;
  width: 100%;
  background-color: #ffffff;
}

/* 맥킨지 스타일 배경 확장 레이어 */
.contents-card::before,
.card-insight::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background-color: #ffffff;
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.contents-card:hover,
.card-insight:hover {
  z-index: 10;
  /* 호버 시 위로 올라오게 함 */
}

.contents-card:hover::before,
.card-insight:hover::before {
  inset: -16px;
  opacity: 1;
  box-shadow: 0px 16px 40px rgba(5, 28, 44, 0.22);
  /* 그림자 약간 더 선명하게 */
}

.contents-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.contents-textbox {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
}

.content-title {
  color: #111111;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.2;
  text-align: left;
  word-break: keep-all;
}

.contents-text {
  margin-top: 20px;
  color: #111111;
  font-size: 20px;
  font-weight: 400;
  line-height: 1.6;
  text-align: left;
  word-break: keep-all;
  white-space: pre-wrap;
}

.top-text {
  margin-top: 0;
  margin-bottom: 40px;
}

.contents-text a {
  color: #0000ee;
  text-decoration: underline;
  transition: none;
}

.contents-text a:hover {
  color: #0000ee;
  text-decoration: underline;
}

.article-title {
  display: block;
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 10px;
  color: #111111;
}

/* 인사이트 섹션 */
#insights,
#insights2 {
  padding: 60px 0;
  background-color: #ffffff;
}

/* 인사이트 섹션 2 전용 레이아웃 */
#insights2 .grid-insight {
  grid-template-columns: repeat(2, 1fr);
  column-gap: 30px;
  row-gap: 60px;
}

#insights2 .card-insight {
  grid-template-columns: 1fr;
  grid-template-rows: auto 1fr;
  row-gap: 20px;
  align-items: start;
}

#insights2 .img-box {
  aspect-ratio: 5 / 2; /* 가로의 40% 높이로 제한 (이전보다 높이를 10% 추가 축소) */
}

.grid-insight {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  column-gap: 40px;
  row-gap: 40px;
  width: 100%;
}

.card-insight {
  position: relative;
  isolation: isolate;
  /* 독립적 쌓임 맥락 형성 */
  display: grid;
  grid-template-rows: auto 1fr;
  row-gap: 30px;
  width: 100%;
  min-width: 0;
  background-color: #ffffff;
}

.card-wide {
  grid-column: span 2;
}

.img-box {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background-color: #f0f0f0;
}

.text-box {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  width: 100%;
}

.ins-title {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: 1fr;
  column-gap: 15px;
  align-items: start;
  color: #111111;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
  text-align: left;
  word-break: keep-all;
}

.ins-title .ins-num,
.ins-title .ins-name {
  font-weight: 400;
  font-size: 20px;
}

.ins-text {
  margin-top: 20px;
  color: #111111;
  font-size: 20px;
  font-weight: 400;
  line-height: 1.6;
  text-align: left;
  word-break: keep-all;
}




/* 푸터 */
#footer {
  position: relative;
  width: 100%;
  padding: 60px 5%;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
}

#footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 1280px;
  height: 1px;
  background-color: #111111;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  row-gap: 20px;
  width: 100%;
  max-width: 1280px;
}

.footer-logo img {
  display: block;
  height: 30px;
  width: auto;
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, auto);
  justify-content: start;
  gap: 80px;
  width: 100%;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.footer-col li a {
  color: #000000;
  font-size: 16px;
  text-decoration: none;
  transition: opacity 0.3s ease;
}

.footer-col li a:hover {
  color: #0000ee;
  text-decoration: underline;
  text-decoration: underline;
}

.footer-legal {
  display: grid;
  grid-template-columns: repeat(4, auto);
  justify-content: end;
  gap: 24px;
  width: 100%;
}

.footer-legal a {
  color: #000000;
  font-size: 12px;
  text-decoration: none;
  transition: opacity 0.3s ease;
}

.footer-legal a:hover {
  color: #0000ee;
  text-decoration: underline;
  text-decoration: underline;
}

.footer-copyright {
  margin: 0;
  color: #000000;
  font-size: 12px;
  text-align: right;
}

.footer-tag {
  font-size: 36px;
  text-align: center;
  margin-top: 100px;
  font-weight: 700;
  color: #111111;
  width: 100%;
}

/* 반응형 - 태블릿 & 모바일 */
@media (max-width: 1279px) {
  :root {
    --hero-height: 600px;
  }

  section.hero-workflow {
    height: 300px;
    background-position: center;
  }

  .hero-title {
    max-width: 70%;
    font-size: 44px;
  }

  .home-hero .hero-title {
    font-size: 38px;
  }

  .hero-workflow .hero-title {
    font-size: 32px;
  }

  .content-title {
    font-size: 32px;
  }

  .contents-text {
    font-size: 18px;
  }

  .ins-title {
    font-size: 22px;
  }

  .ins-text {
    font-size: 18px;
  }

  .grid-insight {
    grid-template-columns: 1fr 1fr;
    row-gap: 40px;
  }

  .card-wide {
    grid-column: auto;
  }
}

@media (max-width: 767px) {
  :root {
    --hero-height: 80vh;
  }

  section.hero-workflow {
    height: 240px;
    background-position: center;
  }

  .hero-title {
    max-width: 90%;
    font-size: 36px;
  }

  .home-hero .hero-title {
    font-size: 31px;
  }

  .hero-workflow .hero-title {
    font-size: 26px;
  }

  .contents-card {
    grid-template-columns: 1fr;
    row-gap: 20px;
  }

  .contents-card::before,
  .card-insight::before {
    display: none;
    /* 모바일에서는 확장 효과 제외 */
  }

  .content-title {
    font-size: 28px;
  }

  .contents-text {
    font-size: 16px;
  }

  .ins-title {
    font-size: 20px;
  }

  .ins-text {
    font-size: 16px;
  }

  .grid-insight {
    grid-template-columns: 1fr;
    row-gap: 40px;
  }

  #insights2 .grid-insight {
    grid-template-columns: 1fr;
  }



  .footer-nav {
    flex-direction: column;
    gap: 30px;
  }

  .footer-legal {
    grid-template-columns: 1fr;
    justify-items: end;
    text-align: right;
    gap: 16px;
  }
}

/* 사이드 패널 스타일 (2단계: 애니메이션 및 인터랙션) */
.menu-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1500;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s ease;
}

.menu-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.side-panel {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 2000;
  width: 300px;
  height: 100%;
  padding: 80px 40px;
  background-color: #ffffff;
  transform: translateX(100%);
  /* 처음엔 우측 바깥에 숨김 */
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
}

.side-panel.active {
  transform: translateX(0);
  /* 활성화 시 나타남 */
}

/* 닫기 버튼 (X) */
.close-btn {
  position: absolute;
  top: 30px;
  right: 30px;
  width: 30px;
  height: 30px;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.close-line {
  position: absolute;
  width: 100%;
  height: 2px;
  background-color: #000000;
}

.close-line:nth-child(1) {
  transform: rotate(45deg);
}

.close-line:nth-child(2) {
  transform: rotate(-45deg);
}

.side-nav-list {
  display: flex;
  flex-direction: column;
  gap: 30px;
  list-style: none;
  padding: 0;
  margin-top: 40px;
}

.side-nav-list li a {
  color: #333333;
  font-size: 24px;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.3s ease;
}

.side-nav-list li a:hover {
  color: #0000ee;
  text-decoration: underline;
}

/* 사이드 메뉴 하단 언어 항목 여백 추가 */
.side-nav-list li:last-child {
  margin-top: 40px;
}