@font-face {
  font-family: Fraunces;
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/fraunces-500-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: Fraunces;
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/fraunces-500.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: dark;
  --bg: #141311;
  --ink: #f3efe6;
  --quiet: #9a9286;
  --line: rgba(243, 239, 230, 0.14);
  --x: 42vw;
  --y: 46vh;
  --r: 168px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background: var(--bg);
  color: var(--ink);
}

.glow,
.plan,
.rule {
  position: fixed;
  pointer-events: none;
}

.glow {
  z-index: 0;
  left: var(--x);
  top: var(--y);
  width: calc(var(--r) * 2);
  height: calc(var(--r) * 2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  mix-blend-mode: screen;
  background: radial-gradient(
    circle,
    rgba(255, 236, 204, 0.34) 0%,
    rgba(255, 196, 120, 0.1) 46%,
    transparent 72%
  );
}

.plan {
  inset: 0;
  z-index: 0;
  background-image: repeating-linear-gradient(
    to bottom,
    transparent 0,
    transparent 31px,
    var(--line) 31px,
    var(--line) 32px
  );
  -webkit-mask-image: radial-gradient(
    circle at var(--x) var(--y),
    #000 0,
    #000 calc(var(--r) * 0.42),
    transparent var(--r)
  );
  mask-image: radial-gradient(
    circle at var(--x) var(--y),
    #000 0,
    #000 calc(var(--r) * 0.42),
    transparent var(--r)
  );
}

.rule {
  z-index: 2;
  height: 1px;
  background: rgba(243, 239, 230, 0.55);
  opacity: 0;
}

.rule.drawn::before,
.rule.drawn::after {
  content: "";
  position: absolute;
  top: -4px;
  width: 1px;
  height: 9px;
  background: inherit;
}

.rule::before {
  left: 0;
}

.rule::after {
  right: 0;
}

.page {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  width: min(40rem, 100%);
  padding:
    max(1.5rem, 7vh)
    max(1.25rem, 7vw)
    max(1.35rem, 4vh);
}

.top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
}

.status,
.lang {
  margin: 0;
  color: var(--quiet);
  font-family: ui-monospace, "Cascadia Code", "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.lang {
  display: flex;
  gap: 0.75rem;
}

.lang button {
  padding: 0.15rem 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  cursor: pointer;
}

.lang button[aria-pressed="true"] {
  color: var(--ink);
}

main {
  margin: auto 0;
  padding: 2.5rem 0 2.5rem 1.15rem;
  border-left: 1px solid rgba(243, 239, 230, 0.16);
}

h1 {
  margin: 0;
  font-family: Fraunces, "Iowan Old Style", Palatino, Georgia, serif;
  font-weight: 500;
  font-size: clamp(2.7rem, 8vw, 4.6rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
}

.role {
  margin: 0.9rem 0 0;
  font-family: ui-sans-serif, system-ui, sans-serif;
  font-size: 1.05rem;
}

.scope {
  margin: 1.15rem 0 0;
  max-width: 28rem;
  color: var(--quiet);
  font-family: ui-sans-serif, system-ui, sans-serif;
  font-size: 0.98rem;
  line-height: 1.5;
}

footer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.5rem;
  color: var(--quiet);
  font-family: ui-monospace, "Cascadia Code", "SFMono-Regular", Menlo, Consolas, monospace;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

a {
  color: var(--ink);
  text-underline-offset: 0.22em;
}

a:hover {
  text-decoration-thickness: 2px;
}

a:focus-visible,
button:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 4px;
}

::selection {
  background: #e7b56a;
  color: #1a120c;
}

@media (max-height: 640px) {
  main {
    margin: 2.5rem 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rule {
    display: none;
  }
}
