.pact-veil,
.pact-story,
.pact-restore,
.pact-sheet {
  font-family: Inter, "Supply Sans", sans-serif;
}

.pact-veil,
.pact-sheet,
.beta-note {
  display: none !important;
}

.pact-story {
  position: fixed;
  left: 50%;
  top: 46%;
  z-index: 4;
  width: min(720px, 88vw);
  transform: translate(-50%, -54%);
  color: #17382c;
  text-align: center;
  pointer-events: none;
}

.pact-story.is-map {
  top: auto;
  bottom: 118px;
  transform: translate(-50%, 0);
}

.pact-story.is-map + .pact-veil,
.pact-veil.is-map {
  opacity: 0;
}

.pact-kicker {
  margin: 0 0 10px;
  font: 600 12px/1 "PP Supply Mono", "Google Sans Code", ui-monospace, monospace;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #2f6d57;
}

.pact-story h1 {
  margin: 0;
  font-family: Newsreader, Georgia, serif;
  font-size: clamp(40px, 6vw, 76px);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 0.96;
}

.pact-story p {
  max-width: 38rem;
  margin: 16px auto 0;
  font-size: clamp(15px, 1.7vw, 18px);
  line-height: 1.45;
  color: #3d5148;
}

.pact-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 22px;
  pointer-events: auto;
}

.pact-actions button,
.pact-restore,
.pact-sheet button,
.pact-sheet a.pact-btn {
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  font: 600 14px/1 Inter, "Supply Sans", sans-serif;
}

.pact-actions button,
.pact-restore {
  min-height: 42px;
  padding: 0 16px;
  color: #17382c;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: inset 0 0 0 1px rgba(23, 56, 44, 0.12), 0 8px 24px rgba(18, 42, 32, 0.08);
}

.pact-actions button.pact-primary,
.pact-sheet .pact-primary {
  color: #f7f4ec;
  background: #1d2422;
}

.pact-restore {
  position: fixed;
  left: 22px;
  bottom: 22px;
  z-index: 4;
}

.pact-restore[hidden],
.pact-story[hidden],
.pact-veil[hidden] {
  display: none;
}

.pact-sheet {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: grid;
  place-items: center;
  padding: 24px 16px;
  background: rgba(18, 36, 29, 0.38);
  backdrop-filter: blur(8px);
}

.pact-sheet[hidden] {
  display: none;
}

.pact-panel {
  width: min(880px, 100%);
  max-height: min(860px, calc(100vh - 48px));
  overflow: auto;
  padding: 28px 28px 22px;
  border-radius: 28px;
  background: #fbf7ef;
  color: #173028;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.28);
}

.pact-panel header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.pact-panel h2 {
  margin: 6px 0 0;
  font-family: Newsreader, Georgia, serif;
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1;
}

.pact-close {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  color: #173028;
  box-shadow: inset 0 0 0 1px rgba(23, 48, 40, 0.1);
}

.pact-panel section {
  margin-top: 28px;
}

.pact-panel h3 {
  margin: 0 0 8px;
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #2f6d57;
}

.pact-panel p,
.pact-panel li {
  margin: 0;
  font-size: 16px;
  line-height: 1.5;
}

.pact-panel p + p,
.pact-panel ul {
  margin-top: 10px;
}

.pact-panel ul {
  padding-left: 18px;
}

.pact-quote {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  background: #eef5ef;
}

.pact-table {
  width: 100%;
  margin-top: 12px;
  border-collapse: collapse;
  font-size: 15px;
}

.pact-table th,
.pact-table td {
  padding: 10px 8px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid rgba(23, 48, 40, 0.1);
}

.pact-table th {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #5d6f67;
}

.pact-token {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 8px 16px;
  margin-top: 12px;
  padding: 16px;
  border-radius: 16px;
  background: #17382c;
  color: #f4f7f2;
}

.pact-token b {
  font-weight: 600;
  color: #d7ecdf;
}

.pact-end {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 28px;
}

.pact-end small {
  max-width: 36rem;
  color: #5d6f67;
  line-height: 1.4;
}

.hud-xp {
  display: none !important;
}

@media (max-width: 720px) {
  .pact-story {
    top: 42%;
  }
  .pact-story.is-map {
    bottom: 96px;
  }
  .pact-token {
    grid-template-columns: 1fr;
  }
  .pact-panel {
    padding: 22px 16px 16px;
  }
}
