:root {
  --ink: #171816;
  --black: #080907;
  --paper: #f2f0e8;
  --paper-deep: #e3e0d4;
  --muted: #65675f;
  --line: #bbb9ad;
  --rust: #9b5f4b;
  --blue: #485269;
  --sage: #737968;
  --max: 1240px;
  --page-pad: clamp(20px, 4vw, 56px);
  --serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", SimSun, serif;
  --sans: "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  --mono: "IBM Plex Mono", Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
}

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

a:focus-visible,
summary:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 4px;
}

.site-header {
  position: absolute;
  z-index: 10;
  top: 0;
  left: 50%;
  display: flex;
  width: min(calc(100% - (var(--page-pad) * 2)), var(--max));
  min-height: 84px;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  transform: translateX(-50%);
}

.wordmark {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.wordmark-cn {
  font-family: var(--serif);
  font-size: 18px;
}

.wordmark-en {
  font-family: var(--mono);
  font-size: 10px;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  font-size: 13px;
}

.desktop-nav a,
.text-link,
.editorial-links a,
.site-footer a {
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 5px;
  transition: text-decoration-color 180ms ease;
}

.desktop-nav a:hover,
.text-link:hover,
.editorial-links a:hover,
.site-footer a:hover {
  text-decoration-color: currentColor;
}

.mobile-nav {
  display: none;
}

.hero {
  position: relative;
  display: grid;
  min-height: min(900px, 94svh);
  overflow: hidden;
  align-items: end;
  color: #fff;
  background-color: #20231f;
  background-image: url("/home-static/assets/europa-map.webp");
  background-position: center 42%;
  background-size: cover;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: rgba(5, 6, 5, 0.7);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(calc(100% - (var(--page-pad) * 2)), var(--max));
  margin: 0 auto;
  padding: 150px 0 78px;
}

.kicker {
  margin: 0 0 22px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11px;
  line-height: 1.4;
}

.kicker.light {
  color: #d5d3c8;
}

h1,
h2 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
}

h1 {
  max-width: 860px;
  font-size: clamp(38px, 4.4vw, 62px);
  line-height: 1.05;
}

.hero-wordmark {
  display: block;
  width: min(860px, 72vw);
  height: auto;
  margin: 0 0 22px;
}

h2 {
  font-size: clamp(32px, 4vw, 54px);
  line-height: 1.16;
}

.hero-prose {
  max-width: 720px;
  margin-top: 38px;
  border-left: 1px solid rgba(255, 255, 255, 0.44);
  padding-left: 24px;
  color: #e4e3dc;
  font-family: var(--serif);
  font-size: 16px;
  line-height: 1.85;
}

.hero-prose p {
  margin: 0 0 8px;
}

.hero-prose p:last-child {
  margin-bottom: 0;
}

.hero-actions {
  display: flex;
  margin-top: 36px;
  align-items: center;
  gap: 26px;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 1px solid transparent;
  border-radius: 4px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.2;
  transition: background 180ms ease, color 180ms ease, border-color 180ms ease;
}

.button-light {
  color: var(--ink);
  background: #fff;
}

.button-light:hover {
  background: var(--paper-deep);
}

.text-link {
  font-size: 13px;
}

.light-link {
  color: #fff;
}

.hero-folio {
  position: absolute;
  z-index: 2;
  right: var(--page-pad);
  bottom: 78px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  color: #cfcec5;
  font-family: var(--mono);
  font-size: 10px;
  line-height: 1.7;
}

.era-section,
.directory-section {
  width: min(calc(100% - (var(--page-pad) * 2)), var(--max));
  margin: 0 auto;
  padding: 112px 0;
}

.section-intro {
  max-width: 720px;
  margin-bottom: 58px;
}

.section-intro > p:last-child {
  margin: 24px 0 0;
  color: var(--muted);
}

.split-intro {
  display: grid;
  max-width: none;
  grid-template-columns: minmax(0, 1.5fr) minmax(260px, 0.7fr);
  align-items: end;
  gap: 80px;
}

.split-intro > p:last-child {
  margin: 0 0 5px;
}

.era-list {
  display: grid;
  margin: 0;
  border-top: 1px solid var(--ink);
  padding: 0;
  grid-template-columns: repeat(5, 1fr);
  list-style: none;
}

.era-list li {
  min-width: 0;
  border-right: 1px solid var(--line);
}

.era-list li:last-child {
  border-right: 0;
}

.era-list a {
  position: relative;
  display: flex;
  min-height: 232px;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px 18px 22px;
  border-bottom: 1px solid var(--ink);
  transition: color 180ms ease, background 180ms ease;
}

.era-list a:hover {
  color: #fff;
  background: var(--ink);
}

.era-index,
.directory-no {
  font-family: var(--mono);
  font-size: 11px;
}

.era-copy {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.era-copy strong,
.directory-grid strong {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 400;
  line-height: 1.3;
}

.era-copy small,
.directory-grid small {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
  line-height: 1.45;
}

.era-list a:hover small {
  color: #c9c8c0;
}

.era-arrow {
  position: absolute;
  top: 18px;
  right: 18px;
}

.atlas-section {
  padding: 88px max(var(--page-pad), calc((100vw - var(--max)) / 2));
  color: #fff;
  background: var(--ink);
}

.atlas-heading {
  display: flex;
  margin-bottom: 46px;
  align-items: end;
  justify-content: space-between;
  gap: 40px;
}

.button-outline {
  flex: none;
  border-color: rgba(255, 255, 255, 0.65);
  color: #fff;
}

.button-outline:hover {
  color: var(--ink);
  background: #fff;
  border-color: #fff;
}

.map-link {
  display: block;
  overflow: hidden;
  border: 1px solid #84877b;
  border-radius: 4px;
  background: #292b27;
}

.map-link img {
  display: block;
  width: 100%;
  height: auto;
  transition: opacity 180ms ease;
}

.map-link:hover img {
  opacity: 0.86;
}

.atlas-caption {
  display: flex;
  padding-top: 14px;
  justify-content: space-between;
  color: #aaa99f;
  font-family: var(--mono);
  font-size: 10px;
}

.directory-section {
  padding-bottom: 128px;
}

.directory-grid {
  display: grid;
  border-top: 1px solid var(--ink);
  border-left: 1px solid var(--line);
  grid-template-columns: repeat(3, 1fr);
}

.directory-grid a {
  position: relative;
  display: flex;
  min-height: 205px;
  flex-direction: column;
  justify-content: flex-end;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 24px;
  transition: background 180ms ease;
}

.directory-grid a:hover {
  background: var(--paper-deep);
}

.directory-no {
  position: absolute;
  top: 22px;
  left: 24px;
}

.directory-arrow {
  position: absolute;
  top: 22px;
  right: 24px;
}

.directory-grid strong {
  margin-bottom: 8px;
  font-size: 24px;
}

.editorial-section {
  display: grid;
  padding: 94px max(var(--page-pad), calc((100vw - var(--max)) / 2));
  color: #fff;
  background: var(--blue);
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.9fr);
  gap: 100px;
}

.editorial-heading h2 {
  max-width: 620px;
}

.editorial-copy {
  border-top: 1px solid rgba(255, 255, 255, 0.55);
  padding-top: 18px;
  color: #e5e5df;
}

.editorial-copy > p {
  margin: 0;
}

.editorial-links {
  display: flex;
  margin-top: 34px;
  flex-wrap: wrap;
  gap: 24px;
  color: #fff;
  font-size: 13px;
}

.site-footer {
  display: grid;
  min-height: 180px;
  padding: 44px max(var(--page-pad), calc((100vw - var(--max)) / 2));
  align-items: end;
  color: #cbc9c0;
  background: var(--black);
  grid-template-columns: 1fr auto auto;
  gap: 54px;
  font-size: 12px;
}

.site-footer > div {
  display: flex;
  flex-direction: column;
}

.footer-wordmark {
  display: block;
  width: min(290px, 100%);
  height: auto;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 900px) {
  .hero-folio {
    display: none;
  }

  .split-intro,
  .editorial-section {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .era-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .era-list li,
  .era-list li:last-child {
    border-right: 1px solid var(--line);
  }

  .era-list a {
    min-height: 190px;
  }

  .directory-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .site-header {
    min-height: 70px;
  }

  .wordmark-en,
  .desktop-nav {
    display: none;
  }

  .mobile-nav {
    position: relative;
    display: block;
  }

  .mobile-nav summary {
    display: flex;
    width: 40px;
    height: 40px;
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    list-style: none;
  }

  .mobile-nav summary::-webkit-details-marker {
    display: none;
  }

  .mobile-nav summary span {
    display: block;
    width: 20px;
    height: 1px;
    background: #fff;
  }

  .mobile-nav-panel {
    position: absolute;
    top: 48px;
    right: 0;
    display: grid;
    width: 180px;
    border: 1px solid #55574f;
    border-radius: 4px;
    color: #fff;
    background: var(--ink);
  }

  .mobile-nav-panel a {
    padding: 12px 14px;
    border-bottom: 1px solid #42443e;
    font-size: 13px;
  }

  .mobile-nav-panel a:last-child {
    border-bottom: 0;
  }

  .hero {
    min-height: 760px;
    background-position: 58% center;
  }

  h1 {
    font-size: clamp(28px, 8.8vw, 34px);
    white-space: nowrap;
  }

  .hero-wordmark {
    width: 100%;
    margin-bottom: 14px;
  }

  .hero-content {
    padding: 120px 0 58px;
  }

  .hero-prose {
    margin-top: 28px;
    padding-left: 16px;
    font-size: 14px;
    line-height: 1.75;
  }

  .hero-prose p:nth-child(3) {
    display: none;
  }

  .hero-actions {
    align-items: flex-start;
    flex-direction: column;
    gap: 18px;
  }

  .era-section,
  .directory-section {
    padding: 78px 0;
  }

  .section-intro {
    margin-bottom: 38px;
  }

  .era-list {
    grid-template-columns: 1fr;
  }

  .era-list a {
    min-height: 122px;
    padding: 16px 48px 16px 16px;
  }

  .era-copy {
    gap: 2px;
  }

  .era-arrow {
    top: 16px;
    right: 16px;
  }

  .atlas-section {
    padding-top: 72px;
    padding-bottom: 72px;
  }

  .atlas-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .map-link img {
    width: 100%;
  }

  .atlas-caption {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .directory-grid {
    border-left: 0;
    grid-template-columns: 1fr;
  }

  .directory-grid a {
    min-height: 150px;
  }

  .editorial-section {
    padding-top: 72px;
    padding-bottom: 72px;
  }

  .site-footer {
    min-height: 220px;
    align-items: start;
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

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

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
