/* База знаний ReStar POS. Светлая тема, акцент — оранжевый ReStar, радиусы 12 px, лёгкие шрифты. */
:root {
  --bg: #f6f7f9; --card: #fff; --line: #e9ecef; --text: #212529; --muted: #6c757d; --soft: #868e96;
  --dark: #1f1f22; --accent: #f76707; --accent-2: #ffa94d; --accent-soft: #fff4e6; --green: #2f9e44; --green-soft: #ebfbee;
  --blue: #1c7ed6; --blue-soft: #e7f5ff; --red: #e03131; --red-soft: #fff5f5; --violet: #7048e8; --r: 12px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: Poppins, 'Segoe UI', system-ui, sans-serif; font-size: 15px; line-height: 1.6; color: var(--text); background: var(--bg); }
b, strong { font-weight: 500; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
code, kbd, .mono { font-family: Consolas, 'JetBrains Mono', monospace; font-size: .9em; }
code { background: #f1f3f5; border-radius: 6px; padding: 1px 6px; }
kbd { display: inline-block; min-width: 24px; text-align: center; padding: 1px 7px; border-radius: 6px; background: #fff; border: 1px solid #dee2e6; box-shadow: 0 2px 0 #dee2e6; font-size: .85em; }

/* шапка */
.top { position: sticky; top: 0; z-index: 30; height: 60px; display: flex; align-items: center; gap: 18px; padding: 0 20px; background: var(--dark); color: #e9ecef; }
.top-logo { display: flex; align-items: center; gap: 12px; color: #fff; }
.top-logo img { height: 30px; width: auto; display: block; }
.top-logo span { font-size: 13px; color: #adb5bd; padding-left: 12px; border-left: 1px solid #3a3a40; }
.search { position: relative; flex: 1; max-width: 520px; margin-left: auto; }
.search i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: #868e96; }
.search input { width: 100%; height: 40px; border-radius: var(--r); border: 1px solid #3a3a40; background: #2b2b30; color: #f1f3f5; padding: 0 14px 0 40px; font: inherit; font-size: 14px; outline: none; }
.search input:focus { border-color: var(--accent-2); }
.search-res { position: absolute; top: 46px; left: 0; right: 0; background: #fff; color: var(--text); border-radius: var(--r); box-shadow: 0 20px 50px -20px rgba(0, 0, 0, .45); overflow: hidden; display: none; max-height: 70vh; overflow-y: auto; }
.search-res.show { display: block; }
.search-res a { display: block; padding: 10px 14px; color: var(--text); border-bottom: 1px solid var(--line); }
.search-res a:hover, .search-res a.on { background: var(--accent-soft); text-decoration: none; }
.search-res small { display: block; color: var(--muted); font-size: 12.5px; }
.search-res mark { background: #ffe8cc; color: inherit; border-radius: 3px; }
.top-links { display: flex; gap: 6px; }
.top-links a { color: #ced4da; font-size: 13.5px; padding: 7px 12px; border-radius: var(--r); background: #2b2b30; display: inline-flex; gap: 6px; align-items: center; }
.top-links a:hover { background: #38383f; text-decoration: none; color: #fff; }
.burger { display: none; color: #fff; font-size: 22px; }

/* раскладка */
.layout { display: grid; grid-template-columns: 280px minmax(0, 1fr); min-height: calc(100vh - 60px); }
.side { position: sticky; top: 60px; height: calc(100vh - 60px); overflow-y: auto; padding: 18px 12px 40px; background: #fff; border-right: 1px solid var(--line); scrollbar-width: thin; }
.side-group { font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--soft); margin: 18px 10px 6px; }
.side-group:first-child { margin-top: 4px; }
.side a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--r); color: #495057; font-size: 14px; }
.side a i { font-size: 18px; color: #adb5bd; }
.side a:hover { background: var(--bg); text-decoration: none; }
.side a.on { background: var(--accent-soft); color: #c2410c; }
.side a.on i { color: var(--accent); }
.side a .new { margin-left: auto; font-size: 10.5px; background: var(--accent); color: #fff; border-radius: 999px; padding: 0 7px; }
.main { padding: 28px 40px 80px; min-width: 0; }
.article { max-width: 900px; margin: 0 auto; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* статья */
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: 8px; display: flex; gap: 6px; align-items: center; }
.crumbs i { font-size: 14px; }
.a-head { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 22px; }
.a-icon { width: 56px; height: 56px; border-radius: var(--r); display: flex; align-items: center; justify-content: center; font-size: 28px; background: var(--accent-soft); color: var(--accent); flex-shrink: 0; }
.article h1 { font-size: 30px; font-weight: 500; line-height: 1.2; margin: 0 0 6px; letter-spacing: -.01em; }
.lead { font-size: 16.5px; color: #495057; margin: 0; }
.meta { font-size: 12.5px; color: var(--soft); margin-top: 8px; display: flex; gap: 14px; flex-wrap: wrap; }
.article h2 { font-size: 21px; font-weight: 500; margin: 36px 0 12px; scroll-margin-top: 80px; display: flex; align-items: center; gap: 10px; }
.article h2 i { color: var(--accent); font-size: 20px; }
.article h3 { font-size: 16.5px; font-weight: 500; margin: 22px 0 8px; }
.article p { margin: 0 0 12px; }
.article ul:not(.plain), .article ol:not(.steps) { padding-left: 22px; margin: 0 0 14px; }
.article li { margin-bottom: 4px; }
.toc { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 8px; }
.toc a { font-size: 13px; padding: 4px 11px; border-radius: 999px; background: #fff; border: 1px solid var(--line); color: #495057; }
.toc a:hover { border-color: var(--accent-2); color: #c2410c; text-decoration: none; }

/* шаги */
.steps { list-style: none; padding: 0; margin: 0 0 16px; counter-reset: s; display: grid; gap: 10px; }
.steps > li { counter-increment: s; position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px 14px 60px; margin: 0; }
.steps > li::before { content: counter(s); position: absolute; left: 16px; top: 14px; width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff; font-size: 14px; display: flex; align-items: center; justify-content: center; }
.steps > li b:first-child { display: block; margin-bottom: 2px; }
.steps > li p:last-child { margin-bottom: 0; }

/* выноски */
.callout { display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--r); margin: 0 0 14px; font-size: 14.5px; border: 1px solid transparent; }
.callout i { font-size: 20px; flex-shrink: 0; margin-top: 1px; }
.callout > div > b:first-child { display: block; }
.callout.tip { background: var(--green-soft); border-color: #d3f9d8; } .callout.tip i { color: var(--green); }
.callout.warn { background: #fff9db; border-color: #ffec99; } .callout.warn i { color: #f08c00; }
.callout.info { background: var(--blue-soft); border-color: #d0ebff; } .callout.info i { color: var(--blue); }
.callout.danger { background: var(--red-soft); border-color: #ffe3e3; } .callout.danger i { color: var(--red); }
.callout.soon { background: #f3f0ff; border-color: #e5dbff; } .callout.soon i { color: var(--violet); }

/* таблицы полей */
.fields { width: 100%; border-collapse: separate; border-spacing: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; margin: 0 0 16px; font-size: 14px; }
.fields th { text-align: left; font-weight: 500; background: #f8f9fa; padding: 10px 14px; color: #495057; font-size: 13px; }
.fields td { padding: 10px 14px; border-top: 1px solid var(--line); vertical-align: top; }
.fields td:first-child { width: 30%; font-weight: 500; }
.fields td small { display: block; color: var(--muted); }
.req { color: var(--red); }

/* карточки */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; margin: 0 0 18px; }
.card { display: flex; flex-direction: column; gap: 6px; padding: 16px; border-radius: var(--r); background: #fff; border: 1px solid var(--line); color: var(--text); transition: transform .12s, box-shadow .2s, border-color .2s; }
.card:hover { transform: translateY(-2px); box-shadow: 0 16px 30px -22px rgba(0, 0, 0, .4); border-color: #ffd8a8; text-decoration: none; }
.card i { font-size: 24px; width: 44px; height: 44px; border-radius: var(--r); display: flex; align-items: center; justify-content: center; background: var(--accent-soft); color: var(--accent); }
.card b { font-size: 15.5px; }
.card small { color: var(--muted); font-size: 13px; line-height: 1.45; }
.card.c-blue i { background: var(--blue-soft); color: var(--blue); } .card.c-green i { background: var(--green-soft); color: var(--green); } .card.c-violet i { background: #f3f0ff; color: var(--violet); }

/* главная */
.hero { position: relative; overflow: hidden; border-radius: var(--r); padding: 34px 34px 30px; background: radial-gradient(120% 140% at 100% 0%, #ff922b 0%, #f76707 30%, #2b1a10 70%, #1f1f22 100%); color: #fff; margin-bottom: 22px; }
.hero h1 { font-size: 32px; font-weight: 500; margin: 0 0 8px; color: #fff; }
.hero p { margin: 0; max-width: 620px; color: #f1f3f5; font-size: 16px; }
.hero .hero-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.hero .hero-row a { background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .25); color: #fff; padding: 8px 14px; border-radius: var(--r); font-size: 14px; display: inline-flex; gap: 6px; align-items: center; }
.hero .hero-row a:hover { background: rgba(255, 255, 255, .24); text-decoration: none; }
.hero-art { position: absolute; right: -20px; bottom: -30px; font-size: 200px; opacity: .08; line-height: 1; }
.sec-title { font-size: 18px; font-weight: 500; margin: 26px 0 12px; }
.news { background: #fff; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.news-item { display: flex; gap: 14px; padding: 12px 16px; border-top: 1px solid var(--line); }
.news-item:first-child { border-top: 0; }
.news-item time { flex-shrink: 0; width: 90px; color: var(--muted); font-size: 13px; }
.news-item b { display: block; font-size: 14.5px; }
.news-item small { color: var(--muted); }

/* схемы */
.diagram { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 18px; margin: 0 0 16px; overflow-x: auto; }
.diagram svg { display: block; width: 100%; min-width: 640px; height: auto; }
.diagram figcaption { font-size: 13px; color: var(--muted); margin-top: 10px; text-align: center; }
.flowdot { animation: dash 1.4s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -24; } }

/* живые примеры */
.demo { position: relative; border-radius: var(--r); background: linear-gradient(160deg, #f1f3f5, #e9ecef); border: 1px solid var(--line); padding: 18px; margin: 0 0 18px; overflow: hidden; }
.demo-head { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 12px; }
.demo-head i { color: var(--accent); font-size: 16px; }
.demo-head .demo-ctl { margin-left: auto; display: flex; gap: 6px; }
.demo-head .demo-ctl button { width: 30px; height: 30px; border-radius: 8px; background: #fff; border: 1px solid var(--line); color: #495057; display: flex; align-items: center; justify-content: center; }
.demo-stage { position: relative; min-height: 300px; user-select: none; }
.demo-cap { margin-top: 12px; min-height: 44px; display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: #fff; border-radius: var(--r); font-size: 14px; border: 1px solid var(--line); }
.demo-cap .n { width: 24px; height: 24px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 12.5px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.cursor { position: absolute; z-index: 20; width: 22px; height: 22px; pointer-events: none; transition: left .7s cubic-bezier(.3, .9, .4, 1), top .7s cubic-bezier(.3, .9, .4, 1); left: 50%; top: 50%; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .35)); }
.cursor svg { width: 22px; height: 22px; display: block; }
.cursor.click::after { content: ""; position: absolute; left: -12px; top: -12px; width: 30px; height: 30px; border-radius: 50%; border: 3px solid var(--accent); animation: ping .5s ease-out forwards; }
@keyframes ping { from { transform: scale(.3); opacity: 1; } to { transform: scale(1.6); opacity: 0; } }
.hl { box-shadow: 0 0 0 3px rgba(247, 103, 7, .45) !important; transition: box-shadow .2s; }

/* мини-интерфейс кассы внутри примеров */
.m-pos { display: grid; grid-template-columns: 1fr 230px; gap: 10px; font-size: 12.5px; }
.m-pos.one { grid-template-columns: 1fr; }
.m-card { background: #fff; border-radius: var(--r); border: 1px solid var(--line); padding: 10px; }
.m-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.m-tile { background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.m-tile .ph { height: 54px; background: linear-gradient(160deg, #ffd8a8, #f08c00); display: flex; align-items: center; justify-content: center; font-size: 22px; color: #fff; }
.m-tile .t { padding: 6px 8px 0; font-size: 12px; line-height: 1.25; min-height: 30px; }
.m-tile .p { padding: 2px 8px 7px; color: #c2410c; font-weight: 500; font-size: 12px; }
.m-head { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; font-weight: 500; }
.m-head .sp { flex: 1; }
.m-btn { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; padding: 4px 8px; border-radius: 8px; background: #f1f3f5; color: #495057; }
.m-btn.o { background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff; }
.m-btn.dark { background: #212529; color: #fff; }
.m-line { display: flex; justify-content: space-between; gap: 6px; padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: 12px; }
.m-line small { display: block; color: var(--muted); font-size: 11px; }
.m-total { display: flex; justify-content: space-between; margin-top: 8px; font-size: 13px; }
.m-total b { font-size: 17px; }
.m-pays { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 6px; margin-top: 8px; }
.m-pays span { text-align: center; padding: 8px 0; border-radius: 9px; color: #fff; font-size: 11px; background: #364fc7; }
.m-pays span:first-child { background: var(--accent); }
.m-pays span:last-child { background: #5f3dc4; }
.m-modal { position: absolute; inset: 20px 40px; background: #fff; border-radius: var(--r); box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .5); padding: 14px; z-index: 10; display: none; }
.m-modal.show { display: block; animation: fade .2s ease; }
.m-modal h4 { margin: 0 0 10px; font-weight: 500; font-size: 14px; }
.m-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.m-grid span { height: 40px; border-radius: 9px; background: #f1f3f5; display: flex; align-items: center; justify-content: center; font-size: 14px; }
.m-grid span.busy { background: #fff4e6; color: #c2410c; }
.m-tabs { display: flex; gap: 6px; margin-top: 10px; }
.m-tab { padding: 6px 10px; border-radius: 9px; background: #fff; border: 1px solid var(--line); font-size: 11.5px; }
.m-tab.on { box-shadow: 0 0 0 2px var(--accent-2); }
.m-tab small { display: block; color: var(--muted); font-size: 10.5px; }
.m-chip { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; padding: 2px 7px; border-radius: 6px; background: var(--green-soft); color: var(--green); }
.m-pad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.m-pad span { height: 30px; border-radius: 8px; background: #f1f3f5; display: flex; align-items: center; justify-content: center; }
.m-big { font-size: 26px; font-weight: 500; padding: 6px 12px; border: 2px solid var(--accent-2); border-radius: 10px; background: #fffaf5; margin-bottom: 6px; }
.m-scale { display: flex; align-items: center; gap: 6px; font-size: 12px; background: #f1f3f5; border-radius: 9px; padding: 6px 8px; margin-bottom: 8px; }
.m-lamp { width: 9px; height: 9px; border-radius: 50%; background: #fab005; }
.m-lamp.ok { background: #40c057; box-shadow: 0 0 0 3px rgba(64, 192, 87, .2); }
.m-win { background: #fff; border-radius: var(--r); border: 1px solid var(--line); overflow: hidden; }
.m-win-bar { height: 26px; background: #f1f3f5; display: flex; align-items: center; gap: 5px; padding: 0 10px; font-size: 11px; color: var(--muted); }
.m-win-bar i { width: 9px; height: 9px; border-radius: 50%; background: #dee2e6; display: inline-block; }
.m-win-body { padding: 12px; font-size: 12.5px; }
.m-field { margin-bottom: 8px; }
.m-field label { display: block; font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.m-field .in { border: 1px solid #dee2e6; border-radius: 8px; padding: 5px 8px; min-height: 28px; font-family: Consolas, monospace; font-size: 12px; background: #fff; }
.m-dot { display: inline-flex; align-items: center; gap: 6px; margin-right: 14px; }
.m-dot::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: #ced4da; }
.m-dot.ok::before { background: #40c057; box-shadow: 0 0 0 3px rgba(64, 192, 87, .2); }

/* код и списки ссылок */
.copy { position: relative; }
.copy pre { background: #1f1f22; color: #e9ecef; border-radius: var(--r); padding: 14px 16px; overflow-x: auto; font-size: 13px; margin: 0 0 14px; }
.copy button { position: absolute; top: 8px; right: 8px; font-size: 12px; color: #adb5bd; background: #2b2b30; border-radius: 8px; padding: 3px 9px; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 40px; }
.pager a { padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r); background: #fff; color: var(--text); }
.pager a:hover { border-color: #ffd8a8; text-decoration: none; }
.pager a small { display: block; color: var(--muted); font-size: 12px; }
.pager a.next { text-align: right; }
.badges { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 14px; }
.badge { font-size: 12px; padding: 2px 9px; border-radius: 999px; background: #f1f3f5; color: #495057; }
.badge.ok { background: var(--green-soft); color: var(--green); }
.badge.wait { background: #fff9db; color: #e67700; }

@media (max-width: 960px) {
  .layout { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 40; top: 60px; left: 0; width: 290px; transform: translateX(-105%); transition: transform .2s; box-shadow: 20px 0 50px -30px rgba(0, 0, 0, .5); }
  .side.open { transform: none; }
  .burger { display: block; }
  .main { padding: 20px 16px 60px; }
  .top-links, .top-logo span { display: none; }
  .m-pos { grid-template-columns: 1fr; }
  .article h1 { font-size: 25px; }
}

/* ---------- живые примеры: детали мини-интерфейса ---------- */
[hidden] { display: none !important; }
.m-tile .ph { background: #f1f3f5 center / cover no-repeat; }
.m-check { display: flex; flex-direction: column; }
.m-check .ttl { font-weight: 500; }
.m-lines { min-height: 60px; }
.m-empty { color: var(--soft); text-align: center; padding: 22px 0; font-size: 12px; }
.m-muted { color: var(--soft); font-size: 11.5px; display: inline-flex; gap: 4px; align-items: center; }
.m-x { display: flex; justify-content: center; gap: 14px; margin-top: 7px; font-size: 11px; color: var(--muted); }
.m-x span { display: inline-flex; gap: 3px; align-items: center; }
.m-modal { inset: auto; top: 12px; left: 50%; transform: translateX(-50%); width: min(500px, 94%); overflow: hidden; }
.m-modal h4 { display: flex; align-items: center; gap: 6px; }
.m-modal h4 i { color: var(--accent); }
.m-foot { display: flex; justify-content: flex-end; align-items: center; gap: 6px; margin-top: 10px; }
.m-foot .m-btn { padding: 7px 12px; font-size: 12px; }
.m-sel { box-shadow: 0 0 0 2px var(--accent) !important; background: var(--accent-soft) !important; }
.m-cfg-hero { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
.m-cfg-hero .ph { width: 54px; height: 42px; border-radius: 9px; background: #f1f3f5 center / cover; flex-shrink: 0; }
.m-cfg-hero b { display: block; font-weight: 500; font-size: 13px; }
.m-cfg-hero small { color: var(--muted); font-size: 11.5px; }
.m-cfg-row { display: grid; grid-template-columns: 1fr 150px; gap: 10px; align-items: start; }
.m-presets { display: flex; gap: 5px; flex-wrap: wrap; }
.m-presets span { font-size: 11px; padding: 4px 8px; border-radius: 8px; background: #f1f3f5; }
.m-sum { margin-right: auto; font-size: 18px; font-weight: 500; }
.m-pad span.ok { background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff; }
.m-lamp.off { background: #ced4da; }
.m-scale .sp { flex: 1; }
.m-scale .m-btn { background: #fff; }
.m-cfg-solo { max-width: 520px; margin: 0 auto; }
.m-sub { font-size: 11px; color: var(--muted); margin: 8px 0 4px; }
.m-proto { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; }
.m-proto span { padding: 6px 7px; border-radius: 9px; background: #f1f3f5; border: 2px solid transparent; font-size: 11px; }
.m-proto span b { display: block; font-weight: 500; }
.m-proto span small { color: var(--muted); font-size: 10px; }
.m-proto span.on { border-color: var(--accent); background: var(--accent-soft); }
.m-baud { display: flex; gap: 5px; margin-bottom: 8px; }
.m-baud span { padding: 5px 10px; border-radius: 8px; background: #f1f3f5; font-size: 11.5px; }
.m-baud span.on { background: #212529; color: #fff; }
.m-dialog { position: absolute; z-index: 15; top: 30px; left: 50%; transform: translateX(-50%); width: min(380px, 90%); background: #fff; border-radius: 10px; box-shadow: 0 24px 60px -16px rgba(0, 0, 0, .55); padding: 14px; font-size: 12px; display: none; }
.m-dialog.show { display: block; animation: fade .2s ease; }
.m-dlg-t { margin-bottom: 10px; }
.m-dlg-list { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.m-dlg-list span { display: block; padding: 7px 10px; border-bottom: 1px solid var(--line); }
.m-dlg-list span:last-child { border-bottom: 0; }
.m-dlg-list span.m-sel { box-shadow: none !important; background: #e7f5ff !important; }
.m-dlg-f { display: flex; justify-content: flex-end; gap: 6px; margin-top: 10px; }
.m-btn.blue { background: #1c7ed6; color: #fff; }
.m-btn.dis { opacity: .45; }
.m-scanner { position: relative; display: flex; align-items: center; gap: 8px; margin-top: 10px; padding: 8px 10px; border-radius: 10px; background: #212529; color: #fff; width: max-content; overflow: hidden; }
.m-scanner i { font-size: 20px; color: var(--accent-2); }
.m-scanner small { color: #adb5bd; font-size: 11px; }
.m-scanner .beam { position: absolute; left: 0; top: 50%; height: 2px; width: 100%; background: #ff6b6b; box-shadow: 0 0 10px #ff6b6b; opacity: 0; }
.m-scanner.go .beam { animation: beam .6s ease 2; }
@keyframes beam { 0% { opacity: 0; transform: translateY(-14px); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }
.m-toast { position: absolute; z-index: 25; left: 50%; bottom: 12px; transform: translate(-50%, 20px); opacity: 0; background: #212529; color: #fff; padding: 8px 14px; border-radius: 10px; font-size: 12.5px; display: flex; gap: 6px; align-items: center; transition: .25s; pointer-events: none; white-space: nowrap; }
.m-toast i { color: #69db7c; }
.m-toast.err { background: #c92a2a; }
.m-toast.err i { color: #fff; }
.m-toast.show { opacity: 1; transform: translate(-50%, 0); }
.m-search { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px; background: #f1f3f5; margin-bottom: 10px; color: var(--muted); }
.m-search .sp { flex: 1; }
.m-search i { font-size: 16px; }
.m-cam { position: relative; height: 170px; border-radius: 10px; background: radial-gradient(circle at 50% 45%, #495057, #212529); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.m-dm { width: 90px; height: 90px; fill: #f8f9fa; background: #212529; padding: 6px; border-radius: 4px; transform: rotate(-6deg); }
.m-scanline { position: absolute; left: 12%; right: 12%; height: 2px; background: var(--accent-2); box-shadow: 0 0 12px var(--accent-2); top: 15%; opacity: 0; }
.m-cam.go .m-scanline { animation: scanl 1.1s ease-in-out infinite alternate; opacity: 1; }
@keyframes scanl { to { top: 85%; } }
.m-frame { position: absolute; width: 120px; height: 120px; border: 3px solid rgba(255, 255, 255, .6); border-radius: 12px; transition: .2s; }
.m-cam.ok .m-frame { border-color: #40c057; box-shadow: 0 0 0 6px rgba(64, 192, 87, .25); }
.m-cam.ok .m-scanline { display: none; }
.m-cam-cap { font-size: 12px; color: var(--muted); margin-top: 8px; text-align: center; }
.m-bar { display: flex; align-items: center; gap: 7px; padding: 7px 9px; border-radius: 9px; border: 1px dashed #ced4da; margin-bottom: 6px; font-size: 12px; }
.m-bar i { color: var(--accent); font-size: 15px; }
.m-bar small { margin-left: auto; color: var(--muted); font-size: 10.5px; }
.m-bar.on { border-style: solid; border-color: #ffd8a8; background: #fffaf5; }
.m-ini { width: 26px; height: 26px; border-radius: 50%; background: linear-gradient(160deg, #ffc078, #f76707); color: #fff; font-size: 10.5px; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.m-res { display: flex; align-items: center; gap: 9px; padding: 8px; border-radius: 10px; border: 1px solid var(--line); font-size: 12px; }
.m-res b { display: block; font-weight: 500; }
.m-res small { color: var(--muted); font-size: 11px; }
.m-res .m-chip { margin-left: auto; }
.m-bonus { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 9px; border-radius: 9px; background: #fff4e6; margin-top: 6px; font-size: 12px; }
.m-bonus small { display: block; color: var(--muted); font-size: 10.5px; }
.m-sw { width: 34px; height: 20px; border-radius: 999px; background: #ced4da; position: relative; flex-shrink: 0; transition: .2s; }
.m-sw::after { content: ""; position: absolute; left: 2px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: .2s; }
.m-sw.on { background: var(--accent); }
.m-sw.on::after { left: 16px; }
.m-kinds { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-bottom: 8px; }
.m-kinds span { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0; border-radius: 9px; background: #f1f3f5; font-size: 11.5px; }
.m-kinds i { font-size: 17px; color: #495057; }
.m-part { display: flex; align-items: center; gap: 8px; padding: 7px 9px; border-radius: 9px; border: 1px solid var(--line); margin-bottom: 5px; font-size: 12px; animation: fade .25s ease; }
.m-part i { color: var(--accent); font-size: 16px; }
.m-part span { flex: 1; }
.m-part small { display: block; color: var(--muted); font-size: 10.5px; }
.m-left { text-align: right; font-size: 12px; color: var(--muted); }
.m-left b { color: var(--text); font-weight: 500; }
.m-done { text-align: center; padding: 26px 0; }
.m-done i { font-size: 44px; color: var(--green); display: block; }
.m-done b { display: block; font-weight: 500; font-size: 15px; }
.m-done small { color: var(--muted); }
.m-paper { margin: 0 auto; width: max-content; max-width: 100%; background: #fffef8; border: 1px solid #f1f3f5; box-shadow: 0 8px 20px -14px rgba(0, 0, 0, .4); padding: 10px 12px; font: 10.5px/1.35 Consolas, monospace; color: #343a40; max-height: 210px; overflow: hidden; transition: transform .8s ease, opacity .8s ease; }
.m-paper.out { transform: translateY(-40px); opacity: 0; }
.m-login { background: radial-gradient(120% 120% at 0% 0%, #2b2b30, #1a1a1d); border-radius: var(--r); padding: 18px; color: #f1f3f5; min-height: 290px; display: flex; align-items: center; justify-content: center; }
.m-login > div { width: 100%; max-width: 380px; text-align: center; }
.m-lt { font-size: 17px; font-weight: 500; margin-bottom: 14px; }
.m-people { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.m-people span { background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); border-radius: 12px; padding: 10px 6px; }
.m-people img, .m-who img { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; display: block; margin: 0 auto 5px; }
.m-people b { display: block; font-weight: 500; font-size: 12.5px; }
.m-people small { color: #adb5bd; font-size: 10.5px; }
.m-who { display: flex; align-items: center; gap: 10px; justify-content: center; margin-bottom: 10px; text-align: left; }
.m-who img { width: 36px; height: 36px; margin: 0; }
.m-who b { display: block; font-weight: 500; }
.m-who small { color: #adb5bd; font-size: 11px; }
.m-dots { display: flex; gap: 10px; justify-content: center; margin-bottom: 10px; }
.m-dots i { width: 12px; height: 12px; border-radius: 50%; border: 2px solid #868e96; transition: .15s; }
.m-dots i.f { background: var(--accent-2); border-color: var(--accent-2); }
.m-login .m-pad { max-width: 210px; margin: 0 auto; }
.m-login .m-pad span { background: rgba(255, 255, 255, .08); color: #f1f3f5; height: 32px; }
.m-lbl { font-size: 11px; color: #adb5bd; }
.m-amount { font-size: 28px; font-weight: 500; margin: 2px 0 8px; }
.m-login .m-presets { justify-content: center; margin-bottom: 12px; }
.m-login .m-presets span { background: rgba(255, 255, 255, .08); color: #f1f3f5; }
.m-go { display: inline-flex; align-items: center; gap: 6px; padding: 9px 18px; border-radius: 10px; background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff; font-size: 13px; }
.m-go.done { background: #2f9e44; }
.m-ints { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.m-ints > span { display: flex; align-items: center; gap: 9px; padding: 10px; border-radius: 10px; border: 1px solid var(--line); }
.m-ints b { width: 30px; height: 30px; border-radius: 8px; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; justify-content: center; font-weight: 500; font-size: 12px; flex-shrink: 0; }
.m-ints small { display: block; color: var(--muted); font-size: 10.5px; }
.m-keyrow { display: flex; gap: 6px; align-items: center; }
.m-keyrow .in { flex: 1; }
.m-st { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.m-st small { color: var(--muted); font-size: 11px; }

/* ---------- схемы ---------- */
.fn-box { fill: #fff; stroke: #e9ecef; stroke-width: 1.5; }
.fn-box.hot { fill: #fffaf5; stroke: #ffd8a8; }
.fn-box.dark { fill: #f8f9fa; stroke: #dee2e6; }
.fn-ic { fill: #fff4e6; }
.fn-ic.blue { fill: #e7f5ff; } .fn-ic.green { fill: #ebfbee; } .fn-ic.dark { fill: #212529; } .fn-ic.hot { fill: #ffe8cc; }
.fn-g { font-family: remixicon; font-size: 23px; fill: #f76707; }
.fn-g.blue { fill: #1c7ed6; } .fn-g.green { fill: #2f9e44; } .fn-g.dark { fill: #ffa94d; }
.fn-t { font-size: 16px; font-weight: 500; fill: #212529; font-family: Poppins, "Segoe UI", sans-serif; }
.fn-s { font-size: 13px; fill: #6c757d; font-family: Poppins, "Segoe UI", sans-serif; }
.fn-l { fill: none; stroke: #dee2e6; stroke-width: 2; }
.fn-a { fill: none; stroke: #f76707; stroke-width: 3; stroke-linecap: round; stroke-dasharray: 2 14; animation: dash 1.1s linear infinite; }
.fn-a.rev { stroke: #1c7ed6; animation-direction: reverse; stroke-dashoffset: 8; }
@keyframes dash { to { stroke-dashoffset: -32; } }
.fn-lab { font-size: 13px; fill: #868e96; paint-order: stroke; stroke: #fff; stroke-width: 4px; font-family: Poppins, "Segoe UI", sans-serif; }
.fn-zone { fill: #f8fbff; stroke: #a5d8ff; stroke-width: 1.5; stroke-dasharray: 6 5; }
.fn-zl { font-size: 12.5px; fill: #1c7ed6; font-family: Poppins, "Segoe UI", sans-serif; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); margin: -6px 0 16px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 18px; height: 3px; border-radius: 2px; background: var(--accent); display: inline-block; }
.legend i.b { background: var(--blue); }

@media (max-width: 960px) {
  .m-cfg-row { grid-template-columns: 1fr; }
  .m-proto { grid-template-columns: repeat(2, 1fr); }
  .demo-stage { min-height: 360px; }
}
.m-sp-top { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 8px; }
.m-sp-top small { display: block; color: var(--muted); font-size: 11px; }
.m-sp-top b { font-size: 20px; font-weight: 500; }
.m-even { font-size: 11px; color: var(--muted); display: flex; gap: 4px; align-items: center; }
.m-even span { width: 24px; height: 24px; border-radius: 7px; background: #f1f3f5; color: var(--text); display: inline-flex; align-items: center; justify-content: center; }
.m-sprow { display: flex; align-items: center; gap: 5px; padding: 6px; border-radius: 9px; border: 1px solid var(--line); margin-bottom: 5px; font-size: 11px; }
.m-sprow .n { width: 18px; height: 18px; border-radius: 50%; background: #f1f3f5; display: inline-flex; align-items: center; justify-content: center; font-size: 10.5px; }
.m-k { display: inline-flex; align-items: center; gap: 3px; padding: 4px 6px; border-radius: 7px; background: #f1f3f5; color: #495057; }
.m-k.on { background: #212529; color: #fff; }
.m-sprow .in { flex: 1; min-width: 50px; height: 26px; border: 1px solid #dee2e6; border-radius: 7px; padding: 4px 7px; font-size: 12px; }
.m-sprow .in.sm { flex: 0 0 62px; min-width: 0; }
.m-sprow .in.sm:empty::before { content: "дал"; color: #adb5bd; }
.m-sprow .sm-gap { flex: 0 0 62px; }
.m-rest { color: var(--accent); font-size: 11px; padding: 4px 6px; border-radius: 7px; background: var(--accent-soft); }
.m-left .ok { color: var(--green); }
.m-scale .m-btn.o { background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff; }
.m-bar > span:not(.m-ini) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.m-bar small { white-space: nowrap; }
.m-win.m-dark { background: #17171a; border-color: #2a2a30; color: #f1f3f5; }
.m-win.m-dark .m-win-bar { background: #222226; color: #a1a6ad; }
.m-win.m-dark .m-field label { color: #a1a6ad; }
.m-win.m-dark .m-field .in { background: rgba(0,0,0,.3); border-color: #34343a; color: #f1f3f5; }
.m-keyok { font-size: 11.5px; color: #8ce99a; margin-top: 4px; min-height: 16px; }
.m-win .m-st .sp { flex: 1; }
.m-win.m-dark .m-st small { color: #a1a6ad; margin-right: 10px; }
.dl { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 12px; background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff !important; text-decoration: none !important; box-shadow: 0 10px 24px -12px rgba(247,103,7,.8); }
.dl i { font-size: 18px; }

/* онлайн-оплата Т-Банка: мини-кабинет Т-Бизнеса и карточка панели ReStar */
.tb-win { position: relative; max-width: 560px; margin: 0 auto; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 0 0 10px; font-size: 12.5px; overflow: hidden; }
.tb-bar { display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: #f6f7f8; border-bottom: 1px solid var(--line); margin-bottom: 8px; overflow: hidden; white-space: nowrap; }
.tb-logo { width: 24px; height: 24px; border-radius: 7px; background: #ffdd2d; color: #222; display: flex; align-items: center; justify-content: center; font-weight: 500; flex: none; }
.tb-logo.rs { background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff; }
.tb-nav { color: var(--muted); }
.tb-nav.on { color: var(--text); box-shadow: inset 0 -2px 0 #222; padding-bottom: 2px; }
.tb-bar.rs .tb-nav.on { box-shadow: none; }
.tb-scr { display: none; padding: 0 12px; }
.tb-scr.on { display: block; animation: fade .2s ease; }
.tb-sub, .tb-tabs { display: flex; gap: 14px; color: var(--muted); padding: 2px 0 10px; border-bottom: 1px solid var(--line); margin-bottom: 10px; overflow-x: auto; white-space: nowrap; }
.tb-tabs span.on, .tb-sub span.on { color: var(--text); box-shadow: inset 0 -2px 0 #ffdd2d; }
.tb-h { font-size: 16px; font-weight: 500; margin: 4px 0 10px; }
.tb-back { color: var(--muted); font-size: 11.5px; margin: 2px 0 6px; }
.tb-shop { position: relative; display: grid; gap: 2px; padding: 12px; border-radius: 12px; box-shadow: 0 4px 16px -6px rgba(0, 0, 0, .18); max-width: 300px; }
.tb-shop small { color: var(--blue); }
.tb-shop b { font-size: 14px; }
.tb-ok { font-style: normal; font-size: 11px; color: #2b8a3e; }
.tb-ok::before { content: '● '; }
.tb-box { display: grid; gap: 6px; padding: 14px; border-radius: 14px; box-shadow: 0 4px 16px -6px rgba(0, 0, 0, .18); max-width: 380px; }
.tb-box b { font-size: 14px; font-weight: 500; }
.tb-box small { color: var(--muted); }
.tb-yb { justify-self: start; padding: 7px 14px; border-radius: 9px; background: #ffdd2d; color: #222; }
.tb-row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; margin: 0 12px 6px; border-radius: 12px; border: 1px solid var(--line); }
.tb-scr .tb-row { margin: 0 0 6px; }
.tb-row small { display: block; color: var(--muted); font-size: 11px; }
.tb-row .tb-sw, .tb-row .tb-go { margin-left: auto; }
.tb-ic { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 12px; flex: none; }
.tb-ic.tp { background: #ffdd2d; color: #222; } .tb-ic.sp { background: #21a038; } .tb-ic.ap { background: #ef3124; } .tb-ic.mp { background: #0f754e; }
.tb-ic.sbp { background: linear-gradient(135deg, #5b57a2, #1d9ad6, #f6a119); } .tb-ic.card { background: #adb5bd; } .tb-ic.cash { background: #74b816; }
.tb-sw { position: relative; width: 38px; height: 22px; border-radius: 11px; background: #e9ecef; transition: background .2s; flex: none; }
.tb-sw::after { content: ''; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: left .2s; }
.tb-sw.on { background: #ffdd2d; } .tb-sw.on.o { background: var(--accent); } .tb-sw.on::after { left: 19px; }
.tb-sw.dis { opacity: .4; }
.tb-go { color: var(--muted); font-size: 18px; }
.tb-kv { display: grid; gap: 3px; margin-bottom: 10px; }
.tb-kv small { color: var(--muted); }
.tb-kv div { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; }
.tb-copy { margin-left: auto; color: var(--blue); font-size: 11.5px; }
.tb-acq span small { display: block; }
.tb-acqbody { margin: -2px 12px 6px; padding: 10px 12px; border: 1px solid var(--line); border-top: 0; border-radius: 0 0 12px 12px; display: grid; gap: 8px; }
.tb-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.tb-chips span { padding: 4px 10px; border-radius: 16px; border: 1px solid var(--accent); color: var(--accent); background: var(--accent-soft); font-size: 11.5px; }
.tb-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tb-fields small { color: var(--muted); font-size: 11px; }
.tb-in { min-height: 30px; padding: 6px 9px; border: 1px solid var(--line); border-radius: 8px; font-family: Consolas, monospace; }
.tb-ob { justify-self: start; padding: 7px 14px; border-radius: 9px; background: linear-gradient(160deg, var(--accent-2), var(--accent)); color: #fff; }
.tb-good { padding: 8px 10px; border-radius: 9px; background: var(--green-soft); color: var(--green); font-size: 12px; }
@media (max-width: 560px) { .tb-fields { grid-template-columns: 1fr; } .tb-win { font-size: 12px; } }

/* узкий экран: длинные строки не распирают пример */
.tb-win { max-width: 100%; min-width: 0; }
.tb-row > span:not([class]) { flex: 1; min-width: 0; }
.tb-fields > div, .tb-kv div { min-width: 0; }
.tb-kv code, .tb-in, .tb-bar .tb-nav { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
