:root {
  --bg: #fbf7f1;
  --surface: #ffffff;
  --surface-2: #f7f0e4;
  --surface-3: #fdfaf5;
  --ink: #2b211c;
  --ink-soft: #4a3c33;
  --muted: #6b5c51;
  --line: #e5d9c8;
  --line-soft: #f0e8db;
  --red: #8d0209;
  --red-2: #a8100f;
  --red-ink: #ffffff;
  --red-wash: #fbeeec;
  --red-line: #efd4cf;
  --gold: #9a7433;
  --gold-wash: #f8f1e0;
  --strip-ink: #f7e7dd;
  --strip-strong: #fff3e8;
  --strip-soft: #f0d6c8;
  --red-dark: #7a0107;
  --red-deep: #6d0208;
  --nav-ink: #fbeee6;
  --nav-line: rgba(255, 240, 230, 0.18);
  --nav-strong: #fff8f0;
  --hover-shadow: 0 2px 8px rgba(90, 40, 20, 0.07);
  --badge-bg: rgba(255, 252, 246, 0.9);
  --chip-ink: #fff6ef;
  --shell: 1000px;
  --radius: 2px;
  --font-body: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Source Han Sans SC", "Noto Sans CJK SC", sans-serif;
  --font-serif: "Songti SC", "Source Han Serif SC", "Noto Serif CJK SC", "STSong", "SimSun", serif;
  --cta-fill: #6d0208;
  --cta-edge: #eed9c4;
  --cta-elevation: 0 3px 10px rgba(70, 20, 10, 0.16);
  --cta-rail: #f9efe0;
  --cta-sheen: #fdf7ee;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.8;
  overflow-wrap: anywhere;
}

h1 {
  font-family: var(--font-serif);
  font-size: 30px;
  line-height: 1.4;
  margin: 0;
  font-weight: 700;
}

h2 {
  font-family: var(--font-serif);
  font-size: 20px;
  line-height: 1.5;
  margin: 0;
  font-weight: 700;
}

h3 {
  font-family: var(--font-serif);
  font-size: 17px;
  line-height: 1.55;
  margin: 0;
  font-weight: 700;
}

p {
  margin: 0;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--ink-soft);
  text-decoration: none;
}

a:hover {
  color: var(--red);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 2px;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.wrap {
  width: var(--shell);
  max-width: calc(100% - 32px);
  margin: 0 auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* top strip */

.topstrip {
  background: var(--red);
  color: var(--strip-ink);
  font-size: 12px;
}

.topstrip-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 34px;
}

.topstrip b {
  font-weight: 600;
  color: var(--strip-strong);
}

.topstrip-right {
  color: var(--strip-soft);
}

/* header */

.masthead {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.masthead-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand img {
  width: 178px;
  height: 58px;
  object-fit: contain;
}

.brand-sub {
  display: block;
  border-left: 1px solid var(--line);
  padding-left: 12px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}

.brand-sub b {
  display: block;
  font-family: var(--font-serif);
  font-size: 14px;
  color: var(--red);
  font-weight: 700;
}

.searchbar {
  display: flex;
  align-items: stretch;
  gap: 6px;
  flex-wrap: wrap;
}

.searchbar select {
  font: inherit;
  font-size: 13px;
  color: var(--ink-soft);
  background: var(--surface-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 8px;
  min-height: 38px;
}

.searchbar input {
  font: inherit;
  font-size: 14px;
  color: var(--ink);
  background: var(--surface-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 6px 10px;
  min-height: 38px;
  width: 210px;
  max-width: 100%;
}

.searchbar button {
  font: inherit;
  font-size: 14px;
  border: 1px solid var(--red);
  background: var(--red);
  color: var(--red-ink);
  border-radius: var(--radius);
  padding: 0 18px;
  min-height: 38px;
  cursor: pointer;
}

.searchbar button:hover {
  background: var(--red-2);
}

/* nav strip */

.catstrip {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--red);
  border-top: 1px solid var(--red-dark);
  border-bottom: 2px solid var(--red-deep);
}

.catstrip-in {
  display: flex;
  overflow-x: auto;
  scrollbar-width: none;
}

.catstrip-in::-webkit-scrollbar {
  display: none;
}

.catstrip ul {
  display: flex;
  min-width: max-content;
}

.catstrip a {
  display: block;
  padding: 0 20px;
  line-height: 46px;
  font-size: 15px;
  color: var(--nav-ink);
  border-right: 1px solid var(--nav-line);
}

.catstrip a:hover,
.catstrip a[aria-current="page"] {
  background: var(--red-deep);
  color: var(--nav-strong);
  text-decoration: none;
}

/* hero */

.hero {
  margin-top: 16px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--red);
}

.hero-copy {
  padding: 30px 28px 26px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
}

.hero-kicker {
  font-size: 12px;
  color: var(--gold);
}

.hero-copy h1 {
  font-size: 33px;
  color: var(--red);
  line-height: 1.35;
}

.hero-line {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--ink);
  line-height: 1.6;
}

.hero-text {
  font-size: 15px;
  line-height: 1.9;
  color: var(--muted);
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.hero-tags span {
  font-size: 12px;
  line-height: 1.8;
  padding: 0 10px;
  border: 1px solid var(--red-line);
  background: var(--red-wash);
  color: var(--red);
  border-radius: 999px;
}

.hero-photo {
  position: relative;
  overflow: hidden;
  border-left: 1px solid var(--line);
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  min-height: 260px;
}

/* notice */

.notice {
  margin-top: 14px;
  background: var(--red-wash);
  border: 1px solid var(--red-line);
  padding: 14px 18px;
}

.notice h2 {
  font-size: 16px;
  color: var(--red);
  margin-bottom: 6px;
}

.notice ul {
  display: grid;
  gap: 3px;
}

.notice li {
  font-size: 15px;
  line-height: 1.8;
  color: var(--ink);
  padding-left: 14px;
  position: relative;
}

.notice li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.72em;
  width: 5px;
  height: 5px;
  background: var(--red);
}

/* home body: left sidebar + main */

.body-cols {
  display: grid;
  grid-template-columns: 196px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  margin-top: 18px;
}

.side {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.side-box {
  background: var(--surface);
  border: 1px solid var(--line);
}

.side-box h2 {
  font-size: 15px;
  padding: 9px 12px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--line);
  color: var(--red);
}

.side-list {
  padding: 8px 12px 10px;
  display: grid;
  gap: 2px;
  font-size: 14px;
  line-height: 1.7;
}

.side-list a {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  padding: 4px 0;
  color: var(--ink-soft);
}

.side-list a span {
  font-size: 12px;
  color: var(--muted);
}

.side-list a:hover {
  color: var(--red);
  text-decoration: none;
}

.side-note {
  padding: 10px 12px 12px;
  font-size: 13px;
  line-height: 1.8;
  color: var(--muted);
}

.main-col {
  min-width: 0;
}

/* section head */

.sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 0 0 8px;
  margin-bottom: 12px;
  border-bottom: 2px solid var(--line);
}

.sec-head h2 {
  font-size: 21px;
  color: var(--ink);
}

.sec-head h2 span {
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--muted);
  margin-left: 8px;
  font-weight: 400;
}

.sec-more {
  font-size: 13px;
  color: var(--muted);
}

/* card grid */

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.card:hover {
  border-color: var(--red-line);
  box-shadow: var(--hover-shadow);
}

.card-photo {
  display: block;
  position: relative;
  overflow: hidden;
  background: var(--surface-2);
  border-bottom: 1px solid var(--line-soft);
}

.card-photo img {
  width: 100%;
  height: 190px;
  object-fit: cover;
}

.card-cat {
  position: absolute;
  left: 8px;
  top: 8px;
  font-size: 12px;
  line-height: 1.7;
  padding: 0 8px;
  background: var(--badge-bg);
  border: 1px solid var(--red-line);
  color: var(--red);
}

.card-body {
  padding: 10px 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.card-body h3 {
  font-size: 16px;
  line-height: 1.6;
}

.card-body h3 a {
  color: var(--ink);
}

.card-lead {
  font-size: 13px;
  line-height: 1.7;
  color: var(--muted);
}

.card-meta {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
  font-size: 12px;
}

.card-meta .cat-name {
  color: var(--red);
  font-weight: 600;
}

/* list rows */

.rows {
  background: var(--surface);
  border: 1px solid var(--line);
}

.row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line-soft);
}

.row:last-child {
  border-bottom: 0;
}

.row:hover {
  background: var(--surface-3);
}

.row-idx {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--gold);
  padding-top: 2px;
}

.row-body {
  min-width: 0;
}

.row-body h2,
.row-body h3 {
  font-size: 17px;
  line-height: 1.55;
  margin-bottom: 2px;
}

.row-body a {
  color: var(--ink);
}

.row-lead {
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
  margin-bottom: 5px;
}

.row-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  font-size: 12px;
}

.chipcat {
  font-size: 12px;
  line-height: 1.8;
  padding: 0 7px;
  color: var(--red);
  background: var(--red-wash);
  border: 1px solid var(--red-line);
}

.tag {
  font-size: 12px;
  line-height: 1.7;
  padding: 0 7px;
  color: var(--muted);
  background: var(--surface-3);
  border: 1px solid var(--line);
}

a.tag:hover {
  color: var(--red);
  border-color: var(--red-line);
  text-decoration: none;
}

.row-thumb {
  display: block;
  overflow: hidden;
  border: 1px solid var(--line-soft);
  background: var(--surface-2);
}

.row-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.row-with-thumb {
  grid-template-columns: 128px 30px minmax(0, 1fr);
  align-items: start;
}

/* tag cloud */

.tagcloud {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tagcloud a {
  font-size: 13px;
  line-height: 1.9;
  padding: 0 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
}

.tagcloud a span {
  color: var(--muted);
  font-size: 11px;
  margin-left: 4px;
}

.tagcloud a:hover {
  border-color: var(--red-line);
  color: var(--red);
  text-decoration: none;
}

/* about */

.about {
  margin-top: 18px;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 18px 20px;
  display: grid;
  gap: 8px;
}

.about p {
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink-soft);
}

/* crumbs */

.crumb {
  font-size: 13px;
  color: var(--muted);
  margin: 14px 0 10px;
  line-height: 1.7;
}

.crumb .sep {
  margin: 0 5px;
  color: var(--gold);
}

/* page head band */

.pagehead {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--red);
  padding: 18px 20px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.pagehead h1 {
  font-size: 27px;
  color: var(--ink);
  margin-top: 4px;
}

.pagehead .kicker {
  font-size: 12px;
  color: var(--gold);
}

.pagehead .count {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

.intro {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 0;
  padding: 14px 20px;
  display: grid;
  gap: 8px;
  margin-bottom: 14px;
}

.intro p {
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink);
}

/* filters */

.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
  font-size: 13px;
  color: var(--muted);
}

.chip {
  font: inherit;
  font-size: 13px;
  line-height: 1.8;
  padding: 0 11px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  border-radius: 999px;
  cursor: pointer;
}

.chip:hover {
  border-color: var(--red-line);
}

.chip.is-on {
  background: var(--red);
  border-color: var(--red);
  color: var(--chip-ink);
}

.empty {
  margin-top: 10px;
  font-size: 14px;
  color: var(--muted);
}

/* article */

.post-wrap {
  max-width: 784px;
  margin: 0 auto;
}

.post {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--red);
  padding: 26px 30px 28px;
}

.post h1 {
  font-size: 29px;
  line-height: 1.45;
  color: var(--ink);
  margin-bottom: 10px;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
  font-size: 12px;
}

.post-cat {
  color: var(--red);
  background: var(--red-wash);
  border: 1px solid var(--red-line);
  padding: 0 8px;
  line-height: 1.8;
}

.post-lead {
  font-family: var(--font-serif);
  font-size: 17px;
  line-height: 1.9;
  color: var(--ink);
  background: var(--surface-2);
  border-left: 3px solid var(--red);
  padding: 12px 14px;
  margin-bottom: 16px;
}

.post-body {
  display: grid;
  gap: 13px;
}

.post-body p {
  font-size: 16px;
  line-height: 1.95;
  color: var(--ink);
}

.rulebox {
  margin-top: 20px;
  background: var(--red-wash);
  border: 1px solid var(--red-line);
  padding: 12px 14px;
}

.rulebox h2 {
  font-size: 15px;
  color: var(--red);
  margin-bottom: 5px;
}

.rulebox ul {
  display: grid;
  gap: 2px;
}

.rulebox li {
  font-size: 14px;
  line-height: 1.8;
}

.related {
  margin-top: 20px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.related h2 {
  font-size: 17px;
  margin-bottom: 8px;
}

.related ul {
  display: grid;
  gap: 7px;
}

.related li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-size: 15px;
  line-height: 1.7;
}

.related li span {
  flex: none;
  font-size: 12px;
  color: var(--muted);
}

/* plain */

.plain {
  max-width: 784px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 22px 26px;
  display: grid;
  gap: 10px;
}

.plain h1 {
  font-size: 26px;
  color: var(--ink);
}

.plain p {
  font-size: 16px;
  line-height: 1.9;
}

.search-wide {
  margin: 4px 0 2px;
}

.search-wide input {
  width: 280px;
  flex: 1;
}

.search-status {
  font-size: 14px;
  color: var(--muted);
}

.search-results {
  display: grid;
}

.search-results li {
  padding: 10px 0;
  border-bottom: 1px dashed var(--line);
}

.search-results li:last-child {
  border-bottom: 0;
}

.search-results a {
  font-size: 16px;
  color: var(--ink);
}

.search-results span {
  display: block;
  font-size: 13px;
  color: var(--muted);
}

/* footer */

.site-foot {
  margin-top: 26px;
  background: var(--surface);
  border-top: 3px solid var(--red);
}

.foot-cols {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(4, minmax(0, 1fr));
  gap: 20px;
  padding: 24px 0 20px;
}

.foot-brand a {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--red);
  font-weight: 700;
}

.foot-brand p {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.85;
  color: var(--muted);
  max-width: 28em;
}

.foot-col h2 {
  font-size: 14px;
  color: var(--ink);
  margin-bottom: 6px;
}

.foot-col ul {
  display: grid;
  gap: 3px;
  font-size: 13px;
}

.foot-col a {
  color: var(--muted);
}

.foot-col a:hover {
  color: var(--red);
}

.foot-base {
  border-top: 1px solid var(--line-soft);
  padding: 10px 0 64px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--muted);
}

/* responsive */

@media (max-width: 980px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) 320px;
  }

  .foot-cols {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .body-cols {
    grid-template-columns: minmax(0, 1fr);
  }

  .side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-photo {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .hero-photo img {
    min-height: 0;
    height: 210px;
  }

  .searchbar {
    width: 100%;
  }

  .searchbar input {
    flex: 1;
    width: auto;
  }
}

@media (max-width: 560px) {
  .wrap {
    max-width: calc(100% - 20px);
  }

  .brand img {
    width: 148px;
    height: 48px;
  }

  .topstrip-right {
    display: none;
  }

  .topstrip-in {
    min-height: 30px;
  }

  .brand-sub {
    display: none;
  }

  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .card-photo img {
    height: 150px;
  }

  .card-body h3 {
    font-size: 15px;
  }

  .side {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-copy {
    padding: 20px 16px 18px;
  }

  .hero-copy h1 {
    font-size: 24px;
  }

  .hero-line {
    font-size: 17px;
  }

  .post {
    padding: 18px 16px 22px;
  }

  .post h1 {
    font-size: 22px;
  }

  .plain {
    padding: 16px 16px 18px;
  }

  .foot-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .related li {
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
  }

  .row-with-thumb {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 10px;
  }

  .row-thumb {
    grid-row: span 2;
    height: 72px;
  }

  .row-with-thumb .row-idx {
    display: none;
  }

  .search-wide input {
    width: 100%;
  }
}
