/* ══════════════════════════════════════════════════════════════════
   ИП Писцов Д. Д. — фирменный стиль «чернила и латунь»
   Единая система с коммерческим предложением.
   ══════════════════════════════════════════════════════════════════ */

:root {
  --ink:        #0D1117;
  --ink-soft:   #1C2430;
  --ink-line:   #2A323E;
  --brass:      #B4924F;
  --brass-lt:   #D4B679;
  --text:       #22262B;
  --muted:      #7C7568;
  --hair:       #DFDAD1;
  --surface:    #F7F5F1;
  --paper:      #FFFFFF;

  --sans: -apple-system, BlinkMacSystemFont, "Helvetica Neue", "Segoe UI",
          "PT Sans", Arial, sans-serif;
  --serif: "PT Serif", Georgia, "Times New Roman", serif;

  --wrap: 1080px;
  --gut: clamp(20px, 5vw, 56px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--serif);
  font-size: 17px;
  line-height: 1.65;
  color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }

a { color: inherit; }

/* ── Разрядка для мелких прописных лейблов ───────────────────────── */
.label {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}
.label.brass { color: var(--brass); }

/* ── Шапка ───────────────────────────────────────────────────────── */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(13, 17, 23, .92);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--ink-line);
}
.topbar .wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: 62px;
}
.brand {
  font-family: var(--sans); font-weight: 500; font-size: 13px;
  letter-spacing: .18em; text-transform: uppercase;
  color: #fff; text-decoration: none; white-space: nowrap;
}
.brand span { color: var(--brass); }
.nav { display: flex; gap: 28px; align-items: center; }
.nav a {
  font-family: var(--sans); font-size: 13px; letter-spacing: .04em;
  color: #A8AEB8; text-decoration: none; transition: color .18s;
}
.nav a:hover { color: var(--brass-lt); }
.nav a.cta {
  color: var(--ink); background: var(--brass);
  padding: 9px 18px; font-weight: 500;
}
.nav a.cta:hover { background: var(--brass-lt); color: var(--ink); }
.burger {
  display: none; background: none; border: 0; cursor: pointer;
  padding: 8px; color: #fff;
}
.burger span {
  display: block; width: 22px; height: 1.5px; background: currentColor;
  margin: 5px 0; transition: transform .2s, opacity .2s;
}

/* ── Первый экран ────────────────────────────────────────────────── */
.hero {
  position: relative; overflow: hidden;
  background: var(--ink); color: #fff;
  padding: clamp(72px, 12vw, 148px) 0 clamp(56px, 9vw, 104px);
}
.hero-mono {
  position: absolute; right: -.05em; bottom: -.28em; z-index: 1;
  font-family: var(--sans); font-weight: 200; font-size: clamp(220px, 34vw, 460px);
  color: #161D28; line-height: .8; pointer-events: none; user-select: none;
  transition: transform .5s cubic-bezier(.22,.61,.36,1);
}
.hero .wrap { position: relative; z-index: 2; }
.hero h1 {
  font-family: var(--sans); font-weight: 200;
  font-size: clamp(34px, 6.4vw, 62px); line-height: 1.1;
  margin: 20px 0 0; letter-spacing: -.015em;
}
.hero h1 em { font-style: normal; color: var(--brass); }
.rule-brass {
  width: 84px; height: 2px; background: var(--brass);
  margin: 30px 0 26px; border: 0;
}
.hero p.lead {
  font-size: clamp(17px, 2.1vw, 20px); line-height: 1.6;
  color: #C3C9D2; max-width: 47ch; margin: 0;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 38px; }

.btn {
  display: inline-block; font-family: var(--sans); font-size: 14px;
  font-weight: 500; letter-spacing: .03em; text-decoration: none;
  padding: 14px 28px; transition: background .18s, color .18s, border-color .18s;
}
.btn-primary { background: var(--brass); color: var(--ink); }
.btn-primary:hover { background: var(--brass-lt); }
.btn-ghost { border: 1px solid var(--ink-line); color: #D8DDE4; }
.btn-ghost:hover { border-color: var(--brass); color: var(--brass-lt); }

/* ── Цифры ───────────────────────────────────────────────────────── */
.stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 0; margin-top: clamp(48px, 8vw, 84px);
  border-top: 1px solid var(--ink-line); padding-top: 32px;
}
.stats > div { padding-right: 24px; }
.stats > div + div { border-left: 1px solid var(--ink-line); padding-left: 28px; }
.stats b {
  display: block; font-family: var(--sans); font-weight: 200;
  font-size: clamp(26px, 4vw, 38px); color: var(--brass); line-height: 1.1;
}
.stats > div > span {           /* только подпись, не цифра внутри <b> */
  display: block; margin-top: 8px; font-family: var(--sans);
  font-size: 12.5px; color: #8B929C; line-height: 1.45;
}
.stats b .count { font: inherit; color: inherit; display: inline; margin: 0; }

/* ── Секции ──────────────────────────────────────────────────────── */
section { padding: clamp(64px, 9vw, 108px) 0; }
section.alt { background: var(--surface); }

.sec-head { margin-bottom: 44px; }
.sec-head .num {
  font-family: var(--sans); font-weight: 200; font-size: 42px;
  color: var(--brass); line-height: 1; margin-right: 16px;
}
.sec-head h2 {
  display: inline; font-family: var(--sans); font-weight: 200;
  font-size: clamp(25px, 3.6vw, 34px); color: var(--ink);
  letter-spacing: -.01em;
}
.sec-head .bar { display: flex; align-items: baseline; }
.sec-head hr {
  border: 0; border-top: 1px solid var(--hair); margin: 18px 0 0;
  position: relative;
}
.sec-head hr::before {
  content: ""; position: absolute; top: -1px; left: 0;
  width: 58px; border-top: 2px solid var(--brass);
}
.sec-intro { font-size: 19px; line-height: 1.6; color: var(--ink-soft); max-width: 62ch; }

/* ── Карточки услуг ──────────────────────────────────────────────── */
.grid { display: grid; gap: 1px; background: var(--hair); border: 1px solid var(--hair); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card { background: var(--paper); padding: 32px 30px 34px; }
section.alt .card { background: var(--surface); }
.card .n {
  font-family: var(--sans); font-weight: 200; font-size: 22px;
  color: var(--brass); display: block; margin-bottom: 14px;
}
.card h3 {
  font-family: var(--sans); font-weight: 500; font-size: 16px;
  margin: 0 0 12px; color: var(--ink); line-height: 1.35;
}
.card p { margin: 0; font-size: 15.5px; line-height: 1.6; color: var(--text); }
.card ul { margin: 12px 0 0; padding-left: 18px; font-size: 15px; color: var(--muted); }
.card li { margin: 5px 0; }

/* ── Принципы работы ─────────────────────────────────────────────── */
.principles { border-top: 1px solid var(--ink); }
.principle {
  display: grid; grid-template-columns: 64px 1fr;
  gap: 0 24px; padding: 26px 0; border-bottom: 1px solid var(--hair);
  align-items: start;
}
.principle:last-child { border-bottom: 1px solid var(--ink); }
.principle .n {
  font-family: var(--sans); font-weight: 200; font-size: 24px; color: var(--brass);
  line-height: 1.3;
}
.principle h3 {
  font-family: var(--sans); font-weight: 500; font-size: 16px;
  margin: 0 0 6px; color: var(--ink);
}
.principle p { margin: 0; font-size: 16px; color: var(--text); max-width: 68ch; }

/* ── Кейс ────────────────────────────────────────────────────────── */
.case {
  background: var(--ink); color: #fff; padding: 44px 40px;
  border-left: 3px solid var(--brass);
}
.case h3 {
  font-family: var(--sans); font-weight: 300; font-size: clamp(20px, 3vw, 27px);
  margin: 14px 0 18px; color: #fff;
}
.case p { color: #B9C0CA; font-size: 16.5px; max-width: 72ch; }
.case .tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; }
.case .tags span {
  font-family: var(--sans); font-size: 12px; letter-spacing: .05em;
  border: 1px solid var(--ink-line); color: #98A0AC; padding: 6px 12px;
}

/* ── Стек ────────────────────────────────────────────────────────── */
.stack { display: flex; flex-wrap: wrap; gap: 10px; }
.stack span {
  font-family: var(--sans); font-size: 13.5px; letter-spacing: .02em;
  border: 1px solid var(--hair); background: var(--paper);
  padding: 9px 16px; color: var(--text);
}
section.alt .stack span { background: var(--paper); }

/* ── Таблица реквизитов ──────────────────────────────────────────── */
.tbl { width: 100%; border-collapse: collapse; font-size: 15.5px; }
.tbl th {
  font-family: var(--sans); font-weight: 500; font-size: 11px;
  letter-spacing: .18em; text-transform: uppercase; color: var(--muted);
  text-align: left; padding: 0 0 10px; border-bottom: 1px solid var(--ink);
}
.tbl td { padding: 14px 20px 14px 0; border-bottom: 1px solid var(--hair); vertical-align: top; }
.tbl td:first-child { color: var(--muted); width: 38%; }
.tbl a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--brass); }
.tbl a:hover { color: var(--brass); }

/* ── Подвал ──────────────────────────────────────────────────────── */
footer {
  background: var(--ink); color: #8B929C; padding: 54px 0 44px;
  font-size: 14px;
}
footer .row {
  display: flex; flex-wrap: wrap; gap: 24px;
  justify-content: space-between; align-items: flex-end;
}
footer a { color: #C3C9D2; text-decoration: none; }
footer a:hover { color: var(--brass-lt); }
footer .fine { font-size: 12.5px; color: #5F6874; margin-top: 26px; line-height: 1.7; }

/* ══════════════════════ Закрытый раздел /demo ══════════════════════ */
.demo-head { background: var(--ink); color: #fff; padding: 56px 0 48px; }
.demo-head h1 {
  font-family: var(--sans); font-weight: 200; font-size: clamp(28px, 5vw, 44px);
  margin: 16px 0 0;
}
.demo-head p { color: #A8AEB8; max-width: 60ch; margin: 18px 0 0; }

.demo-list { border-top: 1px solid var(--ink); margin-top: 8px; }
.demo-item {
  display: grid; grid-template-columns: 1fr auto; gap: 20px 32px;
  padding: 28px 0; border-bottom: 1px solid var(--hair); align-items: center;
}
.demo-item:last-child { border-bottom: 1px solid var(--ink); }
.demo-item h3 {
  font-family: var(--sans); font-weight: 500; font-size: 18px;
  margin: 0 0 8px; color: var(--ink);
}
.demo-item p { margin: 0; font-size: 15.5px; color: var(--text); max-width: 70ch; }
.demo-meta { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.demo-meta span {
  font-family: var(--sans); font-size: 12px; letter-spacing: .04em;
  border: 1px solid var(--hair); padding: 5px 11px; color: var(--muted);
}
.badge {
  font-family: var(--sans); font-size: 11px; letter-spacing: .14em;
  text-transform: uppercase; padding: 5px 11px; white-space: nowrap;
}
.badge.live { background: #E8F0E9; color: #3F6B4A; border: 1px solid #C6DACB; }
.badge.wip  { background: #FBF3E6; color: #8C5B2F; border: 1px solid #E7D5B6; }
.badge.off  { background: #F0EFEC; color: var(--muted); border: 1px solid var(--hair); }
.demo-cta { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }

.notice {
  background: var(--surface); border-left: 3px solid var(--brass);
  padding: 20px 24px; font-size: 15.5px; margin: 34px 0 0;
}
.notice b { font-family: var(--sans); font-weight: 500; font-size: 14px; color: var(--ink); }

/* ── Адаптив ─────────────────────────────────────────────────────── */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .nav { display: none; }
  .nav.open {
    display: flex; flex-direction: column; align-items: stretch; gap: 0;
    position: absolute; top: 62px; left: 0; right: 0;
    background: var(--ink); border-bottom: 1px solid var(--ink-line);
    padding: 8px 0 16px;
  }
  .nav.open a { padding: 13px var(--gut); font-size: 15px; }
  .nav.open a.cta { margin: 8px var(--gut) 0; text-align: center; }
  .burger { display: block; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; gap: 0; }
  .stats > div { padding: 18px 0; border-top: 1px solid var(--ink-line); }
  .stats > div:first-child { border-top: 0; padding-top: 0; }
  .stats > div + div { border-left: 0; padding-left: 0; }
  .principle { grid-template-columns: 1fr; gap: 6px; }
  .demo-item { grid-template-columns: 1fr; }
  .demo-cta { align-items: flex-start; flex-direction: row; }
  .case { padding: 32px 26px; }
  .tbl td:first-child { width: 44%; }
}

@media print {
  .topbar, .hero-mono, .hero-glow, .hero-grid, .burger { display: none; }
  body { font-size: 11pt; }
}


/* ══════════════════════════════════════════════════════════════════
   ДВИЖЕНИЕ
   ══════════════════════════════════════════════════════════════════ */

/* ── Полоса прогресса чтения ─────────────────────────────────────── */
.scrollbar {
  position: absolute; left: 0; right: 0; bottom: -1px; height: 2px;
  background: var(--brass); transform: scaleX(0); transform-origin: 0 50%;
  will-change: transform;
}
.topbar { transition: background .3s, box-shadow .3s; }
.topbar.solid { box-shadow: 0 10px 30px -18px rgba(0,0,0,.9); }

/* ── Крестик из бургера ──────────────────────────────────────────── */
.burger.x span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.burger.x span:nth-child(2) { opacity: 0; }
.burger.x span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── Атмосфера первого экрана ────────────────────────────────────── */
.hero-glow {
  position: absolute; top: 0; left: 0; width: 640px; height: 640px;
  border-radius: 50%; pointer-events: none; z-index: 1; opacity: 0;
  background: radial-gradient(circle, rgba(180,146,79,.13) 0%, rgba(180,146,79,0) 62%);
  transition: opacity .45s;
  will-change: transform;
}
.hero-grid {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.028) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 78% 62% at 32% 34%, #000 12%, transparent 76%);
  -webkit-mask-image: radial-gradient(ellipse 78% 62% at 32% 34%, #000 12%, transparent 76%);
}
.hero { isolation: isolate; }

/* акцент в заголовке подчёркивается латунью «на въезде» */
.hero h1 em { position: relative; display: inline-block; }
.hero h1 em::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: .04em; height: 2px;
  background: var(--brass); transform: scaleX(0); transform-origin: 0 50%;
  transition: transform .8s cubic-bezier(.22,.61,.36,1) .55s;
}
.hero h1.in em::after { transform: scaleX(1); }

.rule-brass { transform-origin: 0 50%; }

/* ── Появление: первый экран и блоки ─────────────────────────────── */
.rise, .reveal {
  opacity: 0; transform: translateY(18px);
  transition: opacity .72s cubic-bezier(.22,.61,.36,1),
              transform .72s cubic-bezier(.22,.61,.36,1);
  will-change: opacity, transform;
}
.rise.in, .reveal.in { opacity: 1; transform: none; }

/* ── Блик по кнопке ──────────────────────────────────────────────── */
.sheen { position: relative; overflow: hidden; }
.sheen::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: -140%; width: 60%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.42), transparent);
  transform: skewX(-18deg); pointer-events: none;
}
.sheen:hover::after { animation: sheen .78s ease-out; }
@keyframes sheen { to { left: 160%; } }

.btn { position: relative; }
.btn-primary:hover { transform: translateY(-1px); }
.btn-ghost:hover  { transform: translateY(-1px); }
.btn-dark {
  background: var(--ink); color: #fff;
}
.btn-dark:hover { background: var(--ink-soft); transform: translateY(-1px); }

/* ── Карточки ────────────────────────────────────────────────────── */
.card {
  position: relative;
  transition: transform .32s cubic-bezier(.22,.61,.36,1), box-shadow .32s;
}
.card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: var(--brass); transform: scaleX(0); transform-origin: 0 50%;
  transition: transform .42s cubic-bezier(.22,.61,.36,1);
}
.card:hover { transform: translateY(-3px); box-shadow: 0 22px 44px -30px rgba(13,17,23,.55); }
.card:hover::before { transform: scaleX(1); }
.card .n { transition: color .3s; }
.card:hover .n { color: var(--ink); }

/* ── Принципы ────────────────────────────────────────────────────── */
.principle { transition: background .3s; }
.principle:hover { background: rgba(180,146,79,.05); }
.principle .n { transition: transform .35s cubic-bezier(.22,.61,.36,1); }
.principle:hover .n { transform: translateX(4px); }

/* ── Кейс ────────────────────────────────────────────────────────── */
.case { position: relative; overflow: hidden; }
.case::after {
  content: ""; position: absolute; right: -120px; top: -120px;
  width: 380px; height: 380px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(180,146,79,.11) 0%, rgba(180,146,79,0) 68%);
}
.case .tags span { transition: border-color .28s, color .28s; }
.case .tags span:hover { border-color: var(--brass); color: var(--brass-lt); }

/* ── Бегущая строка стека ────────────────────────────────────────── */
.stack-sec { overflow: hidden; }
.marquee {
  position: relative; margin-top: 8px;
  border-top: 1px solid var(--hair); border-bottom: 1px solid var(--hair);
  padding: 22px 0; background: var(--paper);
  mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
}
.marquee-row { display: flex; gap: 10px; width: max-content; }
.marquee-row.run { animation: marquee 46s linear infinite; }
.marquee:hover .marquee-row.run { animation-play-state: paused; }
.marquee-row span {
  font-family: var(--sans); font-size: 13.5px; letter-spacing: .02em;
  white-space: nowrap; border: 1px solid var(--hair);
  padding: 9px 16px; color: var(--text); background: var(--paper);
  transition: border-color .25s, color .25s;
}
.marquee-row span:hover { border-color: var(--brass); color: var(--brass); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ── Ссылка-акцент ───────────────────────────────────────────────── */
.lnk {
  color: var(--ink); text-decoration: none;
  border-bottom: 1px solid var(--brass); padding-bottom: 1px;
  transition: color .25s, border-color .25s;
}
.lnk:hover { color: var(--brass); }

/* ── Контакты ────────────────────────────────────────────────────── */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; }
.foot-contacts { text-align: right; line-height: 1.9; }

/* ── Демо-карточки ───────────────────────────────────────────────── */
.demo-item { transition: background .28s; }
.demo-item:hover { background: rgba(180,146,79,.045); }
.badge.live { position: relative; }
.badge.live::before {
  content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: #3F6B4A; margin-right: 7px; vertical-align: middle;
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(63,107,74,.5); }
  50%      { opacity: .55; box-shadow: 0 0 0 5px rgba(63,107,74,0); }
}

@media (max-width: 760px) {
  .contact-grid { grid-template-columns: 1fr; gap: 34px; }
  .foot-contacts { text-align: left; }
  .hero-glow { display: none; }
}

/* ── Уважение к системной настройке ──────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .rise, .reveal { opacity: 1 !important; transform: none !important; }
  .marquee-row.run { animation: none; }
  .hero-glow { display: none; }
}

/* ══════════════════════════════════════════════════════════════════
   СТРАНИЦА ВХОДА В ЗАКРЫТЫЙ РАЗДЕЛ  /vault/
   ══════════════════════════════════════════════════════════════════ */
.gate-body { background: var(--ink); }

.gate {
  position: relative; min-height: 100vh; min-height: 100dvh;
  display: flex; align-items: center; justify-content: center;
  padding: 32px var(--gut); overflow: hidden; isolation: isolate;
}
.gate-grid {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 5%, transparent 72%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 5%, transparent 72%);
}
.gate-mono {
  position: absolute; z-index: 0; right: -.08em; bottom: -.30em;
  font-family: var(--sans); font-weight: 200; font-size: clamp(240px, 40vw, 520px);
  color: #141B25; line-height: .8; pointer-events: none; user-select: none;
}

.gate-card {
  position: relative; z-index: 2; width: 100%; max-width: 452px;
  background: #10161F; border: 1px solid var(--ink-line);
  border-top: 2px solid var(--brass);
  padding: 34px clamp(24px, 5vw, 40px) 30px;
  box-shadow: 0 40px 90px -50px rgba(0,0,0,.95);
  animation: gate-in .55s cubic-bezier(.22,.61,.36,1) both;
}
@keyframes gate-in {
  from { opacity: 0; transform: translateY(16px) scale(.985); }
  to   { opacity: 1; transform: none; }
}
.gate-card.shake { animation: gate-shake .42s cubic-bezier(.36,.07,.19,.97) both; }
@keyframes gate-shake {
  10%, 90% { transform: translateX(-2px); }
  20%, 80% { transform: translateX(4px); }
  30%, 50%, 70% { transform: translateX(-7px); }
  40%, 60% { transform: translateX(7px); }
}

.gate-back {
  display: inline-block; margin-bottom: 26px;
  font-family: var(--sans); font-size: 13px; letter-spacing: .03em;
  color: #8B929C; text-decoration: none; transition: color .2s;
}
.gate-back:hover { color: var(--brass-lt); }
.gate-back span { display: inline-block; transition: transform .25s; }
.gate-back:hover span { transform: translateX(-4px); }

.gate-card h1 {
  font-family: var(--sans); font-weight: 200; font-size: 32px; line-height: 1.15;
  color: #fff; margin: 0 0 14px; letter-spacing: -.01em;
}
.gate-sub {
  font-size: 15px; line-height: 1.6; color: #98A0AC; margin: 0 0 28px;
}

.gate-label {
  display: block; font-family: var(--sans); font-weight: 500; font-size: 11px;
  letter-spacing: .18em; text-transform: uppercase; color: var(--brass);
  margin-bottom: 10px;
}
.gate-field { position: relative; display: flex; align-items: stretch; }
.gate-field input {
  flex: 1; min-width: 0;
  font-family: var(--sans); font-size: 16px; letter-spacing: .06em;
  color: #fff; background: #0A0F16;
  border: 1px solid var(--ink-line); border-right: 0;
  padding: 14px 16px; outline: none;
  transition: border-color .22s, background .22s;
}
.gate-field input::placeholder { color: #4A5563; letter-spacing: .1em; }
.gate-field input:focus { border-color: var(--brass); background: #0C121A; }
.gate-field:focus-within { box-shadow: 0 0 0 3px rgba(180,146,79,.13); }
.gate-eye {
  font-family: var(--sans); font-size: 12px; letter-spacing: .04em;
  color: #8B929C; background: #0A0F16; cursor: pointer;
  border: 1px solid var(--ink-line); border-left: 0;
  padding: 0 14px; transition: color .2s, border-color .22s;
}
.gate-field input:focus ~ .gate-eye { border-color: var(--brass); }
.gate-eye:hover { color: var(--brass-lt); }

.gate-error {
  font-size: 14px; line-height: 1.5; color: #E0A08A;
  background: rgba(180,70,50,.09); border-left: 2px solid #B4553A;
  padding: 11px 14px; margin: 16px 0 0;
}

.gate-submit { width: 100%; margin-top: 22px; text-align: center; border: 0;
               cursor: pointer; font-size: 15px; padding: 15px 28px; }

.gate-foot {
  margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--ink-line);
  font-family: var(--sans); font-size: 13px; color: #6E7684;
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
}
.gate-foot a { color: #A8AEB8; text-decoration: none; border-bottom: 1px solid rgba(180,146,79,.45); }
.gate-foot a:hover { color: var(--brass-lt); }
.gate-dot { color: #3A424E; }

/* Кнопка выхода в шапке закрытого раздела */
.nav a.logout { color: #8B929C; }
.nav a.logout:hover { color: #E0A08A; }

@media (max-width: 420px) {
  .gate-card h1 { font-size: 27px; }
  .gate-foot { font-size: 12.5px; }
}

@media (prefers-reduced-motion: reduce) {
  .gate-card, .gate-card.shake { animation: none; }
}

/* ══════════════════════════════════════════════════════════════════
   ФОРМА ЗАЯВКИ
   ══════════════════════════════════════════════════════════════════ */
.lead { display: block; }
.lead-label {
  display: block; font-family: var(--sans); font-weight: 500; font-size: 11px;
  letter-spacing: .16em; text-transform: uppercase; color: var(--muted);
  margin: 0 0 8px;
}
.lead-label span { color: var(--brass); }
.lead-label + .lead-input { margin-bottom: 18px; }

.lead-input {
  width: 100%; font-family: var(--sans); font-size: 15px; line-height: 1.5;
  color: var(--text); background: var(--paper);
  border: 1px solid var(--hair); border-radius: 0;
  padding: 13px 15px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.lead-input::placeholder { color: #A9A296; }
.lead-input:focus {
  border-color: var(--brass);
  box-shadow: 0 0 0 3px rgba(180,146,79,.13);
}
.lead-input.err { border-color: #B4553A; box-shadow: 0 0 0 3px rgba(180,85,58,.12); }
.lead-area { resize: vertical; min-height: 110px; }

/* Ловушка для ботов — убрана из потока, но не display:none */
.lead-trap {
  position: absolute; left: -9999px; width: 1px; height: 1px;
  overflow: hidden; opacity: 0; pointer-events: none;
}

.lead-submit { width: 100%; margin-top: 6px; border: 0; cursor: pointer; text-align: center; }
.lead-submit[disabled] { opacity: .55; cursor: default; }

.lead-note {
  margin: 16px 0 0; padding: 12px 15px; font-size: 14.5px; line-height: 1.5;
  border-left: 2px solid var(--brass); background: var(--surface);
}
.lead-note.ok   { border-left-color: #3F6B4A; background: #F1F7F2; color: #2F5238; }
.lead-note.fail { border-left-color: #B4553A; background: #FBF2EF; color: #8C3F28; }

.lead-fine {
  margin: 14px 0 0; font-family: var(--sans);
  font-size: 11.5px; line-height: 1.5; color: var(--muted);
}

/* ── Прайс ───────────────────────────────────────────────────────── */
.price { border-top: 1px solid var(--ink); }
.price-row {
  display: grid; grid-template-columns: 1fr 210px;
  gap: 0 32px; padding: 24px 0; align-items: start;
  border-bottom: 1px solid var(--hair);
}
.price-row:last-child { border-bottom: 1px solid var(--ink); }
.price-what h3 {
  font-family: var(--sans); font-weight: 500; font-size: 16px;
  margin: 0 0 8px; color: var(--ink); line-height: 1.35;
}
.price-what p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--muted); }
.price-sum {
  font-family: var(--sans); font-weight: 300; font-size: 24px;
  color: var(--ink); text-align: right; line-height: 1.15;
  white-space: nowrap;
}
/* «от» отдельной строкой, чтобы суммы выстроились по правому краю в одну колонку */
.price-sum span {
  display: block; font-size: 11px; font-weight: 500; letter-spacing: .22em;
  text-transform: uppercase; color: var(--brass); margin-bottom: 4px;
}
.price-sum em {
  display: block; font-style: normal; font-size: 13px; font-weight: 400;
  color: var(--muted); margin-top: 6px; white-space: normal;
}
.price-row { transition: background .28s; }
.price-row:hover { background: var(--paper); }
section.alt .price-row:hover { background: var(--paper); }

@media (max-width: 640px) {
  .price-row { grid-template-columns: 1fr; gap: 12px; padding: 20px 0; }
  .price-sum { text-align: left; font-size: 22px; }
  .price-sum span { display: inline; margin-right: 8px; }
  .price-sum em { margin-top: 2px; }
}

/* ── Частые вопросы ──────────────────────────────────────────────── */
.faq {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 0 48px; border-top: 1px solid var(--ink);
}
.faq-item { padding: 24px 0; border-bottom: 1px solid var(--hair); }
/* последние две карточки в ряду закрывают список сплошной линией */
.faq-item:nth-last-child(-n+2) { border-bottom: 1px solid var(--ink); }
.faq-item h3 {
  font-family: var(--sans); font-weight: 500; font-size: 16px;
  margin: 0 0 10px; color: var(--ink); line-height: 1.4;
  padding-left: 20px; position: relative;
}
.faq-item h3::before {
  content: "—"; position: absolute; left: 0; color: var(--brass); font-weight: 300;
}
.faq-item p { margin: 0; font-size: 15.5px; line-height: 1.65; color: var(--text); }

@media (max-width: 760px) {
  .faq { grid-template-columns: 1fr; gap: 0; }
  .faq-item:nth-last-child(-n+2) { border-bottom: 1px solid var(--hair); }
  .faq-item:last-child { border-bottom: 1px solid var(--ink); }
}

/* ══ Кнопка ШМОТ → shop.denvault.ru ═══════════════════════════════ */
.nav a.shmot {
  --sh: #C98A46;
  position: relative;
  font-family: ui-monospace, SFMono-Regular, Menlo, "JetBrains Mono", monospace;
  font-size: 12px; letter-spacing: .22em; font-weight: 500;
  color: #6E7684; text-transform: uppercase;
  padding: 8px 14px; margin-left: 4px;
  border: 1px solid #2A323E; background: rgba(0,0,0,.25);
  transition: color .2s, border-color .2s, background .2s;
  isolation: isolate;
}
.nav a.shmot::before {
  content: "["; margin-right: 6px; color: #3E4653; transition: color .2s;
}
.nav a.shmot::after {
  content: "]"; margin-left: 6px; color: #3E4653; transition: color .2s;
}
.nav a.shmot:hover { color: var(--sh); border-color: var(--sh); background: rgba(201,138,70,.08); }
.nav a.shmot:hover::before, .nav a.shmot:hover::after { color: var(--sh); }

/* сам глитч живёт на вложенном span, чтобы скобки не дублировались */
.nav a.shmot span { position: relative; display: inline-block; }
.nav a.shmot span::before,
.nav a.shmot span::after {
  content: attr(data-t); position: absolute; inset: 0;
  clip-path: inset(0 0 100% 0); pointer-events: none; opacity: 0;
}
.nav a.shmot span::before { color: #FF2EA8; transform: translateX(-2px); }
.nav a.shmot span::after  { color: #3DF0FF; transform: translateX(2px); }

/* редкий самопроизвольный сбой — чтобы кнопку заметили */
.nav a.shmot span::before { animation: shmotA 7s infinite steps(2); }
.nav a.shmot span::after  { animation: shmotB 7s infinite steps(2); }
.nav a.shmot:hover span::before { animation: shmotA .45s infinite steps(2); }
.nav a.shmot:hover span::after  { animation: shmotB .45s infinite steps(2); }

@keyframes shmotA {
  0%, 92%, 100% { opacity: 0; clip-path: inset(0 0 100% 0); }
  93% { opacity: .9; clip-path: inset(12% 0 62% 0); }
  95% { opacity: .9; clip-path: inset(58% 0 24% 0); }
  97% { opacity: .9; clip-path: inset(32% 0 48% 0); }
}
@keyframes shmotB {
  0%, 92%, 100% { opacity: 0; clip-path: inset(0 0 100% 0); }
  94% { opacity: .9; clip-path: inset(66% 0 10% 0); }
  96% { opacity: .9; clip-path: inset(22% 0 58% 0); }
  98% { opacity: .9; clip-path: inset(44% 0 38% 0); }
}

@media (max-width: 860px) {
  .nav.open a.shmot {
    margin: 10px var(--gut) 0; padding: 12px 14px; text-align: center;
  }
}
@media (prefers-reduced-motion: reduce) {
  .nav a.shmot span::before, .nav a.shmot span::after { animation: none; opacity: 0; }
}

/* ══════════════════════════════════════════════════════════════════
   ПЕРВЫЙ ЭКРАН — общий язык с /shop/
   Терминальные детали, зерно и оранжевый акцент, чтобы главная
   и магазин читались как один бренд. Латунь остаётся основной.
   ══════════════════════════════════════════════════════════════════ */
:root { --flame: #FF7A18; }

/* ── плёночное зерно и развёртка поверх тёмного экрана ── */
.hero::before,
.hero::after { content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.hero::before {
  opacity: .035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: heroGrain 6s steps(6) infinite;
}
.hero::after {
  opacity: .5; mix-blend-mode: overlay;
  background: repeating-linear-gradient(180deg, rgba(255,255,255,.022) 0 1px, transparent 1px 3px);
}
@keyframes heroGrain {
  0%,100% { transform: translate(0,0) }
  20% { transform: translate(-3%,2%) }
  40% { transform: translate(2%,-4%) }
  60% { transform: translate(-4%,-1%) }
  80% { transform: translate(4%,3%) }
}

/* ── надзаголовок как строка терминала ── */
.hero .label.brass {
  font-family: ui-monospace, SFMono-Regular, Menlo, "JetBrains Mono", monospace;
  font-size: 12px; letter-spacing: .2em; color: #8E7A4E;
}
.hero .label.brass::before { content: "> "; color: var(--flame); }
.hero .label.brass::after {
  content: "_"; color: var(--flame); margin-left: .35em;
  animation: heroCaret 1.05s steps(2) infinite;
}
@keyframes heroCaret { 50% { opacity: 0 } }

/* ── блик по акценту заголовка, как по VIBECODE в магазине ── */
.hero h1 em {
  background: linear-gradient(96deg,
    var(--brass) 0 38%, var(--brass-lt) 46%, var(--flame) 54%, var(--brass) 66%);
  background-size: 260% 100%;
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  animation: heroSheen 9s linear infinite;
}
@keyframes heroSheen { to { background-position: -260% 0 } }

/* ── монограмма контуром, как DENVAULT в подвале магазина ── */
.hero-mono {
  color: transparent;
  -webkit-text-stroke: 1px #1B2330;
}

/* ── призрачная кнопка перекликается с кнопкой ШМОТ ── */
.hero .btn-ghost { transition: border-color .22s, color .22s, background .22s; }
.hero .btn-ghost:hover {
  border-color: var(--flame); color: var(--flame);
  background: rgba(255,122,24,.06);
}

/* ── цифры получают моноширинный подпис, как спека в магазине ── */
.hero .stats > div > span {
  font-family: ui-monospace, SFMono-Regular, Menlo, "JetBrains Mono", monospace;
  font-size: 11.5px; letter-spacing: .02em;
}

@media (prefers-reduced-motion: reduce) {
  .hero::before, .hero .label.brass::after, .hero h1 em { animation: none }
  .hero h1 em { color: var(--brass); -webkit-text-fill-color: var(--brass) }
}

/* ══════════════════════════════════════════════════════════════════
   ШМОТ · переход в магазин одежды
   Визитка про разработку, магазин — про вещи: разные миры, поэтому
   блок сделан тёмной вставкой в светлой части страницы. Контраст тут
   работает как дверь, а не как украшение.
   ══════════════════════════════════════════════════════════════════ */

/* Знак-белка внутри кнопки. Скобки и глитч — авторские, они и делают
   кнопку заметной; зверь только добавляет к ним лицо бренда. */
.nav a.shmot { display: inline-flex; align-items: center; }
.nav a.shmot img {
  width: 18px; height: auto; margin-right: 8px; opacity: .55;
  transition: transform .45s cubic-bezier(.16,1,.3,1), opacity .25s;
}
.nav a.shmot:hover img { opacity: 1; transform: translateY(-2px) rotate(-6deg); }

/* сам блок */
.wear {
  position: relative; overflow: hidden;
  background: linear-gradient(168deg, #0D1117, #0A0E14 56%, #0D1117);
  color: #D8DDE4; padding: clamp(56px, 8vw, 118px) 0;
  border-block: 1px solid #1A212B;
}
.wear-grid {
  position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background:
    repeating-linear-gradient(90deg, transparent 0 78px, rgba(180,146,79,.05) 78px 79px),
    repeating-linear-gradient(0deg, transparent 0 78px, rgba(180,146,79,.035) 78px 79px);
}
.wear-in {
  position: relative; z-index: 1;
  display: grid; gap: clamp(28px, 4vw, 64px); align-items: center;
}
@media (min-width: 900px) { .wear-in { grid-template-columns: minmax(0,1.15fr) minmax(0,.85fr); } }

.wear-kicker {
  font-family: var(--sans); font-size: 12px; letter-spacing: .26em;
  text-transform: uppercase; color: var(--brass); margin: 0 0 18px;
}
.wear-h {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(30px, 4.2vw, 56px); line-height: 1.12;
  margin: 0 0 20px; color: #EDF0F4;
}
.wear-h em { font-style: normal; color: var(--brass-lt); }
.wear-lead { color: #9AA3AE; max-width: 52ch; margin: 0 0 28px; }
.wear-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.wear-addr {
  font-family: var(--sans); font-size: 12px; letter-spacing: .18em;
  text-transform: lowercase; color: #5D6670; margin: 0;
}

/* карточка-дверь: знак, имя линии и подпись перехода */
.wear-card {
  display: grid; justify-items: center; gap: 14px; text-align: center;
  padding: clamp(28px, 4vw, 52px) clamp(20px, 3vw, 40px);
  border: 1px solid #222B36; background: rgba(255,255,255,.015);
  text-decoration: none; color: inherit;
  transition: border-color .35s, background .35s, transform .5s cubic-bezier(.16,1,.3,1);
}
.wear-card:hover { border-color: var(--brass); background: rgba(180,146,79,.05); transform: translateY(-4px); }
.wear-mark { width: clamp(84px, 9vw, 128px); height: auto; opacity: .95;
  transition: transform .6s cubic-bezier(.16,1,.3,1); }
.wear-card:hover .wear-mark { transform: translateY(-4px) rotate(-5deg); }
.wear-card-t {
  font-family: var(--sans); font-size: clamp(13px, 1.3vw, 16px);
  letter-spacing: .3em; color: #8C96A2; line-height: 1.7;
}
.wear-card-t b { color: #EDF0F4; font-weight: 600; }
.wear-card-go {
  font-family: var(--sans); font-size: 11.5px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--brass);
  border-top: 1px solid #222B36; padding-top: 14px; width: 100%;
  transition: color .25s, border-color .35s;
}
.wear-card:hover .wear-card-go { color: var(--brass-lt); border-color: rgba(180,146,79,.4); }

@media (prefers-reduced-motion: reduce) {
  .wear-card, .wear-mark, .nav a.shmot img { transition: none; }
}
