/* ТихOn × INCY — светлая спокойная страница подключения.
   Палитра и типографика наследуют лендинг: бумага, мята, чернила, синий акцент. */

:root {
  --ink: #163842;
  --ink-soft: #203c48;
  --blue: #245edb;
  --blue-dark: #1b49ad;
  --paper: #f6faf8;
  --mint: #e4f1ec;
  --mint-deep: #cfe6dd;
  --line: #d3e4dd;
  --muted: #526c75;
  --white: #ffffff;
  --orange: #b4551f;
  --radius: 18px;
  --shadow: 0 18px 50px rgba(22, 56, 66, 0.08);
  --wrap: 1080px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(900px 480px at 88% -10%, rgba(207, 230, 221, 0.75), transparent 70%),
    var(--paper);
  color: var(--ink);
  font-family: Manrope, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; }
a { color: var(--blue); }

a:focus-visible,
button:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
  border-radius: 6px;
}

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 10;
  background: var(--ink);
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 700;
}
.skip:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

/* Шапка */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 0 6px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -0.03em;
}
.brand img { width: 40px; height: 46px; object-fit: contain; }
.brand small {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-left: 2px;
}
.top-badge {
  border: 1px solid var(--mint-deep);
  background: rgba(255, 255, 255, 0.7);
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
}

/* Первый экран */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(220px, 0.75fr);
  gap: 32px;
  align-items: center;
  padding: 38px 0 46px;
}
.eyebrow {
  margin: 0 0 14px;
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #2f6f61;
}
h1 {
  margin: 0 0 18px;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.045em;
  font-weight: 800;
}
.lead {
  margin: 0;
  max-width: 58ch;
  color: var(--muted);
  font-size: clamp(16px, 1.6vw, 18.5px);
}
.facts {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.facts li {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 13px;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-soft);
}
.hero-art {
  justify-self: center;
  width: min(260px, 100%);
  filter: drop-shadow(0 22px 28px rgba(22, 56, 66, 0.12));
}
.hero-art img { display: block; width: 100%; }

/* Карточки-секции */
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 6px);
  box-shadow: var(--shadow);
  padding: clamp(20px, 4vw, 34px);
}
.section { padding: 12px 0 26px; }
.section-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
h2 {
  margin: 0 0 10px;
  font-size: clamp(24px, 3.4vw, 34px);
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-weight: 800;
}
h3 {
  margin: 0 0 6px;
  font-size: 19px;
  line-height: 1.25;
  letter-spacing: -0.01em;
}
.sub { margin: 0 0 18px; color: var(--muted); }
.soft-note {
  background: var(--mint);
  border: 1px solid var(--mint-deep);
  border-radius: 14px;
  padding: 14px 16px;
  color: var(--ink-soft);
  font-size: 14px;
  margin: 20px 0 0;
}
.soft-note b { color: var(--ink); }

/* Виджет выбора ОС */
.guide { position: relative; }
.guide-label {
  display: block;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 7px;
}
.select-row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.select-wrap { position: relative; flex: 1 1 280px; max-width: 420px; }
.select-wrap::after {
  content: "";
  position: absolute;
  right: 18px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-right: 2.5px solid var(--ink);
  border-bottom: 2.5px solid var(--ink);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}
select#os-select {
  width: 100%;
  min-height: 52px;
  appearance: none;
  -webkit-appearance: none;
  background: var(--white);
  border: 1.5px solid #b9d2c9;
  border-radius: 12px;
  padding: 12px 46px 12px 16px;
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
#os-detected {
  margin: 12px 0 0;
  padding: 10px 13px;
  border-radius: 12px;
  background: var(--mint);
  border: 1px solid var(--mint-deep);
  color: var(--ink-soft);
  font-size: 14.5px;
  font-weight: 600;
}
.guide-hint { margin: 8px 0 0; font-size: 13px; color: var(--muted); }

#download-links { margin-top: 16px; }
.dl-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.dl-link {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-height: 58px;
  justify-content: center;
  padding: 13px 18px;
  border: 1.5px solid #b9d2c9;
  border-radius: 14px;
  background: var(--white);
  color: var(--ink);
  text-decoration: none;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}
.dl-link:hover { border-color: var(--blue); background: #f7faff; }
.dl-link:active { transform: translateY(1px); }
.dl-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dl-label { font-weight: 800; font-size: 16.5px; }
.dl-detail { color: var(--muted); font-size: 13.5px; }
.dl-badge {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #8a3f12;
  background: #fdece0;
  border: 1px solid #f6cfb4;
  border-radius: 999px;
  padding: 2px 8px;
}
.dl-note {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.55;
}

/* Шаги */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}
.step {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 16px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
}
.step-num {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--mint);
  border: 1px solid var(--mint-deep);
  color: #235f52;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 18px;
}
.step p { margin: 0; color: var(--muted); font-size: 15.5px; }
.step p + p { margin-top: 8px; }
.step strong { color: var(--ink); }
.step a { font-weight: 700; }
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
  background: var(--mint);
  border: 1px solid var(--mint-deep);
  border-radius: 6px;
  padding: 1px 6px;
  overflow-wrap: anywhere;
}

/* Подсказка про Telegram */
.telegram-hint {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  background: var(--mint);
  border: 1px solid var(--mint-deep);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin: 6px 0 28px;
}
.telegram-hint .tg-dot {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--white);
  display: grid;
  place-items: center;
  font-weight: 800;
  color: var(--blue);
  border: 1px solid var(--mint-deep);
}
.telegram-hint p { margin: 0; font-size: 14.5px; color: var(--ink-soft); }
.telegram-hint b { color: var(--ink); }

/* Без JS */
.noscript {
  border: 1.5px dashed #b9d2c9;
  border-radius: var(--radius);
  padding: 20px 22px;
  margin: 0 0 28px;
  background: rgba(255, 255, 255, 0.75);
}
.noscript h2 { font-size: 22px; }
.noscript ul { margin: 10px 0; padding-left: 20px; }
.noscript li { margin: 4px 0; }
.noscript p { margin: 8px 0 0; font-size: 14.5px; color: var(--muted); }

/* Подвал */
footer {
  border-top: 1px solid var(--line);
  padding: 24px 0 40px;
  color: var(--muted);
  font-size: 13px;
}
.foot-top {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.foot-top b { color: var(--ink); }
footer p { margin: 6px 0 0; max-width: 78ch; }

@media (max-width: 760px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  .top { padding-top: 16px; }
  .brand { font-size: 21px; }
  .brand img { width: 32px; height: 38px; }
  .top-badge { font-size: 11px; padding: 6px 10px; }
  .hero {
    grid-template-columns: 1fr;
    text-align: left;
    padding: 24px 0 30px;
    gap: 8px;
  }
  .hero-art {
    order: -1;
    width: 148px;
    justify-self: end;
    margin: -6px 4px -12px 0;
  }
  .facts { gap: 6px; }
  .facts li { font-size: 12px; padding: 6px 10px; }
  .card { border-radius: 20px; box-shadow: 0 10px 30px rgba(22, 56, 66, 0.06); }
  .select-wrap { max-width: none; flex-basis: 100%; }
  .step { grid-template-columns: 38px minmax(0, 1fr); gap: 12px; padding: 17px 15px; }
  .step-num { width: 38px; height: 38px; font-size: 16px; }
  .telegram-hint { grid-template-columns: 1fr; gap: 8px; }
  .telegram-hint .tg-dot { display: none; }
  .dl-link { padding: 13px 14px; }
  .dl-label { font-size: 15.5px; }
}

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

@media (prefers-contrast: more) {
  :root { --muted: #3d565f; --line: #9dbdb2; }
  .dl-link, select#os-select { border-color: var(--ink); }
}
