@font-face {
  font-family: "Geist";
  src: url("/fonts/geist-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Geist Mono";
  src: url("/fonts/geist-mono-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #f3f3ee;
  --bg-raised: #fbfbf8;
  --panel: #ffffff;
  --text: #10130f;
  --muted: #5a6058;
  --faint: #868c83;
  --line: #d9dad2;
  --line-strong: #bfc1b7;
  --accent: #4d7c0f;
  --accent-fill: #c8f03c;
  --on-accent: #10130f;
  --glow: rgba(132, 180, 20, 0.2);
  --grid: rgba(16, 19, 15, 0.055);
  --header: rgba(243, 243, 238, 0.82);
  --gutter: clamp(1.25rem, 4.5vw, 3rem);
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0b0d0c;
    --bg-raised: #101311;
    --panel: #131714;
    --text: #eff2ea;
    --muted: #9ba298;
    --faint: #6f766c;
    --line: #232823;
    --line-strong: #363d36;
    --accent: #c8f03c;
    --accent-fill: #c8f03c;
    --on-accent: #10130f;
    --glow: rgba(200, 240, 60, 0.13);
    --grid: rgba(239, 242, 234, 0.04);
    --header: rgba(11, 13, 12, 0.78);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b0d0c;
  --bg-raised: #101311;
  --panel: #131714;
  --text: #eff2ea;
  --muted: #9ba298;
  --faint: #6f766c;
  --line: #232823;
  --line-strong: #363d36;
  --accent: #c8f03c;
  --accent-fill: #c8f03c;
  --on-accent: #10130f;
  --glow: rgba(200, 240, 60, 0.13);
  --grid: rgba(239, 242, 234, 0.04);
  --header: rgba(11, 13, 12, 0.78);
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-wrap: break-word;
}

main { flex: 1; }

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

.wrap {
  width: 100%;
  max-width: 84rem;
  margin-inline: auto;
  padding-inline: max(var(--gutter), env(safe-area-inset-left)) max(var(--gutter), env(safe-area-inset-right));
}

.narrow { max-width: 54rem; }

a { color: inherit; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute;
  left: 0.75rem;
  top: -5rem;
  z-index: 50;
  padding: 0.7rem 1rem;
  border-radius: 6px;
  background: var(--accent-fill);
  color: var(--on-accent);
  font-weight: 600;
}
.skip:focus { top: 0.75rem; }

.mono {
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 450;
  letter-spacing: 0.02em;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: var(--header);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  padding-top: env(safe-area-inset-top);
}

.header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 1.25rem;
  min-height: 4.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-height: 44px;
  margin-right: auto;
  color: var(--text);
  font-size: 1.15rem;
  font-weight: 620;
  letter-spacing: -0.03em;
  text-decoration: none;
}
.brand svg { width: 26px; height: 26px; color: var(--accent); flex: none; }

.site-nav { display: flex; gap: 0.25rem; }

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding-inline: 0.85rem;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.8rem;
  text-decoration: none;
  transition: color 0.15s;
}
.site-nav a:hover { color: var(--text); }

.header-tools { display: flex; align-items: center; gap: 0.5rem; }

.language-switch {
  display: flex;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 0.75rem;
}
.language-switch a, .language-switch span {
  display: grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
  border-radius: 999px;
  color: var(--muted);
  text-decoration: none;
}
.language-switch [aria-current] { background: var(--panel); color: var(--accent); font-weight: 650; }
.language-switch a:hover { color: var(--text); }

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s, transform 0.2s;
}
.theme-toggle[hidden] { display: none; }
.theme-toggle:hover { border-color: var(--accent); background: var(--panel); }
.theme-toggle:active { transform: scale(0.94); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .icon-moon { display: none; }
.theme-toggle[aria-pressed="true"] .icon-sun { display: none; }
.theme-toggle[aria-pressed="true"] .icon-moon { display: block; }

/* Hero */

.hero {
  position: relative;
  overflow: hidden;
  overflow: clip;
  border-bottom: 1px solid var(--line);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(ellipse 85% 90% at 70% 20%, #000 20%, transparent 78%);
  mask-image: radial-gradient(ellipse 85% 90% at 70% 20%, #000 20%, transparent 78%);
}

.hero::after {
  content: "";
  position: absolute;
  top: -22rem;
  right: -12rem;
  width: 48rem;
  height: 48rem;
  max-width: 130vw;
  border-radius: 50%;
  background: radial-gradient(circle, var(--glow), transparent 66%);
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(2.5rem, 6vw, 4rem);
  padding-block: clamp(3.5rem, 10vw, 7.5rem) clamp(3rem, 8vw, 6.5rem);
}

h1, h2, h3 { font-weight: 600; text-wrap: balance; }

.hero h1 {
  margin: 0 0 1.75rem;
  font-size: clamp(2.05rem, 10.4vw, 5.5rem);
  font-weight: 580;
  line-height: 1;
  letter-spacing: -0.05em;
}
.hero h1 span { display: block; white-space: nowrap; }
.hero h1 .dim { color: var(--faint); }
html:lang(bg) .hero h1 span { white-space: normal; }

.lead {
  margin: 0 0 2.25rem;
  max-width: 35rem;
  color: var(--muted);
  font-size: clamp(1.06rem, 1.6vw, 1.25rem);
  line-height: 1.55;
  letter-spacing: -0.01em;
}

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 50px;
  padding: 0.6rem 1.5rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.98rem;
  font-weight: 560;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: transform 0.18s, background-color 0.18s, border-color 0.18s;
}
.button:hover { transform: translateY(-1px); }
.button svg { width: 16px; height: 16px; transition: transform 0.18s; }
.button:hover svg { transform: translateX(3px); }
.button-primary { background: var(--accent-fill); color: var(--on-accent); }
.button-ghost { border-color: var(--line-strong); color: var(--text); }
.button-ghost:hover { border-color: var(--text); }
.button-dark { background: var(--on-accent); color: #f4f7ec; }

/* Strip */

.strip { border-bottom: 1px solid var(--line); background: var(--bg-raised); }

.strip ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.35rem 1.75rem;
  margin: 0;
  padding: 1.1rem 0;
  color: var(--muted);
  list-style: none;
}

/* Sections */

.section { padding-block: clamp(4rem, 9vw, 7.5rem); border-bottom: 1px solid var(--line); }

.section-head {
  display: grid;
  gap: 0.9rem;
  margin-bottom: clamp(2.25rem, 5vw, 4rem);
}

.section-head h2 {
  margin: 0;
  max-width: 19ch;
  font-size: clamp(1.9rem, 4.6vw, 3.5rem);
  font-weight: 570;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

/* Services */

.services { margin: 0; padding: 0; border-top: 1px solid var(--line-strong); list-style: none; }

.service {
  position: relative;
  display: grid;
  gap: 0.9rem;
  padding-block: clamp(1.75rem, 3.5vw, 2.75rem);
  border-bottom: 1px solid var(--line);
}

.service::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 100%;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.service:hover::before { transform: scaleX(1); }

.service-num { color: var(--faint); font-family: var(--mono); font-size: 0.82rem; padding-top: 0.5rem; transition: color 0.2s; }
.service:hover .service-num { color: var(--accent); }

.service h3 {
  margin: 0;
  font-size: clamp(1.5rem, 2.8vw, 2.2rem);
  font-weight: 540;
  line-height: 1.12;
  letter-spacing: -0.035em;
}

.service p { margin: 0 0 1.1rem; max-width: 34rem; color: var(--muted); }

.tags { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0; padding: 0; list-style: none; }
.tags li {
  padding: 0.22rem 0.65rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.72rem;
}

/* Principles */

.principles-section { background: var(--bg-raised); }

.principles {
  display: grid;
  gap: 1px;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--line);
  list-style: none;
}

.principle { padding: clamp(1.5rem, 3vw, 2.25rem); background: var(--panel); }
.principle svg { display: block; width: 24px; height: 24px; margin-bottom: 2.5rem; color: var(--accent); }
.principle h3 { margin: 0 0 0.5rem; font-size: 1.25rem; font-weight: 560; letter-spacing: -0.025em; }
.principle p { margin: 0; color: var(--muted); font-size: 1rem; }

/* Process */

.process-intro { margin: 0; max-width: 60ch; color: var(--muted); }

.steps { display: grid; margin: 0; padding: 0; list-style: none; counter-reset: step; }

.step {
  position: relative;
  counter-increment: step;
  padding: 0 0 2.25rem 2.25rem;
  border-left: 1px solid var(--line-strong);
}
.step:last-child { padding-bottom: 0; border-left-color: transparent; }
.step::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 0.4rem;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent-fill);
  box-shadow: 0 0 0 4px var(--bg);
}
.step::after {
  content: "0" counter(step);
  display: block;
  order: -1;
  position: absolute;
  top: 0.2rem;
  right: 0;
  color: var(--faint);
  font-family: var(--mono);
  font-size: 0.78rem;
}
.step h3 { margin: 0 0 0.35rem; font-size: 1.25rem; font-weight: 560; letter-spacing: -0.025em; }
.step p { margin: 0; color: var(--muted); font-size: 1rem; }

/* Contact */

.contact-section { padding-block: clamp(2rem, 5vw, 4rem); }

.contact {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 2rem;
  padding: clamp(2rem, 6vw, 5rem);
  border-radius: 20px;
  background: var(--accent-fill);
  color: var(--on-accent);
}

.contact::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(16, 19, 15, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 19, 15, 0.06) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: linear-gradient(115deg, transparent 45%, #000);
  mask-image: linear-gradient(115deg, transparent 45%, #000);
}

.contact > * { position: relative; z-index: 1; }
.contact h2 {
  margin: 0;
  max-width: 15ch;
  font-size: clamp(2rem, 6vw, 4.5rem);
  font-weight: 580;
  line-height: 1;
  letter-spacing: -0.045em;
}
.contact-side { align-self: end; }
.contact-side p { margin: 0 0 1.25rem; max-width: 26rem; }
.contact .button { max-width: 100%; }

/* Inner pages */

.page { padding-block: clamp(3rem, 8vw, 6rem); }
.page h1 {
  margin: 0 0 2.25rem;
  font-size: clamp(2.3rem, 7vw, 4.25rem);
  font-weight: 570;
  line-height: 1.02;
  letter-spacing: -0.045em;
}
.page h2 { margin: 2.5rem 0 0.6rem; font-size: 1.3rem; font-weight: 560; letter-spacing: -0.02em; }
.page p, .page li { color: var(--muted); }
.page strong { color: var(--text); font-weight: 560; }
.page a:not(.button) { color: var(--accent); text-underline-offset: 0.18em; }
.page ul { padding-left: 1.2rem; }
.page li { margin-bottom: 0.6rem; }
.updated { margin: -1.25rem 0 2rem; font-family: var(--mono); font-size: 0.78rem; }

.details { margin: 0; border-top: 1px solid var(--line-strong); }
.details div {
  display: grid;
  grid-template-columns: minmax(0, 13rem) minmax(0, 1fr);
  gap: 0.15rem 1.5rem;
  padding-block: 1.05rem;
  border-bottom: 1px solid var(--line);
}
.details dt { color: var(--faint); font-family: var(--mono); font-size: 0.8rem; padding-top: 0.2rem; }
.details dd { margin: 0; font-weight: 480; }

.notfound-code { margin: 0 0 1rem; color: var(--accent); font-family: var(--mono); font-size: 0.85rem; }

/* Footer */

.site-footer {
  padding-block: clamp(2.5rem, 5vw, 3.5rem) calc(1.5rem + env(safe-area-inset-bottom));
  color: var(--muted);
  font-size: 0.92rem;
}

.footer-grid { display: grid; gap: 2rem; }
.footer-grid p { margin: 0; }
.footer-brand .brand { margin-bottom: 0.4rem; }
.footer-brand p { max-width: 22rem; }

.footer-title { margin: 0 0 0.6rem !important; color: var(--faint); font-family: var(--mono); font-size: 0.74rem; }

.footer-links { display: flex; flex-wrap: wrap; gap: 0 1.25rem; }
.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--text);
  text-decoration: none;
}
.footer-links a:hover { color: var(--accent); }

.footer-base {
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  color: var(--faint);
}
.footer-base p { margin: 0; }

/* Responsive */

@media (max-width: 46rem) {
  .site-header { position: static; }
  .header-row { gap: 0 0.75rem; padding-block: 0.3rem; }
  .site-nav {
    order: 3;
    width: 100%;
    justify-content: space-between;
    border-top: 1px solid var(--line);
  }
  .site-nav a { padding-inline: 0.2rem; }
  html { scroll-padding-top: 1rem; }
}

@media (max-width: 40rem) {
  html:lang(bg) .hero h1 { font-size: clamp(1.75rem, 8.7vw, 3.5rem); }
  .actions .button { flex: 1 1 100%; }
  .details div { grid-template-columns: 1fr; }
}

@media (min-width: 48rem) {
  .service { grid-template-columns: 4.5rem minmax(0, 1fr) minmax(0, 1.15fr); gap: 2rem; align-items: start; }
  .principles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .step {
    padding: 2rem 1.75rem 0 0;
    border-left: 0;
    border-top: 1px solid var(--line-strong);
  }
  .step:last-child { padding-bottom: 0; }
  .step::before { left: 0; top: -5px; }
  .step::after { top: 0.6rem; right: 1.75rem; }
  .footer-grid { grid-template-columns: 1.6fr 1fr 1fr; }
}

@media (min-width: 62rem) {
  .hero h1 { font-size: clamp(4.5rem, 7.6vw, 7.5rem); }
  .lead { max-width: 40rem; }
  .contact { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
