@font-face {
  font-family: "Google Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 400 700;
  src: url("./fonts/google-sans-cyrillic-full-normal.woff2") format("woff2-variations");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "Google Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 400 700;
  src: url("./fonts/google-sans-latin-full-normal.woff2") format("woff2-variations");
  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: light;
  --background: #EFF2F5;
  --surface-raised: #FFFFFF;
  --surface-subtle: #002B8F14;
  --surface-hover: #002B8F1A;
  --segmented-control-fill: #002B8F14;
  --segmented-control-active: #FFFFFF;
  --text: #0F172A;
  --text-secondary: #0F172AA8;
  --text-tertiary: #0F172A75;
  --selection-strong: #006EC9;
  --focus: #0F172A;
  --fixed-panel-background: rgb(239 242 245 / 70%);
  --fixed-panel-blur: 20px;
  --shape-medium: 18px;
  --shape-large: 24px;
  --shape-extra-large: 28px;
  --shape-full: 100px;
  --font-ui: "Google Sans", -apple-system, BlinkMacSystemFont, "SF Pro Text", Inter, "Segoe UI", sans-serif;
  font-family: var(--font-ui);
  font-optical-sizing: auto;
  font-synthesis: none;
  font-variation-settings: "GRAD" 0;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 280px;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background: var(--background);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--selection-strong);
  text-underline-offset: 0.18em;
}

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

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

.visually-hidden,
.language-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  width: 100%;
  color: var(--text);
  background: var(--fixed-panel-background);
  -webkit-backdrop-filter: blur(var(--fixed-panel-blur));
  backdrop-filter: blur(var(--fixed-panel-blur));
}

.site-header-inner,
.site-main,
.site-footer {
  width: min(100% - 32px, 780px);
  margin-inline: auto;
}

.site-header-inner {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
  padding-block: 8px 12px;
}

.brand {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  min-height: 40px;
  color: var(--text);
  font-size: 18px;
  font-weight: 700;
  line-height: 24px;
  letter-spacing: -0.5px;
  text-decoration: none;
}

.brand img {
  display: block;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border-radius: 30%;
}

.language-switcher {
  position: relative;
  display: flex;
  flex: 0 0 auto;
  gap: 2px;
  align-items: center;
  height: 44px;
  padding: 0 2px;
  margin: 0;
  border: 0;
  border-radius: var(--shape-full);
  background: transparent;
}

.language-switcher::before {
  position: absolute;
  inset: 6px 0;
  border-radius: var(--shape-full);
  background: var(--segmented-control-fill);
  content: "";
  pointer-events: none;
}

.language-switcher label {
  position: relative;
  z-index: 1;
  display: grid;
  min-width: 40px;
  height: 44px;
  padding-inline: 8px;
  border-radius: var(--shape-full);
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
  line-height: 16px;
  place-items: center;
  transition:
    color 160ms cubic-bezier(0.2, 0, 0, 1);
  isolation: isolate;
}

.language-switcher label::before {
  position: absolute;
  inset: 8px 0;
  z-index: -1;
  border-radius: var(--shape-full);
  background: transparent;
  content: "";
  transition: background-color 160ms cubic-bezier(0.2, 0, 0, 1);
}

.language-switcher label:hover {
  color: var(--text);
}

#language-en:checked ~ label[for="language-en"],
#language-ru:checked ~ label[for="language-ru"] {
  color: var(--text);
}

#language-en:checked ~ label[for="language-en"]::before,
#language-ru:checked ~ label[for="language-ru"]::before {
  background: var(--segmented-control-active);
}

#language-en:focus-visible ~ label[for="language-en"],
#language-ru:focus-visible ~ label[for="language-ru"] {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.site-main {
  padding-block: 16px 32px;
}

.policy {
  display: none;
  gap: 14px;
}

#english {
  display: grid;
}

body:has(#language-ru:checked) #english {
  display: none;
}

body:has(#language-ru:checked) #russian {
  display: grid;
}

.policy-heading,
.policy section {
  min-width: 0;
  max-width: none;
  padding: 24px;
  border-radius: var(--shape-extra-large);
  background: var(--surface-raised);
}

.policy-heading {
  padding-block: 28px;
}

.eyebrow,
.updated {
  margin: 0;
  color: var(--text-secondary);
  font-size: 12px;
  line-height: 1.45;
}

.eyebrow {
  font-weight: 700;
}

h1 {
  margin: 6px 0 2px;
  font-size: clamp(30px, 6vw, 38px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.lead {
  max-width: 62ch;
  margin: 20px 0 0;
  color: var(--text-secondary);
  font-size: 16px;
  line-height: 1.55;
}

h2 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

p,
ul {
  margin-block: 0 12px;
}

p:last-child,
ul:last-child {
  margin-bottom: 0;
}

ul {
  padding-inline-start: 22px;
}

li + li {
  margin-top: 7px;
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  justify-content: space-between;
  padding-block: 4px 40px;
  color: var(--text-secondary);
  font-size: 12px;
}

@media (max-width: 680px) {
  .site-header-inner,
  .site-main,
  .site-footer {
    width: min(100% - 24px, 780px);
  }

  .policy-heading,
  .policy section {
    padding: 20px;
    border-radius: var(--shape-large);
  }

  .policy-heading {
    padding-block: 24px;
  }

  h1 {
    font-size: clamp(23px, 7.3vw, 30px);
    line-height: 1.12;
    hyphens: auto;
    overflow-wrap: anywhere;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --background: #000000;
    --surface-raised: #222228;
    --surface-subtle: #C5C8D82E;
    --surface-hover: #C5C8D838;
    --segmented-control-fill: #C5C8D82E;
    --segmented-control-active: #C5C8D873;
    --text: #FFFFFF;
    --text-secondary: #FFFFFFB2;
    --text-tertiary: #FFFFFF66;
    --selection-strong: #69B8FF;
    --focus: #FFFFFF;
    --fixed-panel-background: rgb(0 0 0 / 70%);
  }
}

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

  .language-switcher label {
    transition: none;
  }

  .language-switcher label::before {
    transition: none;
  }
}
