:root {
  --bg-deep: #d5e0e4;
  --bg-mid: #e2eaed;
  --bg-glow: #b7c9cf;
  --brand: #1c2d33;
  --accent: #4a7078;
  --muted: rgba(28, 45, 51, 0.72);
  --line: rgba(74, 112, 120, 0.32);
  --surface: rgba(255, 255, 255, 0.45);
  --surface-hover: rgba(255, 255, 255, 0.72);
  --toast: #243940;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  color: var(--brand);
  font-family: "Noto Serif SC", "Songti SC", serif;
  background:
    radial-gradient(ellipse 80% 55% at 50% 0%, var(--bg-glow) 0%, transparent 55%),
    radial-gradient(ellipse 60% 40% at 15% 100%, rgba(183, 201, 207, 0.5) 0%, transparent 50%),
    linear-gradient(165deg, var(--bg-deep) 0%, var(--bg-mid) 48%, #eaf1f3 100%);
  background-attachment: fixed;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.08) 2px,
    rgba(0, 0, 0, 0.08) 3px
  );
  pointer-events: none;
  opacity: 0.08;
  z-index: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

.wrap {
  position: relative;
  z-index: 1;
  width: min(1100px, calc(100% - 2rem));
  margin: 0 auto;
}

/* Hero */
.hero {
  min-height: 88vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 4rem 0 3rem;
  animation: rise 1s ease-out both;
}

.brand {
  font-family: "ZCOOL XiaoWei", "Noto Serif SC", serif;
  font-size: clamp(2.8rem, 10vw, 5rem);
  font-weight: 400;
  letter-spacing: 0.18em;
  text-indent: 0.18em;
  line-height: 1.15;
  text-shadow: none;
}

.divider {
  width: 3.5rem;
  height: 1px;
  margin: 1.3rem auto 1.1rem;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: line-in 1.1s 0.3s ease-out both;
}

.tagline {
  font-size: clamp(1rem, 2.8vw, 1.2rem);
  letter-spacing: 0.36em;
  text-indent: 0.36em;
  color: var(--muted);
  animation: fade-up 1s 0.5s ease-out both;
}

.hero-cta {
  margin-top: 2.2rem;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.75rem 1.35rem;
  border: 1px solid var(--line);
  color: var(--brand);
  letter-spacing: 0.18em;
  text-indent: 0.18em;
  font-size: 0.95rem;
  transition: background 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
  animation: fade-up 1s 0.7s ease-out both;
}

.hero-cta:hover {
  background: var(--surface-hover);
  border-color: var(--accent);
  transform: translateY(-2px);
}

/* Sticky nav */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(10px);
  background: rgba(226, 234, 237, 0.92);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.2rem;
  padding: 0.85rem 0;
  justify-content: center;
}

.nav a {
  color: var(--muted);
  letter-spacing: 0.14em;
  font-size: 0.92rem;
  padding: 0.25rem 0;
  border-bottom: 1px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.nav a:hover,
.nav a.active {
  color: var(--brand);
  border-bottom-color: var(--accent);
}

/* Sections */
main {
  padding: 2.5rem 0 4rem;
}

.section {
  padding: 2.2rem 0 1rem;
  scroll-margin-top: 4.5rem;
  animation: fade-up 0.8s ease-out both;
}

.section-head {
  margin-bottom: 1.35rem;
}

.section-head h2 {
  font-family: "ZCOOL XiaoWei", "Noto Serif SC", serif;
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 400;
  letter-spacing: 0.16em;
  text-indent: 0.08em;
}

.section-head p {
  margin-top: 0.45rem;
  color: var(--muted);
  font-size: 0.95rem;
  letter-spacing: 0.06em;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 0.85rem;
}

.item {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 1.05rem 1.1rem 1.15rem;
  background: var(--surface);
  border-top: 1px solid var(--line);
  cursor: pointer;
  text-align: left;
  color: inherit;
  font: inherit;
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.item:hover {
  background: var(--surface-hover);
  border-top-color: var(--accent);
  transform: translateY(-2px);
}

.item-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.item-title {
  font-size: 1.02rem;
  letter-spacing: 0.04em;
  line-height: 1.35;
}

.item-action {
  flex-shrink: 0;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--accent);
  opacity: 0.9;
}

.item-desc {
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.55;
  letter-spacing: 0.02em;
}

.footer {
  border-top: 1px solid var(--line);
  padding: 1.6rem 0 2.4rem;
  text-align: center;
  color: var(--muted);
  font-size: 0.88rem;
  letter-spacing: 0.12em;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 1.6rem;
  transform: translateX(-50%) translateY(20px);
  background: var(--toast);
  color: #e8f0f2;
  border: 1px solid var(--accent);
  padding: 0.7rem 1.15rem;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 50;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.sheet-mask {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: end center;
  padding: 1rem;
  background: rgba(28, 45, 51, 0.35);
}

.sheet-mask[hidden] {
  display: none;
}

.sheet {
  width: min(520px, 100%);
  background: #eef4f6;
  border: 1px solid var(--line);
  padding: 1.15rem 1.1rem 1.2rem;
  box-shadow: 0 -8px 28px rgba(28, 45, 51, 0.12);
}

.sheet h3 {
  font-family: "ZCOOL XiaoWei", "Noto Serif SC", serif;
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  color: var(--brand);
}

.sheet-tip {
  margin-top: 0.45rem;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.sheet-input {
  width: 100%;
  margin-top: 0.9rem;
  padding: 0.75rem 0.8rem;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--brand);
  font: inherit;
  font-size: 0.88rem;
  line-height: 1.4;
  word-break: break-all;
}

.sheet-actions {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.95rem;
}

.sheet-btn {
  flex: 1;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--brand);
  font: inherit;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.sheet-btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #f3f8f9;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes line-in {
  from { opacity: 0; transform: scaleX(0.2); }
  to { opacity: 1; transform: scaleX(1); }
}

@media (max-width: 640px) {
  .wrap {
    width: min(100% - 1.25rem, 1100px);
  }

  .hero {
    min-height: 78vh;
    padding-top: 3rem;
  }

  .nav-inner {
    gap: 0.25rem 0.9rem;
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    -webkit-overflow-scrolling: touch;
  }

  .nav a {
    white-space: nowrap;
    font-size: 0.86rem;
  }
}
