
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
.image-container {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background-color: black;
}
.bg-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  user-select: none;
  -webkit-user-drag: none;
}
.frog {
  position: absolute;
  top: 63%;   
  left: 18%;  
  width: 10%;
  transform: translate(-50%, -50%); 
  cursor: pointer; 
  transition: transform 0.1s ease;
}

.frog:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

#fly-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    z-index: 999;
    pointer-events: none;
}

#fly-overlay.active {
    display: block;
}

.fly {
    position: absolute;
    width: 20px; height: 20px;
    background-size: contain;
   background-repeat: no-repeat;
   pointer-events: none;
}

.fly:nth-child(1) { background-image: url('파리1.svg');
  top:20%; left: 30%; 
  animation: fly-move-4 2s infinite linear; 
}

.fly:nth-child(2) { background-image: url('파리2.svg');
  top: 20%; left: 80%; animation: fly-move-3 1s infinite alternate; 
}

.fly:nth-child(3) { background-image: url('파리3.svg');
  top: 70%; left: 80%; animation: fly-move-1 0.4s infinite alternate; 
}

.fly:nth-child(4) { background-image: url('파리4.svg');
  top: 10%; left: 60%; animation: fly-move-4 1s infinite linear; 
}

@keyframes fly-move-2 {
    from { transform: translate(0, 0); }
    to { transform: translate(800px, -900px); } 
}

@keyframes fly-move-3 {
    from { transform: translate(0, 0); }
    to { transform: translate(-900px, 800px); } 
}

@keyframes fly-move-1 {
    0% { transform: rotate(0deg) translate(600px) rotate(0deg); }
    100% { transform: rotate(360deg) translate(100px) rotate(-360deg); }
}

@keyframes fly-move-4 {
   0% { transform: rotate(360deg) translate(400px) rotate(-360deg); } /* 반경 20px -> 400px */
    100% { transform: rotate(0deg) translate(400px) rotate(0deg); }
}

.fly:nth-child(5) { 
  background-image: url('파리5.svg');
  top: 15%; left: 15%; 
  animation: fly-straight-long 2.5s infinite alternate ease-in-out; 
}

.fly:nth-child(6) { 
  background-image: url('파리6.svg');
  top: 45%; left: 45%; 
  animation: fly-curve-huge 3.5s infinite linear; 
}

.fly:nth-child(7) { 
  background-image: url('파리7.svg');
  top: 60%; left: 20%; 
  animation: fly-swoop 4s infinite linear; 
}

.fly:nth-child(8) { 
  background-image: url('파리8.svg');
  top: 80%; left: 70%; 
  animation: fly-dash 1.2s infinite alternate ease-in-out; 
}

.fly:nth-child(9) { 
  background-image: url('파리9.svg');
  top: 30%; left: 5%; 
  animation: fly-circle-tight 0.4s infinite linear; 
}


.fly:nth-child(10) { 
  background-image: url('파리10.svg');
  top: 75%; left: 10%; 
  animation: fly-zigzag 1.8s infinite linear; 
}

@keyframes fly-straight-long {
    0% { transform: translate(0, 0); }
    100% { transform: translate(1000px, -800px); } }

@keyframes fly-dash {
    0% { transform: translate(0, 0); }
    100% { transform: translate(-1200px, 400px); } 
}

@keyframes fly-curve-huge {
    0% { transform: rotate(0deg) translate(400px) rotate(0deg); } 
    100% { transform: rotate(360deg) translate(400px) rotate(-360deg); }
}

@keyframes fly-swoop {
    0% { transform: translate(0px, 0px); }
    25% { transform: translate(300px, -250px); }
    50% { transform: translate(600px, 0px); }
    75% { transform: translate(300px, 250px); }
    100% { transform: translate(0px, 0px); }
}

@keyframes fly-circle-tight {
    0% { transform: rotate(0deg) translate(80px) rotate(0deg); } 
    100% { transform: rotate(360deg) translate(80px) rotate(-360deg); }
}

@keyframes fly-zigzag {
    0% { transform: translate(0px, 0px); }
    20% { transform: translate(150px, -150px); }
    40% { transform: translate(-80px, -300px); }
    60% { transform: translate(200px, -450px); }
    80% { transform: translate(-100px, -150px); }
    100% { transform: translate(0px, 0px); }
}

.question {
  position: absolute;
  top: 9%;   
  left: 17.4%;  
  width: 7%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
}

.question:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

@keyframes spin-in-place {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

.leye {
  position: absolute;
  top: 85.6%;   
  left: 45.5%;  
  width: 2.8%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
  animation: spin-in-place 5s infinite linear;
  pointer-events: none;
  transition: transform 0.1s ease, scale 0.1s ease;
}

.reye {
  position: absolute;
  top: 85.6%;   
  left: 52.5%;  
  width: 2.8%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
  animation: spin-in-place 5s infinite linear;
  pointer-events: none;
  transition: transform 0.1s ease, scale 0.1s ease;
}

.book {
  position: absolute;
  top: 89%;   
  left: 50%;  
  width: 13.5%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
}

.book:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

.dragon {
  position: absolute;
  top: 61.5%;   
  left: 80.4%;  
  width: 11%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
}

.dragon:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

.plant {
  position: absolute;
  top: 34.3%;   
  left: 80.7%;  
  width: 10%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
}

.plant:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

.error-window {
  position: fixed; 
  width: 280px; 
  z-index: 10000;
  box-shadow: 2px 2px 10px rgba(0,0,0,0.5);
  pointer-events: none;
}

.book:hover ~ .leye,
.book:hover ~ .reye {
  scale: 1.1; 
}

.camo-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  overflow: hidden;
  animation: fadeInOut 8s forwards ease-in-out;
}

.camo-blob {
  position: absolute;
  width: 70vw; 
  height: 70vh;
  filter: blur(40px); 
  mix-blend-mode: multiply; 
  opacity: 0.9;
  
  animation: 
    blob-wobble 4s infinite alternate ease-in-out,
    camo-drift 6s infinite alternate ease-in-out;
}

@keyframes camo-drift {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  50% { transform: translate(5%, 10%) scale(1.1) rotate(5deg); }
  100% { transform: translate(-5%, -10%) scale(0.9) rotate(-5deg); }
}

@keyframes fadeInOut {
  0% { opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  100% { opacity: 0; }
}

.blood-scene {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    pointer-events: none;
    overflow: hidden;
}

.blood-mass {
    position: absolute;
    top: 0; left: 0;
    width: 100vw; height: 200vh;
    filter: url('#goo'); 
    opacity: 0.8;
    animation: flowDown 2.5s ease-in forwards; 
}

.blood-blob {
    position: absolute;
    background-color: #550a0a;
    border-radius: 50%; 
    animation: bob 2s infinite alternate ease-in-out;
}

.blood-drip {
    position: absolute;
    background-color: #6c1515;
    border-radius: 50px; 
    transform-origin: top center;
    animation: stretchDown 2s ease-in forwards; 
}

@keyframes flowDown {
    0% { transform: translateY(-120vh); }
    15% { transform: translateY(-90vh); } 
    100% { transform: translateY(120vh); }
}

@keyframes bob {
    from { transform: translateY(0) scale(1); }
    to { transform: translateY(3vh) scale(1.1); }
}

@keyframes stretchDown {
    0% { height: 5vh; }
    100% { height: var(--max-h); }
}

.fish {
  position: absolute;
  top: 10%;   
  left: 80.4%;  
  width: 11%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
}

.fish:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

.sparkle-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
    overflow: hidden;
    animation: sparkleFade 7s forwards;
}

@keyframes sparkleFade {
    0% { opacity: 0; }
    15% { opacity: 0.6; }
    85% { opacity: 0.6; }
    100% { opacity: 0; }
}


.sparkle {
    position: absolute;
    background-color: #ffd700;
    border-radius: 60%;
    box-shadow: 0 0 12px 5px rgba(255, 255, 255, 0.8);
    animation: twinkle var(--twinkle-duration) infinite ease-in-out var(--twinkle-delay);
}

@keyframes twinkle {
    0%, 100% { opacity: 0; transform: scale(0.3); }
    50% { opacity: 1; transform: scale(1.2); }
}

.snake {
  position: absolute;
  top: 34.8%;   
  left: 17.4%;  
  width: 11%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
}

.snake:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

#thermal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    pointer-events: none;
    display: none;
    opacity: 0;
    backdrop-filter: url(#thermal-lookup) contrast(1.2) brightness(1.1);
    -webkit-backdrop-filter: url(#thermal-lookup) contrast(1.2) brightness(1.1);
    transition: opacity 0.5s ease;
}

#thermal-overlay.active {
    display: block;
    opacity: 1;
}

#book-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    cursor: pointer;
}

.book-content {
    position: relative;
    max-width: 65%;
    max-height: 100%;
    cursor: default; 
}

.book-frame {
    width: 100%;
    height: auto;
    display: block;
    box-shadow: 0 0 50px rgba(0,0,0,1);
    border-radius: 10px;
}

.no-click {
    pointer-events: none;
}

.drunk-spin {
    filter: url(#drunk-vortex); 
    pointer-events: none;
}

@keyframes gentle-shake {
    0% { transform: translate(1px, 1px) rotate(0deg); }
    100% { transform: translate(-1px, -1px) rotate(0.5deg); }
}

.drunk-spin {
    filter: url(#drunk-vortex); 
    transform: scale(1.1); 
    transition: transform 0.5s ease-out;
    pointer-events: none;
}


.drunk-spin {
    filter: url(#drunk-vortex); 
    transform: scale(1.1);
    transition: transform 0.5s ease-out;
    pointer-events: none;
}

#blackout-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: black;
    z-index: 20000;
    display: none;
    pointer-events: none;
}

#blackout-overlay.active {
    display: block;
    animation: blackout-blink 6s ease-in-out forwards;
}

@keyframes blackout-blink {
    0% { opacity: 0; }
    20% { opacity: 0.9; } 
    35% { opacity: 0.2; }  
    55% { opacity: 0.95; } 
    70% { opacity: 0.4; }  
    85% { opacity: 1; }    
    100% { opacity: 1; }
}


.drunk-spin {
    filter: url(#drunk-vortex); 
    transform: scale(1.1); 
    transition: transform 0.5s ease-out;
    pointer-events: none;
}

.vo {
  position: absolute;
  top: 82%;   
  left: 40%;  
  width: 5%; 
  transform: translate(-50%, -50%); 
  transition: transform 0.1s ease;
  cursor: pointer; 
}

.vo:hover {
  transform: translate(-50%, -50%) scale(1.1); 
}

body {
    background-color: black;
    margin: 0;
    overflow: hidden;
}

.desc-layer {
    position: absolute;
    top: 0; left: 0;
    width: 50%; height: 50%;
    background: rgba(0,0,0,0.8); /* 검정 80% */
    display: flex;
    flex-direction: column; /* 위아래로 배치 */
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: 0.3s;
}

.alcohol-item:hover .desc-layer {
    opacity: 1;
}

.title { font-size: 2.2rem; font-weight: bold; margin-bottom: 8px; color: #ffffff; }
.content { font-size: 1.9rem; color: #ccc; }

.hover-group {
    position: absolute;

    display: inline-block;
}

/* 이미지 설정 */
.hover-group img {
    width: 100%;
    height: auto;
    display: block;
}

.desc-layer {
    position: absolute;
    /* top, left 설정은 아래에서 개별적으로 할 것이므로 여기서 지우거나 기본값만 둡니다 */
    width: 17vw; /* 내용 길이에 맞게 박스 크기 조절 */
    min-width: 200px;
    max-width: 1000px;
    white-space: normal !important;
    word-break: keep-all;
    height: auto !important;
    min-height: max-content;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
    border: 1.5px solid #ffffff;
    padding: 2vw;
    z-index: 100; /* 이미지보다 위에 뜨도록 */
    box-sizing: border-box;

}

/* 호버 시 등장 */
.hover-group:hover .desc-layer {
    opacity: 1;
}

/* 제목(title)과 본문(content) 글자 크기 다르게 설정 */
.title {
    font-size: 1.6vw;      /* 제목은 크게 */
    font-weight: bold;
    color: #ffffff;
    margin-bottom: 15px;
    text-align: center;
    line-height: 1.2;
    width: 100%;
    

}

.content {
    font-size: 1vw;   /* 본문은 작게 */
    color: #ffffff;
    margin: 0;
    line-height: 1.4;
    line-height: 1.3;
    width: 100%;
    text-align: center;
}

/* 1. 개구리: 이미지 오른쪽에 배치 */
.frog .desc-layer {
    top: 50%;
    left: 110%; /* 이미지 너비의 110% 지점(오른쪽 밖) */
    transform: translateY(-50%);
}

/* 2. 물음표: 이미지 왼쪽에 배치 */
.question .desc-layer {
  top: 60%;
    left: 145%; /* 이미지 너비의 110% 지점(오른쪽 밖) */
    transform: translateY(-50%);}

/* 3. 만드레이크: 이미지 아래쪽에 배치 */
.plant .desc-layer {

  top: 20%;
  left: auto;
    right: 120%;
  overflow: visible;}

/* 4. 창자: 이미지 왼쪽에 배치 */
.dragon .desc-layer {
  left: auto;
    top: 20%;
    right: 110%;
}

/* 5. 인어: 이미지 오른쪽에 배치 */
.fish .desc-layer {
  left: auto;
  top: 5%;
    right: 110%;}

/* 6. 뱀: 이미지 위쪽에 배치 */
.snake .desc-layer{
  top: 50%;
    left: 110%; /* 이미지 너비의 110% 지점(오른쪽 밖) */
    transform: translateY(-50%);
}

/* 7. 토(Vo): 이미지 오른쪽에 배치 */
.vo .desc-layer {
    top: -60%;
    left: -120%;
    transform: translateY(-50%);
}