:root {
  color-scheme: dark;
  --bg: #09090b;
  --card: #121216;
  --card-2: #18181d;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: #3a3a44;
  --text: #f4f4f5;
  --muted: #a1a1aa;
  --accent: #9b87ff;
  --accent-deep: #2c2640;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --font: "Outfit", system-ui, "Segoe UI", "Noto Sans", "Noto Sans Arabic", "Noto Sans SC", "Noto Sans JP", "Noto Sans KR", sans-serif;
  --display: "Syne", "Outfit", system-ui, sans-serif;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(720px 320px at 100% -10%, rgba(155, 135, 255, 0.16), transparent 55%),
    var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--font);
}

a { color: var(--accent); }

img { max-width: 100%; height: auto; }

::selection { background: #d8ccff; color: #1a1028; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.layout {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 72px;
  display: grid;
  gap: 28px;
}

@media (min-width: 960px) {
  .layout {
    grid-template-columns: 232px minmax(0, 1fr);
    column-gap: 36px;
    align-items: start;
  }

  .layout:has(nav[hidden]) {
    grid-template-columns: minmax(0, 1fr);
  }
}

.hero {
  position: relative;
  grid-column: 1 / -1;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.hero:has(.menu-btn[aria-expanded="true"]) { z-index: 20; }

.hero-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.mark {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.mark img {
  display: block;
  height: 34px;
  width: auto;
}

.menu {
  position: relative;
  display: inline-block;
  max-width: 100%;
}

.menu:has(.menu-btn[aria-expanded="true"]) { z-index: 5; }

.menu-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: 100%;
  min-height: 42px;
  padding: 0 12px 0 8px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: #141418;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 140ms ease, background 140ms ease;
}

.menu-btn:hover { border-color: #5a5a66; background: #1b1b22; }

.menu-btn[aria-expanded="true"] {
  border-color: #7c6bb8;
  background: #1b1b22;
}

.menu-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chev {
  flex: none;
  color: var(--muted);
  transition: transform 160ms ease;
}

.menu-btn[aria-expanded="true"] .chev { transform: rotate(180deg); }

.menu-pop {
  position: absolute;
  z-index: 30;
  top: calc(100% + 8px);
  inset-inline-start: 0;
  width: max(100%, 240px);
  max-width: min(280px, calc(100vw - 32px));
  max-height: min(380px, 62vh);
  overflow: auto;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  background: #141418;
  box-shadow: var(--shadow);
}

.menu-pop.align-end {
  inset-inline-start: auto;
  inset-inline-end: 0;
}

.menu-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 40px;
  padding: 0 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  text-align: start;
  cursor: pointer;
}

.menu-opt:hover { background: #23232c; }

.menu-opt[aria-selected="true"] {
  background: var(--accent-deep);
  color: #fff;
}

.tick {
  margin-inline-start: auto;
  flex: none;
  color: var(--accent);
}

.flag,
.glyph {
  flex: none;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.flag {
  width: 22px;
  height: 16px;
  border-radius: 3px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.16);
}

.glyph {
  width: 18px;
  height: 18px;
  color: var(--accent);
}

.menu .logo {
  width: 18px;
  height: 18px;
  object-fit: contain;
  flex: none;
  display: block;
}

.flag svg,
.glyph svg,
.chev,
.tick { display: block; }

.flag svg { width: 22px; height: 16px; }
.glyph svg { width: 18px; height: 18px; }

@media (prefers-reduced-motion: no-preference) {
  .menu-pop:not([hidden]) { animation: menu-in 140ms ease-out; }
}

@keyframes menu-in {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

h1 {
  margin: 0 0 18px;
  font-family: var(--display);
  font-size: clamp(40px, 6vw, 64px);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.045em;
}

.actions,
.switch-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  align-items: center;
}

.switch-row { margin-top: 16px; }

.group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.group .label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 16px 0 10px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  transition: background 140ms ease, transform 140ms ease;
}

.btn img,
.btn svg {
  display: block;
  width: 22px;
  height: 22px;
  flex: none;
}

.btn.store {
  background: #3c4043;
  color: #fff;
}

.btn.store img { width: 26px; height: 26px; }

.btn.store:hover { background: #4e5256; }

.btn.telegram {
  background: #2aabee;
  color: #fff;
}

.btn.telegram:hover { background: #229ad6; }

nav {
  position: sticky;
  top: 0;
  z-index: 4;
  display: flex;
  gap: 6px;
  overflow: auto;
  scrollbar-width: none;
  background: rgba(9, 9, 11, 0.92);
  padding: 8px 0;
  backdrop-filter: blur(12px);
}

nav::-webkit-scrollbar { display: none; }

.nav-indicator { display: none; }

@media (min-width: 960px) {
  nav {
    position: sticky;
    top: 20px;
    flex-direction: column;
    gap: 2px;
    overflow: visible;
    padding: 4px 0 4px 16px;
    background: transparent;
    backdrop-filter: none;
  }

  nav::before {
    content: "";
    position: absolute;
    inset-inline-start: 5px;
    top: 10px;
    bottom: 10px;
    width: 1px;
    background: var(--line-strong);
  }

  .nav-indicator {
    display: block;
    position: absolute;
    inset-inline-start: 3px;
    top: 0;
    width: 3px;
    border-radius: 99px;
    background: var(--accent);
    pointer-events: none;
    transition: transform 200ms ease, height 200ms ease;
  }
}

nav a {
  flex: 0 0 auto;
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 12px;
  border-radius: 10px;
  transition: color 140ms ease, background 140ms ease;
}

nav a:hover { color: var(--text); background: #1c1c22; }

nav a[aria-current="true"] {
  color: #fff;
  background: var(--accent-deep);
  font-weight: 600;
}

main { display: grid; gap: 16px; min-width: 0; }

article {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 20px 20px 18px;
  scroll-margin-top: 72px;
}

@media (min-width: 960px) {
  article { scroll-margin-top: 24px; }
}

.step-no {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h2 {
  margin: 0 0 10px;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.25;
}

p { margin: 0 0 10px; }

ol, ul { margin: 0 0 12px; padding-inline-start: 1.2em; }

li + li { margin-top: 6px; }

.ui {
  font-weight: 700;
  color: #fff;
}

figure {
  margin: 14px 0 0;
  padding: 10px;
  border-radius: 14px;
  background: #0c0c0e;
  border: 1px solid var(--line);
  display: flex;
  justify-content: center;
}

figure + figure { margin-top: 10px; }

button.zoom {
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
  max-width: 100%;
  border-radius: 10px;
}

button.zoom img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 10px;
}

figure.phone button.zoom { max-width: 360px; }

table {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0 4px;
  font-size: 14px;
}

th, td {
  text-align: start;
  padding: 10px 10px 10px 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

th { color: var(--muted); font-weight: 600; width: 34%; }

dialog {
  width: min(1100px, calc(100% - 24px));
  max-height: calc(100% - 24px);
  padding: 12px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: #0c0c0e;
}

dialog::backdrop { background: rgba(0, 0, 0, 0.78); }

dialog img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 64px);
  margin: 0 auto;
  object-fit: contain;
}

dialog button {
  position: absolute;
  top: 8px;
  inset-inline-end: 8px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  background: #27272a;
  color: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .nav-indicator,
  .chev,
  .menu-btn,
  nav a,
  .btn { transition: none; }
}
