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

body {
  background-color: beige;
  overflow-x: hidden;
  font-family: "Pretendard", sans-serif;
}

/* ===== HEADER ===== */
/* 헤더 전체 정렬 */
header {
  width: 100%;
  margin: 80px auto 20px;
  display: flex;
  justify-content: center;
}

/* 헤더 글씨를 감싸는 박스 */
.headerBox {
  display: inline-block;

  padding: 15px 28px;

  background: white;
  border: 3px solid black;
  box-shadow: 0px 0px 0 firebrick;

  font-family: "IBM Plex Sans KR", sans-serif;
  font-size: 4.2em;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: firebrick;

  transform: rotate(0deg); /* 살짝 기울여 붙인 느낌 */
}


/* ===== 설명문 ===== */
#siteDescription {
  max-width: 900px;
  margin: 0 auto 30px;
  padding: 0 24px;

  font-size: 14px;
  line-height: 1.9;
  color: darkred;
  text-align: center;
  word-break: keep-all;

  position: relative;
  z-index: 5;
}

/* ===== MINI TITLE ===== */
#miniTitle {
  position: fixed;
  top: 16px;
  left: 16px;

  font-size: 1.1em;
  font-weight: 700;

  background: white;
  padding: 6px 10px;
  border: 0px darkred;

  z-index: 2000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

/* ===== IMAGE GRID ===== */
.container {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding: 20px 20px 60px;
  row-gap: 30px;
}

.container img {
  width: 70%;
  margin: 0 auto;
  display: block;
  cursor: not-allowed;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* 이미지 기본 회전 */
.container img {
  transform: rotate(var(--rot));
}

/* 각각 살짝 다른 각도 부여 */
.container img:nth-child(5n + 1) { --rot: -3deg; }
.container img:nth-child(5n + 2) { --rot: 2deg; }
.container img:nth-child(5n + 3) { --rot: -2deg; }
.container img:nth-child(5n + 4) { --rot: 4deg; }
.container img:nth-child(5n)     { --rot: -3deg; }


.container img:hover {
  transform: scale(1.2) rotate(0deg);
  box-shadow: 4px 4px 0 darkred;

}

/* ===== EMOJI CURSOR ===== */
#emojiCursor {
  position: fixed;
  pointer-events: none;
  font-size: 24px;
  z-index: 9999;
}

/* ===== CAPTION ===== */
#captionBox {
  position: fixed;
  display: none;
  background-color: yellow;
  color: solid black;
  padding: 8px 12px;
  font-size: 1em;
  border: 2px solid black;
  z-index: 999;
  max-width: 130px;
  word-break: keep-all;
}

/* ===== INFO BUTTON ===== */
#infoBtn {
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 3000;

  width: 60px;
  height: 44px;

  background: darkred;
  border: 2px yellow;
  box-shadow: 3px 3px 0 red;

  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  f
}

/* ===== INFO PANEL ===== */
#infoPanel {
  position: fixed;
  top: 16px;
  left: 70px;
  z-index: 3000;

  width: min(380px, calc(100vw - 96px));
  padding: 14px;

  background: rgba(255, 255, 255, 0.95);
  border: 2px solid black;
  box-shadow: 3px 3px 0 darkred;

  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: 0.2s ease;
}

/* 인포메이션 박스 기본 상태 */
#infoPanel {
  transition: 
    opacity 0.2s ease,
    transform 0.2s ease;
}

/* 마우스 올렸을 때 살짝 커지기 */
#infoPanel:hover {
  transform: scale(1.05) translateY(0);
}


#infoPanel.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.infoTitle {
  font-weight: 800;
  margin-bottom: 8px;
  color: darkred
}

.infoText {
  font-size: 0.95em;
  line-height: 1.55;
}
