/* 미르종합환경 팔레트 — 홈 시안(딥 네이비·클린 틸·화이트)과 동일하게 맞춤 (2026-08-02) */
:root {
  --color-bg-primary: #ffffff;
  --color-bg-secondary: #F5FAFB;
  --color-bg-tertiary: #EAF4F6;
  --color-text-primary: #0B2B3C;
  --color-text-secondary: #24485B;
  --color-text-tertiary: #4A6675;
  --color-point: #0E7C86; /* 클린 틸 — 물·청결 */
  --color-dark: #0B2B3C;  /* 딥 네이비 */

  --font-en: 'Outfit', sans-serif;
  --font-kr: 'Noto Sans KR', sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Lenis Recommended CSS */
html.lenis, html.lenis body {
  height: auto;
}
.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}
.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}
.lenis.lenis-stopped {
  overflow: hidden;
}
.lenis.lenis-scrolling iframe {
  pointer-events: none;
}

body {
  font-family: var(--font-kr);
  color: var(--color-text-primary);
  background-color: var(--color-bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  /* 2026-08-02 추가: 한국어 단어가 중간에서 쪼개지는 줄바꿈 방지 ("제안" → "제 / 안") */
  word-break: keep-all;
  overflow-wrap: break-word;
}

/* Typography Base */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-en);
  font-weight: 300;
  letter-spacing: -0.02em;
}

.v2-container {
  width: 100%;
  overflow-x: clip; 
}

/* Sections */
.section {
  position: relative;
  width: 100%;
  min-height: 100vh;
  padding: 120px 8vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.section.full-height {
  height: 100vh;
}

.section.dark {
  background-color: var(--color-dark);
  color: var(--color-bg-primary);
}

.section.bg-secondary {
  background-color: var(--color-bg-secondary);
}

.section.bg-tertiary {
  background-color: var(--color-bg-tertiary);
}

/* Typography styles */
.text-giant {
  font-size: clamp(4rem, 8vw, 10rem);
  font-weight: 100;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: -0.04em;
}
.text-giant strong {
  font-weight: 600;
  color: var(--color-point);
}

.text-title {
  font-size: clamp(2rem, 4vw, 4rem);
  font-weight: 500;
  margin-bottom: 24px;
}

.text-desc {
  font-size: clamp(1rem, 1.2vw, 1.5rem);
  color: var(--color-text-secondary);
  font-weight: 400;
  line-height: 1.8;
  max-width: 650px;
}
.section.dark .text-desc {
  color: var(--color-text-tertiary);
}

/* Utility */
.flex-split {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  gap: 80px;
}
@media (max-width: 1024px) {
  .flex-split {
    flex-direction: column;
  }
}

.image-container {
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  background-color: var(--color-bg-tertiary);
}
.image-container img,
.image-container video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.image-container:hover img,
.image-container:hover video {
  transform: scale(1.05);
}
.no-zoom:hover img,
.no-zoom:hover video {
  transform: scale(1) !important;
}

/* 시안 바로가기 링크 버튼 (2026-08-02 추가 — 브랜딩업 기본: 제안서에 시안 링크를 넣는다) */
.link-btn {
  display: inline-block;
  padding: 16px 36px;
  border: 1px solid var(--color-point);
  font-family: var(--font-en);
  font-size: 0.95rem;
  letter-spacing: 1.5px;
  text-decoration: none;
  color: var(--color-text-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
}
.section.dark .link-btn {
  color: var(--color-bg-primary);
}
.link-btn:hover,
.link-btn:focus-visible {
  background-color: var(--color-point);
  color: var(--color-dark);
}
.link-btn:focus-visible {
  outline: 2px solid var(--color-point);
  outline-offset: 3px;
}

/* Overlapping effects */
.overlap-box {
  position: relative;
  z-index: 2;
  margin-top: -100px;
  margin-left: auto;
  background: var(--color-bg-primary);
  padding: 60px;
  width: 80%;
  box-shadow: 0 40px 100px rgba(0,0,0,0.03);
}

/* Big number */
.big-number {
  font-family: var(--font-en);
  font-size: 20vw;
  font-weight: 200;
  color: rgba(0,0,0,0.04);
  position: absolute;
  top: 0;
  right: 8vw;
  z-index: 0;
  line-height: 0.8;
  pointer-events: none;
}
.section.dark .big-number {
  color: rgba(255,255,255,0.04);
}

/* Ensure content stays above the big number */
.section > *:not(.big-number) {
  position: relative;
  z-index: 10;
}

/* Decor line */
.decor-line {
  width: 60px;
  height: 1px;
  background-color: var(--color-point);
  margin: 40px 0;
}

/* GSAP Default Hidden Class */
.gsap-fade-up, .gsap-fade-in, .gsap-slide-left, .gsap-slide-right {
  /* JS가 에러나도 내용이 보이도록 CSS에서 강제로 숨기지 않음 */
}

/* Carousel */
.carousel-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}
.carousel-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  z-index: 0;
  /* 2026-08-02: 시안 스크린샷은 흰 배경이라 크로스페이드가 길면 두 장이 겹쳐 지저분해 보인다 → 전환 시간 단축 */
  transition: opacity 0.7s ease-in-out, transform 6s ease-out;
  transform: scale(1.05);
}
.carousel-img.prev-active {
  opacity: 1;
  z-index: 1;
  transform: scale(1);
  /* prev-active일 때는 투명도 변화 없이 1을 유지 */
  transition: opacity 0s, transform 6s ease-out; 
}
.carousel-img.active {
  opacity: 1;
  z-index: 2;
  transform: scale(1);
  transition: opacity 0.7s ease-in-out, transform 6s ease-out;
}
.carousel-indicators {
  position: absolute;
  bottom: 5%;
  right: 5%;
  display: flex;
  gap: 10px;
  z-index: 10;
}
.carousel-dot {
  width: 40px;
  height: 2px;
  background-color: rgba(255,255,255,0.3);
  transition: background-color 0.5s;
}
.carousel-dot.active {
  background-color: var(--color-bg-primary);
}

/* -------------------------------------
   Mobile & Tablet Responsive 
-------------------------------------- */
@media (max-width: 1024px) {
  .section {
    padding: 100px 5vw !important;
  }
  /* Split Layouts to Column */
  .flex-split {
    flex-direction: column !important;
    gap: 40px !important;
    height: auto !important;
  }
  .flex-split > div {
    width: 100% !important;
  }
  /* Slide 1 specific */
  .section.full-height .flex-split > div:first-child {
    padding: 60px 5vw !important;
  }
  .section.full-height .flex-split > div:last-child {
    height: 60vh !important;
    min-height: 400px;
  }
  .section.full-height .flex-split > div:last-child > .gsap-fade-up {
    left: 5% !important;
    bottom: 5% !important;
    padding: 20px !important;
    width: 90% !important;
  }
  /* Typography Adjustments */
  .text-giant {
    font-size: clamp(3rem, 12vw, 5rem) !important;
  }
  .text-title {
    font-size: clamp(1.8rem, 8vw, 2.5rem) !important;
  }
  /* Boxes and Containers */
  div[style*="display: flex; gap: 40px;"] {
    flex-direction: column !important;
    padding: 30px !important;
    gap: 20px !important;
  }
  div[style*="padding: 50px; display: flex"] {
    flex-direction: column !important;
    padding: 30px !important;
    gap: 15px !important;
  }
  /* Slide 11 Parallax Height */
  #slide11 > div:last-child {
    flex-direction: column !important;
    height: auto !important;
    gap: 20px !important;
  }
  .parallax-img-1, .parallax-img-2 {
    height: 300px !important;
    width: 100% !important;
  }
  /* Slide 13 & 15 Tables / Lists */
  div[style*="padding: 30px 0"], div[style*="padding: 40px 0"] {
    flex-direction: column !important;
    align-items: flex-start !important;
    padding: 20px 0 !important;
  }
  div[style*="padding: 30px 0"] > div, div[style*="padding: 40px 0"] > div {
    width: 100% !important;
    text-align: left !important;
    margin-bottom: 5px;
  }
  div[style*="padding: 30px 0"] > div.mobile-right {
    text-align: right !important;
    padding-right: 0 !important;
  }
  /* Slide 8 Language Selector */
  div[style*="display: flex"][style*="gap: 2px"] {
    flex-wrap: wrap !important;
  }
  div[style*="display: flex"][style*="gap: 2px"] > div {
    width: 49% !important;
    padding: 20px 0 !important;
    flex: auto !important;
  }
  /* Slide 12 Estimate Header */
  .estimate-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 30px !important;
  }
  .estimate-header > div {
    text-align: left !important;
  }
}

@media (max-width: 768px) {
  .pc-only { display: none !important; }
  .section {
    padding: 80px 5vw !important;
    min-height: auto !important;
  }
  .section.full-height {
    height: auto !important;
  }
  /* Big Number */
  .big-number {
    font-size: 40vw;
    top: 50px;
    right: 5vw;
    opacity: 0.5;
  }
  .decor-line {
    margin: 20px 0;
  }
  /* Hide slide 1 indicators on mobile to save space */
  .carousel-indicators {
    bottom: 2%;
    transform: scale(0.8);
  }
}

/* Top Button */
.top-btn {
  position: fixed;
  bottom: 40px;
  right: 40px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: var(--color-dark);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 100;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, background-color 0.3s ease;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.top-btn.show {
  opacity: 1;
  visibility: visible;
}
.top-btn:hover {
  background-color: var(--color-point);
  transform: translateY(-3px);
}
@media (max-width: 768px) {
  .top-btn {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
  }
}
