.pp-page {
  --pp-gold: #a6782a;
  --pp-ink: #29271f;
  --pp-muted: #756c5d;
  --pp-line: #ded3bd;
  max-width: 1320px;
  margin: auto;
  padding: 26px 32px 36px;
  color: var(--pp-ink);
  font-family: "Noto Serif SC", "Songti SC", serif;
}
.pp-page * {
  box-sizing: border-box;
}
.pp-page button,
.pp-page select {
  font: inherit;
  cursor: pointer;
}
.pp-page button,
.pp-page select,
.pp-page a {
  touch-action: manipulation;
}
.pp-page button:focus-visible,
.pp-page a:focus-visible,
.pp-page select:focus-visible,
.pp-page input:focus-visible,
.pp-page summary:focus-visible {
  outline: 2px solid #97572c;
  outline-offset: 4px;
}
.pp-page button {
  transition:
    background 0.2s,
    color 0.2s;
  border: 1px solid var(--pp-line);
  background: transparent;
  color: var(--pp-ink);
  border-radius: 5px;
  padding: 9px 14px;
  font-size: 13px;
}
.pp-page button:hover {
  background: #ece2ce;
}
.pp-page a:hover {
  color: var(--pp-gold);
}
.pp-breadcrumb {
  display: flex;
  gap: 12px;
  color: var(--pp-muted);
  font-size: 12px;
}
.pp-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 28px 0 30px;
}
.pp-eyebrow {
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--pp-gold);
  margin: 0 0 10px;
}
.pp-heading h1 {
  font-size: 44px;
  font-weight: 500;
  letter-spacing: 7px;
  line-height: 1.3;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 18px;
}
.pp-seal {
  color: #a74730;
  border: 1px solid #a74730;
  padding: 5px 4px;
  font-size: 13px;
  letter-spacing: 0;
  line-height: 1.2;
  transform: rotate(-4deg);
  border-radius: 3px;
}
.pp-subtitle {
  font-size: 14px;
  color: var(--pp-muted);
  margin: 13px 0 0;
  letter-spacing: 1px;
}
.pp-heading-note {
  font-size: 11px;
  display: grid;
  gap: 12px;
  text-align: right;
  color: var(--pp-muted);
  padding-bottom: 2px;
}
.pp-heading-note a {
  color: var(--pp-gold);
}
.pp-workbench {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 324px;
  gap: 22px;
}
.pp-stage-panel {
  border: 1px solid var(--pp-line);
  border-radius: 10px;
  overflow: hidden;
  background: #f8f2e6;
  box-shadow: 0 12px 35px #70511e08;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.pp-stage-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  gap: 10px;
}
.pp-tabs {
  display: flex;
  gap: 3px;
  padding: 3px;
  background: #eee5d5;
  border-radius: 6px;
}
.pp-page .pp-tabs button {
  border: 0;
  padding: 7px 14px;
  font-size: 12px;
  color: #766c59;
}
.pp-page .pp-tabs button[aria-pressed="true"] {
  background: #fffaf0;
  color: #765117;
  box-shadow: 0 2px 6px #5e462111;
}
.pp-live {
  font-size: 11px;
  color: var(--pp-muted);
  display: flex;
  align-items: center;
  gap: 7px;
}
.pp-live i {
  width: 5px;
  height: 5px;
  background: #9e792d;
  border-radius: 50%;
}
.pp-canvas-wrap {
  position: relative;
  flex: 1;
  min-height: 390px;
}
.pp-canvas-wrap canvas {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  display: block;
  cursor: pointer;
}
.pp-stage-caption {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 12px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 10px;
  color: #82765e;
  pointer-events: none;
}
.pp-pipe-keys {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  padding: 12px 18px 16px;
  gap: 3px;
}
.pp-page .pp-pipe-keys button {
  border: 0;
  padding: 9px 2px;
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
}
.pp-pipe-keys button small {
  font-size: 9px;
  color: var(--pp-muted);
}
.pp-page .pp-pipe-keys button[aria-pressed="true"] {
  background: #a6782a;
  color: #fff8e9;
}
.pp-pipe-keys button[aria-pressed="true"] small {
  color: #fff3d5;
}
.pp-playback {
  border-top: 1px solid var(--pp-line);
  padding: 15px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.pp-actions {
  display: flex;
  gap: 9px;
}
.pp-page .pp-primary {
  background: #a6782a;
  color: #fffaf1;
  border-color: #a6782a;
}
.pp-page .pp-primary:hover {
  background: #89601f;
}
.pp-speed {
  font-size: 11px;
  color: var(--pp-muted);
  white-space: nowrap;
}
.pp-speed select {
  border: 0;
  color: var(--pp-ink);
  background: transparent;
  padding: 5px;
}
.pp-progress {
  height: 2px;
  background: #e9dfcb;
}
.pp-progress span {
  height: 100%;
  display: block;
  width: 0;
  background: var(--pp-gold);
}
.pp-reading {
  border: 1px solid var(--pp-line);
  border-radius: 10px;
  padding: 22px;
  background: #fdfbf7;
  min-width: 0;
}
.pp-term-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.pp-term-heading h2 {
  font-size: 36px;
  font-weight: 500;
  letter-spacing: 5px;
  line-height: 1.3;
}
.pp-longitude {
  font-size: 10px;
  color: var(--pp-muted);
  text-align: right;
}
.pp-longitude strong {
  display: block;
  font-size: 21px;
  font-weight: 400;
  margin-top: 4px;
  color: var(--pp-ink);
}
.pp-term-prose {
  font-size: 12px;
  line-height: 1.9;
  color: var(--pp-muted);
  margin: 14px 0 20px;
  min-height: 46px;
}
.pp-sound-card {
  background: #f5efdf;
  border: 1px solid #e7dac1;
  border-radius: 7px;
  padding: 15px;
}
.pp-sound-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.pp-sound-title h3 {
  font-size: 25px;
  letter-spacing: 4px;
  margin-top: 3px;
}
.pp-small {
  font-size: 10px;
  color: var(--pp-muted);
  line-height: 1.7;
}
.pp-frequency {
  text-align: right;
}
.pp-frequency strong {
  font-size: 22px;
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  display: block;
}
.pp-frequency span {
  font-size: 9px;
  color: var(--pp-muted);
}
#pp-wave {
  width: 100%;
  height: 32px;
  margin: 8px 0;
  stroke: #b9934c;
  fill: none;
  stroke-width: 1;
}
.pp-sound-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.pp-page .pp-sound-controls button {
  font-size: 11px;
  padding: 7px 9px;
  border-color: #d8c49e;
}
.pp-sound-controls label {
  font-size: 10px;
  color: var(--pp-muted);
  display: flex;
  align-items: center;
  gap: 5px;
}
.pp-sound-controls input {
  width: 65px;
  accent-color: var(--pp-gold);
}
#pp-audio-status {
  margin-top: 8px;
  font-size: 9px;
}
.pp-gua-card {
  display: flex;
  align-items: center;
  gap: 20px;
  border-bottom: 1px solid #e5dbca;
  padding: 20px 0;
}
.pp-hex-lines {
  width: 54px;
  flex-shrink: 0;
  display: grid;
  gap: 5px;
}
.pp-hex-lines div {
  display: flex;
  height: 5px;
  gap: 8px;
}
.pp-hex-lines i {
  flex: 1;
  background: #a6782a;
}
.pp-gua-card h3 {
  font-size: 18px;
  margin: 3px 0 4px;
}
.pp-middle {
  font-size: 10px;
  color: #a05c45;
  margin-top: 8px;
}
.pp-phenology {
  padding-top: 18px;
}
.pp-phenology ol {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 8px;
  font-size: 12px;
}
.pp-phenology li {
  display: flex;
  align-items: center;
  gap: 13px;
}
.pp-phenology li span {
  font-size: 9px;
  color: #9a8257;
  letter-spacing: 1px;
}
.pp-year {
  margin-top: 28px;
  padding: 23px 24px;
  border: 1px solid var(--pp-line);
  border-radius: 10px;
  background: #fdfbf7;
}
.pp-section-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  gap: 12px;
}
.pp-section-heading h2 {
  font-size: 22px;
  letter-spacing: 3px;
}
.pp-section-heading .pp-eyebrow {
  margin-bottom: 5px;
}
.pp-year-actions {
  display: flex;
  gap: 7px;
}
.pp-page .pp-year-actions button {
  padding: 7px 12px;
  font-size: 11px;
}
.pp-term-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 7px;
}
.pp-page .pp-term-grid button {
  padding: 11px 2px 9px;
  font-size: 13px;
  display: grid;
  gap: 7px;
  text-align: center;
  border-color: #e8e0d3;
  position: relative;
}
.pp-term-grid small {
  font-size: 9px;
  color: var(--pp-muted);
}
.pp-term-grid button[data-season="spring"] {
  border-top: 2px solid #95a486;
}
.pp-term-grid button[data-season="summer"] {
  border-top: 2px solid #b87963;
}
.pp-term-grid button[data-season="autumn"] {
  border-top: 2px solid #c2a263;
}
.pp-term-grid button[data-season="winter"] {
  border-top: 2px solid #8597a0;
}
.pp-page .pp-term-grid button[aria-pressed="true"] {
  background: #a6782a;
  border-color: #a6782a;
  color: white;
}
.pp-term-grid button[aria-pressed="true"] small {
  color: #ffebc7;
}
.pp-term-grid button[data-today="true"]:after {
  content: "";
  width: 4px;
  height: 4px;
  background: #ac402a;
  border-radius: 50%;
  position: absolute;
  right: 5px;
  top: 5px;
}
.pp-footnote {
  font-size: 11px;
  line-height: 1.8;
  color: var(--pp-muted);
  margin-top: 16px;
}
.pp-notes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 36px;
  padding: 40px 0 30px;
  scroll-margin-top: 100px;
}
.pp-notes h2 {
  font-size: 18px;
  margin: 10px 0 15px;
}
.pp-notes article > p:not(.pp-eyebrow) {
  font-size: 12px;
  line-height: 2;
  color: var(--pp-muted);
  margin-bottom: 10px;
}
.pp-notes a {
  font-size: 11px;
  color: #94702e;
}
.pp-reference {
  border-top: 1px solid var(--pp-line);
  border-bottom: 1px solid var(--pp-line);
  padding: 18px 0;
}
.pp-reference summary {
  cursor: pointer;
  font-size: 15px;
}
.pp-reference summary span {
  font-size: 11px;
  color: var(--pp-muted);
  margin-left: 20px;
}
.pp-table-scroll {
  overflow: auto;
  margin-top: 20px;
}
.pp-reference table {
  border-collapse: collapse;
  width: 100%;
  font-size: 12px;
  white-space: nowrap;
}
.pp-reference td,
.pp-reference th {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #e8dfcf;
}
.pp-reference th {
  color: #93712f;
  font-weight: 400;
}
.pp-reference caption {
  text-align: left;
  padding-bottom: 12px;
}
.pp-endnote {
  text-align: center;
  color: #99866a;
  font-size: 11px;
  letter-spacing: 5px;
  padding-top: 30px;
}
@media (min-width: 1450px) {
  .pp-canvas-wrap {
    min-height: 425px;
  }
}
@media (max-width: 1000px) {
  .pp-page {
    padding: 20px;
  }
  .pp-workbench {
    grid-template-columns: minmax(0, 1fr) 290px;
    gap: 15px;
  }
  .pp-reading {
    padding: 18px;
  }
  .pp-stage-toolbar {
    padding: 14px 12px;
  }
  .pp-live {
    font-size: 10px;
  }
  .pp-pipe-keys {
    grid-template-columns: repeat(6, 1fr);
    padding: 8px 12px;
  }
  .pp-page .pp-pipe-keys button {
    flex-direction: row;
    justify-content: center;
    padding: 6px 2px;
  }
  .pp-playback {
    padding: 12px;
  }
  .pp-actions {
    gap: 5px;
  }
  .pp-page .pp-actions button {
    padding: 8px;
    font-size: 11px;
  }
  .pp-term-grid {
    grid-template-columns: repeat(8, 1fr);
  }
}
@media (max-width: 760px) {
  .pp-page {
    padding: 18px 14px;
  }
  .pp-heading {
    padding: 24px 0;
    display: block;
  }
  .pp-heading h1 {
    font-size: 34px;
  }
  .pp-subtitle {
    font-size: 12px;
    letter-spacing: 0;
    line-height: 1.9;
  }
  .pp-heading-note {
    display: none;
  }
  .pp-workbench {
    grid-template-columns: 1fr;
  }
  .pp-canvas-wrap {
    min-height: 340px;
  }
  .pp-stage-caption {
    left: 14px;
    right: 14px;
    font-size: 9px;
  }
  .pp-reading {
    padding: 20px;
  }
  .pp-term-prose {
    min-height: 0;
  }
  .pp-term-grid {
    grid-template-columns: repeat(6, 1fr);
    gap: 5px;
  }
  .pp-year {
    padding: 20px 12px;
    margin-top: 20px;
  }
  .pp-page .pp-term-grid button {
    font-size: 12px;
  }
  .pp-notes {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 30px 6px;
  }
  .pp-notes article {
    border-bottom: 1px solid #e7dece;
    padding-bottom: 18px;
  }
  .pp-reference summary span {
    display: block;
    margin: 8px 0 0;
    font-size: 10px;
  }
  .pp-section-heading h2 {
    font-size: 19px;
  }
  .pp-page .pp-year-actions button {
    padding: 7px 9px;
  }
  .pp-playback {
    flex-wrap: wrap;
  }
  .pp-gua-card {
    gap: 24px;
  }
  .pp-pipe-keys {
    grid-template-columns: repeat(6, 1fr);
  }
}
@media (prefers-reduced-motion: reduce) {
  .pp-page * {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
