:root {
  color-scheme: light;
  --page: #eef2ee;
  --paper: #fbfaf4;
  --paper-deep: #f1eee4;
  --ink: #202522;
  --soft-ink: #5d655f;
  --line: rgba(48, 57, 50, 0.16);
  --moss: #60786b;
  --blue-gray: #536f79;
  --cinnabar: #9b4d41;
  --shadow: 0 18px 46px rgba(31, 39, 35, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--page);
  overflow-x: hidden;
}

body {
  min-height: 100%;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(96, 120, 107, 0.12) 0 1px, transparent 1px)
      left top / 80px 100%,
    var(--page);
  font-family:
    "Noto Serif SC", "Source Han Serif SC", "Songti SC", SimSun, serif;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  background-image: url("./assets/paper-texture.png");
  background-size: 360px 360px;
  opacity: 0.58;
  pointer-events: none;
}

.page-shell {
  width: 100%;
  max-width: 760px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 30px 18px 44px;
}

.masthead {
  position: relative;
  min-height: 270px;
  padding: 18px 0 34px;
  border-bottom: 1px solid var(--line);
}

.masthead::after {
  position: absolute;
  top: 54px;
  right: 0;
  width: 148px;
  height: 148px;
  content: "";
  background: url("./assets/poem-mark.png") center / contain no-repeat;
  opacity: 0.72;
  pointer-events: none;
}

.brand-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.seal {
  display: inline-grid;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  place-items: center;
  margin-top: 7px;
  border-radius: 6px;
  background: var(--cinnabar);
  box-shadow: 0 10px 26px rgba(155, 77, 65, 0.24);
  color: #fffdf7;
  font-size: 1.28rem;
  font-weight: 700;
  line-height: 1;
}

.kicker,
.eyebrow,
.board-note,
.message-meta,
.page-footer {
  font-family:
    "Noto Sans SC", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

.kicker {
  margin: 0 0 6px;
  color: var(--moss);
  font-size: 0.8rem;
  font-weight: 700;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 3.35rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 0.98;
}

.lead {
  max-width: 12em;
  margin: 70px 0 0;
  color: #303830;
  font-size: 1.3rem;
  line-height: 1.85;
}

.board-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  padding: 24px 0 16px;
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  margin-bottom: 7px;
  color: var(--blue-gray);
  font-size: 0.78rem;
  font-weight: 700;
}

h2 {
  margin-bottom: 0;
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.2;
}

.board-note {
  min-width: max-content;
  margin-bottom: 3px;
  color: var(--soft-ink);
  font-size: 0.86rem;
}

.board-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.message-list {
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 22px 0 10px;
}

.message-guide {
  margin: 22px 0 4px;
  border: 1px solid rgba(48, 57, 50, 0.14);
  border-radius: 8px;
  background: rgba(251, 250, 244, 0.78);
  box-shadow: var(--shadow);
  padding: 18px;
}

.message-guide h2 {
  font-size: 1.28rem;
}

.guide-lead {
  margin: 10px 0 0;
  color: var(--soft-ink);
  font-size: 0.96rem;
  line-height: 1.85;
}

.guide-list {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  font-family:
    "Noto Sans SC", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

.guide-list p {
  margin-bottom: 0;
  color: var(--soft-ink);
  font-size: 0.9rem;
  line-height: 1.65;
}

.guide-list span {
  color: var(--cinnabar);
  font-weight: 700;
}

.message-card {
  position: relative;
  overflow: hidden;
  min-width: 0;
  border: 1px solid rgba(48, 57, 50, 0.14);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(251, 250, 244, 0.88)),
    var(--paper);
  box-shadow: var(--shadow);
  padding: 19px 18px 18px;
}

.message-card::before {
  position: absolute;
  top: 18px;
  left: 0;
  width: 3px;
  height: 46px;
  content: "";
  background: var(--moss);
}

.message-card:nth-child(2n)::before {
  background: var(--blue-gray);
}

.message-card:nth-child(3n)::before {
  background: var(--cinnabar);
}

.message-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  min-width: 0;
  color: var(--soft-ink);
  font-size: 0.88rem;
}

.message-name {
  overflow-wrap: anywhere;
  font-weight: 700;
}

.message-date {
  flex: 0 0 auto;
  color: rgba(93, 101, 95, 0.78);
  white-space: nowrap;
}

.message-content {
  margin: 13px 0 0;
  font-size: 1.08rem;
  line-height: 1.88;
  overflow-wrap: anywhere;
}

.empty-state {
  border: 1px dashed var(--line);
  border-radius: 8px;
  padding: 34px 22px;
  color: var(--soft-ink);
  text-align: center;
}

.page-footer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 28px 0 6px;
  color: rgba(93, 101, 95, 0.82);
  font-size: 0.88rem;
  line-height: 1.7;
}

.page-footer p {
  margin-bottom: 0;
}

.beian-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  width: 100%;
  color: rgba(93, 101, 95, 0.78);
  font-size: 0.78rem;
}

.beian-links a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: inherit;
  text-decoration: none;
}

.beian-links a:focus,
.beian-links a:hover {
  color: var(--ink);
  text-decoration: underline;
}

.police-beian img {
  width: 20px;
  height: 21px;
  flex: 0 0 auto;
}

.footer-line {
  width: 42px;
  height: 1px;
  flex: 0 0 auto;
  background: var(--line);
}

@media (min-width: 720px) {
  .page-shell {
    padding: 54px 30px 62px;
  }

  .masthead {
    min-height: 330px;
    padding-top: 24px;
  }

  .masthead::after {
    top: 62px;
    right: 20px;
    width: 214px;
    height: 214px;
  }

  h1 {
    font-size: 5.25rem;
  }

  .lead {
    max-width: 14em;
    margin-top: 92px;
    font-size: 1.5rem;
  }

  .message-card {
    padding: 24px 26px 24px;
  }

  .message-content {
    font-size: 1.16rem;
  }
}

@media (max-width: 600px) {
  .page-shell {
    margin-right: 0;
    margin-left: 0;
    max-width: 390px;
  }
}

@media (max-width: 360px) {
  .page-shell {
    padding-right: 14px;
    padding-left: 14px;
  }

  h1 {
    font-size: 2.78rem;
  }

  .masthead::after {
    width: 118px;
    height: 118px;
  }

  .board-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .board-actions {
    width: 100%;
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .board-note {
    min-width: 0;
  }
}

@media (max-width: 480px) {
  .board-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .board-actions {
    width: 100%;
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .board-note {
    min-width: 0;
  }

  .message-meta {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }

  .message-date {
    white-space: normal;
  }
}
