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

:root {
  --paper: #f5e6c8;
  --accent: #d4a574;
  --ink: #262117;
  --ink-soft: #5b4b36;
  --brown: #8a6540;
  --line: rgba(38, 33, 23, 0.18);
  --glass: rgba(255, 248, 232, 0.55);
  --shadow: 0 12px 26px -16px rgba(38, 33, 23, 0.8);
  --serif: "Songti SC", "Noto Serif SC", "Source Han Serif SC", Georgia, serif;
  --sans: "Cabin", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.8;
  overflow-x: hidden;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(60% 45% at 88% 4%, rgba(255, 214, 150, 0.6), rgba(255, 214, 150, 0) 70%),
    radial-gradient(50% 40% at 4% 96%, rgba(212, 165, 116, 0.42), rgba(212, 165, 116, 0) 72%),
    linear-gradient(180deg, #f8ecd3 0%, #f0e0bd 62%, #e7d5ac 100%);
  animation: leak 18s ease-in-out infinite alternate;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  opacity: 0.15;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23g)'/%3E%3C/svg%3E");
}

@keyframes leak {
  from { opacity: 0.82; }
  to { opacity: 1; filter: saturate(1.12); }
}

img { max-width: 100%; }

a { color: var(--brown); }
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px dashed var(--ink);
  outline-offset: 3px;
}

.skip {
  position: absolute;
  left: 10px;
  top: -60px;
  z-index: 90;
  padding: 8px 14px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  border-radius: 4px;
}
.skip:focus { top: 10px; }

/* ---------- 顶部 ---------- */
.masthead {
  position: relative;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px clamp(14px, 4vw, 32px);
  border-bottom: 1px solid var(--line);
  background: rgba(245, 230, 200, 0.88);
  backdrop-filter: blur(8px);
}

@media (min-width: 960px) {
  .masthead { position: sticky; top: 0; }
}

.brand {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  text-decoration: none;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: 0.14em;
}

.brand__mark {
  position: relative;
  width: 16px;
  height: 24px;
  border: 2px solid var(--ink);
  border-radius: 2px;
  background: var(--accent);
  transform: rotate(-6deg);
}

.brand__mark::after {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  right: 4px;
  height: 2px;
  background: var(--ink);
  box-shadow: 0 5px 0 var(--ink), 0 10px 0 var(--ink);
}

.menu { margin-left: auto; min-width: 0; }

.menu ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.menu li { animation: drop 0.45s both; }
.menu li:nth-child(2) { animation-delay: 0.05s; }
.menu li:nth-child(3) { animation-delay: 0.1s; }
.menu li:nth-child(4) { animation-delay: 0.15s; }
.menu li:nth-child(5) { animation-delay: 0.2s; }
.menu li:nth-child(6) { animation-delay: 0.25s; }
.menu li:nth-child(7) { animation-delay: 0.3s; }

@keyframes drop {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}

.menu a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 6px 10px;
  border-radius: 4px;
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 16px;
  letter-spacing: 0.03em;
}

.menu a::before {
  content: "";
  flex: 0 0 auto;
  width: 5px;
  height: 5px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--accent);
}

.menu a:hover { background: rgba(212, 165, 116, 0.38); color: var(--ink); }

.btn-contact {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 16px;
  border: 1px solid var(--ink);
  border-radius: 4px;
  background: var(--glass);
  color: var(--ink);
  text-decoration: none;
  font-size: 16px;
}

.btn-contact:hover { background: var(--ink); color: var(--paper); }

/* ---------- 头图 ---------- */
.hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  align-items: center;
  gap: clamp(20px, 4vw, 54px);
  max-width: 1120px;
  min-height: 70vh;
  margin: 0 auto;
  padding: clamp(26px, 5vw, 64px) clamp(16px, 4vw, 32px);
}

.hero__ghost {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4%;
  z-index: 0;
  padding-left: clamp(10px, 3vw, 28px);
  font-family: var(--serif);
  font-size: clamp(56px, 15vw, 180px);
  line-height: 0.82;
  letter-spacing: 0.06em;
  color: rgba(38, 33, 23, 0.09);
  white-space: nowrap;
  pointer-events: none;
  animation: vhs 9s steps(1, end) infinite;
}

@keyframes vhs {
  0%, 96% { transform: none; }
  97% { transform: translate3d(-4px, 0, 0) skewX(-1.2deg); }
  98% { transform: translate3d(3px, 0, 0) skewX(0.8deg); }
  99% { transform: translate3d(-2px, 0, 0) skewX(-0.4deg); }
  100% { transform: none; }
}

.polaroid {
  position: relative;
  z-index: 2;
  margin: 0;
  padding: 12px 12px 42px;
  border: 1px solid rgba(38, 33, 23, 0.16);
  border-radius: 4px;
  background: #fdf6e6;
  box-shadow: var(--shadow);
  transform: rotate(-1.8deg);
  animation: shake 7s ease-in-out infinite;
}

@keyframes shake {
  0%, 100% { transform: rotate(-1.8deg); }
  50% { transform: rotate(-0.6deg); }
}

.polaroid img,
.polaroid__blank {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 2px;
  background: #e7d3ab;
}

.polaroid img { filter: sepia(0.32) saturate(0.82) contrast(1.05); }

.polaroid__blank {
  background-image: repeating-linear-gradient(135deg, #e7d3ab 0 10px, #dfc79c 10px 20px);
}

.hero__copy {
  position: relative;
  z-index: 2;
  text-align: center;
}

.hero h1 {
  margin: 0 0 14px;
  font-family: var(--serif);
  font-size: clamp(30px, 5vw, 52px);
  line-height: 1.3;
  letter-spacing: 0.03em;
  text-shadow: 0 1px 0 rgba(255, 250, 238, 0.8);
}

.hero__lead {
  max-width: 34ch;
  margin: 0 auto;
  color: var(--ink-soft);
  font-size: 17px;
}

/* ---------- 主体 ---------- */
.shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px;
  align-items: start;
  gap: clamp(20px, 3vw, 44px);
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(18px, 4vw, 46px) clamp(16px, 4vw, 32px) 56px;
}

.reel { min-width: 0; }

.reel > article {
  padding-top: 26px;
  scroll-margin-top: 96px;
}

.reel > article + article {
  margin-top: 32px;
  border-top: 1px dashed var(--line);
}

.reel > article:first-child { padding-top: 0; }

.reel h2 {
  margin: 0 0 6px;
  font-family: var(--serif);
  font-size: clamp(22px, 3.2vw, 30px);
  line-height: 1.35;
  letter-spacing: 0.02em;
}

.reel h3 {
  margin: 26px 0 8px;
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.4;
}

.reel p { margin: 0 0 16px; }
.reel ul, .reel ol { margin: 0 0 16px; padding-left: 1.2em; }
.reel li { margin: 6px 0; }

.reel a {
  color: #7a4f26;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.reel strong {
  background: linear-gradient(transparent 64%, rgba(212, 165, 116, 0.62) 64%);
  padding: 0 1px;
}

.reel blockquote {
  margin: 20px 0;
  padding: 14px 18px;
  border-left: 3px solid var(--accent);
  border-radius: 0 4px 4px 0;
  background: rgba(255, 248, 232, 0.55);
  color: var(--ink-soft);
}

.reel img {
  height: auto;
  border-radius: 4px;
  filter: sepia(0.25) saturate(0.9);
}

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

.reel th, .reel td {
  padding: 8px 10px;
  border-bottom: 1px dashed var(--line);
  text-align: left;
}

hr {
  margin: 8px 0 18px;
  border: 0;
  border-top: 1px dashed rgba(38, 33, 23, 0.34);
}

/* ---------- 侧栏 ---------- */
.rail {
  position: sticky;
  top: 92px;
  padding: 18px 16px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--glass);
  box-shadow: var(--shadow);
  backdrop-filter: blur(7px);
}

.rail h2 {
  margin: 0 0 8px;
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 0.18em;
}

.rail ul { margin: 0; padding: 0; list-style: none; }

.rail a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 2px;
  border-bottom: 1px dotted rgba(38, 33, 23, 0.22);
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 16px;
}

.rail a:hover { color: var(--ink); padding-left: 5px; }

.totop {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  margin-top: 12px;
  color: var(--brown);
  font-size: 16px;
}

/* ---------- 页脚 ---------- */
.foot {
  margin-top: 18px;
  padding: 34px clamp(16px, 4vw, 32px) 18px;
  border-top: 1px solid var(--line);
  background: rgba(38, 33, 23, 0.06);
}

.foot__top { max-width: 1120px; margin: 0 auto 26px; }

.sub { display: flex; gap: 8px; max-width: 340px; }

.sub input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fffaf0;
  color: var(--ink);
  font: inherit;
  font-size: 16px;
}

.sub button {
  flex: 0 0 auto;
  min-height: 42px;
  padding: 8px 16px;
  border: 1px solid var(--ink);
  border-radius: 4px;
  background: var(--accent);
  color: var(--ink);
  font: inherit;
  font-size: 16px;
  cursor: pointer;
}

.sub button:hover { background: var(--ink); color: var(--paper); }

.foot__cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  max-width: 1120px;
  margin: 0 auto;
}

.foot dl { margin: 0; }

.foot dt {
  margin-bottom: 6px;
  color: var(--brown);
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 0.2em;
}

.foot dd { margin: 0; color: var(--ink-soft); }

.foot a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 16px;
}

.foot a:hover { color: var(--ink); text-decoration: underline; }

.foot__bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  max-width: 1120px;
  margin: 22px auto 0;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
  color: var(--ink-soft);
  font-size: 15px;
}

.foot__bar p { margin: 0; }

/* ---------- 动效 ---------- */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.in { opacity: 1; transform: none; }

/* ---------- 断点 ---------- */
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .rail { position: static; }
  .reel > article { scroll-margin-top: 20px; }
}

@media (max-width: 760px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    gap: 18px;
    padding-top: 18px;
  }
  .hero__copy { order: -1; }
  .hero__ghost { bottom: auto; top: 10px; font-size: clamp(48px, 17vw, 96px); opacity: 0.75; }
  .polaroid { width: 100%; max-width: 430px; margin: 0 auto; }
  .foot__cols { grid-template-columns: 1fr 1fr; gap: 14px 18px; }
}

@media (max-width: 700px) {
  .masthead { flex-wrap: wrap; gap: 6px 10px; padding: 8px 14px; }
  .menu { order: 3; flex: 1 1 100%; margin-left: 0; }
  .menu ul { justify-content: flex-start; }
  .btn-contact { margin-left: auto; }
}

@media (max-width: 440px) {
  .foot__cols { grid-template-columns: 1fr; }
  .brand { font-size: 18px; }
}

@media print {
  body::before, body::after { display: none; }
  .rail, .skip { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}

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