/* ==========================================================================
   Disconto - проверка подлинности кассовых чеков (B2B)
   Dark-tech. Onest (UI) + IBM Plex Mono (данные/чек). Один акцент: orange.
   Тема - тёмная, единая на всю страницу (Page Theme Lock).
   ========================================================================== */

:root {
  --bg:      #0E0F12;
  --bg-2:    #15161B;
  --bg-3:    #1C1E25;
  --ink:     #F2F0EB;
  --ink-soft:#A8A39A;
  --ink-mute:#6E6B63;
  --line:    rgba(242, 240, 235, .10);
  --line-2:  rgba(242, 240, 235, .06);
  --accent:  #FF6A1A;
  --accent-2:#FF8B4D;
  --accent-dim: rgba(255, 106, 26, .14);
  --on-accent: #0E0F12;
  --ok:      #57C98A;
  --paper:   #F6F3EC;  /* для карточки-чека (бумага) */
  --paper-ink:#1A1814;

  --maxw: 1280px;
  --gutter: clamp(20px, 5vw, 64px);
  --r: 12px;
  --r-sm: 9px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --ff-sans: 'Onest', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --ff-mono: 'IBM Plex Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--ff-sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: none; }
input, textarea { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--on-accent); }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }
section { padding-block: clamp(64px, 10vw, 140px); position: relative; }

/* ---------- Typography ---------- */
.h-xl { font-size: clamp(34px, 5.2vw, 64px); line-height: 1.04; letter-spacing: -.02em; font-weight: 800; }
.h-lg { font-size: clamp(28px, 4vw, 46px); line-height: 1.06; letter-spacing: -.02em; font-weight: 800; }
.lead { font-size: clamp(17px, 1.7vw, 20px); color: var(--ink-soft); line-height: 1.55; max-width: 58ch; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--ff-mono); font-size: 12.5px; font-weight: 500;
  letter-spacing: .12em; text-transform: uppercase; color: var(--accent);
}
.eyebrow::before { content: ""; width: 18px; height: 1px; background: var(--accent); }
.mono { font-family: var(--ff-mono); }

.section-head { max-width: 62ch; }
.section-head h2 { margin-top: 16px; }
.section-head p { margin-top: 18px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .55em;
  padding: 14px 26px; border-radius: var(--r-sm);
  font-size: 15px; font-weight: 600; letter-spacing: .01em; white-space: nowrap;
  transition: transform .2s var(--ease), background-color .25s var(--ease), border-color .25s var(--ease), color .25s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-2); }
.btn-ghost { border: 1px solid var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); background: rgba(242,240,235,.04); }
.btn-lg { padding: 17px 32px; font-size: 16px; }
.btn .arw { transition: transform .25s var(--ease); }
.btn:hover .arw { transform: translateX(3px); }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50; height: 72px;
  display: flex; align-items: center;
  transition: background-color .35s var(--ease), border-color .35s var(--ease), backdrop-filter .35s;
  border-bottom: 1px solid transparent;
}
.site-header.is-solid {
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: saturate(150%) blur(14px); -webkit-backdrop-filter: saturate(150%) blur(14px);
  border-bottom-color: var(--line);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 21px; letter-spacing: -.02em; }
.brand .dot { width: 10px; height: 10px; border-radius: 3px; background: var(--accent); }
.nav { display: flex; align-items: center; gap: clamp(16px, 2.2vw, 32px); }
.nav a { font-size: 15px; color: var(--ink-soft); transition: color .2s; }
.nav a:hover { color: var(--ink); }
.header-cta { display: flex; align-items: center; gap: 18px; }
.menu-toggle { display: none; width: 42px; height: 42px; align-items: center; justify-content: center; }
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after { content: ""; display: block; width: 22px; height: 2px; background: var(--ink); transition: .3s var(--ease); position: relative; }
.menu-toggle span::before { position: absolute; top: -7px; } .menu-toggle span::after { position: absolute; top: 7px; }
body.menu-open .menu-toggle span { background: transparent; }
body.menu-open .menu-toggle span::before { top: 0; transform: rotate(45deg); }
body.menu-open .menu-toggle span::after { top: 0; transform: rotate(-45deg); }

.mobile-nav { position: fixed; inset: 0; z-index: 45; background: var(--bg); display: flex; flex-direction: column; justify-content: center; gap: 6px; padding: var(--gutter); transform: translateY(-100%); transition: transform .45s var(--ease); visibility: hidden; }
body.menu-open .mobile-nav { transform: translateY(0); visibility: visible; }
.mobile-nav a { font-size: clamp(26px, 8vw, 38px); font-weight: 700; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.mobile-nav .btn { margin-top: 24px; justify-content: center; }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero { min-height: 100dvh; display: flex; align-items: center; padding-top: 96px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 50% at 78% 18%, rgba(255,106,26,.16), transparent 60%),
    radial-gradient(50% 40% at 12% 90%, rgba(255,106,26,.07), transparent 60%);
}
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 5vw, 72px); align-items: center; width: 100%; }
.hero h1 { margin-top: 22px; max-width: 18ch; }
.hero h1 .ac { color: var(--accent); }
.hero__sub { margin-top: 24px; max-width: 50ch; }
.hero__cta { margin-top: 36px; display: flex; gap: 14px; flex-wrap: wrap; }
.hero__chips { margin-top: 30px; display: flex; gap: 10px; flex-wrap: wrap; }
.chip { font-family: var(--ff-mono); font-size: 12.5px; color: var(--ink-soft); border: 1px solid var(--line); padding: 7px 13px; border-radius: 999px; }
.chip b { color: var(--accent); font-weight: 500; }

/* ---------- Receipt card (доменный артефакт продукта) ---------- */
.receipt-wrap { display: flex; justify-content: center; perspective: 1400px; }
.receipt {
  width: min(360px, 100%); background: var(--paper); color: var(--paper-ink);
  border-radius: 6px; padding: 26px 26px 0; font-family: var(--ff-mono); font-size: 13px;
  box-shadow: 0 40px 80px -30px rgba(0,0,0,.7), 0 0 0 1px rgba(0,0,0,.04);
  transform: rotate(-2.2deg); position: relative;
}
.receipt__top { display: flex; justify-content: space-between; align-items: flex-start; padding-bottom: 14px; border-bottom: 1px dashed rgba(26,24,20,.28); }
.receipt__top b { font-family: var(--ff-sans); font-weight: 800; font-size: 15px; letter-spacing: -.01em; }
.receipt__top span { color: #8a857a; font-size: 11px; }
.receipt__rows { padding: 14px 0; display: flex; flex-direction: column; gap: 9px; }
.receipt__rows .r { display: flex; justify-content: space-between; }
.receipt__rows .r span:first-child { color: #6f6a60; }
.receipt__tot { display: flex; justify-content: space-between; padding: 13px 0; border-top: 1px dashed rgba(26,24,20,.28); font-weight: 600; }
.receipt__fns { padding: 12px 0 18px; display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; border-top: 1px dashed rgba(26,24,20,.28); }
.receipt__fns .meta { font-size: 10.5px; line-height: 1.7; color: #6f6a60; }
.receipt__qr { width: 62px; height: 62px; border-radius: 5px; padding: 4px; background: var(--paper-ink);
  background-image:
    linear-gradient(45deg, var(--paper) 25%, transparent 25%, transparent 75%, var(--paper) 75%),
    linear-gradient(45deg, var(--paper) 25%, transparent 25%, transparent 75%, var(--paper) 75%);
  background-size: 11px 11px; background-position: 0 0, 5.5px 5.5px; background-origin: content-box; background-clip: content-box; }
.receipt__perf { height: 18px; margin: 0 -26px; background:
  radial-gradient(circle at 9px 18px, transparent 9px, var(--paper) 9px) repeat-x 0 0/18px 18px; }
.receipt__stamp {
  position: absolute; top: -14px; right: -10px; background: var(--ok); color: #06180f;
  font-family: var(--ff-sans); font-weight: 700; font-size: 12px; letter-spacing: .02em;
  padding: 7px 14px; border-radius: 6px; display: inline-flex; align-items: center; gap: 6px;
  box-shadow: 0 10px 24px -8px rgba(0,0,0,.5);
}
.receipt__stamp .tick { width: 7px; height: 11px; border: solid #06180f; border-width: 0 2px 2px 0; transform: rotate(42deg) translateY(-1px); }

/* ==========================================================================
   Logos / trust strip
   ========================================================================== */
.beam { border-block: 1px solid var(--line); background: var(--bg-2); }
.beam__inner { display: flex; align-items: center; gap: clamp(20px, 4vw, 48px); flex-wrap: wrap; justify-content: space-between; padding-block: 26px; }
.beam__item { display: flex; flex-direction: column; gap: 3px; }
.beam__item b { font-family: var(--ff-mono); font-size: clamp(22px, 3vw, 30px); font-weight: 600; }
.beam__item span { font-size: 13px; color: var(--ink-mute); }

/* ==========================================================================
   Features (bento)
   ========================================================================== */
.features { background: var(--bg); }
.bento { margin-top: clamp(36px, 5vw, 56px); display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.cell { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(24px, 2.5vw, 34px); display: flex; flex-direction: column; transition: border-color .3s var(--ease), transform .3s var(--ease), background-color .3s; }
.cell:hover { border-color: rgba(255,106,26,.4); transform: translateY(-3px); }
.cell--wide { grid-column: span 4; }
.cell--mid  { grid-column: span 3; }
.cell--sq   { grid-column: span 2; }
.cell--accent { background: linear-gradient(150deg, var(--accent-dim), transparent 70%), var(--bg-2); }
.cell__ix { font-family: var(--ff-mono); font-size: 13px; color: var(--accent); }
.cell h3 { font-size: clamp(20px, 2vw, 25px); font-weight: 700; margin-top: 16px; letter-spacing: -.01em; }
.cell p { margin-top: 10px; color: var(--ink-soft); font-size: 15.5px; }
.cell__big { margin-top: auto; padding-top: 22px; font-family: var(--ff-mono); font-size: clamp(30px, 4vw, 46px); font-weight: 600; color: var(--ink); line-height: 1; }
.cell__big small { display: block; font-family: var(--ff-sans); font-size: 14px; font-weight: 400; color: var(--ink-mute); margin-top: 8px; }

/* ==========================================================================
   How it works (flow)
   ========================================================================== */
.flow { background: var(--bg-2); border-block: 1px solid var(--line); }
.flow__grid { margin-top: clamp(40px, 5vw, 60px); display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.fstep { padding: 8px clamp(18px, 2vw, 28px) 8px 0; position: relative; }
.fstep:not(:last-child) { border-right: 1px solid var(--line); margin-right: clamp(18px, 2vw, 28px); }
.fstep__n { font-family: var(--ff-mono); font-size: 13px; color: var(--accent); }
.fstep__bar { height: 2px; background: var(--line); margin: 18px 0 22px; position: relative; overflow: hidden; }
.fstep__bar::after { content: ""; position: absolute; inset: 0; width: 38%; background: var(--accent); }
.fstep h3 { font-size: 21px; font-weight: 700; letter-spacing: -.01em; }
.fstep p { margin-top: 10px; color: var(--ink-soft); font-size: 15px; }

/* ==========================================================================
   Use-cases
   ========================================================================== */
.cases { background: var(--bg); }
.cases__grid { margin-top: clamp(36px, 5vw, 56px); display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.case { border: 1px solid var(--line); border-radius: var(--r); padding: clamp(26px, 2.6vw, 38px); display: flex; gap: 22px; align-items: flex-start; transition: border-color .3s; }
.case:hover { border-color: rgba(255,106,26,.4); }
.case__tag { font-family: var(--ff-mono); font-size: 12px; color: var(--accent); border: 1px solid var(--accent-dim); border-radius: 6px; padding: 8px 11px; white-space: nowrap; }
.case h3 { font-size: 22px; font-weight: 700; letter-spacing: -.01em; }
.case p { margin-top: 10px; color: var(--ink-soft); font-size: 15.5px; }

/* ==========================================================================
   Ecosystem
   ========================================================================== */
.eco { background: var(--bg-2); border-block: 1px solid var(--line); }
.eco__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.eco__links { display: flex; flex-direction: column; gap: 2px; margin-top: 30px; border-top: 1px solid var(--line); }
.eco__links a { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--line); transition: padding-left .3s var(--ease), color .3s; }
.eco__links a:hover { padding-left: 10px; color: var(--accent); }
.eco__links .nm { font-weight: 700; font-size: 18px; }
.eco__links .ds { font-size: 14px; color: var(--ink-mute); }
.soon { display: inline-flex; align-items: center; gap: 8px; font-family: var(--ff-mono); font-size: 12px; color: var(--accent); border: 1px dashed var(--accent-dim); border-radius: 999px; padding: 7px 14px; margin-top: 26px; }
.soon b { color: var(--ink); font-weight: 500; }

/* ==========================================================================
   CTA + form
   ========================================================================== */
.cta { background: var(--bg); }
.cta__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
.cta__intro .lead { margin-top: 20px; }
.cta__cards { margin-top: 36px; display: flex; flex-direction: column; gap: 2px; border-top: 1px solid var(--line); }
.cta__cards a { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 17px 0; border-bottom: 1px solid var(--line); transition: padding-left .3s var(--ease); }
.cta__cards a:hover { padding-left: 10px; }
.cta__cards .k { font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-mute); }
.cta__cards .v { font-weight: 600; font-size: 18px; }

.form { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(26px, 3vw, 40px); }
.field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.field label { font-size: 13px; font-weight: 500; color: var(--ink-soft); }
.field input, .field textarea { background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 14px 16px; font-size: 16px; color: var(--ink); transition: border-color .2s; }
.field input::placeholder, .field textarea::placeholder { color: var(--ink-mute); }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field textarea { resize: vertical; min-height: 92px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form .btn { width: 100%; justify-content: center; }
.form__note { margin-top: 14px; font-size: 12.5px; color: var(--ink-mute); line-height: 1.5; }
.form__note a { color: var(--ink-soft); text-decoration: underline; text-underline-offset: 2px; }
.form__status { margin-top: 14px; font-size: 14.5px; display: none; padding: 12px 14px; border-radius: var(--r-sm); }
.form__status.show { display: block; }
.form__status.ok { background: rgba(87,201,138,.12); color: var(--ok); }
.form__status.err { background: rgba(255,106,26,.12); color: var(--accent-2); }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { background: var(--bg); border-top: 1px solid var(--line); padding-block: clamp(48px, 7vw, 84px) 32px; }
.footer__top { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 36px; padding-bottom: 44px; border-bottom: 1px solid var(--line); }
.footer__brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 24px; letter-spacing: -.02em; }
.footer__brand .dot { width: 10px; height: 10px; border-radius: 3px; background: var(--accent); }
.footer__about { margin-top: 16px; color: var(--ink-mute); max-width: 38ch; font-size: 14.5px; }
.footer__col h4 { font-family: var(--ff-mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-mute); margin-bottom: 14px; font-weight: 500; }
.footer__col a, .footer__col p { display: block; color: var(--ink-soft); font-size: 15px; padding: 5px 0; }
.footer__col a:hover { color: var(--ink); }
.footer__bottom { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 24px; font-size: 12.5px; color: var(--ink-mute); }
.footer__bottom .mono { font-size: 12px; }

/* ==========================================================================
   Reveal
   ========================================================================== */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .07s; }
.reveal[data-d="2"] { transition-delay: .14s; }
.reveal[data-d="3"] { transition-delay: .21s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .receipt { transform: none; }
  * { scroll-behavior: auto; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .bento { grid-template-columns: repeat(4, 1fr); }
  .cell--wide { grid-column: span 4; } .cell--mid { grid-column: span 2; } .cell--sq { grid-column: span 2; }
  .flow__grid { grid-template-columns: repeat(2, 1fr); gap: 28px; }
  .fstep:not(:last-child) { border-right: none; margin-right: 0; }
}
@media (max-width: 860px) {
  .nav, .header-cta .btn { display: none; }
  .menu-toggle { display: flex; }
  .hero__grid, .cta__grid, .eco__grid { grid-template-columns: 1fr; }
  .hero { padding-top: 110px; min-height: auto; padding-bottom: 64px; }
  .receipt-wrap { margin-top: 8px; }
  .cases__grid { grid-template-columns: 1fr; }
  .footer__top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .bento { grid-template-columns: 1fr; }
  .cell--wide, .cell--mid, .cell--sq { grid-column: span 1; }
  .flow__grid { grid-template-columns: 1fr; }
  .case { flex-direction: column; gap: 14px; }
  .footer__top { grid-template-columns: 1fr; gap: 28px; }
  .hero__cta { flex-direction: column; align-items: stretch; } .hero__cta .btn { justify-content: center; }
}
