@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('/assets/bricolage-latin.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;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('/assets/inter-latin.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;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('/assets/inter-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: Inter;
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('/assets/inter-cyrillic-ext.woff2') format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}

:root {
  color-scheme: light;
  --paper: #f6f5ef;
  --ink: #142322;
  --muted: #485652;
  --line: #d5d9cf;
  --accent: #dff45c;
  --night: #0d201f;
  --light: #f5f6ef;
  --sans: Inter, 'Helvetica Neue', Arial, sans-serif;
  --display: 'Bricolage Grotesque', Inter, 'Helvetica Neue', Arial, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, SFMono-Regular, Consolas, monospace;
  --gutter: clamp(1rem, 4.3vw, 4.25rem);
  --content: 1240px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }
button, input { font: inherit; }

::selection { background: var(--accent); color: var(--ink); }

a:focus-visible, button:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 5px;
}

.shell {
  width: min(var(--content), calc(100% - var(--gutter) * 2));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  z-index: 5;
  top: .75rem;
  left: var(--gutter);
  padding: .7rem 1rem;
  background: var(--accent);
  color: var(--ink);
  transform: translateY(calc(-100% - 2rem));
}

.skip-link:focus { transform: none; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  clip-path: inset(50%);
  overflow: hidden;
  white-space: nowrap;
}

.header-inner, .footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.header-inner { min-height: 4.75rem; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  width: fit-content;
  color: var(--ink);
  font: 700 1.16rem/1.15 var(--display);
  letter-spacing: -.045em;
  text-decoration: none;
}

.brand-name { display: inline-flex; flex-wrap: wrap; gap: .1em .27em; }
.brand-name strong { font-weight: 500; }

.brand-mark {
  position: relative;
  display: inline-grid;
  flex: 0 0 1.65rem;
  width: 1.65rem;
  height: 1.65rem;
  place-items: center;
  overflow: hidden;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  transform: rotate(-35deg);
}

.brand-mark::before, .brand-mark::after {
  position: absolute;
  border: 1px solid currentColor;
  border-radius: 50%;
  content: '';
}

.brand-mark::before { inset: -.15rem .35rem; }
.brand-mark::after { inset: .4rem -.15rem; }
.brand-mark i { width: .28rem; height: .28rem; border-radius: 50%; background: var(--ink); }
.brand-mark i + i { display: none; }

.site-nav, .language-switch {
  display: flex;
  align-items: center;
}

.site-nav { gap: clamp(1.1rem, 2.7vw, 2.5rem); margin-left: auto; }
.site-nav a { color: var(--muted); font-size: .9rem; font-weight: 600; text-decoration: none; }
.site-nav a:hover, .language-switch a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: .25em; }

.language-switch {
  gap: .17rem;
  padding: .18rem;
  margin-left: clamp(0rem, 3vw, 2.75rem);
  border: 1px solid var(--line);
  border-radius: .24rem;
  font: 600 .83rem/1 var(--mono);
}

.language-switch > * {
  display: grid;
  min-width: 2.2rem;
  min-height: 2.05rem;
  place-items: center;
  padding: .25rem .38rem;
  border-radius: .13rem;
  text-decoration: none;
}

.language-switch [aria-current] { background: var(--ink); color: var(--light); }

.hero {
  position: relative;
  z-index: 0;
  display: flex;
  min-height: clamp(29rem, 38vw, 34rem);
  flex-direction: column;
  justify-content: flex-end;
  isolation: isolate;
  overflow: hidden;
  border: 1px solid #233b39;
  border-radius: .35rem;
  background: #142729;
  color: var(--light);
  --inset: clamp(1.6rem, 5.15vw, 4.65rem);
}

.hero-media, .hero-media::after, .hero-media img, .hero-media picture, .hero::after {
  position: absolute;
  inset: 0;
}

.hero-media { z-index: -3; overflow: hidden; margin: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 55% 50%; }

.hero-media::after {
  background:
    linear-gradient(90deg, rgb(7 20 25 / .94), rgb(8 20 24 / .79) 26%, rgb(8 20 24 / .38) 61%, rgb(8 20 24 / .06) 90%),
    linear-gradient(0deg, rgb(6 19 21 / .69) 0%, transparent 44%);
  content: '';
}

.hero::after {
  z-index: -2;
  background-image: linear-gradient(rgb(207 226 217 / .22) 1px, transparent 1px), linear-gradient(90deg, rgb(207 226 217 / .22) 1px, transparent 1px);
  background-size: 4.75rem 4.75rem;
  background-position: center;
  mask-image: linear-gradient(120deg, transparent 39%, #000 100%);
  opacity: .39;
  pointer-events: none;
  content: '';
}

.hero-inner {
  width: 100%;
  padding: clamp(3rem, 5vw, 5rem) var(--inset) clamp(2.6rem, 4.7vw, 4rem);
  overflow-wrap: break-word;
}

.hero-kicker, .hero-foot, .project-meta {
  font: 500 .83rem/1.35 var(--mono);
  letter-spacing: .045em;
  text-transform: uppercase;
}

.hero-kicker {
  display: flex;
  align-items: center;
  gap: .68rem;
  margin-bottom: 1.35rem;
  color: #e8eee4;
}

.hero-kicker::before {
  width: .45rem;
  height: .45rem;
  flex: 0 0 .45rem;
  border: 1px solid var(--accent);
  background: var(--accent);
  content: '';
}

.hero h1 {
  max-width: 12ch;
  font: 700 clamp(3.3rem, 6.4vw, 6.15rem)/.94 var(--display);
  letter-spacing: -.069em;
  text-wrap: balance;
}

.hero h1 em { display: block; color: var(--accent); font-style: normal; }

.hero-copy {
  max-width: 34rem;
  margin-top: 1.36rem;
  color: #e5ece5;
  font-size: clamp(1.02rem, 1.4vw, 1.16rem);
  line-height: 1.57;
  text-wrap: pretty;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.6rem; }

.button {
  display: inline-flex;
  min-height: 3rem;
  align-items: center;
  justify-content: center;
  gap: .58rem;
  padding: .55rem 1.05rem;
  border: 1px solid var(--accent);
  border-radius: .22rem;
  background: var(--accent);
  color: #16210e;
  font-size: .94rem;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  transition: background-color .16s, border-color .16s;
}

.button:hover { border-color: #f3ffac; background: #f3ffac; }
.hero a:focus-visible { outline-color: #fbfff1; }

.hero-foot {
  display: flex;
  min-height: 3.3rem;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .38rem 1.3rem;
  padding: .86rem var(--inset);
  border-top: 1px solid rgb(230 241 229 / .31);
  background: rgb(5 20 23 / .46);
  color: #e3ece3;
  font-size: .78rem;
}

.hero-coordinates { color: var(--accent); font-variant-numeric: tabular-nums; }

.hero-reticle {
  position: absolute;
  z-index: -1;
  top: 44%;
  right: clamp(2.6rem, 15vw, 13.2rem);
  width: clamp(6rem, 13vw, 10rem);
  aspect-ratio: 1;
  border: 1px solid rgb(226 242 203 / .5);
  border-radius: 50%;
  color: rgb(233 248 198 / .64);
  pointer-events: none;
}

.hero-reticle::before, .hero-reticle::after {
  position: absolute;
  top: 50%;
  left: 50%;
  background: currentColor;
  transform: translate(-50%, -50%);
  content: '';
}

.hero-reticle::before { width: 130%; height: 1px; }
.hero-reticle::after { width: 1px; height: 130%; }

.projects { padding-block: clamp(3.4rem, 5.2vw, 4.85rem) clamp(3.5rem, 6vw, 5.7rem); }
.projects, .about { scroll-margin-top: 1.4rem; }

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 2rem;
  margin-bottom: 1.55rem;
}

.section-heading h2, .about h2 {
  font: 700 clamp(2.1rem, 4.1vw, 3.55rem)/1.04 var(--display);
  letter-spacing: -.055em;
  text-wrap: balance;
}

.section-heading p { max-width: 33rem; color: var(--muted); text-wrap: pretty; }

.project-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(.9rem, 2.15vw, 1.65rem); }

.project-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: .35rem;
  background: #fbfbf6;
}

.project-visual {
  position: relative;
  isolation: isolate;
  min-height: clamp(8rem, 12vw, 11rem);
  overflow: hidden;
  color: #dff45c;
}

.project-visual img { width: 100%; height: 100%; object-fit: cover; }

.tile-visual {
  background:
    linear-gradient(0deg, rgb(145 183 157 / .19) 1px, transparent 1px),
    linear-gradient(90deg, rgb(145 183 157 / .19) 1px, transparent 1px),
    radial-gradient(ellipse at 78% 26%, #294845, #142929 73%);
  background-size: 29px 29px, 29px 29px, auto;
  background-position: 50% 50%;
}

.tile-visual::before, .tile-visual::after, .gaze-visual::before, .gaze-visual::after {
  position: absolute;
  z-index: -1;
  pointer-events: none;
  content: '';
}

.tile-visual::before {
  inset: 27% 13% 10% 23%;
  transform: skew(-29deg, -9deg);
  border: 1px solid rgb(214 242 163 / .77);
  background:
    linear-gradient(90deg, transparent 60%, rgb(216 244 114 / .13) 60%),
    repeating-linear-gradient(0deg, transparent 0 24px, rgb(214 242 163 / .41) 24px 25px),
    repeating-linear-gradient(90deg, transparent 0 35px, rgb(214 242 163 / .41) 35px 36px);
  box-shadow: 1.55rem -.7rem 0 -1px #21403b, 1.55rem -.7rem 0 rgb(138 196 158 / .47), -.95rem .85rem 0 -1px #203936, -.95rem .85rem 0 rgb(138 196 158 / .47);
}

.tile-visual::after {
  top: 34%;
  left: 62%;
  width: 2.6rem;
  height: 1.45rem;
  border: 1px solid #e3f881;
  background: rgb(223 244 92 / .43);
  transform: skew(-29deg, -9deg);
  box-shadow: 0 0 1rem rgb(223 244 92 / .23);
}

.gaze-visual {
  background:
    linear-gradient(0deg, rgb(139 173 165 / .2) 1px, transparent 1px),
    linear-gradient(90deg, rgb(139 173 165 / .2) 1px, transparent 1px),
    radial-gradient(ellipse at 69% 50%, #2c4d40, #182e2d 74%);
  background-position: center;
  background-size: 29px 29px, 29px 29px, auto;
}

.gaze-visual::before {
  inset: -35% 6% -40%;
  background:
    radial-gradient(ellipse 13% 22% at 58% 46%, transparent 96%, rgb(225 248 181 / .74) 97% 100%, transparent 101%),
    radial-gradient(ellipse 22% 36% at 58% 46%, transparent 96%, rgb(225 248 181 / .52) 97% 100%, transparent 101%),
    radial-gradient(ellipse 33% 51% at 58% 46%, transparent 97%, rgb(225 248 181 / .32) 98% 100%, transparent 101%),
    radial-gradient(ellipse 48% 66% at 58% 46%, transparent 97%, rgb(225 248 181 / .22) 98% 100%, transparent 101%),
    linear-gradient(0deg, transparent 53.7%, rgb(203 235 178 / .39) 53.7% 54.1%, transparent 54.1%),
    linear-gradient(90deg, transparent 57.85%, rgb(203 235 178 / .41) 57.85% 58.15%, transparent 58.15%);
  transform: rotate(-13deg);
}

.gaze-visual::after {
  top: calc(40% - .3rem);
  left: calc(56% - .3rem);
  width: .6rem;
  height: .6rem;
  border-radius: 50%;
  background: #ebff9e;
  box-shadow: 0 0 0 .33rem rgb(220 248 140 / .32), 0 0 1.5rem rgb(220 248 140 / .82), -5rem 1.9rem 0 -.13rem #c5dda8, 5.3rem -1.1rem 0 -.15rem #c5dda8;
}

.project-content { display: flex; flex: 1; flex-direction: column; padding: clamp(1.2rem, 2.65vw, 2rem); }
.project-meta { display: flex; flex-wrap: wrap; gap: .35rem .8rem; margin-bottom: .74rem; color: #3d5c4c; }
.project-content h3 { font: 700 clamp(1.5rem, 3vw, 2.25rem)/1.08 var(--display); letter-spacing: -.046em; text-wrap: balance; }
.project-description { margin-top: .7rem; color: var(--muted); text-wrap: pretty; }

.paper-title {
  flex: 1;
  margin-top: 1.15rem;
  padding-bottom: 1.2rem;
  color: #425650;
  font-size: .92rem;
  text-wrap: pretty;
}

.paper-title span {
  display: block;
  margin-bottom: .22rem;
  color: var(--ink);
  font-weight: 650;
}

.project-link {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .35rem .8rem;
  min-height: 2.6rem;
  padding-top: .65rem;
  border-top: 1px solid var(--line);
  font-size: .95rem;
  font-weight: 700;
}

.project-link a, a.project-link, .about a { text-decoration-color: #7f9a8a; text-decoration-thickness: 1px; text-underline-offset: .25em; }
.project-link a:hover, a.project-link:hover, .about a:hover { text-decoration-color: currentColor; }
.project-link [aria-hidden='true'] { margin-left: .14em; }
.access-note {
  padding: .12rem .42rem;
  border-radius: .16rem;
  background: #edf1e7;
  color: #3f5148;
  font-size: .86rem;
  font-weight: 500;
}

.about { border-block: 1px solid var(--line); background: #eeefe6; }

.about-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 1.05rem clamp(1.8rem, 6vw, 6rem);
  align-items: start;
  padding-block: clamp(2.5rem, 5vw, 4.25rem);
}

.about p { max-width: 43rem; color: #3f5148; text-wrap: pretty; }
.about a { display: inline-flex; min-height: 2.6rem; align-items: center; gap: .45rem; margin-top: .58rem; font-weight: 700; }

.footer-inner { min-height: 4.4rem; padding-block: 1rem; color: var(--muted); font-size: .88rem; }
.footer-inner a { text-underline-offset: .23em; }
.footer-inner .brand { flex: 0 1 auto; }

html[lang='mn'] .hero h1 { max-width: 15ch; font-family: var(--sans); font-size: clamp(2.8rem, 5.8vw, 5.45rem); letter-spacing: -.065em; }
html[lang='mn'] .hero-copy { max-width: 37rem; }

@media (max-width: 850px) {
  .hero { min-height: 29rem; }
  .hero-reticle { right: 12%; opacity: .6; }
  .section-heading { display: block; }
  .section-heading p { margin-top: .65rem; }
}

@media (max-width: 640px) {
  .header-inner { min-height: 4.55rem; gap: .55rem; }
  .brand { gap: .5rem; font-size: 1.05rem; }
  .language-switch { margin-left: 0; }
  .hero { min-height: 32rem; --inset: clamp(1.18rem, 5.8vw, 2rem); }
  .hero-media img { object-position: 66% 50%; }
  .hero-media::after { background: linear-gradient(90deg, rgb(7 20 25 / .83), rgb(7 20 25 / .43)), linear-gradient(0deg, rgb(7 20 25 / .89), transparent 76%); }
  .hero-inner { padding-top: 3rem; }
  .hero h1 { font-size: clamp(2.85rem, 9.3vw, 3.65rem); }
  html[lang='mn'] .hero h1 { font-size: clamp(2.3rem, 7.7vw, 3.4rem); }
  .hero-kicker { margin-bottom: 1rem; }
  .hero-copy { margin-top: 1.05rem; }
  .hero-foot { font-size: .75rem; }
  .hero-reticle { top: 14%; right: 12%; width: 5rem; opacity: .42; }
  .project-grid { grid-template-columns: 1fr; gap: 1rem; }
  .project-visual { min-height: 8rem; }
  .about-inner { grid-template-columns: 1fr; }
  .footer-inner { flex-wrap: wrap; }
}

@media (max-width: 450px) {
  .header-inner { flex-wrap: wrap; min-height: 0; padding-block: .72rem; }
  .site-nav { flex-basis: 100%; order: 1; margin: 0; }
  .site-nav a { display: grid; min-height: 1.8rem; align-items: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button { transition: none; }
}
