/* Self-hosted Iansui: the same font downloads on every device. */
@font-face {
  font-family: "Iansui";
  src: url("fonts/iansui-regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
/* Shared navigation for the invitation and YaoYue. */
:root {
  --menu: #E9FFFD;
  --separator: #C7DFE9;
  --latin: Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif;
  --chinese: "Iansui", serif;
  --header-height: 66px;
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
  flex-shrink: 0;
  color: #171c1d;
  font-family: var(--latin);
  padding: 0 max(30px, env(safe-area-inset-right)) 0 max(30px, env(safe-area-inset-left));
  background-color: var(--menu);
  background-image: url("menu-paper.svg");
  background-size: 480px 480px;
  border-bottom: 1px solid var(--separator);
  font-size: 16px;
}
.menu-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0;
  color: inherit;
  font: inherit;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.menu-toggle svg { stroke: #375c70; stroke-width: 1.5; fill: none; }
.menu-panel {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 180px;
  padding: 10px 20px;
  background-color: var(--menu);
  background-image: url("menu-paper.svg");
  background-size: 480px 480px;
  border: 1px solid var(--separator);
  border-top: 0;
  box-shadow: 0 5px 12px #203e5114;
}
.menu-panel a { display: block; padding: 12px 10px; text-decoration: none; }
.menu-panel a:hover { text-decoration: underline; text-underline-offset: 5px; }
.languages { display: flex; gap: 20px; align-items: center; }
.languages a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  text-decoration: none;
}
.languages a[aria-current="true"] { text-decoration: underline; text-underline-offset: 9px; text-decoration-thickness: 1px; }
.site-header:lang(zh-Hant), .site-header [lang="zh-Hant"] { font-family: var(--chinese); }
.languages a[lang="en"], .languages a[lang="it"] { font-family: var(--latin); }

.site-header a { color: inherit; }
.site-header :focus-visible { outline: 2px solid #375c70; outline-offset: 4px; }
.site-header button, .site-header a { -webkit-tap-highlight-color: transparent; }
@media (max-width: 650px) {
  :root { --header-height: 64px; }
  .site-header { padding-left: max(17px, env(safe-area-inset-left)); padding-right: max(10px, env(safe-area-inset-right)); }
  .languages { gap: 9px; }
  .menu-toggle { gap: 8px; }
  .menu-panel { min-width: 160px; padding-left: 7px; }
}
