:root {
  color-scheme: light;
  --paper: #f5f3ed;
  --ink: #24332d;
  --muted: #626d64;
  --accent: #346b58;
  --line: #d4d9ce;
  --selected: #ffffff;
  --selected-ink: #24332d;
  --hover: #e9ece3;
  --serif: "Noto Serif CJK SC", "Source Han Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #151c18;
  --ink: #e3e9df;
  --muted: #a0aca2;
  --accent: #a1c6ae;
  --line: #354039;
  --selected: #35443a;
  --selected-ink: #edf3e9;
  --hover: #26332b;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --paper: #151c18;
    --ink: #e3e9df;
    --muted: #a0aca2;
    --accent: #a1c6ae;
    --line: #354039;
    --selected: #35443a;
    --selected-ink: #edf3e9;
    --hover: #26332b;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }
::selection { background: var(--accent); color: var(--paper); }
.wrap { width: min(1080px, calc(100% - 96px)); margin-inline: auto; }
.skip-link { position: absolute; left: 24px; top: -80px; z-index: 2; padding: 12px 18px; background: var(--ink); color: var(--paper); text-decoration: none; }
.skip-link:focus { top: 16px; }
.site-header { min-height: 108px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--accent); }
.brand svg { width: 30px; height: 30px; }
.brand path { fill: none; stroke: currentColor; stroke-width: 2.5; }
.brand span { font-size: 13px; letter-spacing: .06em; }
.theme-control { display: inline-flex; gap: 3px; padding: 4px; border: 1px solid var(--line); border-radius: 999px; }
.theme-control button { min-width: 53px; min-height: 34px; border: 0; border-radius: 999px; padding: 7px 12px; background: transparent; color: var(--muted); font: inherit; font-size: 12px; cursor: pointer; }
.theme-control button:hover { background: var(--hover); color: var(--ink); }
.theme-control button[aria-pressed="true"] { background: var(--selected); color: var(--selected-ink); box-shadow: 0 1px 3px #00000012; }
main { display: flex; align-items: center; padding-block: 90px 110px; }
.intro { padding-block: 15px; }
h1 { margin: 0; font-family: var(--serif); font-size: clamp(58px, 7.5vw, 88px); font-weight: 500; line-height: 1.3; letter-spacing: .04em; }
.subtitle { margin: 27px 0 0; color: var(--accent); font-size: 17px; letter-spacing: .12em; line-height: 1.8; }
.description { max-width: 32em; margin: 17px 0 0; color: var(--muted); font-size: 14px; line-height: 1.9; }
.site-footer { min-height: 94px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; padding-block: 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; line-height: 1.8; }
.site-footer a { text-decoration: none; text-underline-offset: 4px; }
.site-footer a:hover { text-decoration: underline; color: var(--accent); }
.footer-domain { justify-self: end; font-size: 11px; letter-spacing: .04em; }

@media (max-width: 650px) {
  .wrap { width: calc(100% - 40px); }
  .site-header { min-height: 88px; gap: 12px; }
  .brand { gap: 8px; }
  .brand svg { width: 25px; height: 25px; }
  .brand span { font-size: 12px; }
  .theme-control { padding: 3px; gap: 1px; }
  .theme-control button { min-width: 45px; min-height: 34px; padding-inline: 9px; }
  main { padding-block: 70px 90px; }
  h1 { font-size: 60px; }
  .subtitle { font-size: 15px; margin-top: 23px; letter-spacing: .08em; }
  .description { max-width: 22em; font-size: 13px; }
  .site-footer { min-height: 100px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 24px; text-align: center; }
  .site-footer a { flex-basis: 100%; order: 1; }
}
