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

body {
  font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
  background: #0a0808;
  color: #f5f2ec;
  min-height: 100vh;
}

.book-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.book-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  background: linear-gradient(180deg, rgba(26, 8, 8, 0.98), rgba(10, 8, 8, 0.92));
  border-bottom: 1px solid rgba(224, 200, 120, 0.25);
  flex-wrap: wrap;
}

.book-brand {
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(224, 200, 120, 0.75);
}

.book-title {
  font-family: 'Creepster', cursive;
  font-size: clamp(1.2rem, 4vw, 1.6rem);
  color: #fff;
  text-shadow: 0 0 18px rgba(196, 30, 58, 0.35);
}

.book-sub {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.55);
  margin-top: 2px;
}

.book-exit {
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
  font-size: 0.82rem;
  padding: 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  white-space: nowrap;
}

.book-exit:hover {
  color: #fff;
  border-color: rgba(224, 200, 120, 0.45);
}

.book-stage {
  flex: 1;
  display: flex;
  align-items: stretch;
  justify-content: center;
  padding: 12px;
  min-height: 0;
}

.book-frame-wrap {
  flex: 1;
  max-width: 1200px;
  width: 100%;
  background: #111;
  border: 1px solid rgba(224, 200, 120, 0.2);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55);
  min-height: calc(100vh - 96px);
}

.book-frame {
  width: 100%;
  height: calc(100vh - 96px);
  min-height: 480px;
  border: 0;
  background: #fff;
}

.book-setup {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 14px;
  padding: 32px 24px;
  min-height: calc(100vh - 96px);
}

.book-setup h2 {
  font-family: 'Creepster', cursive;
  font-size: 1.8rem;
  color: #e0c878;
}

.book-setup p {
  max-width: 520px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.92rem;
}

.book-setup ol {
  text-align: left;
  max-width: 520px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.88rem;
  padding-left: 1.2rem;
}

.book-setup code {
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.82rem;
}

.book-setup a {
  color: #e0c878;
}

.book-footer {
  padding: 8px 16px 14px;
  text-align: center;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.35);
}

.book-frame-wrap[hidden],
.book-setup[hidden] {
  display: none !important;
}
