:root {
  --bg: #fbfcfa;
  --bg-tint: #f1f6ee;
  --surface: #ffffff;
  --text: #1c2419;
  --muted: #5b6757;
  --line: #dfe6db;
  --accent: #3f9a2a;
  --accent-strong: #2f7d1f;
  --accent-soft: #e5f3de;
  --on-accent: #ffffff;
  --danger: #b3261e;
  --shadow: 0 1px 2px rgb(20 40 10 / .06), 0 12px 40px rgb(20 40 10 / .10);

  /* окно программы в стиле Windows */
  --win-bg: #f0f0f0;
  --win-surface: #ffffff;
  --win-line: #d6d6d6;
  --win-text: #1b1b1b;
  --win-muted: #6d6d6d;
  --win-sel: #cce8ff;
  --win-bar: #06b025;
  --win-bar-done: #3aa0e8;

  --radius: 14px;
  --font: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "Cascadia Mono", Consolas, ui-monospace, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #11150f;
    --bg-tint: #161c13;
    --surface: #1a2117;
    --text: #e6ece2;
    --muted: #9aa894;
    --line: #2a3426;
    --accent: #5cbd44;
    --accent-strong: #74cf5c;
    --accent-soft: #1f3019;
    --on-accent: #0c1409;
    --danger: #ff8a80;
    --shadow: 0 1px 2px rgb(0 0 0 / .4), 0 16px 48px rgb(0 0 0 / .45);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; }
a { color: var(--accent-strong); }
code { font: .9em var(--mono); background: var(--accent-soft); padding: .1em .35em; border-radius: 5px; overflow-wrap: anywhere; }
h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -.01em; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.2rem); }

.wrap { max-width: 1140px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 32px; } }

/* Шапка */
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner { display: flex; align-items: center; justify-content: space-between; height: 60px; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.15rem; color: var(--text); text-decoration: none; }
.brand--small { font-size: 1rem; gap: 8px; }
.nav { display: flex; gap: 4px; }
.nav a { color: var(--muted); text-decoration: none; padding: 6px 10px; border-radius: 8px; font-size: .95rem; }
.nav a:hover { color: var(--text); background: var(--accent-soft); }
@media (max-width: 420px) { .nav { gap: 0; } .nav a { padding: 6px 6px; font-size: .88rem; } .brand__name { display: none; } }

/* Кнопки */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 22px; border-radius: 10px;
  font-weight: 600; text-decoration: none;
  transition: background .15s, transform .15s;
}
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.btn--primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 4px 14px color-mix(in srgb, var(--accent) 35%, transparent); }
.btn--primary:hover { background: var(--accent-strong); transform: translateY(-1px); }
.btn--big { padding: 15px 26px; font-size: 1.08rem; }

/* Первый экран */
.hero { padding: 56px 0 72px; background: radial-gradient(1000px 420px at 85% 0%, var(--accent-soft), transparent 70%); }
.hero__inner { display: grid; gap: 48px; align-items: center; }
@media (min-width: 980px) { .hero__inner { grid-template-columns: 1fr 1.15fr; } .hero { padding: 88px 0 104px; } }
.eyebrow { margin: 0 0 14px; color: var(--accent-strong); font-weight: 600; font-size: .9rem; letter-spacing: .02em; }
.hero h1 { font-size: clamp(2.1rem, 5vw, 3.3rem); font-weight: 750; }
.lead { font-size: 1.15rem; color: var(--muted); margin: 20px 0 30px; max-width: 34em; }
.hero__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.hero__meta { color: var(--muted); font-size: .92rem; }

/* Окно программы */
.app {
  --fs: 12px;
  font: var(--fs)/1.35 "Segoe UI", system-ui, sans-serif;
  color: var(--win-text);
  background: var(--win-bg);
  border: 1px solid #9aa39a;
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
  min-width: 0;
  transform: perspective(1600px) rotateY(-4deg);
  transform-origin: left center;
}
@media (max-width: 979px) { .app { transform: none; } }
@media (max-width: 560px) { .app { --fs: 10px; } .app .row > :nth-child(2) { display: none; } .app .row { grid-template-columns: 1fr 74px 62px !important; } .app__side { display: none; } .app .app__body { grid-template-columns: 1fr; } .app__search { display: none; } }
.app__title { display: flex; align-items: center; gap: 8px; height: 30px; padding: 0 0 0 10px; background: var(--win-surface); }
.app__title span:first-of-type { flex: 1; }
.app__ctl { display: flex; height: 100%; }
.app__ctl i { width: 40px; position: relative; }
.app__ctl i::before { content: ""; position: absolute; inset: 50% auto auto 50%; width: 9px; transform: translate(-50%, -50%); border-top: 1px solid #333; }
.app__ctl i:nth-child(2)::before { height: 9px; border: 1px solid #333; }
.app__ctl i:nth-child(3)::before { width: 11px; border: 0; height: 1px; background: #333; transform: translate(-50%, -50%) rotate(45deg); box-shadow: 0 0 0 0 #333; }
.app__ctl i:nth-child(3)::after { content: ""; position: absolute; inset: 50% auto auto 50%; width: 11px; height: 1px; background: #333; transform: translate(-50%, -50%) rotate(-45deg); }
.app__menu { display: flex; gap: 14px; padding: 3px 10px; background: var(--win-surface); border-bottom: 1px solid var(--win-line); }
.app__tools { display: flex; align-items: center; gap: 4px; padding: 5px 8px; border-bottom: 1px solid var(--win-line); }
.app__tools b { width: 22px; height: 22px; border-radius: 4px; position: relative; }
.app__tools b::before { content: ""; position: absolute; inset: 5px; border-radius: 2px; }
.t-add::before { background: #4caf50; clip-path: polygon(40% 0, 60% 0, 60% 40%, 100% 40%, 100% 60%, 60% 60%, 60% 100%, 40% 100%, 40% 60%, 0 60%, 0 40%, 40% 40%); }
.t-link::before { border: 2px solid #3a7bd5; border-radius: 50% !important; }
.t-new::before { background: #f3c24b; clip-path: polygon(0 0, 70% 0, 100% 30%, 100% 100%, 0 100%); }
.t-del::before { background: #d9453b; clip-path: polygon(15% 0, 50% 35%, 85% 0, 100% 15%, 65% 50%, 100% 85%, 85% 100%, 50% 65%, 15% 100%, 0 85%, 35% 50%, 0 15%); }
.t-play::before { background: #2e9d3a; clip-path: polygon(15% 0, 100% 50%, 15% 100%); }
.t-pause::before { background: linear-gradient(90deg, #555 0 35%, transparent 35% 65%, #555 65%); }
.t-stop::before { background: #555; }
.t-up::before { background: #3a7bd5; clip-path: polygon(50% 0, 100% 60%, 0 60%); }
.t-down::before { background: #3a7bd5; clip-path: polygon(0 40%, 100% 40%, 50% 100%); }
.app__tools .sep { width: 1px; height: 18px; background: var(--win-line); margin: 0 4px; }
.app__search { margin-left: auto; padding: 2px 8px; min-width: 110px; background: var(--win-surface); border: 1px solid var(--win-line); color: var(--win-muted); }
.app__body { display: grid; grid-template-columns: 138px 1fr; background: var(--win-surface); }
.app__side { list-style: none; margin: 0; padding: 4px 0; border-right: 1px solid var(--win-line); }
.app__side li { padding: 2px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.app__side .grp { font-weight: 600; margin-top: 4px; }
.app__side .sub { padding-left: 20px; }
.app__side .on { background: var(--win-sel); }
.app__list { min-width: 0; }
.row { display: grid; grid-template-columns: 1fr 58px 86px 70px; gap: 8px; padding: 3px 8px; align-items: center; white-space: nowrap; }
.row > * { overflow: hidden; text-overflow: ellipsis; }
.row > :nth-child(n+2) { text-align: right; }
.row.head { color: var(--win-muted); border-bottom: 1px solid var(--win-line); background: var(--win-bg); }
.row.sel { background: var(--win-sel); }
.row:nth-child(odd):not(.head):not(.sel) { background: #f7f9fb; }
.row em {
  display: block; font-style: normal; text-align: center; font-size: .92em;
  border: 1px solid #bcbcbc; height: 1.45em; line-height: 1.35em;
  background: linear-gradient(90deg, var(--win-bar) var(--p), #e6e6e6 var(--p));
  color: #0b240e;
}
.row em.done { background: linear-gradient(90deg, var(--win-bar-done) var(--p), #e6e6e6 var(--p)); color: #06243a; }
.app__tabs { display: flex; gap: 2px; padding: 4px 6px 0; border-top: 1px solid var(--win-line); overflow: hidden; white-space: nowrap; }
.app__tabs span { padding: 3px 9px; border: 1px solid transparent; border-bottom: 0; color: var(--win-muted); }
.app__tabs .on { background: var(--win-surface); border-color: var(--win-line); color: var(--win-text); }
.app__graph { height: 64px; margin: 0 6px; padding: 6px; background: var(--win-surface); border: 1px solid var(--win-line); }
.app__graph svg { width: 100%; height: 100%; }
.app__graph polyline { fill: none; stroke-width: 1.6; vector-effect: non-scaling-stroke; }
.g-down { stroke: #2e9d3a; }
.g-up { stroke: #d9453b; }
.app__status { display: flex; gap: 18px; justify-content: flex-end; padding: 4px 10px; margin-top: 6px; border-top: 1px solid var(--win-line); color: var(--win-muted); }

/* Разделы */
.section { padding: 80px 0; }
.section--tint { background: var(--bg-tint); border-block: 1px solid var(--line); }
.section__lead { color: var(--muted); font-size: 1.08rem; margin: 12px 0 40px; max-width: 40em; }

.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card h3 { font-size: 1.12rem; margin: 16px 0 8px; }
.card p { margin: 0; color: var(--muted); }
.card__icon { width: 44px; height: 44px; border-radius: 11px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-strong); }
.card__icon svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.card--accent { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); background: linear-gradient(160deg, var(--accent-soft), var(--surface) 60%); }

/* Скачать */
.download { display: grid; gap: 40px; }
@media (min-width: 900px) { .download { grid-template-columns: 1.3fr 1fr; align-items: center; } }
.download .section__lead { margin-bottom: 28px; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px 24px; margin: 32px 0 16px; }
.facts dt { color: var(--muted); font-size: .85rem; }
.facts dd { margin: 0; font-weight: 600; }
.hash { color: var(--muted); font-size: .85rem; margin: 0; }
.hash code { background: none; padding: 0; }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.checks li { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px 18px 52px; position: relative; color: var(--muted); }
.checks li b { color: var(--text); font-weight: 600; }
.checks li::before {
  content: ""; position: absolute; left: 18px; top: 21px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E") center / 14px no-repeat;
}

/* Вопросы */
.faq { max-width: 820px; }
#features h2, .faq h2 { margin-bottom: 28px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 18px 36px 18px 0; font-weight: 600; font-size: 1.05rem; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 1.5rem; font-weight: 400; color: var(--accent-strong); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { margin: 0 0 20px; color: var(--muted); }

/* Подвал */
.footer { border-top: 1px solid var(--line); padding: 28px 0 36px; color: var(--muted); font-size: .9rem; }
.footer__inner { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; justify-content: space-between; }
.footer .brand { color: var(--text); }
.footer__legal { flex-basis: 100%; font-size: .8rem; }

/* Страница 404 */
.notfound { padding: 96px 0 120px; min-height: 60vh; background: radial-gradient(900px 380px at 85% 0%, var(--accent-soft), transparent 70%); }
.notfound h1 { font-size: clamp(2rem, 5vw, 3rem); font-weight: 750; }

/* Обратная связь */
.feedback { display: grid; gap: 32px; }
@media (min-width: 900px) { .feedback { grid-template-columns: 1fr 1.3fr; align-items: start; } }
.feedback__intro .section__lead { margin-bottom: 0; }
.feedback__form { display: grid; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.feedback__kind { border: 0; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.feedback__kind legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.feedback__kind label { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.feedback__kind input { accent-color: var(--accent); width: 18px; height: 18px; margin: 0; }
.feedback__field { display: grid; gap: 6px; font-weight: 600; }
.feedback__field small { font-weight: 400; color: var(--muted); }
.feedback__field textarea, .feedback__field input {
  font: inherit; font-weight: 400; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; width: 100%; resize: vertical;
}
.feedback__field textarea:focus, .feedback__field input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.feedback__field--short input { max-width: 220px; }
.feedback__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.feedback__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.feedback__actions .btn { border: 0; cursor: pointer; font: inherit; font-weight: 600; }
.feedback__actions .btn:disabled { opacity: .6; cursor: progress; transform: none; }
.feedback__status { margin: 0; color: var(--muted); }
.feedback__status[data-kind="ok"] { color: var(--accent-strong); font-weight: 600; }
.feedback__status[data-kind="error"] { color: var(--danger); }

/* Подвал: ссылка справа от названия */
.footer__link { color: var(--muted); }
.footer__link:hover { color: var(--accent-strong); }

/* Ссылка «Что нового» в разделе «Скачать» */
.download__notes { margin: 14px 0 0; }
.download__notes a { font-weight: 600; text-decoration: none; }
.download__notes a:hover { text-decoration: underline; }

/* Страница «Что нового» */
.releases { padding: 64px 0 96px; }
.releases__wrap { max-width: 820px; }
.releases h1 { font-size: clamp(2rem, 5vw, 2.8rem); font-weight: 750; }
.releases .section__lead { margin-bottom: 28px; }
.releases__download {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px;
  background: var(--accent-soft); border-radius: var(--radius); padding: 18px 22px; margin-bottom: 40px;
}
.releases__download > div span { display: block; color: var(--muted); font-size: .92rem; }
.release { padding: 28px 0; border-top: 1px solid var(--line); }
.release__head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin-bottom: 10px; }
.release__head h2 { font-size: 1.4rem; }
.release__head time { color: var(--muted); }
.release__current { background: var(--accent); color: var(--on-accent); font-size: .78rem; font-weight: 600; padding: 2px 10px; border-radius: 999px; }
.release p, .release ul { margin: 10px 0 0; }
.release ul { padding-left: 1.3em; }
.release li { margin: 4px 0; }
.release li::marker { color: var(--accent); }
.release__none, .releases__empty { color: var(--muted); }

