/* Сайт программы на главном домене: страница о программе, регистрация и
   вход (templates/site). Цвета, шрифт и поля ввода — из app.css; здесь
   только раскладка сайта. Оформление — светлое или темное (как в системе
   или по кнопке в шапке, site.js), классического здесь нет. */

.site { min-height: 100vh; display: flex; flex-direction: column; }
.site main { flex: 1; }
.site-wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: var(--card); padding: 8px 12px; border-radius: var(--r); }
.skip:focus { left: 8px; }

/* Шапка */
.site-top { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 84%, transparent); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); }
.site-top .site-wrap { display: flex; align-items: center; gap: 28px; height: 64px; }
.site-brand { display: flex; align-items: center; gap: 10px; font-weight: 750; font-size: 19px; letter-spacing: -.02em; color: var(--strong); }
.site-brand:hover { text-decoration: none; }
.site-brand::before { content: ""; width: 26px; height: 26px; flex: none;
  background: url(/static/icons/icon.svg) center / contain no-repeat; border-radius: 0; }
.site-nav { display: flex; gap: 2px; }
.site-nav a { color: var(--muted); padding: 7px 12px; border-radius: var(--r); font-weight: 500; font-size: 14.5px; }
.site-nav a:hover { background: var(--hover); color: var(--strong); text-decoration: none; }
.site-actions { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.site-actions .button { padding: 7px 16px; }
.theme-btn { width: 38px; height: 38px; padding: 0; display: grid; place-items: center; color: var(--muted); }
.theme-btn svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.theme-btn .i-moon { display: none; }
:root[data-theme="dark"] .theme-btn .i-sun { display: none; }
:root[data-theme="dark"] .theme-btn .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .theme-btn .i-sun { display: none; }
  :root:not([data-theme]) .theme-btn .i-moon { display: block; }
}

.btn-lg { padding: 12px 22px; font-size: 15.5px; border-radius: 10px; }
.button.wide, button.wide { width: 100%; text-align: center; padding: 11px 16px; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: 12.5px; font-weight: 650; color: var(--accent-text); margin: 0 0 14px; }

/* Первый экран */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 44px 44px; opacity: .45;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 70% 30%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 80% 70% at 70% 30%, #000 20%, transparent 75%); }
.hero::after { content: ""; position: absolute; inset: -20% -10% auto auto; width: 70%; height: 90%; pointer-events: none;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 16%, transparent), transparent); }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); gap: 56px; align-items: center; padding: 84px 24px 96px; }
.hero h1 { font-size: clamp(48px, 7vw, 76px); line-height: 1; letter-spacing: -.045em; margin: 0 0 20px; }
.lead { font-size: 18.5px; line-height: 1.6; color: var(--muted); margin: 0 0 30px; max-width: 34em; }
.cta { display: flex; gap: 12px; flex-wrap: wrap; }
.cta.center { justify-content: center; }
.chips-cap { margin: 30px 0 10px; font-size: 13.5px; color: var(--muted); }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip-l { border: 1px solid var(--line-strong); border-radius: 16px; padding: 6px 14px; font-size: 13.5px; color: var(--muted); background: var(--card); }
.chip-l b { color: var(--strong); font-weight: 600; }

/* Окно программы (пример) */
.win { background: var(--card); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-pop); overflow: hidden; }
.win-bar { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); background: var(--raised); }
.win-dots { display: flex; gap: 6px; }
.win-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-strong); }
.win-url { flex: 1; min-width: 0; font: 12.5px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--muted);
  background: var(--card); border: 1px solid var(--line); border-radius: 7px; padding: 3px 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.win-tag { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--subtle); font-weight: 650; }
.win-app { display: grid; grid-template-columns: 128px minmax(0, 1fr); }
.win-side { display: flex; flex-direction: column; gap: 2px; padding: 14px 10px; border-right: 1px solid var(--line); background: var(--raised); font-size: 12.5px; }
.win-side span { padding: 5px 8px; border-radius: 6px; color: var(--muted); }
.win-side span.on { background: var(--accent-soft); color: var(--accent-text); font-weight: 600; }
.win-brand { display: flex; align-items: center; gap: 7px; color: var(--strong); font-size: 14px; margin: 0 0 10px 6px; }
.win-brand::before { content: ""; width: 16px; height: 16px; background: url(/static/icons/icon.svg) center / contain no-repeat; border-radius: 0; }
.win-body { padding: 18px 20px 20px; min-width: 0; }
.win-h { display: flex; flex-direction: column; margin-bottom: 12px; }
.win-h b { font-size: 17px; color: var(--strong); letter-spacing: -.01em; }
.win-h span { font-size: 12px; color: var(--muted); }
.mkpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.mkpi { border: 1px solid var(--line); border-radius: 10px; padding: 9px 11px; background: var(--raised); min-width: 0; }
.mkpi span { display: block; font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mkpi b { display: block; font-size: 19px; color: var(--strong); letter-spacing: -.02em; font-variant-numeric: tabular-nums; white-space: nowrap; margin: 1px 0; }
.mkpi em { display: block; font-style: normal; font-size: 11px; color: var(--subtle); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mkpi em.up { color: var(--ok-fg); }
.mkpi em.late { color: var(--warn); }
.bars { display: flex; align-items: flex-end; gap: 6px; height: 48px; margin: 14px 0 4px; padding: 0 2px; border-bottom: 1px solid var(--line); }
.bars span { flex: 1; border-radius: 4px 4px 0 0; background: color-mix(in srgb, var(--accent) 22%, var(--chip)); }
.bars span.on { background: var(--accent); }
.bars .b1 { height: 38%; } .bars .b2 { height: 46%; } .bars .b3 { height: 41%; } .bars .b4 { height: 55%; }
.bars .b5 { height: 49%; } .bars .b6 { height: 62%; } .bars .b7 { height: 58%; } .bars .b8 { height: 70%; }
.bars .b9 { height: 66%; } .bars .b10 { height: 78%; } .bars .b11 { height: 84%; } .bars .b12 { height: 96%; }
.win-sub { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 650; color: var(--subtle); margin: 14px 0 6px; }
.rows { display: flex; flex-direction: column; gap: 6px; }
.row { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto 76px; gap: 10px; align-items: center;
  border: 1px solid var(--line); border-radius: 9px; padding: 7px 10px; font-size: 12.5px; }
.row .d { color: var(--muted); font-variant-numeric: tabular-nums; }
.row .t { color: var(--strong); font-weight: 600; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .t small { display: block; font-weight: 400; color: var(--muted); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; }
.row .s { font-size: 10.5px; font-weight: 650; padding: 1px 8px; border-radius: 999px; background: var(--warn-bg); color: var(--warn); white-space: nowrap; }
.row .s.ok { background: var(--ok-bg); color: var(--ok-fg); }
.row b { text-align: right; color: var(--strong); font-variant-numeric: tabular-nums; }

/* Разделы страницы */
.sec { padding: 88px 0; border-bottom: 1px solid var(--line); scroll-margin-top: 64px; }
.sec h2, .cta-band h2 { font-size: clamp(30px, 4.2vw, 44px); line-height: 1.08; letter-spacing: -.035em; margin: 0 0 16px; color: var(--strong); }
.intro { font-size: 17px; line-height: 1.65; color: var(--muted); max-width: 44em; margin: 0 0 40px; }
.feat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.feat { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px; box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, transform .15s ease; }
.feat:hover { border-color: var(--line-strong); transform: translateY(-1px); }
.feat h3 { font-size: 16.5px; letter-spacing: -.01em; color: var(--strong); margin: 14px 0 6px; }
.feat p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.6; }
.ico { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-text); }
.ico svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .9fr); gap: 56px; align-items: center; }
.split .intro { margin-bottom: 22px; }
.ticks { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.ticks li { position: relative; padding-left: 30px; color: var(--fg); }
.ticks li::before { content: ""; position: absolute; left: 0; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--accent-soft); }
.ticks li::after { content: ""; position: absolute; left: 6px; top: 7px; width: 5px; height: 8px; border: solid var(--accent-text); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.login-mock { display: flex; flex-direction: column; padding: 34px 40px 38px; max-width: 360px; margin: 0 auto; }
.lm-brand { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--strong); margin-bottom: 18px; }
.lm-brand::before { content: ""; width: 20px; height: 20px; background: url(/static/icons/icon.svg) center / contain no-repeat; border-radius: 0; }
.login-mock > b { font-size: 22px; color: var(--strong); letter-spacing: -.02em; }
.lm-org { color: var(--muted); font-size: 13.5px; margin-bottom: 14px; }
.lm-label { font-size: 12.5px; color: var(--muted); margin: 8px 0 4px; }
.lm-input { border: 1px solid var(--line-strong); border-radius: var(--r); padding: 7px 10px; font-size: 14px; color: var(--fg); background: var(--card); }
.lm-btn { margin-top: 18px; border-radius: var(--r); padding: 9px; text-align: center; font-weight: 600; background: var(--primary-bg); color: var(--primary-fg); border: 1px solid var(--primary-line); }

.steps { list-style: none; padding: 0; margin: 8px 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; counter-reset: step; }
.steps li { counter-increment: step; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px; display: flex; flex-direction: column; gap: 6px; }
.steps li::before { content: counter(step); width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 8px;
  background: var(--accent); color: var(--accent-fg); font-weight: 700; font-size: 14px; }
.steps b { color: var(--strong); font-size: 16px; }
.steps span { color: var(--muted); font-size: 14.5px; line-height: 1.55; }

.faq { border-top: 1px solid var(--line); max-width: 900px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 20px 40px 20px 0; position: relative; font-weight: 600; font-size: 17px; color: var(--strong); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 22px; font-weight: 400; color: var(--muted); transition: transform .15s ease; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { margin: 0 0 20px; color: var(--muted); line-height: 1.65; max-width: 46em; }

.cta-band { padding: 88px 0; text-align: center; position: relative; overflow: hidden; }
.cta-band::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 50% 80% at 50% 100%, color-mix(in srgb, var(--accent) 14%, transparent), transparent); }
.cta-band .site-wrap { position: relative; }
.cta-band p { color: var(--muted); font-size: 17px; margin: 0 0 26px; }

.site-foot { border-top: 1px solid var(--line); padding: 26px 0; color: var(--muted); font-size: 14px; }
.site-foot .site-wrap { display: flex; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; }
.site-foot b { color: var(--strong); }
.site-foot .links { display: flex; gap: 20px; }

/* Регистрация и вход */
.auth-page { display: grid; place-items: center; padding: 56px 16px 72px; position: relative; }
.auth-page::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 50% 60% at 50% 0%, color-mix(in srgb, var(--accent) 10%, transparent), transparent); }
.auth-card { position: relative; width: 100%; max-width: 440px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 30px; box-shadow: var(--shadow-pop); }
.auth-card.wide { max-width: 560px; }
.auth-card h2, .signin-dialog h2 { font-size: 24px; letter-spacing: -.025em; margin: 0 0 6px; color: var(--strong); }
.auth-card .sub, .signin-dialog .sub { color: var(--muted); margin: 0 0 20px; line-height: 1.55; }
.auth-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.site-form { display: flex; flex-direction: column; gap: 14px; }
.site-form .error { margin: 0; }
.site-form label .hint { display: block; font-weight: 400; color: var(--subtle); font-size: 12.5px; margin-top: 5px; }
.site-form .pair { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.site-form .fine { font-size: 13px; color: var(--muted); margin: 2px 0 0; line-height: 1.55; }
.slug-field { display: flex; align-items: stretch; margin-top: 4px; }
.slug-field input { margin-top: 0; border-radius: var(--r) 0 0 var(--r); min-width: 0; }
.slug-field .suffix { display: flex; align-items: center; border: 1px solid var(--line-strong); border-left: 0; border-radius: 0 var(--r) var(--r) 0;
  padding: 0 11px; background: var(--raised); color: var(--muted); font-size: 14px; white-space: nowrap; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.site-form .notice { margin: 0; }
.site-note { margin: 0; padding: 10px 14px; border-radius: var(--r); font-size: 14px; line-height: 1.5; color: var(--fg);
  background: color-mix(in srgb, var(--accent) 7%, var(--card)); border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent); }
.site-form input.code { font-size: 22px; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.site-form.resend { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }

.signin-dialog { border: 1px solid var(--line); border-radius: 16px; padding: 30px; width: min(440px, calc(100vw - 32px));
  background: var(--card); color: var(--fg); box-shadow: var(--shadow-pop); }
.signin-dialog::backdrop { background: rgb(5 7 15 / .45); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.signin-dialog .x { position: absolute; right: 12px; top: 10px; width: 34px; height: 34px; padding: 0; border: 0; box-shadow: none;
  background: transparent; font-size: 22px; font-weight: 400; color: var(--muted); }
.signin-dialog .x:hover { background: var(--hover); }

@media (max-width: 960px) {
  .hero-grid, .split { grid-template-columns: minmax(0, 1fr); gap: 44px; }
  .hero-grid { padding: 56px 24px 64px; }
  .feat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-nav { display: none; }
}
@media (max-width: 640px) {
  .site-wrap, .hero-grid { padding-left: 16px; padding-right: 16px; }
  .site-top .site-wrap { gap: 12px; }
  .hide-sm { display: none; }
  .hero h1 { font-size: 48px; }
  .lead { font-size: 17px; }
  .win-app { grid-template-columns: minmax(0, 1fr); }
  .win-side { display: none; }
  .mkpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .row { grid-template-columns: minmax(0, 1fr) auto; }
  .row .d, .row .s { display: none; }
  .feat-grid, .steps { grid-template-columns: minmax(0, 1fr); }
  .sec, .cta-band { padding: 64px 0; }
  .site-form .pair { grid-template-columns: minmax(0, 1fr); }
  .auth-card { padding: 24px 20px; }
}

/* Кабинет владельца программы (/owner) */
.owner { padding: 36px 0 72px; }
.owner h1 { font-size: 30px; letter-spacing: -.03em; margin: 0 0 6px; }
.owner h2 { font-size: 20px; margin: 28px 0 12px; }
.owner-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; flex-wrap: wrap; margin-bottom: 20px; }
.owner-user { display: flex; gap: 12px; align-items: center; }
.owner .card { padding: 14px 16px; }
.owner table { width: 100%; }
.owner .inline { display: inline-block; margin-right: 6px; }
.owner button.small { padding: 4px 10px; font-size: 13px; }
.owner .nowrap { white-space: nowrap; }
.owner form.card .grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px 16px; }
.owner form.card label { display: block; }
.owner .kpis { margin-bottom: 8px; }

/* Страницы о программе: тарифы, сравнение, возможности, вопросы, контакты, документы */
.site-nav a[aria-current="page"] { color: var(--strong); background: var(--hover); }
.page-head { padding: 72px 0 40px; border-bottom: 1px solid var(--line); position: relative; overflow: hidden; }
.page-head::after { content: ""; position: absolute; inset: auto -10% -60% auto; width: 60%; height: 160%; pointer-events: none;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 12%, transparent), transparent); }
.page-head .site-wrap { position: relative; }
.page-head h1 { font-size: clamp(34px, 5vw, 56px); line-height: 1.05; letter-spacing: -.04em; margin: 0 0 18px; color: var(--strong); max-width: 20em; }
.page-head .lead { margin-bottom: 0; max-width: 46em; }
.toc { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; }
.toc a { border: 1px solid var(--line-strong); border-radius: 16px; padding: 6px 14px; font-size: 13.5px; color: var(--muted); background: var(--card); }
.toc a:hover { color: var(--strong); border-color: var(--accent); text-decoration: none; }
.foot-cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 28px; padding-bottom: 22px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.foot-about { line-height: 1.6; max-width: 34em; }
.foot-links { display: flex; flex-direction: column; gap: 8px; }
.foot-links b { color: var(--strong); margin-bottom: 4px; }
.foot-links a { color: var(--muted); }
.foot-links a:hover { color: var(--strong); }
.foot-line { display: flex; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; font-size: 13px; color: var(--subtle); }

/* Тарифы */
.plans-sec { padding-top: 56px; }
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; align-items: stretch; }
.plan { position: relative; display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 28px 26px; box-shadow: var(--shadow-sm); }
.plan.featured { border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 14%, transparent), var(--shadow-pop); }
.plan-badge { position: absolute; top: -13px; left: 24px; background: var(--accent); color: var(--accent-fg); font-size: 12px; font-weight: 650; letter-spacing: .04em; padding: 4px 12px; border-radius: 999px; }
.plan h2 { font-size: 24px; letter-spacing: -.02em; margin: 0 0 8px; color: var(--strong); }
.plan-blurb { color: var(--muted); font-size: 14.5px; line-height: 1.55; margin: 0 0 20px; min-height: 3.1em; }
.plan-price { display: flex; align-items: baseline; gap: 10px; }
.plan-price b { font-size: 34px; letter-spacing: -.03em; color: var(--strong); font-variant-numeric: tabular-nums; }
.plan-price span { color: var(--muted); font-size: 14px; }
.plan-price.alt { margin-top: 2px; }
.plan-price.alt b { font-size: 18px; color: var(--muted); font-weight: 600; }
.plan-limits { list-style: none; padding: 0; margin: 22px 0 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.plan-limits li { position: relative; padding-left: 26px; font-size: 14.5px; color: var(--fg); line-height: 1.45; }
.plan-limits li::before { content: ""; position: absolute; left: 0; top: 4px; width: 16px; height: 16px; border-radius: 50%; background: var(--accent-soft); }
.plan-limits li::after { content: ""; position: absolute; left: 5.5px; top: 7px; width: 4px; height: 7px; border: solid var(--accent-text); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.plan-limits b { color: var(--strong); }
/* Переключатель «За год / Помесячно» без сценария: радиокнопки скрыты,
   подписи работают как вкладки, видимая цена зависит от выбранной. */
.terms { position: relative; }
.term-radio { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.term-switch { display: inline-flex; gap: 4px; margin: 0 auto 28px; padding: 4px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; box-shadow: var(--shadow-sm); }
.terms { display: flex; flex-direction: column; align-items: center; }
.terms .plans, .terms .plans-note { width: 100%; }
.term-switch label { display: inline-flex; align-items: center; gap: 8px; padding: 9px 18px; border-radius: 999px; font-weight: 600; font-size: 14.5px; color: var(--muted); cursor: pointer; user-select: none; }
.term-switch label:hover { color: var(--strong); }
.term-save { font-size: 12px; font-weight: 650; padding: 2px 8px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-text); }
#term-year:checked ~ .term-switch label[for="term-year"], #term-month:checked ~ .term-switch label[for="term-month"] { background: var(--accent); color: var(--accent-fg); }
#term-year:checked ~ .term-switch label[for="term-year"] .term-save { background: rgba(255, 255, 255, .22); color: inherit; }
.term-radio:focus-visible ~ .term-switch { outline: 2px solid var(--accent); outline-offset: 2px; }
#term-year:checked ~ .plans .price-month, #term-month:checked ~ .plans .price-year { display: none; }
.plan-save { margin: 8px 0 0; font-size: 13px; color: var(--accent-text); line-height: 1.45; }
.price-month .plan-save { color: var(--muted); }
.plans-note { margin: 26px auto 0; max-width: 60em; text-align: center; color: var(--muted); font-size: 14px; line-height: 1.6; }
.matrix { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.matrix th, .matrix td { padding: 12px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.matrix thead th { color: var(--muted); font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
.matrix thead th:not(:first-child), .matrix td.c { text-align: center; width: 120px; }
.matrix .yes { color: var(--ok-fg); font-weight: 700; }
.matrix .no { color: var(--subtle); }

/* Сравнение с 1С */
.diff-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.diff { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px; }
.diff h3 { font-size: 16.5px; margin: 0 0 8px; color: var(--strong); letter-spacing: -.01em; }
.diff p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.6; }
.cmp { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.cmp th, .cmp td { padding: 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; line-height: 1.55; }
.cmp thead th { color: var(--muted); font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; }
.cmp td:first-child { font-weight: 600; color: var(--strong); white-space: nowrap; }
.cmp td:nth-child(2) { color: var(--fg); }
.cmp td:nth-child(3) { color: var(--muted); }
.ticks.plain li { color: var(--muted); }
.steps.vertical { grid-template-columns: minmax(0, 1fr); gap: 10px; }
.steps.vertical li { flex-direction: row; align-items: flex-start; gap: 14px; padding: 16px 18px; }
.steps.vertical li::before { margin: 0; flex: none; }
.steps.vertical b { display: block; margin-bottom: 2px; }

/* Возможности: снимки экрана */
.feature-sec .intro { margin-bottom: 24px; }
.shot { margin: 0; }
.shot a { display: block; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--card); box-shadow: var(--shadow-sm);
  transition: transform .15s ease, border-color .15s ease; }
.shot a:hover { transform: translateY(-2px); border-color: var(--line-strong); }
.shot img { display: block; width: 100%; height: auto; }
.shot figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); text-align: center; }
.shot.wide { margin-top: 18px; }
.shot.wide a { aspect-ratio: 14 / 7; }
.shot.wide img { object-fit: cover; object-position: top; height: 100%; }
.shots-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.shots-2.narrow { gap: 14px; }
.shots-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-bottom: 8px; }
.shots-3 .shot a, .shots-2 .shot a { aspect-ratio: 14 / 9; }
.shots-3 .shot img, .shots-2 .shot img { object-fit: cover; object-position: top; height: 100%; }
.shots-phone { display: grid; grid-template-columns: 1.3fr .7fr; gap: 18px; align-items: start; }
.shot.tall a { max-width: 260px; margin: 0 auto; aspect-ratio: 9 / 18; }
.shot.tall img { object-fit: cover; object-position: top; height: 100%; }
.shot-dialog { border: 0; border-radius: 14px; padding: 0; background: var(--card); color: var(--fg); box-shadow: var(--shadow-pop);
  width: min(1280px, calc(100vw - 32px)); max-height: calc(100vh - 32px); }
.shot-dialog::backdrop { background: rgb(5 7 15 / .7); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.shot-dialog img { display: block; width: 100%; height: auto; max-height: calc(100vh - 100px); object-fit: contain; background: var(--raised); }
.shot-dialog .shot-cap { margin: 0; padding: 12px 18px; font-size: 14px; color: var(--muted); text-align: center; }
.shot-dialog .x { position: absolute; right: 10px; top: 8px; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 50%;
  background: rgb(5 7 15 / .55); color: #fff; font-size: 22px; font-weight: 400; z-index: 1; }

/* Вопросы и ответы */
.faq-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 48px; }
.faq-cols h2 { font-size: 22px; letter-spacing: -.02em; margin: 28px 0 6px; }
.faq-cols h2:first-child { margin-top: 0; }
.faq-cols .faq { max-width: none; }
.faq-cols .faq summary { font-size: 16px; padding: 16px 36px 16px 0; }

/* Контакты и документы */
.contacts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.contact-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.contact-card { display: flex; flex-direction: column; gap: 4px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 20px; color: var(--muted); }
.contact-card:hover { text-decoration: none; border-color: var(--accent); }
.contact-card .ico { margin-bottom: 10px; }
.contact-card b { color: var(--strong); font-size: 16px; }
.contact-card span { font-size: 14px; overflow-wrap: anywhere; }
.contacts-grid h2 { font-size: 22px; margin: 0 0 12px; letter-spacing: -.02em; }
.contacts-grid .props th { white-space: nowrap; }
.legal { max-width: 820px; line-height: 1.65; color: var(--fg); }
.legal h2 { font-size: 20px; letter-spacing: -.015em; margin: 32px 0 10px; color: var(--strong); }
.legal p { margin: 0 0 10px; }
.legal-note { padding: 10px 14px; border-radius: var(--r); background: var(--warn-bg); color: var(--warn); font-size: 14px; }
.legal .props { margin: 8px 0 14px; }
.legal .props th { white-space: nowrap; vertical-align: top; }

@media (max-width: 960px) {
  .plans, .diff-grid { grid-template-columns: minmax(0, 1fr); }
  .plans { max-width: 520px; margin: 0 auto; }
  .diff-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shots-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot-cols { grid-template-columns: 1fr 1fr; }
  .faq-cols, .contacts-grid { grid-template-columns: minmax(0, 1fr); }
  .cmp td:first-child { white-space: normal; }
}
@media (max-width: 640px) {
  .page-head { padding: 44px 0 28px; }
  .diff-grid, .shots-2, .shots-3, .contact-cards, .foot-cols { grid-template-columns: minmax(0, 1fr); }
  .shots-phone { grid-template-columns: minmax(0, 1fr); }
  .plan-price b { font-size: 30px; }
  .cmp { font-size: 13.5px; }
  .cmp th, .cmp td { padding: 10px 8px; }
}

/* Кабинет владельца: разделы, состояние и безопасность */
.owner-nav { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 18px; }
.owner-nav a { padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); text-decoration: none; font-size: 14px; }
.owner-nav a.on { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); }
.owner .inline-form { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; margin-top: 10px; }
.owner .inline-form label { max-width: 260px; }
.owner .steps { margin: 10px 0 4px 20px; line-height: 1.7; }
.owner code.secret { font-size: 15px; letter-spacing: .06em; user-select: all; }
.owner tr.bad-row td { color: var(--err-fg); }
.owner .small { font-size: 13px; }
