:root {
  color-scheme: light;
  --paper: #f6f2ea;
  --ink: #20211f;
  --muted: #686d66;
  --line: #d2cbc0;
  --panel: #fffaf1;
  --concrete: #5f6762;
  --rust: #b95b3d;
  --signal: #d0a73d;
  --green: #2f6e5a;
  --danger: #9b3d34;
  font-family:
    "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(rgba(246, 242, 234, 0.88), rgba(246, 242, 234, 0.96)),
    url("assets/concrete-strip.svg") top center / 100% auto no-repeat,
    var(--paper);
}

button {
  min-height: 48px;
  border: 1px solid #1f2522;
  border-radius: 6px;
  padding: 12px 16px;
  color: #fffaf1;
  background: #1f2522;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

button:hover {
  background: #3b433f;
}

button:focus-visible {
  outline: 3px solid var(--signal);
  outline-offset: 2px;
}

.ghost-button {
  color: var(--ink);
  background: transparent;
  border-color: var(--line);
}

.ghost-button:hover {
  background: rgba(95, 103, 98, 0.08);
}

.game-shell {
  width: min(920px, calc(100% - 28px));
  margin: 0 auto;
  padding: 32px 0 56px;
}

.site-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  min-height: 172px;
  padding-top: 38px;
}

.kicker,
.node-tag,
.status-label {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0;
}

h1,
h2,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 8px 0 0;
  font-size: clamp(34px, 8vw, 62px);
  line-height: 1.04;
  letter-spacing: 0;
}

h2 {
  margin: 10px 0 18px;
  font-size: 30px;
  line-height: 1.22;
  letter-spacing: 0;
}

.status-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 18px 0;
  border: 1px solid var(--line);
  background: var(--line);
}

.status-strip > div {
  min-width: 0;
  padding: 14px;
  background: rgba(255, 250, 241, 0.86);
}

.status-strip strong {
  display: block;
  margin-top: 5px;
  font-size: 15px;
  line-height: 1.3;
}

.start-panel,
.story-panel,
.ending-panel,
.review-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(22px, 4vw, 38px);
  background: rgba(255, 250, 241, 0.94);
  box-shadow: 0 18px 50px rgba(47, 52, 49, 0.08);
}

.start-panel p:not(.node-tag) {
  max-width: 680px;
  margin: 0 0 26px;
  color: #2b2d2a;
  font-size: 18px;
  line-height: 1.85;
}

#storyText,
#endingText {
  margin: 0 0 28px;
  color: #2b2d2a;
  font-size: 19px;
  line-height: 1.85;
}

.option-list {
  display: grid;
  gap: 12px;
}

.option-button {
  display: grid;
  grid-template-columns: 34px 1fr;
  align-items: start;
  gap: 12px;
  width: 100%;
  min-height: 64px;
  padding: 16px;
  text-align: left;
  color: var(--ink);
  background: #f9f4ea;
  border-color: #c7beb0;
}

.option-button:hover {
  background: #efe6d6;
  border-color: #9a8f80;
}

.option-key {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: #fffaf1;
  background: var(--concrete);
  font-weight: 800;
}

.option-text {
  line-height: 1.6;
}

.ending-panel {
  border-color: #c8b477;
}

.ending-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.review-panel {
  margin-top: 16px;
}

.review-panel h2 {
  font-size: 22px;
}

.review-panel ol {
  margin: 0;
  padding-left: 22px;
}

.review-panel li {
  margin: 0 0 12px;
  line-height: 1.65;
}

.hidden {
  display: none;
}

@media (max-width: 720px) {
  .game-shell {
    width: min(100% - 20px, 920px);
    padding-top: 20px;
  }

  .site-header {
    display: grid;
    min-height: 146px;
    align-items: end;
  }

  .site-header .ghost-button {
    width: 100%;
  }

  .status-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  h2 {
    font-size: 25px;
  }

  #storyText,
  #endingText,
  .start-panel p:not(.node-tag) {
    font-size: 17px;
  }

  .option-button {
    grid-template-columns: 30px 1fr;
    padding: 14px;
  }
}

@media (max-width: 420px) {
  .status-strip {
    grid-template-columns: 1fr;
  }
}
