@import url('https://fonts.googleapis.com/css2?family=Amatic+SC:wght@400;700&family=Cabin:wght@400;500;600;700&display=swap');

:root {
  --paper: #fafaf8;
  --ink: #1a1a1a;
  --mid: #4a4a4a;
  --tape: #eeeade;
  --rule: rgba(26, 26, 26, 0.3);
  --pad: clamp(16px, 4vw, 46px);
  --dock: 74px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding-bottom: calc(var(--dock) + 22px);
  font-family: "Cabin", "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 17px;
  line-height: 1.74;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    radial-gradient(rgba(26, 26, 26, 0.11) 1px, transparent 1px),
    repeating-linear-gradient(0deg, rgba(26, 26, 26, 0.026) 0 1px, transparent 1px 4px);
  background-size: 19px 19px, 100% 4px;
  overflow-x: hidden;
}

h1,
h2,
h3,
.mark,
.colophon address strong {
  font-family: "Amatic SC", "Cabin", "PingFang SC", cursive;
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1;
}

h1 {
  margin: 0;
  font-size: clamp(54px, 13vw, 136px);
  line-height: 0.92;
}

p {
  margin: 0 0 1.05em;
}

a {
  color: var(--ink);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

img {
  max-width: 100%;
  height: auto;
}

hr {
  border: 0;
  height: 0;
  border-top: 2px dashed var(--rule);
  margin: 0.6em 0 1.1em;
}

:focus-visible {
  outline: 3px solid var(--mid);
  outline-offset: 2px;
}

/* ---------- 底部固定条 ---------- */
.dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px max(10px, calc(var(--pad) * 0.5));
  background: rgba(250, 250, 248, 0.97);
  border-top: 2px solid var(--ink);
}

.dock .mark {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 2px solid var(--ink);
  border-radius: 4px;
  background: var(--tape);
  color: var(--ink);
  font-size: 26px;
  text-decoration: none;
  transform: rotate(-3deg);
}

.dock .mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dock nav {
  flex: 1 1 auto;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
}

.dock nav::-webkit-scrollbar {
  display: none;
}

.dock-list {
  display: flex;
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.dock-list a {
  display: flex;
  align-items: baseline;
  gap: 5px;
  min-height: 44px;
  padding: 12px 10px;
  font-size: 16px;
  color: var(--mid);
  text-decoration: none;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
}

.dock-list a:hover,
.dock-list a:focus-visible {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

.idx {
  font-size: 12px;
  letter-spacing: 0.08em;
  opacity: 0.72;
}

.dock .cta {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 11px 18px;
  font-size: 16px;
  border: 2px solid var(--ink);
  border-radius: 4px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  transform: rotate(1.6deg);
}

/* ---------- 首屏 ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 14vh var(--pad) 16vh;
  overflow: hidden;
  border-bottom: 3px solid var(--ink);
  background-image: radial-gradient(rgba(26, 26, 26, 0.2) 1.4px, transparent 1.4px);
  background-size: 23px 23px;
}

.hero::before {
  content: "";
  position: absolute;
  top: 11vh;
  right: 7vw;
  width: 148px;
  height: 36px;
  background: var(--tape);
  border: 1px solid var(--rule);
  transform: rotate(-4.5deg);
  opacity: 0.92;
}

.hero::after {
  content: "";
  position: absolute;
  left: var(--pad);
  bottom: 20vh;
  width: min(58%, 320px);
  height: 2px;
  background: var(--ink);
  transform: rotate(-1.1deg);
  opacity: 0.4;
}

.hero h1 {
  max-width: 15ch;
  text-align: left;
  letter-spacing: 0.01em;
}

.kicker {
  margin: 0 0 16px;
  font-size: 16px;
  letter-spacing: 0.4em;
  color: var(--mid);
  text-transform: uppercase;
}

/* ---------- 主体 ---------- */
.shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 238px;
  gap: clamp(22px, 4vw, 52px);
  align-items: start;
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(34px, 6vw, 78px) var(--pad);
}

main {
  min-width: 0;
}

.sheet {
  padding: clamp(18px, 3.6vw, 44px);
  border: 2px solid var(--ink);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.62);
}

.sheet > div {
  scroll-margin-top: 26px;
  padding-bottom: 10px;
  border-bottom: 2px dotted var(--rule);
}

.sheet > div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.sheet h2 {
  margin: 1.5em 0 0.18em;
  font-size: clamp(31px, 5vw, 46px);
}

.sheet > div:first-child h2 {
  margin-top: 0.25em;
}

.sheet h3 {
  margin: 1.5em 0 0.2em;
  font-size: clamp(24px, 3.4vw, 31px);
}

.sheet h4 {
  margin: 1.4em 0 0.3em;
  font-size: 18px;
  letter-spacing: 0.02em;
}

.sheet ul,
.sheet ol {
  margin: 0 0 1.1em;
  padding-left: 1.35em;
}

.sheet li {
  margin-bottom: 0.42em;
}

.sheet blockquote {
  margin: 1.4em 0;
  padding: 6px 0 6px 16px;
  border-left: 4px solid var(--ink);
  color: var(--mid);
}

.sheet img {
  display: block;
  margin: 1.3em 0;
  border: 2px solid var(--ink);
  border-radius: 4px;
  background: var(--tape);
}

.sheet figure {
  margin: 1.4em 0;
}

.sheet figcaption {
  font-size: 16px;
  color: var(--mid);
}

.sheet table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.3em 0;
  font-size: 16px;
}

.sheet th,
.sheet td {
  border: 1px solid var(--rule);
  padding: 8px 10px;
  text-align: left;
}

/* ---------- 侧栏 ---------- */
.side {
  position: sticky;
  top: 22px;
  padding: 16px 14px 18px;
  border: 2px solid var(--ink);
  border-radius: 4px;
  background: var(--tape);
  transform: rotate(0.7deg);
}

.side h2 {
  margin: 0;
  font-size: 33px;
}

.side-list {
  list-style: none;
  margin: 0 0 10px;
  padding: 0;
}

.side-list a {
  display: block;
  min-height: 40px;
  padding: 9px 3px;
  font-size: 16px;
  text-decoration: none;
  border-bottom: 1px dashed var(--rule);
}

.side-list a:hover,
.side-list a:focus-visible {
  background: rgba(26, 26, 26, 0.06);
}

.side .to-top {
  display: inline-block;
  margin-top: 12px;
  font-size: 16px;
}

/* ---------- 页脚 ---------- */
.colophon {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 12px 34px;
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(26px, 5vw, 52px) var(--pad) 30px;
  border-top: 3px solid var(--ink);
}

.colophon address {
  font-style: normal;
  color: var(--mid);
  font-size: 16px;
}

.colophon address strong {
  display: block;
  margin-bottom: 8px;
  font-size: 34px;
  color: var(--ink);
}

.colophon ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0 16px;
}

.colophon ul a {
  display: inline-block;
  min-height: 40px;
  padding: 8px 0;
  font-size: 16px;
}

.colophon .copy {
  grid-column: 1 / -1;
  margin: 10px 0 0;
  padding-top: 12px;
  font-size: 16px;
  color: var(--mid);
  border-top: 1px dashed var(--rule);
}

/* ---------- 揭示 ---------- */
html.has-js .reveal {
  opacity: 0;
  transform: translateY(12px) rotate(-0.3deg);
}

html.has-js .reveal.in {
  opacity: 1;
  transform: none;
  transition: opacity 0.32s steps(3, end), transform 0.32s steps(3, end);
  transition-delay: inherit;
}

.dock-list li {
  animation: pop 0.34s steps(2, end) backwards;
}

.dock-list li:nth-child(1) { animation-delay: 0.02s; }
.dock-list li:nth-child(2) { animation-delay: 0.06s; }
.dock-list li:nth-child(3) { animation-delay: 0.1s; }
.dock-list li:nth-child(4) { animation-delay: 0.14s; }
.dock-list li:nth-child(5) { animation-delay: 0.18s; }
.dock-list li:nth-child(6) { animation-delay: 0.22s; }
.dock-list li:nth-child(7) { animation-delay: 0.26s; }

@keyframes pop {
  from {
    opacity: 0;
    transform: translateY(7px) rotate(-2deg);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ---------- 断点 ---------- */
@media (max-width: 900px) {
  .shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .side {
    position: static;
    transform: none;
    margin-top: 4px;
  }

  .side-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 14px;
  }
}

@media (max-width: 760px) {
  .colophon {
    grid-template-columns: minmax(0, 1fr);
  }

  .dock .cta {
    padding: 11px 14px;
  }
}

@media (max-width: 420px) {
  body {
    font-size: 16px;
  }

  .hero::before {
    width: 108px;
    height: 30px;
  }

  .dock-list a {
    padding: 12px 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .dock-list li {
    animation: none;
  }

  html.has-js .reveal,
  html.has-js .reveal.in {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

button[aria-expanded]{min-width:44px;min-height:44px}
