:root {
  color-scheme: light dark;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  color: #242a33;
  background: #ffffff;
  line-height: 1.7;
  overflow-wrap: anywhere;
  -webkit-text-size-adjust: 100%;
}

* { box-sizing: border-box; }

body {
  max-width: 768px;
  margin: 0 auto;
  padding: 24px;
}

.lang-switch {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin: 0 0 2em;
}

.lang-switch select {
  width: 192px;
  min-width: 168px;
  max-width: 100%;
  padding: 9px 34px 9px 12px;
  border: 1px solid #c8c8c8;
  border-radius: 10px;
  font: inherit;
  color: #222222;
  background-color: #ffffff;
  color-scheme: light;
  cursor: pointer;
}

.lang-switch select:hover { border-color: #888888; }
.lang-switch select:focus,
.lang-switch select:focus-visible {
  outline: none;
  outline-offset: 0;
  box-shadow: none;
  border-color: #1a73e8;
}
.lang-switch label {
  flex-shrink: 0;
  color: #666666;
  font-size: 0.9em;
  white-space: nowrap;
}
.lang-panel { display: none; }
.lang-panel.active { display: block; }
h1 { font-size: 1.5em; line-height: 1.4; margin: 0 0 8px; }
h2 { font-size: 1.12em; line-height: 1.5; margin: 30px 0 10px; }
p { margin: 0 0 14px; }
ul { margin: 0 0 14px; padding-left: 24px; }
li { margin-bottom: 8px; }
.meta { color: #5d6470; font-size: 0.9rem; margin-bottom: 24px; }
a { color: #315bae; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible { outline: 3px solid #6a85c3; outline-offset: 4px; }

details { margin-bottom: 18px; }
summary { cursor: pointer; font-weight: 600; }
summary:focus-visible { outline: 3px solid #6a85c3; outline-offset: 4px; }
details[open] > summary { margin-bottom: 8px; }
.contact {
  background: #f7f8f7;
  border: 1px solid #e3e7e2;
  border-radius: 10px;
  padding: 14px 18px;
}
.contact p { margin: 0.6em 0; }
.contact a { color: #2b6a44; text-decoration: none; font-weight: 600; }
.contact a:hover { text-decoration: underline; }
.legal {
  margin-top: 18px;
  padding-top: 0;
  font-size: 0.85em;
  color: #666666;
}
.legal-links { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35em 0.75em; }
.legal-links a { color: #58606b; text-decoration: none; font-weight: 600; }
.legal-links a:hover { color: #2b6a44; text-decoration: underline; }
.legal-separator { color: #b2b7bd; }
.legal-copyright { margin: 0.45em 0 0; }

@media (max-width: 480px) {
  body { padding: 18px 16px 32px; }
  .lang-switch { justify-content: space-between; }
  .lang-switch select { width: min(210px, 66vw); min-width: 0; }
}

@media (prefers-color-scheme: dark) {
  :root { color: #e3e7ed; background: #171a20; }
  .meta { color: #abb3c1; }
  .lang-switch label { color: #abb3c1; }
  a { color: #a5bff6; }
  .contact { background: #2c2c2e; border-color: #3a3a3c; }
  .contact a { color: #7ec89a; }
  .legal { color: #aaaaaa; }
  .legal-links a { color: #b8bdc5; }
  .legal-links a:hover { color: #7ec89a; }
  .legal-separator { color: #63666b; }
}

@media print {
  :root { color: #111111; background: #ffffff; }
  body { max-width: none; padding: 0; }
  .lang-switch, noscript { display: none; }
  h2 { break-after: avoid; }
  a { color: inherit; }
}
