:root {
  --bg: #fbf6ec;
  --ink: #1d1a16;
  --muted: rgba(29, 26, 22, 0.68);
  --line: rgba(29, 26, 22, 0.12);
  --paper: rgba(255, 255, 255, 0.7);

  --accent: #d14b2a;
  --accent2: #1e6b5a;
  --glow: rgba(209, 75, 42, 0.22);

  --radius: 18px;
  --shadow: 0 18px 45px rgba(29, 26, 22, 0.12);
  --shadow2: 0 10px 24px rgba(29, 26, 22, 0.1);

  --font-display: "Ma Shan Zheng", system-ui, -apple-system, "PingFang SC", "Hiragino Sans GB", sans-serif;
  --font-body: "Noto Sans SC", system-ui, -apple-system, "PingFang SC", "Hiragino Sans GB", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: var(--font-body);
  line-height: 1.55;
  overflow-x: hidden;
  /* 让背景网格能“只在页面顶部出现”，避免页面底部（尤其 footer）线框干扰。 */
  position: relative;
  z-index: 0;
}

.bg-grid {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  /* 背景只铺在页面上半部分，向下滚动时底部保持干净。 */
  height: clamp(520px, 72vh, 860px);
  background-image:
    linear-gradient(to right, rgba(29, 26, 22, 0.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(29, 26, 22, 0.06) 1px, transparent 1px),
    radial-gradient(80% 60% at 20% 10%, rgba(209, 75, 42, 0.16), transparent 60%),
    radial-gradient(60% 60% at 78% 22%, rgba(30, 107, 90, 0.12), transparent 60%);
  background-size: 28px 28px, 28px 28px, auto, auto;
  pointer-events: none;
  filter: saturate(1.05);
  /* 淡出到底部，保证“页面下方”没有网格线。 */
  -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 1) 55%, rgba(0, 0, 0, 0) 100%);
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 1) 55%, rgba(0, 0, 0, 0) 100%);
  z-index: -1;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(251, 246, 236, 0.78);
  backdrop-filter: blur(10px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 240px;
}

.brand__seal {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(29, 26, 22, 0.14);
  box-shadow: var(--shadow2);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 26px;
  color: var(--accent);
  transform: rotate(-6deg);
}

.brand__title {
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: 0.2px;
}

.brand__sub {
  margin-top: 2px;
  font-size: 12px;
  color: var(--muted);
}

.topnav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.topnav__link {
  text-decoration: none;
  color: var(--ink);
  font-size: 13px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(29, 26, 22, 0.14);
  background: rgba(255, 255, 255, 0.55);
  transition: transform 140ms ease, background 140ms ease, box-shadow 140ms ease;
}

.topnav__link:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.75);
  box-shadow: 0 10px 22px rgba(29, 26, 22, 0.09);
}

.shell {
  width: min(1120px, calc(100% - 32px));
  margin: 18px auto 60px;
}

.hero {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 18px;
  align-items: stretch;
  padding: 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(29, 26, 22, 0.14);
  background: rgba(255, 255, 255, 0.62);
  box-shadow: var(--shadow);
}

.hero__headline {
  font-family: var(--font-display);
  font-size: 44px;
  line-height: 1.05;
  margin: 8px 0 10px;
}

.hero__accent {
  color: var(--accent);
  text-shadow: 0 10px 35px var(--glow);
}

.hero__lead {
  margin: 0 0 14px;
  color: rgba(29, 26, 22, 0.82);
  font-size: 15px;
}

.mantra {
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px dashed rgba(29, 26, 22, 0.22);
  background: rgba(251, 246, 236, 0.75);
}

.mantra__label {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
}

.mantra__text {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.cards {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.card {
  display: block;
  text-decoration: none;
  color: var(--ink);
  padding: 12px 12px 14px;
  border-radius: 18px;
  border: 1px solid rgba(29, 26, 22, 0.14);
  background: rgba(255, 255, 255, 0.66);
  box-shadow: 0 10px 24px rgba(29, 26, 22, 0.08);
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
  position: relative;
  overflow: hidden;
}

.card::after {
  content: "";
  position: absolute;
  inset: -40px;
  background: radial-gradient(50% 50% at 20% 20%, rgba(209, 75, 42, 0.12), transparent 60%),
    radial-gradient(50% 50% at 80% 60%, rgba(30, 107, 90, 0.09), transparent 60%);
  opacity: 0;
  transition: opacity 160ms ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 40px rgba(29, 26, 22, 0.14);
  border-color: rgba(29, 26, 22, 0.2);
}

.card:hover::after {
  opacity: 1;
}

.card__kicker {
  font-size: 12px;
  color: var(--muted);
  position: relative;
  z-index: 1;
}

.card__title {
  font-family: var(--font-display);
  font-size: 22px;
  margin-top: 2px;
  position: relative;
  z-index: 1;
}

.card__desc {
  margin-top: 6px;
  font-size: 13px;
  color: rgba(29, 26, 22, 0.8);
  position: relative;
  z-index: 1;
}

.card__meta {
  margin-top: 10px;
  font-size: 12px;
  color: rgba(29, 26, 22, 0.65);
  font-family: var(--mono);
  position: relative;
  z-index: 1;
}

.poster {
  height: 100%;
  border-radius: 20px;
  border: 1px solid rgba(29, 26, 22, 0.14);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.6)),
    radial-gradient(120% 80% at 20% 0%, rgba(209, 75, 42, 0.18), transparent 60%),
    radial-gradient(120% 80% at 100% 60%, rgba(30, 107, 90, 0.16), transparent 60%);
  box-shadow: var(--shadow2);
  padding: 14px;
}

.poster__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid rgba(29, 26, 22, 0.16);
  background: rgba(251, 246, 236, 0.8);
  font-size: 12px;
  color: rgba(29, 26, 22, 0.76);
}

.poster__list {
  margin: 12px 0 0;
  padding-left: 18px;
  color: rgba(29, 26, 22, 0.84);
  font-size: 14px;
}

.poster__list li {
  margin: 8px 0;
}

.poster__footer {
  margin-top: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: rgba(29, 26, 22, 0.68);
  border-top: 1px solid rgba(29, 26, 22, 0.12);
  padding-top: 10px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--accent2);
  box-shadow: 0 0 0 5px rgba(30, 107, 90, 0.14);
}

.panel {
  margin-top: 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(29, 26, 22, 0.14);
  background: rgba(255, 255, 255, 0.62);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel__head {
  padding: 16px 16px 12px;
  border-bottom: 1px solid rgba(29, 26, 22, 0.12);
  background: linear-gradient(180deg, rgba(251, 246, 236, 0.76), rgba(255, 255, 255, 0.4));
}

.panel__title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 28px;
}

.panel__sub {
  margin: 6px 0 0;
  color: rgba(29, 26, 22, 0.75);
  font-size: 14px;
}

.panel__body {
  padding: 16px;
}

code {
  font-family: var(--mono);
  font-size: 0.95em;
}

.foot {
  border-top: 1px solid rgba(29, 26, 22, 0.12);
  /* 用不透明底色遮住背景网格，保持底部清爽。 */
  background: var(--bg);
}

.foot__inner {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 16px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: rgba(29, 26, 22, 0.7);
  font-size: 12px;
}

/* Responsive */
@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .hero__headline {
    font-size: 40px;
  }
  .topnav {
    display: none;
  }
}
