:root {
  color-scheme: light;
  --bg: #f6f3ec;
  --ink: #171d1b;
  --muted: #65706a;
  --line: #d9d0c1;
  --surface: rgba(255, 253, 247, 0.88);
  --surface-strong: #fffdf8;
  --accent: #126b5b;
  --accent-2: #8f4e2a;
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(120deg, rgba(18, 107, 91, 0.11), transparent 35%),
    linear-gradient(260deg, rgba(143, 78, 42, 0.12), transparent 38%),
    var(--bg);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 18px 0 8px;
}

.topbar {
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.nav-links {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
  font-size: 1rem;
}

.brand-mark {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow:
    18px 0 0 var(--accent-2),
    9px 15px 0 rgba(23, 29, 27, 0.82);
}

.nav-links {
  gap: 18px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.nav-links a {
  border-bottom: 1px solid transparent;
  transition: color 160ms ease, border-color 160ms ease;
}

.nav-links a:hover {
  color: var(--ink);
  border-color: var(--accent);
}

.intro {
  margin-top: 22px;
  padding: 22px 0 12px;
  display: grid;
  grid-template-columns: minmax(240px, 0.42fr) minmax(0, 0.58fr);
  gap: 26px;
  align-items: end;
  border-top: 1px solid var(--line);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(1.9rem, 4vw, 3.1rem);
  line-height: 1;
  letter-spacing: 0;
}

.intro p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.65;
}

.section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 28px 0 0;
}

.section--alt {
  padding-top: 42px;
  padding-bottom: 42px;
}

.section-header {
  margin-bottom: 12px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: end;
}

.section-header h2 {
  margin-bottom: 0;
  font-size: clamp(1.35rem, 2.4vw, 2rem);
  line-height: 1;
}

.section-header h2 span {
  color: var(--accent);
  font-size: 0.78em;
}

.section-header p:last-child {
  max-width: 520px;
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.5;
  text-align: right;
}

.link-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.link-grid--compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.link-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.link-card:hover {
  transform: translateY(-2px);
  border-color: rgba(18, 107, 91, 0.45);
  background: var(--surface-strong);
}

.card-main {
  min-height: 112px;
  padding: 16px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
}

.link-card--compact .card-main {
  min-height: 104px;
}

.card-emoji {
  font-size: 1.35rem;
  line-height: 1;
}

.card-copy {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 6px;
}

.card-title {
  font-size: 1.05rem;
  font-weight: 850;
}

.card-description {
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.92rem;
}

.open-mark {
  color: var(--accent);
  font-weight: 900;
}

.card-meta {
  min-height: 34px;
  padding: 8px 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
}

.secondary-link {
  color: var(--accent);
}

.footer {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 20px 0 34px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  color: var(--muted);
  font-size: 0.92rem;
}

.footer a {
  color: var(--accent);
  font-weight: 800;
}

@media (max-width: 900px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .intro {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  .section-header {
    display: block;
  }

  .section-header p:last-child {
    margin-top: 8px;
    text-align: left;
  }

  .link-grid,
  .link-grid--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .site-header,
  .section,
  .footer {
    width: min(100% - 28px, 1180px);
  }

  .nav-links {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.82rem;
  }

  .link-grid,
  .link-grid--compact {
    grid-template-columns: 1fr;
  }

  .card-main,
  .link-card--compact .card-main {
    min-height: 88px;
  }

  .footer {
    flex-direction: column;
  }
}
