@font-face {
  font-family: "Yujian Serif SC";
  src: url("/assets/noto-serif-sc.woff2") format("woff2");
  font-style: normal;
  font-weight: 700 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #f7f4eb;
  --sage: #e9ede2;
  --ink: #243329;
  --green: #234635;
  --muted: #555e51;
  --russet: #964328;
  --line: #d6d7c8;
  --display: "Yujian Serif SC", "Noto Serif CJK SC", "Source Han Serif SC", "Songti SC", SimSun, Georgia, serif;
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.7 system-ui, "Microsoft YaHei UI", sans-serif;
}

:root[lang="en"] { --display: Georgia, "Times New Roman", serif; }
*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, h3, p, ul, figure { margin: 0; }
body { min-height: 100vh; display: flex; flex-direction: column; }
ul { padding: 0; list-style: none; }
a { color: var(--green); text-underline-offset: .25em; }
a:focus-visible { outline: 2px solid var(--green); outline-offset: 4px; }
h1, h2, h3, .brand strong {
  color: var(--ink);
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.2;
  overflow-wrap: break-word;
}
h1 { font-size: clamp(2.25rem, 5vw, 3.65rem); letter-spacing: -.025em; }
h2 { font-size: clamp(1.55rem, 3vw, 2.3rem); letter-spacing: -.02em; }
h3 { font-size: clamp(1.125rem, 2.1vw, 1.5rem); }
i { font-family: Georgia, serif; }

.container { width: min(1392px, calc(100% - clamp(32px, 6.4vw, 96px))); margin-inline: auto; }
.skip-link {
  position: absolute;
  z-index: 1;
  top: 0;
  left: 1rem;
  padding: 10px 15px;
  transform: translateY(-150%);
  background: var(--green);
  color: var(--paper);
}
.skip-link:focus { transform: none; }

.mast {
  min-height: 78px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px clamp(18px, 2.5vw, 35px);
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; }
.brand strong { color: var(--green); font-size: clamp(1.6rem, 2.5vw, 2.35rem); }
.brand small { border-inline-start: 1px solid var(--line); padding-inline-start: 12px; font: 1rem Georgia, serif; }
.site-nav { display: flex; flex-wrap: wrap; gap: 0 clamp(15px, 2.5vw, 35px); margin-inline-start: auto; }
.site-nav a, .language a { display: inline-flex; min-height: 44px; align-items: center; text-decoration: none; }
.site-nav a[aria-current], .language a[aria-current], .site-nav a:hover, .language a:hover {
  text-decoration: underline;
  text-underline-offset: .5em;
}
.site-nav a[aria-current], .language a[aria-current] { font-weight: 700; }
.language {
  display: flex;
  gap: 13px;
  padding-inline-start: clamp(12px, 2vw, 26px);
  border-inline-start: 1px solid var(--line);
  font-size: .875rem;
}
.language a { white-space: nowrap; }
.language a:not([aria-current]) { color: var(--muted); }

main.container { flex: 1; padding-block: clamp(30px, 4.5vw, 64px); }
main.homepage { padding-block-start: 33px; }
.page-head { max-width: 44rem; display: grid; gap: 13px; margin-bottom: 30px; }
.lede, .byline { color: var(--muted); }
.byline, figcaption { font-size: .83rem; }
.eyebrow { color: var(--russet); font-size: .88rem; font-weight: 700; }
.cover, .species-intro {
  display: grid;
  grid-template-columns: minmax(0, .91fr) minmax(0, 1.66fr);
  gap: clamp(22px, 4.4vw, 66px);
  align-items: center;
}
.cover .page-head, .species-intro .page-head { margin-bottom: 0; }
.cover h1 { font-size: clamp(2.6rem, 5.5vw, 5.2rem); font-weight: 850; }
.cover .page-head { gap: clamp(12px, 1.65vw, 24px); }
.cover .photo { aspect-ratio: 2.05; }
.cover figcaption { display: flex; flex-wrap: wrap; column-gap: .35em; }
.main-action {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 9px 25px;
  background: var(--green);
  color: var(--paper);
  border-radius: 3px;
  text-decoration: none;
  font-weight: 700;
}
.main-action:hover { background: #325a43; }
.photo { display: block; width: 100%; height: auto; object-fit: cover; background: var(--sage); }
figcaption { margin-top: 7px; color: var(--muted); }

.home-bottom {
  display: grid;
  grid-template-columns: minmax(0, 3.35fr) minmax(0, 1fr);
  gap: clamp(19px, 2vw, 30px);
  margin-top: 29px;
  padding-top: 34px;
  border-top: 1px solid var(--line);
}
.home-bottom h2 { margin-bottom: 19px; }
.spotlight { align-self: start; background: var(--sage); padding: 16px; }
.spotlight h2 { font-size: clamp(1.15rem, 1.8vw, 1.65rem); }
.spotlight .text-link { margin-top: 6px; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px 20px; }
.cards .photo, .spotlight .photo { aspect-ratio: 1.6; }
.card-link { display: grid; gap: 8px; text-decoration: none; color: inherit; }
.card-link h2, .card-link h3 { font-size: clamp(1.125rem, 2.1vw, 1.5rem); }
.card-link:hover :is(h2, h3) { text-decoration: underline; }
.story-list { max-width: 830px; }
.story-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.1fr);
  align-items: center;
  gap: 24px;
  padding-block: 19px;
  border-top: 1px solid var(--line);
}
.story-row .photo { aspect-ratio: 1.6; }
.story-copy { display: grid; gap: 6px; }

.reading { max-width: 760px; margin-inline: auto; }
.reading .page-head { max-width: none; }
.crumb { margin: -10px 0 15px; }
.text-link { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; }
.body-copy { display: grid; gap: 24px; max-width: 66ch; margin: 25px auto 0; }
.body-copy section, .facts section { display: grid; gap: 9px; }
.body-copy p { line-height: 1.85; }
.body-copy h2, .facts h2 { font-size: clamp(1.3rem, 2.6vw, 1.85rem); }
.scientific { color: var(--muted); font-size: 1.15rem; }
.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 26px; }
.facts section { align-content: start; background: var(--sage); padding: 23px; }
.credits { list-style: disc; padding-inline-start: 20px; }
.credits li + li { margin-top: 7px; }
.journal-footer {
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0 22px;
  padding-block: 12px;
  color: var(--muted);
  font-size: .82rem;
}
.journal-footer > :first-child { margin-inline-end: auto; }

@media (min-width: 1050px) {
  .cover .page-head { padding-inline-start: 20px; }
  .cover .main-action { font-size: 1.15rem; }
}

@media (max-width: 790px) {
  .mast { justify-content: space-between; }
  .site-nav { order: 1; width: 100%; margin: 0; }
  .language { padding: 0; border: 0; }
  .home-bottom { grid-template-columns: minmax(0, 1fr); }
  .spotlight { max-width: 21rem; }
}

@media (max-width: 560px) {
  .cover, .species-intro, .facts, .home-bottom .cards { grid-template-columns: minmax(0, 1fr); }
  .cover .photo { aspect-ratio: 1.65; }
  .home-bottom .cards { gap: 25px; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 19px 13px; }
  .story-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.47fr); gap: 12px; }
  .story-row .lede { display: none; }
  .journal-footer { column-gap: 15px; }
}

@media (max-width: 370px) {
  .brand small { display: none; }
  .site-nav { gap: 0 11px; }
  .site-nav a { font-size: .875rem; }
}
