:root {
  color-scheme: light;
  font-family: "Inter", "Segoe UI", sans-serif;
  background: #f4f6fb;
  color: #1d1d1f;
}

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

body {
  min-height: 100vh;
}

.app {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px 48px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.app__header {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
}

.app__header h1 {
  font-size: 2rem;
  margin-bottom: 4px;
}

.app__header p {
  color: #4b5563;
}

.stats {
  display: flex;
  gap: 16px;
}

.stats__item {
  background: white;
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
  min-width: 120px;
}

.stats__label {
  display: block;
  font-size: 0.8rem;
  color: #64748b;
}

.stats__value {
  font-size: 1.2rem;
  font-weight: 600;
}

.app__main {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}

.map {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  min-height: 420px;
  background: linear-gradient(145deg, #e0f2fe, #bae6fd);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.5);
}

.map__background {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 20% 30%, #a7f3d0, transparent 50%),
    radial-gradient(circle at 70% 20%, #fcd34d, transparent 45%),
    radial-gradient(circle at 80% 70%, #c4b5fd, transparent 40%),
    radial-gradient(circle at 30% 80%, #fbcfe8, transparent 50%);
  opacity: 0.7;
}

.hotspot {
  position: absolute;
  padding: 10px 16px;
  border-radius: 999px;
  border: none;
  background: #1d4ed8;
  color: white;
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 10px 18px rgba(37, 99, 235, 0.35);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.hotspot[data-hotspot="forest"] {
  top: 18%;
  left: 12%;
}

.hotspot[data-hotspot="ruins"] {
  top: 35%;
  right: 14%;
}

.hotspot[data-hotspot="lake"] {
  bottom: 18%;
  left: 40%;
}

.hotspot[data-hotspot="cave"] {
  bottom: 30%;
  right: 22%;
}

.hotspot:disabled {
  cursor: not-allowed;
  opacity: 0.4;
  box-shadow: none;
}

.hotspot:not(:disabled):hover {
  transform: translateY(-2px) scale(1.02);
}

.inventory {
  background: white;
  border-radius: 20px;
  padding: 20px;
  box-shadow: 0 20px 35px rgba(15, 23, 42, 0.1);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.inventory__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.inventory__header h2 {
  font-size: 1.4rem;
}

.inventory__clear {
  border: none;
  background: #fef2f2;
  color: #b91c1c;
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
}

.inventory__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  min-height: 180px;
}

.inventory__slot {
  border: 1px dashed #cbd5f5;
  border-radius: 12px;
  padding: 12px;
  min-height: 90px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  justify-content: center;
  align-items: flex-start;
  background: #f8fafc;
}

.inventory__slot--filled {
  border: 1px solid #93c5fd;
  background: #eff6ff;
}

.inventory__slot span {
  font-size: 0.85rem;
  color: #475569;
}

.inventory__slot strong {
  font-size: 1rem;
  color: #0f172a;
}

.inventory__footer {
  display: flex;
  justify-content: space-between;
  color: #475569;
  font-size: 0.9rem;
}

.log {
  background: white;
  border-radius: 16px;
  padding: 12px 16px;
  min-height: 70px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.log__item {
  display: flex;
  justify-content: space-between;
  color: #475569;
  font-size: 0.9rem;
}

.popup {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.popup[aria-hidden="false"] {
  display: flex;
}

.popup__content {
  background: white;
  border-radius: 16px;
  padding: 24px;
  max-width: 320px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: 0 25px 40px rgba(15, 23, 42, 0.2);
}

.popup__actions {
  display: flex;
  gap: 12px;
}

.popup__actions button {
  flex: 1;
  border: none;
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  background: #2563eb;
  color: white;
}

.popup__actions button.secondary {
  background: #e2e8f0;
  color: #1e293b;
}
