/* =========================================================================
   QR Репликатор ЧЗ — дизайн-система сайта
   Контраст: основной текст на тёмном ≥ 12:1, вторичный ≥ 7:1 (AA/AAA).
   ========================================================================= */

:root {
  /* Тёмные поверхности */
  --d-900: #080D16;
  --d-800: #0B1220;
  --d-700: #101A2B;
  --d-600: #16223A;
  --d-line: rgba(148, 178, 220, 0.16);
  --d-line-strong: rgba(148, 178, 220, 0.3);

  /* Светлые поверхности */
  --l-bg: #F5F7FB;
  --l-card: #FFFFFF;
  --l-soft: #EEF2F8;
  --l-line: #D7DEE9;
  --l-line-soft: #E6EBF2;

  /* Текст на тёмном (проверено на --d-800) */
  --t-on-dark: #F4F8FD;        /* 17.4:1 */
  --t-on-dark-2: #C4D2E4;      /* 10.4:1 */
  --t-on-dark-3: #9DB0C9;      /*  6.8:1 */

  /* Текст на светлом (проверено на #FFFFFF) */
  --t-on-light: #101828;       /* 16.7:1 */
  --t-on-light-2: #3D4A5E;     /*  9.1:1 */
  --t-on-light-3: #57657C;     /*  6.2:1 */

  /* Акценты */
  --blue: #2E7DF6;
  --blue-600: #1C63D4;
  --blue-ink: #1B5FCB;         /* синий для текста на белом, 5.1:1 */
  --cyan: #38BDF8;
  --cyan-ink: #0B6E9B;

  --green: #22C55E;
  --green-ink: #157F3C;
  --green-soft: #E8F8EE;

  --amber: #F59E0B;
  --amber-ink: #8A5A00;
  --amber-soft: #FEF6E6;

  --red: #EF4444;
  --red-ink: #B32020;
  --red-soft: #FDECEC;

  /* Цвета плашек статусов — как в программе */
  --chip-ok: #86EFAC;
  --chip-warn: #FEF08A;
  --chip-block: #FCA5A5;

  --font: "Inter", "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --wrap: 1200px;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 26px;

  --sh-1: 0 1px 2px rgba(16, 24, 40, .06), 0 1px 3px rgba(16, 24, 40, .1);
  --sh-2: 0 4px 8px -2px rgba(16, 24, 40, .1), 0 2px 4px -2px rgba(16, 24, 40, .06);
  --sh-3: 0 12px 16px -4px rgba(16, 24, 40, .08), 0 4px 6px -2px rgba(16, 24, 40, .03);
  --sh-4: 0 24px 48px -12px rgba(16, 24, 40, .18);
  --sh-dark: 0 30px 60px -12px rgba(0, 0, 0, .55);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* Атрибут hidden должен побеждать display у компонентов вроде .btn */
[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--t-on-light);
  background: var(--l-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img, svg, canvas { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
table { border-collapse: collapse; width: 100%; }

::selection { background: rgba(46, 125, 246, .22); }

:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 2px;
  border-radius: 4px;
}

.wrap { width: min(var(--wrap), calc(100% - 40px)); margin-inline: auto; }
.wrap-narrow { width: min(900px, calc(100% - 40px)); margin-inline: auto; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  background: #fff;
  color: var(--t-on-light);
  padding: 12px 18px;
  border-radius: 0 0 var(--r-sm) 0;
  font-weight: 700;
}
.skip-link:focus { left: 0; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ============================== Шапка ============================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: rgba(8, 13, 22, .9);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--d-line);
  color: var(--t-on-dark);
}

.header-row {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 70px;
  position: relative;
}

.brand { display: flex; align-items: center; gap: 11px; flex-shrink: 0; }
.brand img { width: 34px; height: 34px; }
.brand-name { font-weight: 800; font-size: 17px; letter-spacing: -.02em; color: #fff; }
.brand-ver {
  font-size: 11px;
  font-weight: 700;
  color: #A9D6F5;
  background: rgba(56, 189, 248, .14);
  border: 1px solid rgba(56, 189, 248, .3);
  padding: 2px 7px;
  border-radius: 99px;
  letter-spacing: .02em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  font-size: 14.5px;
  font-weight: 600;
}
.main-nav a {
  color: var(--t-on-dark-2);
  padding: 8px 12px;
  border-radius: var(--r-sm);
  transition: background .16s ease, color .16s ease;
}
.main-nav a:hover { color: #fff; background: rgba(255, 255, 255, .07); }
.main-nav a[aria-current="page"] { color: #fff; background: rgba(46, 125, 246, .2); }
.main-nav .nav-cta-mobile { display: none; }

.header-cta { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.header-cta .btn { white-space: nowrap; }

.burger {
  display: none;
  background: transparent;
  border: 1px solid var(--d-line-strong);
  color: #fff;
  width: 42px; height: 42px;
  border-radius: var(--r-sm);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

/* ============================== Кнопки ============================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 11px 20px;
  font-size: 14.5px;
  font-weight: 700;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  cursor: pointer;
  white-space: nowrap;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease;
}
.btn:active { transform: translateY(1px); }
.btn svg { flex-shrink: 0; }

.btn-lg { padding: 15px 28px; font-size: 16px; border-radius: var(--r-lg); }
.btn-sm { padding: 8px 15px; font-size: 13.5px; }
.btn-block { width: 100%; }

.btn-primary {
  background: linear-gradient(135deg, #3B8CFF 0%, #1C63D4 100%);
  color: #fff;
  box-shadow: 0 6px 16px rgba(28, 99, 212, .34);
}
.btn-primary:hover { box-shadow: 0 10px 24px rgba(28, 99, 212, .44); transform: translateY(-1px); }

.btn-ghost-light {
  background: rgba(255, 255, 255, .08);
  color: #fff;
  border-color: rgba(255, 255, 255, .22);
}
.btn-ghost-light:hover { background: rgba(255, 255, 255, .16); }

.btn-outline {
  background: #fff;
  color: var(--t-on-light);
  border-color: var(--l-line);
  box-shadow: var(--sh-1);
}
.btn-outline:hover { border-color: #A9B7CA; box-shadow: var(--sh-2); transform: translateY(-1px); }

.btn-dark { background: var(--d-800); color: #fff; }
.btn-dark:hover { background: var(--d-700); transform: translateY(-1px); }

.btn-green { background: var(--green-ink); color: #fff; }
.btn-green:hover { background: #106E32; transform: translateY(-1px); }

.btn[disabled], .btn[aria-disabled="true"] {
  opacity: .55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ============================== Бейджи ============================== */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 13px;
  border-radius: 99px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .01em;
}
.pill-blue { background: rgba(46, 125, 246, .12); color: var(--blue-ink); border: 1px solid rgba(46, 125, 246, .28); }
.pill-green { background: var(--green-soft); color: var(--green-ink); border: 1px solid rgba(34, 197, 94, .32); }
.pill-amber { background: var(--amber-soft); color: var(--amber-ink); border: 1px solid rgba(245, 158, 11, .36); }
.pill-red { background: var(--red-soft); color: var(--red-ink); border: 1px solid rgba(239, 68, 68, .32); }
.pill-gray { background: var(--l-soft); color: var(--t-on-light-2); border: 1px solid var(--l-line); }

.pill-on-dark {
  background: rgba(56, 189, 248, .14);
  color: #A9D6F5;
  border: 1px solid rgba(56, 189, 248, .3);
}
.pill-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

/* Плашка «скоро» — честная маркировка незаконченного */
.pill-soon {
  background: rgba(148, 163, 184, .16);
  color: #4A5769;
  border: 1px dashed #94A3B8;
}

/* ============================== Секции ============================== */
.section { padding: 88px 0; }
.section-sm { padding: 60px 0; }
.section-dark { background: var(--d-800); color: var(--t-on-dark); }
.section-darker { background: var(--d-900); color: var(--t-on-dark); }
.section-white { background: #fff; }

.section-dark p, .section-darker p { color: var(--t-on-dark-2); }

.sec-head { max-width: 760px; margin: 0 auto 52px; text-align: center; }
.sec-head.left { margin-inline: 0; text-align: left; }

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--blue-ink);
  margin-bottom: 14px;
}
.section-dark .eyebrow, .section-darker .eyebrow { color: #7DC8F5; }

h1, h2, h3, h4 { letter-spacing: -.025em; line-height: 1.18; font-weight: 800; }

.h-xl { font-size: clamp(34px, 4.6vw, 56px); line-height: 1.08; }
.h-lg { font-size: clamp(28px, 3.4vw, 42px); }
.h-md { font-size: clamp(22px, 2.4vw, 30px); }
.h-sm { font-size: 20px; }

.lede { font-size: 18px; line-height: 1.6; color: var(--t-on-light-2); }
.section-dark .lede, .section-darker .lede, .hero .lede { color: var(--t-on-dark-2); }

.muted { color: var(--t-on-light-3); font-size: 14px; }
.section-dark .muted, .section-darker .muted { color: var(--t-on-dark-3); }

.note {
  font-size: 13.5px;
  color: var(--t-on-light-3);
  line-height: 1.55;
}
.section-dark .note, .section-darker .note { color: var(--t-on-dark-3); }

/* ============================== Hero ============================== */
.hero {
  position: relative;
  background: var(--d-800);
  color: var(--t-on-dark);
  padding: 76px 0 90px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -260px 0 auto 0;
  height: 620px;
  background: radial-gradient(58% 60% at 50% 50%, rgba(46, 125, 246, .3) 0%, rgba(11, 18, 32, 0) 72%);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(148, 178, 220, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 178, 220, .05) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(70% 60% at 50% 30%, #000 0%, transparent 78%);
  -webkit-mask-image: radial-gradient(70% 60% at 50% 30%, #000 0%, transparent 78%);
  pointer-events: none;
}
.hero > * { position: relative; z-index: 2; }

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr);
  gap: 54px;
  align-items: center;
}

.hero h1 { color: #fff; margin-bottom: 20px; }
.hero h1 .accent {
  background: linear-gradient(100deg, #7DD3FC 0%, #4C9BFF 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero .lede { max-width: 580px; margin-bottom: 30px; font-size: 18.5px; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 13px; margin-bottom: 26px; }

.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  font-size: 14px;
  color: var(--t-on-dark-2);
}
.hero-facts span { display: inline-flex; align-items: center; gap: 8px; }
.hero-facts svg { color: var(--green); flex-shrink: 0; }

.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  margin-top: 58px;
  padding-top: 34px;
  border-top: 1px solid var(--d-line);
}
.metric-v { font-size: 27px; font-weight: 800; color: #fff; letter-spacing: -.03em; }
.metric-v .unit { font-size: 16px; color: var(--t-on-dark-2); font-weight: 700; }
.metric-l { font-size: 13.5px; color: var(--t-on-dark-2); line-height: 1.45; margin-top: 3px; }

/* ============================== Реплика окна программы ============================== */
.app-window {
  background: #F0F2F5;
  border: 1px solid #C3CBD6;
  border-radius: 10px;
  box-shadow: var(--sh-dark);
  overflow: hidden;
  font-size: 11.5px;
  color: #1A1F27;
  line-height: 1.35;
}
.app-titlebar {
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(#FBFCFD, #EDEFF3);
  border-bottom: 1px solid #C3CBD6;
  padding: 7px 10px;
}
.app-titlebar .t-icon { width: 15px; height: 15px; }
.app-titlebar .t-text { font-weight: 600; font-size: 11.5px; color: #23303F; }
.app-titlebar .t-btns { margin-left: auto; display: flex; gap: 14px; color: #5A6675; }
.app-titlebar .t-btns i { width: 11px; height: 11px; display: block; position: relative; }
.app-titlebar .t-btns i::before {
  content: "";
  position: absolute;
  inset: 0;
  border-top: 1px solid currentColor;
  top: 5px;
}
.app-titlebar .t-btns i.sq::before { inset: 0; border: 1px solid currentColor; top: 0; }
.app-titlebar .t-btns i.x::before {
  border: 0;
  top: 5px;
  transform: rotate(45deg);
  border-top: 1px solid currentColor;
  box-shadow: 0 0 0 0 currentColor;
}

.app-body { padding: 9px; display: flex; flex-direction: column; gap: 9px; }

.app-toolbar {
  background: #F4F6F8;
  border: 1px solid #D0D5DD;
  border-radius: 4px;
  padding: 8px;
}
.app-fields { display: flex; gap: 12px; margin-bottom: 7px; }
.app-field { display: flex; align-items: center; gap: 7px; flex: 1; min-width: 0; }
.app-field span { color: #38424F; white-space: nowrap; }
.app-input {
  flex: 1;
  min-width: 0;
  background: #fff;
  border: 1px solid #ACB6C2;
  border-radius: 2px;
  padding: 3px 6px;
  font-size: 11px;
  color: #101828;
}
.app-btnrow { display: flex; flex-wrap: wrap; gap: 6px; }
.app-btn {
  background: linear-gradient(#FCFCFD, #EFF1F4);
  border: 1px solid #ADB6C2;
  border-radius: 3px;
  padding: 4px 9px;
  font-size: 11px;
  color: #1A2430;
  white-space: nowrap;
}
.app-btn.accent { background: linear-gradient(#DCEBFF, #C3DBFB); border-color: #7BA7E0; color: #12365F; font-weight: 600; }

.app-cols { display: grid; grid-template-columns: 42fr 58fr; gap: 9px; align-items: start; }

.app-group {
  border: 1px solid #C6CDD8;
  border-radius: 3px;
  padding: 9px 8px 8px;
  position: relative;
  background: #F7F8FA;
}
.app-group > .g-title {
  position: absolute;
  top: -8px;
  left: 8px;
  background: #F0F2F5;
  padding: 0 5px;
  font-size: 11px;
  font-weight: 600;
  color: #35404E;
}
.app-group + .app-group { margin-top: 12px; }

.app-check { display: flex; align-items: flex-start; gap: 6px; margin-bottom: 5px; color: #26303C; }
.app-check .bx {
  width: 12px; height: 12px;
  border: 1px solid #7A8798;
  border-radius: 2px;
  background: #fff;
  flex-shrink: 0;
  margin-top: 1px;
  position: relative;
}
.app-check.on .bx { background: #2E7DF6; border-color: #2E7DF6; }
.app-check.on .bx::after {
  content: "";
  position: absolute;
  left: 3.5px; top: .5px;
  width: 3.5px; height: 7px;
  border: solid #fff;
  border-width: 0 1.6px 1.6px 0;
  transform: rotate(45deg);
}

.app-scanbox {
  background: #fff;
  border: 1px solid #7BA7E0;
  box-shadow: 0 0 0 2px rgba(46, 125, 246, .16);
  border-radius: 2px;
  padding: 6px 7px;
  font-family: var(--mono);
  font-size: 10px;
  color: #0F2E52;
  word-break: break-all;
  min-height: 42px;
  line-height: 1.45;
  position: relative;
  overflow: hidden;
}
.app-hint { font-size: 10.5px; color: #5B6675; margin-top: 5px; }

.app-list { margin-top: 7px; display: flex; flex-direction: column; gap: 3px; }
.app-row {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #fff;
  border: 1px solid #E1E5EC;
  border-radius: 2px;
  padding: 5px 7px;
}
.app-row.sel { background: #EAF2FE; border-color: #B7D2F5; }
.app-row .r-main { flex: 1; min-width: 0; }
.app-row .r-t { font-weight: 600; color: #16202C; font-size: 11px; }
.app-row .r-s { font-size: 10px; color: #5B6675; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Плашки статуса ЧЗ — те же цвета, что в программе */
.crpt-chip {
  font-size: 10.5px;
  font-weight: 700;
  color: #000;
  border-radius: 3px;
  padding: 4px 8px;
  white-space: nowrap;
  flex-shrink: 0;
}
.crpt-chip.ok { background: var(--chip-ok); }
.crpt-chip.warn { background: var(--chip-warn); }
.crpt-chip.block { background: var(--chip-block); }

.app-select {
  background: linear-gradient(#FFF, #F3F5F8);
  border: 1px solid #ACB6C2;
  border-radius: 2px;
  padding: 4px 7px;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #16202C;
}
.app-select::after { content: "▾"; color: #5B6675; font-size: 10px; }
.app-label-cap { font-size: 10.5px; color: #38424F; margin-bottom: 3px; }

.app-preview {
  background: #FAFBFC;
  border: 1px solid #D0D5DD;
  border-radius: 3px;
  padding: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 132px;
  margin-top: 8px;
}

/* ============================== Превью этикетки ============================== */
.label-card {
  background: #fff;
  border: 1px solid #C8D0DC;
  border-radius: 3px;
  padding: 7px 8px;
  display: flex;
  gap: 9px;
  align-items: flex-start;
  width: 100%;
  max-width: 250px;
  box-shadow: 0 2px 6px rgba(16, 24, 40, .08);
}
.label-card .dm { width: 62px; height: 62px; flex-shrink: 0; image-rendering: pixelated; }
.label-card .l-txt { min-width: 0; flex: 1; }
.label-card .l-name { font-size: 10.5px; font-weight: 700; color: #0B1220; line-height: 1.25; }
.label-card .l-meta { font-size: 9px; color: #47536A; margin-top: 2px; line-height: 1.35; }
.label-card .l-code { font-family: var(--mono); font-size: 8.5px; color: #17233A; margin-top: 3px; word-break: break-all; }

/* ============================== Карточки ============================== */
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; }

.card {
  background: var(--l-card);
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-lg);
  padding: 30px 26px;
  box-shadow: var(--sh-1);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--sh-3); border-color: #C8D5E6; }
.card h3 { font-size: 19px; margin-bottom: 10px; color: var(--t-on-light); }
.card p { color: var(--t-on-light-2); font-size: 15px; }

.card-dark {
  background: var(--d-700);
  border: 1px solid var(--d-line);
  border-radius: var(--r-lg);
  padding: 30px 26px;
  transition: transform .2s ease, border-color .2s ease;
}
.card-dark:hover { transform: translateY(-3px); border-color: rgba(56, 189, 248, .42); }
.card-dark h3 { color: #fff; font-size: 20px; margin-bottom: 12px; }
.card-dark p { color: var(--t-on-dark-2); font-size: 15px; }

.ico-box {
  width: 46px; height: 46px;
  border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
  background: rgba(46, 125, 246, .1);
  color: var(--blue-ink);
}
.card-dark .ico-box { background: rgba(56, 189, 248, .14); color: #7DD3FC; }

.step-n {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--blue-ink);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 14px;
  margin-bottom: 16px;
}

/* Списки с галочками */
.checks { list-style: none; display: flex; flex-direction: column; gap: 11px; }
.checks li { display: flex; gap: 11px; align-items: flex-start; font-size: 15px; color: var(--t-on-light-2); }
.checks li svg { color: var(--green-ink); flex-shrink: 0; margin-top: 3px; }
.section-dark .checks li, .card-dark .checks li { color: var(--t-on-dark-2); }
.section-dark .checks li svg, .card-dark .checks li svg { color: #4ADE80; }

/* ============================== Таблицы ============================== */
.table-box {
  background: #fff;
  border: 1px solid var(--l-line);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-1);
}
.table-scroll { overflow-x: auto; }

.tbl { font-size: 14.5px; min-width: 640px; color: var(--t-on-light); }
.tbl th, .tbl td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--l-line-soft); color: var(--t-on-light); }
.tbl tbody th { font-weight: 600; color: var(--t-on-light); }
.tbl thead th {
  background: var(--l-soft);
  font-weight: 800;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--t-on-light);
  white-space: nowrap;
}
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tbody tr:hover { background: #FAFCFF; }
.tbl td.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.tbl .col-hi { background: rgba(46, 125, 246, .05); }
.tbl thead .col-hi { background: rgba(46, 125, 246, .12); color: var(--blue-ink); }

.yes { color: var(--green-ink); font-weight: 700; }
.no { color: var(--t-on-light-3); }

/* ============================== Размеры этикеток ============================== */
.size-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(184px, 1fr));
  gap: 16px;
}
.size-card {
  background: #fff;
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-md);
  padding: 18px 16px;
  box-shadow: var(--sh-1);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.size-card:hover { transform: translateY(-3px); box-shadow: var(--sh-3); border-color: var(--blue); }
.size-card.is-custom { border-style: dashed; border-color: #9DB0C9; background: #FAFCFF; }

.size-dim { font-size: 21px; font-weight: 800; color: var(--t-on-light); letter-spacing: -.02em; }
.size-dim .mm { font-size: 13px; font-weight: 700; color: var(--t-on-light-3); }
.size-role { font-size: 13px; color: var(--t-on-light-2); margin-top: 6px; min-height: 36px; }
.size-a4 {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed var(--l-line);
  font-size: 12.5px;
  color: var(--t-on-light-3);
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.size-a4 b { color: var(--blue-ink); font-variant-numeric: tabular-nums; }

/* Пропорциональная миниатюра этикетки */
.size-shape {
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
}
.size-shape i {
  display: block;
  border: 1.5px solid var(--blue);
  background: rgba(46, 125, 246, .07);
  border-radius: 2px;
}

/* ============================== Онлайн-сервис ============================== */
.svc-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr);
  gap: 26px;
  align-items: start;
}

.panel {
  background: #fff;
  border: 1px solid var(--l-line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-2);
  overflow: hidden;
}
.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 17px 22px;
  border-bottom: 1px solid var(--l-line-soft);
  background: #FBFCFE;
}
.panel-head h2, .panel-head h3 { font-size: 16px; font-weight: 800; }
.panel-body { padding: 22px; }
.panel-body + .panel-body { border-top: 1px solid var(--l-line-soft); }

.field { margin-bottom: 18px; }
.field:last-child { margin-bottom: 0; }
.field > label, .field-label {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--t-on-light-2);
  margin-bottom: 7px;
}

.inp, .sel, .ta {
  width: 100%;
  background: #fff;
  border: 1px solid var(--l-line);
  border-radius: var(--r-sm);
  padding: 11px 13px;
  font-size: 15px;
  color: var(--t-on-light);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.inp:focus, .sel:focus, .ta:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(46, 125, 246, .18);
}
.ta { resize: vertical; min-height: 92px; font-family: var(--mono); font-size: 13px; line-height: 1.5; }
.sel { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%2357657C' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 13px center; padding-right: 36px; }

.scan-field {
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.5;
  min-height: 84px;
}
.scan-field.armed {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(46, 125, 246, .2);
}

.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.row-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.inline-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  background: var(--l-soft);
  border: 1px solid var(--l-line);
  color: var(--t-on-light-2);
  padding: 7px 14px;
  border-radius: 99px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s ease;
}
.chip:hover { border-color: var(--blue); color: var(--blue-ink); }
.chip[aria-pressed="true"] {
  background: var(--blue-ink);
  border-color: var(--blue-ink);
  color: #fff;
}

/* Разбор КИЗ */
.parse-list { display: flex; flex-direction: column; gap: 9px; }
.parse-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: #F8FAFD;
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-sm);
  padding: 10px 14px;
}
.parse-ai {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: var(--blue-ink);
  border-radius: 4px;
  padding: 3px 7px;
  flex-shrink: 0;
}
.parse-ai.warn { background: var(--amber-ink); }
.parse-name { font-size: 13px; color: var(--t-on-light-2); flex-shrink: 0; min-width: 132px; }
.parse-val {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--t-on-light);
  word-break: break-all;
  margin-left: auto;
  text-align: right;
}

.verdict {
  display: flex;
  align-items: center;
  gap: 13px;
  border-radius: var(--r-md);
  padding: 14px 17px;
  font-size: 14.5px;
  font-weight: 700;
  border: 1px solid transparent;
}
.verdict.ok { background: var(--green-soft); color: var(--green-ink); border-color: rgba(34, 197, 94, .34); }
.verdict.warn { background: var(--amber-soft); color: var(--amber-ink); border-color: rgba(245, 158, 11, .38); }
.verdict.bad { background: var(--red-soft); color: var(--red-ink); border-color: rgba(239, 68, 68, .34); }
.verdict small { display: block; font-weight: 600; font-size: 12.5px; opacity: .9; margin-top: 2px; }

/* Сцена предпросмотра этикетки */
.preview-stage {
  background:
    linear-gradient(45deg, #EDF1F7 25%, transparent 25%) -8px 0/16px 16px,
    linear-gradient(-45deg, #EDF1F7 25%, transparent 25%) -8px 0/16px 16px,
    linear-gradient(45deg, transparent 75%, #EDF1F7 75%) 0 0/16px 16px,
    linear-gradient(-45deg, transparent 75%, #EDF1F7 75%) 0 0/16px 16px,
    #F7F9FC;
  border: 1px solid var(--l-line);
  border-radius: var(--r-md);
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 268px;
}
.preview-stage canvas {
  background: #fff;
  box-shadow: 0 8px 22px rgba(16, 24, 40, .16);
  border-radius: 2px;
  max-width: 100%;
  height: auto;
}

.stage-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin-top: 14px;
  font-size: 13px;
  color: var(--t-on-light-2);
}
.stage-meta b { color: var(--t-on-light); font-variant-numeric: tabular-nums; }

/* Мини-макет листа A4 */
.a4-mini {
  --cols: 3;
  --rows: 7;
  aspect-ratio: 210 / 297;
  background: #fff;
  border: 1px solid var(--l-line);
  border-radius: 3px;
  padding: 3.8%;
  display: grid;
  grid-template-columns: repeat(var(--cols), 1fr);
  grid-template-rows: repeat(var(--rows), 1fr);
  gap: 0;
  width: 100%;
  max-width: 210px;
  margin-inline: auto;
  box-shadow: var(--sh-2);
}
.a4-mini i {
  border: 1px dashed #9DB0C9;
  background: rgba(46, 125, 246, .07);
}

/* ============================== Тарифы ============================== */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; align-items: stretch; }
.plan {
  background: #fff;
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-xl);
  padding: 34px 28px;
  display: flex;
  flex-direction: column;
  position: relative;
  box-shadow: var(--sh-1);
  transition: transform .2s ease, box-shadow .2s ease;
}
.plan:hover { transform: translateY(-4px); box-shadow: var(--sh-4); }
.plan.best { border: 2px solid var(--blue); box-shadow: var(--sh-3), 0 0 0 6px rgba(46, 125, 246, .08); }
.plan-flag {
  position: absolute;
  top: -13px; left: 50%;
  transform: translateX(-50%);
  background: var(--blue-ink);
  color: #fff;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 5px 16px;
  border-radius: 99px;
  white-space: nowrap;
}
.plan-name { font-size: 19px; font-weight: 800; }
.plan-for { font-size: 14px; color: var(--t-on-light-2); margin: 8px 0 20px; min-height: 44px; }
.plan-price { font-size: 36px; font-weight: 800; letter-spacing: -.03em; }
.plan-price .cur { font-size: 22px; }
.plan-unit { font-size: 13px; color: var(--t-on-light-3); margin-top: 4px; margin-bottom: 24px; }
.plan .checks { margin-bottom: 26px; flex: 1; }
.plan .checks li { font-size: 14px; }

.addons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.addon {
  background: #fff;
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-md);
  padding: 20px;
  box-shadow: var(--sh-1);
}
.addon-n { font-size: 15px; font-weight: 800; margin-bottom: 4px; }
.addon-p { font-size: 22px; font-weight: 800; color: var(--blue-ink); letter-spacing: -.02em; }
.addon-d { font-size: 13px; color: var(--t-on-light-2); margin-top: 8px; }

/* ============================== База знаний ============================== */
.kb-layout { display: grid; grid-template-columns: 254px minmax(0, 1fr); gap: 40px; align-items: start; }

.kb-side {
  position: sticky;
  top: 90px;
  background: #fff;
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-lg);
  padding: 20px;
  box-shadow: var(--sh-1);
}
.kb-side h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .07em; color: var(--t-on-light-3); margin-bottom: 14px; }
.kb-side ul { list-style: none; display: flex; flex-direction: column; gap: 2px; }
.kb-side a {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--r-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--t-on-light-2);
  transition: background .15s ease, color .15s ease;
}
.kb-side a:hover, .kb-side a.on { background: rgba(46, 125, 246, .1); color: var(--blue-ink); }
.kb-side a span { color: var(--t-on-light-3); font-weight: 700; font-size: 12.5px; }

.kb-search { position: relative; margin-bottom: 26px; }
.kb-search .inp { padding-left: 44px; font-size: 15.5px; padding-block: 14px; }
.kb-search svg { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: var(--t-on-light-3); }

.kb-group { margin-bottom: 40px; scroll-margin-top: 92px; }
.kb-group > h3 {
  font-size: 22px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--l-line-soft);
}

.qa { display: flex; flex-direction: column; gap: 10px; }
.qa-item {
  background: #fff;
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-md);
  overflow: hidden;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.qa-item:hover { border-color: #C8D5E6; }
.qa-item.open { border-color: var(--blue); box-shadow: var(--sh-2); }
.qa-q {
  width: 100%;
  background: none;
  border: 0;
  text-align: left;
  padding: 17px 22px;
  font-size: 16px;
  font-weight: 700;
  color: var(--t-on-light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.qa-ic {
  flex-shrink: 0;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--l-soft);
  color: var(--t-on-light-2);
  display: flex; align-items: center; justify-content: center;
  transition: transform .22s ease, background .22s ease, color .22s ease;
  font-size: 17px;
  line-height: 1;
}
.qa-item.open .qa-ic { background: var(--blue-ink); color: #fff; transform: rotate(45deg); }
.qa-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .26s ease;
}
.qa-item.open .qa-a { grid-template-rows: 1fr; }
.qa-a > div { overflow: hidden; }
.qa-a .qa-inner {
  padding: 0 22px 20px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--t-on-light-2);
}
.qa-a p + p { margin-top: 12px; }
.qa-a ul { margin: 12px 0 0 20px; display: flex; flex-direction: column; gap: 7px; }
.qa-a code {
  font-family: var(--mono);
  font-size: 13px;
  background: var(--l-soft);
  border: 1px solid var(--l-line-soft);
  border-radius: 4px;
  padding: 1px 6px;
  color: #17233A;
}

.kb-empty {
  display: none;
  text-align: center;
  padding: 50px 20px;
  color: var(--t-on-light-2);
}
.kb-empty.on { display: block; }

/* Видеоинструкции */
.vid-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.vid {
  background: #fff;
  border: 1px solid var(--l-line-soft);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-1);
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease;
}
.vid:hover { transform: translateY(-3px); box-shadow: var(--sh-3); }
.vid-poster {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(140deg, #16223A 0%, #0B1220 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.vid-poster::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(148, 178, 220, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 178, 220, .07) 1px, transparent 1px);
  background-size: 26px 26px;
}
.vid-play {
  position: relative;
  width: 54px; height: 54px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .14);
  border: 1.5px solid rgba(255, 255, 255, .4);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  backdrop-filter: blur(3px);
}
.vid-dur {
  position: absolute;
  right: 10px; bottom: 10px;
  background: rgba(8, 13, 22, .82);
  color: #E7EEF8;
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  font-variant-numeric: tabular-nums;
}
.vid-state {
  position: absolute;
  left: 10px; top: 10px;
}
.vid-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.vid-body h4 { font-size: 16px; }
.vid-body p { font-size: 13.5px; color: var(--t-on-light-2); flex: 1; }
.vid-link { font-size: 13.5px; font-weight: 700; color: var(--blue-ink); display: inline-flex; align-items: center; gap: 6px; }
.vid-link:hover { text-decoration: underline; }

/* Плашка «в разработке» — честно про заглушки */
.disclosure {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #FFFBF0;
  border: 1px solid #F5D89B;
  border-left: 4px solid var(--amber);
  border-radius: var(--r-md);
  padding: 16px 20px;
  font-size: 14.5px;
  color: #6B4A05;
  line-height: 1.55;
}
.disclosure svg { color: var(--amber-ink); flex-shrink: 0; margin-top: 2px; }
.disclosure b { color: #573D04; }

.info-box {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #F1F6FE;
  border: 1px solid #C5DAF8;
  border-left: 4px solid var(--blue);
  border-radius: var(--r-md);
  padding: 16px 20px;
  font-size: 14.5px;
  color: #123A70;
  line-height: 1.55;
}
.info-box svg { color: var(--blue-ink); flex-shrink: 0; margin-top: 2px; }

/* ============================== Формы / CTA ============================== */
.cta-band {
  background: linear-gradient(140deg, #101A2B 0%, #0B1220 60%, #12203A 100%);
  border: 1px solid var(--d-line);
  border-radius: var(--r-xl);
  padding: 62px 48px;
  text-align: center;
  color: var(--t-on-dark);
  position: relative;
  overflow: hidden;
}
.cta-band::before {
  content: "";
  position: absolute;
  inset: -50% 20% auto;
  height: 380px;
  background: radial-gradient(50% 50% at 50% 50%, rgba(46, 125, 246, .34), transparent 70%);
}
.cta-band > * { position: relative; z-index: 2; }
.cta-band h2 { color: #fff; margin-bottom: 14px; }
.cta-band p { max-width: 620px; margin: 0 auto 30px; color: var(--t-on-dark-2); font-size: 17px; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 13px; justify-content: center; }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.form-grid .full { grid-column: 1 / -1; }

.form-ok {
  background: var(--green-soft);
  border: 1px solid rgba(34, 197, 94, .35);
  border-radius: var(--r-md);
  padding: 28px;
  text-align: center;
}
.form-ok h4 { font-size: 19px; color: var(--green-ink); margin: 12px 0 8px; }
.form-ok p { font-size: 14.5px; color: var(--t-on-light-2); }
.form-err {
  margin-top: 14px;
  padding: 12px 14px;
  background: var(--red-soft);
  border: 1px solid rgba(179, 32, 32, .28);
  border-radius: var(--r-md);
  color: var(--red-ink);
  font-size: 14.5px;
}
.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.mod-list { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.mod-list label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14.5px;
  color: var(--t-on-light);
  cursor: pointer;
}
.mod-list input { margin-top: 3px; accent-color: var(--blue); }
.order-total {
  margin-top: 14px;
  font-size: 18px;
  font-weight: 800;
  color: var(--t-on-light);
}

/* ============================== Подвал ============================== */
.site-footer {
  background: var(--d-900);
  color: var(--t-on-dark-2);
  padding: 66px 0 30px;
  font-size: 14.5px;
  border-top: 1px solid var(--d-line);
}
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 44px; margin-bottom: 46px; }
.footer-about { font-size: 14px; color: var(--t-on-dark-2); margin-top: 14px; max-width: 330px; line-height: 1.6; }
.footer-col h5 { color: #fff; font-size: 14.5px; margin-bottom: 16px; }
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: var(--t-on-dark-2); transition: color .15s ease; }
.footer-col a:hover { color: #fff; }
.footer-col li { color: var(--t-on-dark-2); }
.footer-bottom {
  border-top: 1px solid var(--d-line);
  padding-top: 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--t-on-dark-3);
}
.footer-legal { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-legal a { color: var(--t-on-dark-3); }
.footer-legal a:hover { color: var(--t-on-dark); }

.legal { font-size: 15.5px; line-height: 1.72; color: var(--t-on-light-2); }
.legal h2 {
  font-size: 21px; color: var(--t-on-light);
  margin: 38px 0 14px; padding-bottom: 10px;
  border-bottom: 2px solid var(--l-line-soft);
}
.legal h2:first-child { margin-top: 0; }
.legal h3 { font-size: 16.5px; color: var(--t-on-light); margin: 22px 0 10px; }
.legal p { margin-bottom: 12px; }
.legal ul, .legal ol { margin: 12px 0 16px 22px; display: flex; flex-direction: column; gap: 8px; }
.legal strong { color: var(--t-on-light); }
.legal a { color: var(--blue-ink); text-decoration: underline; text-underline-offset: 3px; }

.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 4px 0 16px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--t-on-light-2);
}
.consent-row input { margin-top: 3px; accent-color: var(--blue); flex-shrink: 0; }
.consent-row a { color: var(--blue-ink); text-decoration: underline; text-underline-offset: 2px; }
.consent-row.is-invalid {
  padding: 10px 12px;
  border-radius: var(--r-md);
  background: var(--red-soft);
  outline: 1px solid rgba(179, 32, 32, .28);
  color: var(--red-ink);
}

.cookie-bar {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 80;
  max-width: 720px;
  margin-inline: auto;
  background: var(--d-800);
  color: var(--t-on-dark);
  border: 1px solid var(--d-line-strong);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-dark);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.cookie-bar p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--t-on-dark-2); }
.cookie-bar a { color: var(--cyan); text-decoration: underline; text-underline-offset: 2px; }
.cookie-bar-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; }
body.has-cookie-bar { padding-bottom: 220px; }

@media (max-width: 620px) {
  .cookie-bar { left: 10px; right: 10px; bottom: 10px; padding: 16px; }
  .cookie-bar-actions .btn { flex: 1; }
}

/* Хлебные крошки */
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13.5px; color: var(--t-on-dark-3); margin-bottom: 18px; }
.crumbs a { color: var(--t-on-dark-2); }
.crumbs a:hover { color: #fff; text-decoration: underline; }

.page-head { background: var(--d-800); color: var(--t-on-dark); padding: 46px 0 58px; position: relative; overflow: hidden; }
.page-head::before {
  content: "";
  position: absolute;
  inset: -240px 0 auto 0;
  height: 520px;
  background: radial-gradient(50% 60% at 50% 50%, rgba(46, 125, 246, .22), transparent 72%);
}
.page-head > * { position: relative; z-index: 2; }
.page-head h1 { color: #fff; margin-bottom: 16px; }
.page-head .lede { max-width: 780px; }

/* ============================== Анимации ============================== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}
@keyframes sweep {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(220%); }
}
@keyframes pulseDot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, .55); }
  70% { box-shadow: 0 0 0 9px rgba(34, 197, 94, 0); }
}
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}
@keyframes caret {
  0%, 45% { opacity: 1; }
  50%, 95% { opacity: 0; }
}

/* Появление при прокрутке */
.reveal { opacity: 0; transform: translateY(22px); }
.reveal.in { animation: fadeUp .62s cubic-bezier(.22, .68, .36, 1) forwards; }
.reveal.d1 { animation-delay: .08s; }
.reveal.d2 { animation-delay: .16s; }
.reveal.d3 { animation-delay: .24s; }
.reveal.d4 { animation-delay: .32s; }

/* Живой индикатор */
.live-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--green);
  animation: pulseDot 2.1s ease-out infinite;
  flex-shrink: 0;
}

/* Луч сканирования в поле окна программы */
.app-scanbox .beam {
  position: absolute;
  top: 0; bottom: 0;
  width: 46px;
  background: linear-gradient(90deg, transparent, rgba(46, 125, 246, .28), transparent);
  animation: sweep 2.6s ease-in-out infinite;
}

.app-window.float { animation: floaty 7s ease-in-out infinite; }

.caret { display: inline-block; width: 1px; background: currentColor; animation: caret 1.1s steps(1) infinite; }

.counter { font-variant-numeric: tabular-nums; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ============================== Адаптив ============================== */
@media (max-width: 1080px) {
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .hero .lede { max-width: none; }
  .svc-shell { grid-template-columns: 1fr; }
  .kb-layout { grid-template-columns: 1fr; }
  .kb-side { position: static; }
  .kb-side ul { flex-direction: row; flex-wrap: wrap; }
  .grid-4, .addons { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .vid-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 34px; }
  .metrics { grid-template-columns: repeat(2, 1fr); gap: 26px; }
}

@media (max-width: 860px) {
  .header-row { gap: 10px; }
  .brand-ver { display: none; }
  .brand-name { font-size: 15px; max-width: min(42vw, 160px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

  .main-nav {
    display: none;
    position: absolute;
    left: 0; right: 0;
    top: 100%;
    z-index: 210;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    background: var(--d-900);
    border-bottom: 1px solid var(--d-line);
    padding: 16px 20px 22px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, .35);
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 12px 14px; font-size: 16px; }
  .main-nav .nav-cta-mobile {
    display: flex;
    margin-top: 8px;
    justify-content: center;
  }
  .burger {
    display: flex;
    margin-left: auto;
    flex-shrink: 0;
    z-index: 220;
  }
  .header-cta { display: none; }

  .section { padding: 62px 0; }
  .grid-2, .grid-3, .plans { grid-template-columns: 1fr; }
  .cta-band { padding: 42px 24px; }
  .form-grid, .row-2, .row-3 { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .grid-4, .addons, .vid-grid { grid-template-columns: 1fr; }
  .metrics { grid-template-columns: 1fr 1fr; }
  .app-cols { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .parse-row { flex-wrap: wrap; gap: 8px; }
  .parse-val { margin-left: 0; text-align: left; width: 100%; }
  .parse-name { min-width: 0; }
  .hero-actions .btn, .cta-actions .btn { width: 100%; }
}

@media print {
  .site-header, .site-footer, .cta-band, .burger { display: none; }
  body { background: #fff; }
}
