@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,600;1,400&display=swap');

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

body {
  overflow: hidden;
  background: #000;
  font-family: 'Cormorant Garamond', Georgia, serif;
  color: #3B2F1E;
}

canvas {
  display: block;
}

/* Title / Blocker Screen */
#blocker {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  cursor: pointer;
}

#blocker.hidden {
  display: none;
}

#title-screen {
  text-align: center;
  color: #E8D5B0;
}

#title-screen h1 {
  font-size: 4rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  margin-bottom: 0.3em;
  text-shadow: 0 0 40px rgba(232, 169, 74, 0.3);
}

#title-screen .subtitle {
  font-size: 1.4rem;
  font-style: italic;
  margin-bottom: 2em;
  opacity: 0.8;
}

#title-screen .instruction {
  font-size: 1.2rem;
  animation: pulse 2s ease-in-out infinite;
}

#title-screen .controls-hint {
  margin-top: 2em;
  font-size: 0.9rem;
  opacity: 0.5;
}

@keyframes pulse {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

/* HUD */
#hud {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 50;
}

#crosshair {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-size: 8px;
  color: rgba(232, 213, 176, 0.6);
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.8);
}

#crosshair.active {
  color: #E8A94A;
  font-size: 12px;
}

#objective {
  position: absolute;
  bottom: 80px;
  left: 30px;
  max-width: 400px;
  padding: 15px 20px;
  background: rgba(232, 213, 176, 0.9);
  border: 1px solid #8B7355;
  border-radius: 2px;
  font-size: 1.05rem;
  line-height: 1.5;
  display: none;
  box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
}

#objective.visible {
  display: block;
}

#hint {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  padding: 8px 16px;
  background: rgba(232, 213, 176, 0.85);
  border: 1px solid #8B7355;
  border-radius: 2px;
  font-size: 0.9rem;
  font-style: italic;
  display: none;
}

#hint.visible {
  display: block;
}

#light-toggle {
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 24px;
  cursor: pointer;
  pointer-events: auto;
  opacity: 0.6;
  transition: opacity 0.2s;
  user-select: none;
  text-shadow: 0 0 8px rgba(255, 200, 50, 0.5);
}

#light-toggle:hover {
  opacity: 1;
}

#light-toggle.dim {
  opacity: 0.3;
  text-shadow: none;
}

/* Notebook Overlay */
#notebook {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 90;
}

#notebook.hidden {
  display: none;
}

#notebook-content {
  width: 600px;
  max-height: 80vh;
  padding: 40px;
  background: #E8D5B0;
  border: 2px solid #8B7355;
  box-shadow: 4px 4px 20px rgba(0, 0, 0, 0.5);
  overflow-y: auto;
}

#notebook-content h2 {
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 1em;
  text-align: center;
  border-bottom: 1px solid #8B7355;
  padding-bottom: 0.5em;
}

#observations {
  font-size: 1rem;
  line-height: 1.8;
}

#observations .entry {
  margin-bottom: 1em;
  padding-left: 1em;
  border-left: 2px solid #8B7355;
  font-style: italic;
}
