:root {
  color-scheme: light dark;
  --bg: #ffffff;
  --fg: #1a1d23;
  --muted: #5b6270;
  --line: #e2e5ea;
  --accent: #2f6f4f;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1115;
    --fg: #e7e9ee;
    --muted: #9aa1ad;
    --line: #262a33;
    --accent: #7fc4a0;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 32px 20px 80px;
  background: var(--bg);
  color: var(--fg);
  font:
    17px/1.6 -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    sans-serif;
}

main {
  max-width: 720px;
  margin: 0 auto;
}

h1 {
  font-size: 28px;
  line-height: 1.25;
  margin: 0 0 8px;
}

h2 {
  font-size: 20px;
  margin: 40px 0 12px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

p,
li {
  margin: 0 0 12px;
}

ul {
  padding-left: 22px;
}

a {
  color: var(--accent);
}

.date {
  color: var(--muted);
  font-size: 15px;
  margin-bottom: 32px;
}

.footer {
  margin-top: 48px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 15px;
}

/* Главная страница сайта. Классы используются только в index.html. */

.hero {
  text-align: center;
  padding: 24px 0 8px;
}

.hero img {
  width: 96px;
  height: 96px;
  border-radius: 22px;
}

.hero h1 {
  margin: 20px 0 12px;
}

.lead {
  font-size: 19px;
  color: var(--muted);
  margin: 0 auto 28px;
  max-width: 520px;
}

.badges {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.badge {
  display: inline-block;
  padding: 14px 28px;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--muted);
  font-size: 17px;
}

/* Кнопка магазина: та же плашка, но живая ссылка. */
.badge-store {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.note {
  color: var(--muted);
  font-size: 15px;
  margin-top: 14px;
}

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

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 44px;
  margin-bottom: 20px;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -1px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--bg);
  font-size: 16px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Лента скриншотов листается вбок, как в карточке магазина. align-items:
   start и height: auto не дают flex растянуть картинки по высоте (Safari
   считал высоту ряда по исходному размеру файла). */
.shots {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 12px;
}

.shots img {
  flex: 0 0 auto;
  width: 180px;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  scroll-snap-align: start;
}

@media (max-width: 560px) {
  .shots img {
    width: 42%;
  }
}

.warn {
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  padding: 20px 20px 8px;
}

.warn p:first-child {
  margin-top: 0;
}

@media (max-width: 560px) {
  .badge {
    width: 100%;
  }
}
