:root {
  --fg-1: #403735;
  --fg-1-enhanced: #291f1e;
  --bg-1: #fffefd;
  --fg-2: #352b29;
  --fg-2-enhanced: #140a09;
  --bg-2: #f5f4f3;
  --primary: #ed4a43;
  --primary-highlight: #ff4d4666;
  --primary-muted: #fc998e;
  --primary-bg: #ffeeec;
  --muted: #87817f;
  --muted-enhanced: #6b6462;
  --white: var(--bg-1);
  color-scheme: light;
}

html {
  font: 16px / 1.4 sans-serif;
  text-rendering: optimizeLegibility;
  color: var(--fg-1);
  background: var(--bg-1);
}

h2, h3 {
  color: var(--fg-1-enhanced);
}

img, iframe {
  max-width: 100%;
}

.wide-only {
  display: none;
}

.sr-only {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  overflow: hidden;
}

section:nth-child(odd) {
  background: var(--bg-2);
  color: var(--fg-2);
}

section:nth-child(odd) h2,
section:nth-child(odd) h3 {
  color: var(--fg-2-enhanced);
}

section a {
  color: var(--primary);
  text-decoration: none;
}

section ul, section ol {
  list-style: none;
  padding-left: 1em;
}

section ul > li,
section ol > li {
  margin-left: 2em;
}

section ul > li::before,
section ol > li::before {
  display: inline-block;
  position: relative;
  top: -0.2em;
  margin-left: -2em;
  margin-right: 0.5em;
  border-radius: 50%;
  width: 1.4em;
  font-size: 0.6em;
  font-weight: bold;
  text-align: center;
  color: var(--white);
  background: var(--primary);
}

section ul > li::before {
  content: '✓';
}

section ol > li::before {
  content: counter(list-item);
}

ol.extended {
  padding-left: 0;
}

ol.extended > li {
  position: relative;
  padding: 1.5em 2.5em 1.5em 3em;
  border: 1.5px solid var(--primary);
  color: var(--fg-1-enhanced);
  background: var(--primary-bg);
  margin: 1em 0 1em 2em;
}

ol.extended > li::before {
  position: absolute;
  margin-left: 0;
  top: 0.6em;
  left: -1em;
  font-size: 1.8em;
  line-height: 1.6;
  width: 1.8em;
  padding-right: 0.2em;
  border-radius: 5% 45% 45% 40%;
  box-shadow: 0.3em 0.05em 0.1em var(--primary-muted);
}

ol.extended > li > h3 {
  font-size: 1.25em;
  font-weight: normal;
  margin: 0;
}

ol.extended > li > *:last-child {
  margin-bottom: 0;
}

.expand-li-margin li {
  margin-top: 0.5em;
}

.expand-li-margin li:first-child {
  margin-top: 0;
}

body {
  margin: 0;
}

header, section, footer {
  padding-left: 1rem;
  padding-right: 1rem;
}

section {
  padding-top: 1.5em;
  padding-bottom: 2em;
}

section.title {
  position: relative;
  background: radial-gradient(#0009, #0000);
  text-align: center;
  min-height: 20rem;
}

.title > img {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  object-fit: cover;
  z-index: -1;
  filter: saturate(110%);
}

.title > div {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  transform: translateY(-50%);
}

.title h1,
.title p {
  width: fit-content;
  padding: 0.2em 0.5em;
  color: var(--white);
  background: var(--primary-highlight);
  margin-left: 50%;
  transform: translateX(-50%);
  text-shadow: 0px 0px 5px var(--primary-muted);
}

.title h1 {
  font-size: 2rem;
}

.title p {
  font-size: 1.2rem;
}

.site-home {
  display: flex;
  text-decoration: none;
}

.site-home .site-logo {
  height: 100%;
}

.site-home .site-name {
  font-family: serif;
  color: var(--primary);
  margin-left: 0.5em;
  align-self: center;
}

header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  margin-top: 1em;
  margin-bottom: 1em;
}

header .lang-chooser {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  font-size: 0.8em;
  color: var(--muted);
}

header .lang-chooser a {
  text-decoration: none;
  color: var(--primary);
}

header .site-home {
  font-size: 1.4em;
  max-width: 100%;
  height: 6rem;
}

header .site-home .site-name {
  align-self: flex-end;
  margin-left: 0.25em;
  margin-bottom: 0.6em;
}

header nav {
  display: flex;
  height: 100%;
  align-items: center;
  color: var(--muted);
  z-index: 1;
}

header nav > *,
header nav details .nav-submenu-content > * {
  display: block;
  height: 1em;
  padding: 0.8em 0.5em 1.2em;
  transition: color 0.2s, background-color 0.2s;
}

header nav > *:hover,
header nav details[open],
header nav details .nav-submenu-content > *:hover {
  color: var(--white);
  background: var(--primary);
}

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

header nav details {
  cursor: pointer;
}

header nav details > summary {
  list-style: none;
  padding-bottom: 0.6em;
}

header nav details > summary::after {
  content: "▼";
  font-size: 0.6em;
  margin-left: 0.2em;
  position: relative;
  top: -0.25em;
}

header nav details .nav-submenu {
  width: 0;
}

header nav details .nav-submenu-content {
  display: flex;
  flex-direction: column;
  color: var(--muted-enhanced);
  background: var(--primary-bg);
  min-width: 10em;
  width: max-content;
  margin-top: 0.2em;
  margin-left: -0.5em;
  box-shadow: 0 2px 2px var(--primary-muted);
}

header nav details .nav-submenu-content.nav-shift-left {
  margin-left: -4em;
}

footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  padding-top: 2rem;
  margin-bottom: 2rem;
}

footer .site-home {
  font-size: 1.8em;
  max-width: 100%;
  height: 10rem;
}

footer .contact {
  font-size: 0.8em;
}

footer .contact h2 {
  font-weight: normal;
  margin-bottom: 0;
}

footer .contact a {
  color: inherit;
  text-decoration: none;
}

footer .contact > ul {
  list-style: none;
  padding-left: 0;
  margin-top: 0.4em;
}

footer .contact > ul > li {
  margin-left: 2em;
}

footer .contact .icon-phone::before,
footer .contact .icon-wechat::before,
footer .contact .icon-email::before {
  margin-left: -2em;
  margin-right: 0.5em;
}

section ul .icon-phone::before,
section ul .icon-web::before,
section ul .icon-twitter::before {
  background: none;
  top: 0.2em;
}

.icon-phone::before {
  content: url(/asset/phone.svg);
}

.icon-email::before {
  content: url(/asset/email.svg);
}

.icon-web::before {
  content: url(/asset/web.svg);
}

.icon-wechat::before {
  content: url(/asset/wechat.svg);
}

.icon-twitter::before {
  content: url(/asset/twitter.svg);
}

.gallery {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 2em;
  width: 100%;
}

.gallery img {
  width: 49%;
}

@media (min-width: 400px) {
  section.image > img
  section.image > iframe {
    display: block;
    max-width: 368px;
    margin: 0 auto;
  }

  header nav > *,
  header nav details .nav-submenu-content > * {
    padding: 0.8em 0.8em 1.2em;
  }

  header nav details .nav-submenu-content {
    margin-left: -0.8em;
  }
}

@media (min-width: 680px) {
  header nav {
      margin-left: auto;
      margin-bottom: 0.25em;
      align-self: flex-end;
  }

  header nav > *,
  header nav details .nav-submenu-content > * {
    padding: 0.8em 1em 1.2em;
  }

  header nav details .nav-submenu-content {
    margin-left: -1em;
  }

  header nav details .nav-submenu-content.nav-shift-left {
    margin-left: -1em;
  }

  header nav details > summary::after {
    margin-left: 0.8em;
  }

  header .site-home .site-name,
  footer .site-home .site-name {
    max-width: 4.5em;
    align-self: center;
    margin-bottom: 0;
  }

  footer .contact {
    margin-left: auto;
    margin-right: 2rem;
  }
}

@media (min-width: 760px) {
  header nav > *,
  header nav details .nav-submenu-content > * {
    padding: 0.8em 1.2em 1.2em;
  }

  header nav details .nav-submenu-content {
    margin-left: -1.2em;
  }

  header nav details .nav-submenu-content.nav-shift-left {
    margin-left: -1.2em;
  }

  header .site-home .site-name,
  footer .site-home .site-name {
    max-width: 7.5em;
  }
}

@media (min-width: 1000px) {
  .wide-only {
    display: initial;
  }

  header, section, footer {
    padding-left: calc(50% - 484px);
    padding-right: calc(50% - 484px);
  }

  section.image {
    display: flex;
    align-items: center;
  }

  section.image > div {
    width: 60%;
  }

  section.image > div h2 {
    margin-right: -5%;
  }

  section.image > img,
  section.image > iframe {
    width: 35%;
    margin-left: auto;
  }

  .extended {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    padding-right: 2%;
  }

  .extended > li {
    box-sizing: border-box;
    width: 45%;
  }

  header .site-home .site-name {
    max-width: 12em;
    align-self: flex-end;
    margin-bottom: 0.6em;
  }

  footer .site-home .site-name {
    max-width: 12em;
    align-self: flex-end;
    margin-bottom: 1em;
  }
}

@media (prefers-contrast: more) {
  :root {
    --fg-1: #111111;
    --fg-1-enhanced: #030303;
    --bg-1: #ffffff;
    --fg-2: #090909;
    --fg-2-enhanced: #000000;
    --bg-2: #fafafa;
    --muted: #666462;
    --muted-enhanced: #5c5a57;
  }
}
