/* ====== 기본 설정 및 폰트 ====== */
@font-face {
  font-family: 'HankenGrotesk';
  src: url('../HankenGrotesk-VariableFont_wght-SHUaRYnB.ttf') format('truetype');
}

@font-face {
  font-family: 'CabinetGrotesk';
  src: url('../CabinetGrotesk-Variable-DZ-mBhZu.ttf') format('truetype');
}

* {
  margin: 0;
  padding: 0;
}

h3 {
  text-decoration: none;
  font-weight: 100;
}

/* ====== 페이지 레이아웃 ====== */
html, body {
  font-family: HankenGrotesk, serif;
  margin: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100vh;
  position: relative;
  text-align: center;

  font-weight: 300;
  background: radial-gradient(ellipse at 75% 50%, 
      #D7C5EC 0%,     /* 중심 가장 밝은 라벤더 */
      #A7A6F1 100%    /* 가장 외곽 진한 보라 */
  );
  color: #fff;
  overflow: hidden; /* 스크롤바 방지 */
  height: 100%;
}

.webgl {
  position: fixed;
  top: 0;
  left: 0;
  outline: none;
  background-color: #000000;
}

#overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 10;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.title {
  position: absolute;
  top: 5%;
  left: 5%;
  font-size: 36px;
  font-weight: 700;
  color: #000;
  text-align: left;
}

.title h1 {
  font-size: 48px;
  margin: 0;
}

.title p {
  font-size: 28px;
  margin: 0;
}

.icons-container {
  position: absolute;
  top: 5%;
  right: 10%;
  display: flex;
  gap: 15px;
}

.icon {
  width: 80px;
  height: 80px;
  cursor: pointer;
}

.info-box {
  position: absolute;
  top: 15%;
  right: 10%;
  width: 250px;
  padding: 15px;
  text-align: left;
  font-size: 18px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.text-column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  font-weight: 700;
}

.hidden {
  display: none;
}




/* ====== Start Info Overlay - 수정된 버전 ====== */
/* ====== Start Info Overlay - 수정된 버전 ====== */
#start-info-overlay {
    position: fixed;
    top: 15%;
    left: 15%;
    right: 15%;
    bottom: 0%;
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.4) 0%,
        rgba(0, 0, 0, 0.4) 100%
    );
    backdrop-filter: blur(4px);
    border-top-left-radius: 50px;
    border-top-right-radius: 50px;
    z-index: 10000;
    display: flex; /* Flexbox로 수평 배치 */
    opacity: 1;
    transition: opacity 2.0s ease-out, transform 2.0s ease-out;
    overflow: hidden;
    box-shadow: 0 30px 30px rgba(0, 0, 0, 0.4);
}

#start-info-overlay.fade-out {
    opacity: 0;
    transform: translateY(100%);
}

/* ====== 왼쪽 텍스트 영역 - 모델 위에 오버레이 ====== */
.start-info-container {
    flex: 0 0 50%; /* 왼쪽 50% 고정 */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start; /* 왼쪽 정렬 */
    padding: 60px 40px 60px 60px;
    border-top-left-radius: 50px;
    border-top-right-radius: 50px;
    color: #fff;
    z-index: 3; /* 모델보다 위에 위치 */
    position: relative; /* z-index 적용을 위해 필요 */
    background: linear-gradient(90deg, 
        rgba(0, 0, 0, 0.3) 0%,     /* 왼쪽은 약간 어둡게 */
        rgba(0, 0, 0, 0.1) 70%,    /* 중간은 투명하게 */
        rgba(0, 0, 0, 0) 100%      /* 오른쪽은 완전 투명 */
    ); /* 텍스트 가독성을 위한 배경 그라데이션 */
}

/* ====== 제목 섹션 수정 ====== */
.start-title {
    margin-bottom: 40px;
    text-align: left; /* 왼쪽 정렬로 변경 */
    width: 100%;
    z-index: 3;
}

.start-main-title {
    font-family: 'CabinetGrotesk';
    font-size: 3.5rem; /* 크기 조정 */
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    color: #fff;
    line-height: 1.1;
}


.start-subtitle {
  width: 80%;
  font-family: 'CabinetGrotesk';
  font-size: 1.8em; /* 크기 조정 */
  font-weight: 500;
  margin-bottom: 20px;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  color: #fff;
  line-height: 1.1;
}


/* ====== 컨텐츠 섹션 수정 ====== */
.content-section {
    width: 90%;
    margin-bottom: 40px;
    /* position: absolute 제거 */
    /* left: -10% 제거 */
    position: relative;
    z-index: 3;
}

.text-content {
    width: 100%;
    text-align: left;
    padding: 0; /* 패딩 초기화 */
    /* flex 관련 속성 제거 */
}

.start-description {
    font-size: 1.1rem;
    font-weight: 300;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* ====== 버튼 섹션 수정 - 전체 오버레이 기준 중앙 하단 ====== */
.button-section {
    position: absolute;
    bottom: 4%; /* 전체 오버레이 하단에서 8% 떨어진 위치 */
    left: 50%;
    transform: translateX(-50%); /* 수평 중앙 정렬 */
    text-align: center;
    z-index: 4; /* 다른 요소들보다 위에 */
    width: auto;
}

.start-button-new {
    font-family: 'CabinetGrotesk';
    background: linear-gradient(45deg, 
        rgba(255, 255, 255, 0.25), 
        rgba(255, 255, 255, 0.15)
    );
    border: 2px solid rgba(0, 0, 0, 0.5);
    border-radius: 50px;
    padding: 18px 50px;
    font-size: 1.1rem;
    font-weight: 300;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(15px);
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.start-button-new:hover {
    background: linear-gradient(45deg, 
        rgba(255, 255, 255, 0.35), 
        rgba(255, 255, 255, 0.25)
    );
    border-color: rgba(255, 255, 255, 0.7);
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.25);
}

/* ====== 오른쪽 3D 모델 영역 - 텍스트 뒤로 확장 ====== */
.model-content {
    position: absolute; /* flex에서 absolute로 변경 */
    top: 0;
    left: 0; /* 전체 오버레이 왼쪽부터 시작 */
    width: 100%; /* 전체 너비 사용 */
    height: 100%; /* 전체 높이 사용 */
    z-index: 1; /* 텍스트보다 뒤에 위치 */
    pointer-events: none;
    overflow: visible; /* 모델이 범위를 벗어나도 잘리지 않음 */
}

.model-canvas-container {
    position: absolute;
    top: 10%;
    left: 0%; /* 오른쪽 절반에서 시작 */
    width: 150%; /* 캔버스가 충분한 공간을 가지도록 */
    height: 100%;
    overflow: visible; /* 중요: 모델이 잘리지 않도록 */
    display: flex;
    justify-content: flex-start; /* 왼쪽 정렬로 모델이 오른쪽 영역에 위치 */
    align-items: center;
    border-radius: 0;
    box-shadow: none;
}

#model-canvas {
    width: 150%; /* 캔버스를 더 크게 해서 회전 시 여유 공간 확보 */
    height: 150%; /* 캔버스를 더 크게 해서 회전 시 여유 공간 확보 */
    display: block;
    max-width: none; /* 최대 너비 제한 해제 */
    max-height: none; /* 최대 높이 제한 해제 */
}

.model-loading {
    position: absolute;
    top: 50%;
    left: 75%; /* 오른쪽 영역의 중앙에 위치 */
    transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    z-index: 2;
}

/* ====== 포커스 효과 수정 - 제거 또는 조정 ====== */
.model-focus-area {
    /* 이제 모델이 전체 영역에 있으므로 포커스 효과는 필요없거나 조정 필요 */
    display: none; /* 임시로 숨김 */
}










/* ====== 애니메이션 ====== */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.25);
  }
}

/* ====== 시작 화면 오버레이 스타일 (기존 - 필요시 제거) ====== */
.start-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(22, 47, 150, 0.8); /* 반투명 파란색 배경 */
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Start 버튼 스타일 (기존 - 필요시 제거) */
.start-button {
  position: fixed;
  top: 65.0%;
  left: 58.5%;
  width: 138px;
  height: 138px;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.0);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
  text-decoration: none; /* 링크 밑줄 제거 */
}

.start-button:hover {
  transform: scale(1.05);
  box-shadow: 0 0 30px rgba(255, 255, 255, 0.8);
}

/* ====== 네비게이션 버튼 스타일 ====== */
.navigation-container {
  position: absolute;
  bottom: 1%;
  left: 0;
  width: 100%;
  height: 15%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.navigation {
  position: relative;
  width: 23.4vw;
  height: 7.8vw;
  display: flex;
  justify-content: center;
  align-items: center;
}

.circle-buttons-container {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  gap: 10px;
  position: relative;
  top: 40%;
  z-index: 10;
}

/* 버튼 기본 스타일 */
.circle-group {
  position: relative;
  width: 100px;
  height: 100px;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all 0.3s ease;
}

.circle-group .outer-circle {
  position: absolute;
  width: 100px;
  height: 100px;
  border: 3px solid white;
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 9;
  box-sizing: border-box;
  transition: all 0.3s ease;
}

.circle-group .nav-button {
  position: absolute;
  background-color: rgba(0, 0, 0, 0.7);
  border: none;
  cursor: pointer;
  border-radius: 50%;
  width: 3%;
  height: 3%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  font-weight: 700;
  font-size: 0.7em;
  color: #33a;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  pointer-events: auto;
  transition: all 0.3s ease;
}

/* 활성 버튼 스타일 */
.circle-group.active {
  width: 8vw;
  height: 8vw;
  transform: translate(0%, -35%);
}

.circle-group.active .nav-button {
  width: 7.4vw;
  height: 7.4vw;
  font-size: 1.5vw;
}

/* 버튼 텍스트 스타일 */
.button-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.main-text {
  font-size: inherit;
  margin-bottom: 0px;
}

.sub-text {
  width: 90%;
  font-size: 0.8vw;
  margin-top: 0.5em;
  line-height: 1.2;
  font-weight: 100;
  color: #fff;
}

/* 버튼 연결선 */
.nav-line {
  position: absolute;
  width: 70%;
  height: 2px;
  background-color: #fff;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
}

/* 뷰 컨테이너 */
.view-container {
  display: none;
}

.view-container.active {
  display: block;
}

/* SVG 중앙 배치 */
.center-svg {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 54%;
  left: 50%;
  transform: translate(-50%, 0%);
  z-index: 5; /* 버튼들보다 뒤에 위치 */
  pointer-events: none; /* 클릭 방지 */
}

.navigation-svg {
  opacity: 0.8; /* 투명도 조정 */
  background-color: rgba(0, 0, 0, 0.0);
}

/* ====== 수평 POI 리스트 스타일 (옵션 2: 네비게이션 좌측) ====== */
.poi-list {
  position: fixed;
  bottom: 0%; /* 네비게이션과 같은 높이 */
  right: 1%; /* 화면 왼쪽에서 5% 떨어진 위치 */
  width: 32%;
  max-width: 32%; /* 화면 너비의 40% */
  height: auto;
  background-color: rgba(0, 0, 0, 0.8);
  border-top-left-radius: 2vw;
  border-top-right-radius: 2vw;
  padding: 0.85% 1% 1% 2%;
  display: flex;
  flex-direction: row; /* 수평 배치 */
  align-items: center;
  gap: 8.8%;
  max-height: none;
  overflow-x: auto; /* 수평 스크롤 */
  overflow-y: hidden;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  pointer-events: auto;
}

/* 수평 스크롤바 스타일링 (더 세련되게) */
.poi-list::-webkit-scrollbar {
  height: 4px;
}

.poi-list::-webkit-scrollbar-track {
  background: transparent;
}

.poi-list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 2px;
}

.poi-list::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.5);
}

/* POI 리스트 아이템 스타일 (컴팩트하게) */
.poi-list-item {
  width: 2.8%; 
  height: 2.8%; 
  flex-shrink: 0; /* 크기 고정 */
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  pointer-events: auto;
  border-radius: 8px;
}

/* POI 아이콘 스타일 */
.poi-list-item img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  filter: brightness(0) invert(1);
  opacity: 0.8;
  transition: all 0.1s ease;
  pointer-events: auto;
}

/* 호버 효과 */
.poi-list-item:hover {
  background-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

.poi-list-item:hover img {
  opacity: 1;
  transform: scale(1.1);
}

/* 액티브 효과 (클릭 시) */
.poi-list-item.active {
  background-color: rgba(255, 255, 255, 0.1);
  width: 68px;
  height: 68px;
  border-radius: 50%;
  transform: translate(0px, 0px);
  padding: 0px;
  margin: -30px;
}

.poi-list-item.active img {
  opacity: 1;
  transform: scale(1.15);
}

.poi-list-alt1 {
  position: fixed;
  bottom: 15%;
  right: 1%;
  width: 32%;
  max-width: 32%;
  height: 80px;
  
  /* 외부 SVG 파일 사용 */
  background-image: url('../images/navigation/Sub_Navbar_b.svg');
  background-size: 100%;
  background-repeat: no-repeat;
  background-position: center;

  display: flex;
  align-items: center;
  padding: 0 20px;
  z-index: 999;
}

/* ====== POI 정보창 스타일 ====== */
/* 인포창 기본 컨테이너 */
.poi-info-box {
  position: absolute;
  left: 17%;
  bottom: 0%;
  padding: 0.5%;
  text-align: left;
  background-color: rgba(0, 0, 0, 0.8);
  transform: translateX(-50%);
  width: 30%;
  border-top-left-radius: 30px;
  border-top-right-radius: 30px;
  color: white;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  z-index: 100;
  pointer-events: none;
  font-size: 1vw;
}

/* 콘텐츠 컨테이너 */
.poi-content-container {
  background-color: rgba(0, 0, 0, 0);
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 0px;
  transition: all 0.3s ease;
}

.poi-content-wrap {
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
}

.poi-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
  width: 100%;
}

/* 헤더 영역 */
.poi-header {
  padding: 0px;
  background-color: rgba(0, 0, 0, 0.8);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

/* 제목 스타일 */
#poi-title-container {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
  transition: all 0.3s ease;
}

#poi-title-icon {
  margin-right: 80px;
  width: auto;
  height: 24px;
  vertical-align: middle;
  filter: brightness(0) invert(1);
}

#poi-title {
  font-family: "CabinetGrotesk";
  margin: 0;
  font-size: 2.3vw;
  font-weight: 100;
}

/* 텍스트 콘텐츠 */
.poi-text-content {
  width: 100%;
  margin-bottom: 15px;
  transition: all 0.3s ease;
}

#poi-text {
  margin: 0;
  line-height: 1.5;
  font-size: 1vw;
  font-weight: 300;
}

/* 이미지 컨테이너 */
.poi-image-container {
  width: 100%;
  max-width: 100%;
  margin-top: 10%;
  position: relative;
  text-align: center;
  margin-bottom: 15px;
  transition: all 0.3s ease;
}

.poi-image-container img, #poi-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  margin-bottom: 10%;
  max-width: 100%;
  border-radius: 4px;
}

/* 닫기 버튼 */
.toggle-button-fixed {
  position: absolute;
  bottom: 0;
  right: 15px;
  z-index: 101;
}

.close-buttonweb {
  font-family: "HankenGrotesk";
  font-size: 1vw;
  font-weight: 100;
  color: rgba(220, 220, 220, 1.0);
  position: absolute;
  bottom: 10px;
  right: 10px;
  width: 120px;
  height: 30px;
  background-color: rgba(120, 120, 120, 0.8);
  border-radius: 5px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  z-index: 101;
  transition: all 0.3s ease;
  pointer-events: auto;
  border: 0px solid rgba(255, 255, 255, 0.4);
  user-select: none;
}

.close-buttonweb:hover {
  background-color: rgba(150, 150, 150, 0.8);
}

/* 확장 가능한 콘텐츠 */
.poi-expandable-content {
  max-height: auto;
  opacity: 1;
  overflow: hidden;
  transition: all 0.3s ease;
}

/* 최소화된 상태의 정보창 */
content-wrap {
  transform: translateY(0);
}

.poi-info-box.minimized .poi-text-content,
.poi-info-box.minimized .poi-image-container {
  display: none;
}

/* ====== 로딩 오버레이 ====== */
#loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.loading-container {
  text-align: center;
  color: white;
}

.loading-container h3 {
  font-family: HankenGrotesk;
  font-weight: 100;
  line-height: 0em;
}

.progress-container {
  width: 300px;
  height: 10px;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 4px;
  margin: 20px auto;
  overflow: hidden;
}

#loading-progress-bar {
  width: 0%;
  height: 100%;
  background-color: rgba(200, 200, 200, 0.5);
  border-radius: 4px;
  transition: width 0.3s ease;
}

#loading-percent {
  font-family: HankenGrotesk;
  font-size: 13px;
  font-weight: 100;
}




content-container {
  height: 70px;
  padding: 15px;
  background-color: transparent;
  box-shadow: none;
}

.poi-info-box.minimized .poi-expandable-content {
  max-height: 70px;
  opacity: 0;
  overflow: hidden;
  margin: 30px;
}

.poi-info-box.minimized #poi-title {
  position: absolute;
  top: 0px;
  left: 15px;
  padding: 10px;
  width: calc(100% - 20px);
}


.poi-info-box.minimized #poi-title-container {
  position: absolute;
  top: 0px;
  left: 15px;
  padding: 10px;
  width: calc(100% - 20px);
}

.poi-info-box.minimized .poi-content-wrap {
  transform: translateY(0);
}

.poi-info-box.minimized .poi-text-content,
.poi-info-box.minimized .poi-image-container {
  display: none;
}

/* ====== 로딩 오버레이 ====== */
#loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.loading-container {
  text-align: center;
  color: white;
}

.loading-container h3 {
  font-family: HankenGrotesk;
  font-weight: 100;
  line-height: 0em;
}

.progress-container {
  width: 300px;
  height: 10px;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 4px;
  margin: 20px auto;
  overflow: hidden;
}

#loading-progress-bar {
  width: 0%;
  height: 100%;
  background-color: rgba(200, 200, 200, 0.5);
  border-radius: 4px;
  transition: width 0.3s ease;
}

#loading-percent {
  font-family: HankenGrotesk;
  font-size: 13px;
  font-weight: 100;
}