/* Buildify — buildify.info
   Токены: тёплая бумага, почти-чёрные чернила, один акцент.
   Шрифты системные — ни одного сетевого запроса за шрифтами. */

:root {
  --paper:      #FBFAF8;
  --paper-2:    #F3F1EC;
  --ink:        #14171A;
  --ink-2:      #3E464C;
  --muted:      #767E85;
  --line:       #E4E1DA;
  --line-2:     #CFCBC1;
  --accent:     #135C4B;
  --accent-ink: #0E4438;

  --wrap: 1080px;
  --gap: clamp(2.5rem, 6vw, 5.5rem);

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

*, *::before, *::after { box-sizing: border-box; }

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

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

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--accent-ink); }

img { max-width: 100%; height: auto; display: block; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.mono { font-family: var(--mono); font-size: 0.82em; letter-spacing: 0.01em; }

/* ---------- шапка ---------- */

.top {
  border-bottom: 1px solid var(--line);
  background: rgba(251, 250, 248, 0.92);
  backdrop-filter: saturate(180%) blur(8px);
  position: sticky; top: 0; z-index: 20;
}
.top__in { display: flex; align-items: center; gap: 24px; height: 60px; }
.brand {
  font-weight: 600; font-size: 1.05rem; letter-spacing: -0.01em;
  color: var(--ink); text-decoration: none;
}
.nav { display: flex; gap: 22px; margin-left: auto; }
.nav a { color: var(--ink-2); text-decoration: none; font-size: 0.92rem; }
.nav a:hover { color: var(--accent); }

/* ---------- кнопки ---------- */

.btn {
  display: inline-block;
  background: var(--ink); color: var(--paper);
  padding: 12px 20px; border-radius: 3px;
  text-decoration: none; font-size: 0.95rem; font-weight: 500;
  border: 1px solid var(--ink);
}
.btn:hover { background: var(--accent-ink); border-color: var(--accent-ink); color: var(--paper); }
.btn--sm { padding: 7px 14px; font-size: 0.88rem; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn--ghost:hover { background: transparent; color: var(--accent); border-color: var(--accent); }

/* ---------- герой ---------- */

.hero { padding: clamp(3.5rem, 9vw, 7rem) 0 var(--gap); }
h1 {
  margin: 0 0 1.1rem;
  font-size: clamp(1.95rem, 1.1rem + 3.4vw, 3.15rem);
  line-height: 1.1; letter-spacing: -0.025em; font-weight: 600;
  max-width: 20ch;
}
.lede { max-width: 62ch; font-size: 1.06rem; color: var(--ink-2); margin: 0 0 1.9rem; }
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- секции ---------- */

.band { padding: var(--gap) 0; border-top: 1px solid var(--line); }
.band--end { background: var(--paper-2); }

h2 {
  margin: 0 0 0.9rem;
  font-size: clamp(1.3rem, 1rem + 1.1vw, 1.65rem);
  letter-spacing: -0.015em; font-weight: 600;
}
h3 { margin: 0 0 0.4rem; font-size: 1.02rem; font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0 0 0.95rem; }
.sub { color: var(--muted); max-width: 60ch; margin-top: -0.3rem; margin-bottom: 2.2rem; }
.note { color: var(--muted); font-size: 0.94rem; max-width: 68ch; }
.meta { color: var(--muted); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); }
.grid-2 > div > p:last-child, .grid-2 article > p:last-child { margin-bottom: 0; }

/* ---------- каскад скринов ---------- */

.cascade { margin: 0 0 1.8rem; }

.shot { margin: 0 0 -46px; position: relative; width: 80%; }
.shot:last-child { margin-bottom: 0; }
.shot:nth-child(1) { margin-left: 0;      z-index: 1; }
.shot:nth-child(2) { margin-left: 6.66%;  z-index: 2; }
.shot:nth-child(3) { margin-left: 13.33%; z-index: 3; }
.shot:nth-child(4) { margin-left: 20%;    z-index: 4; }

.shot img {
  width: 100%;
  border: 1px solid var(--line-2);
  border-top: none;
  box-shadow: 0 20px 44px -26px rgba(20, 23, 26, 0.5);
}
.shot__bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--paper-2);
  border: 1px solid var(--line-2);
  border-bottom: none;
  padding: 7px 12px;
  color: var(--muted);
}
.shot__bar .lnk { text-decoration: none; }
.shot__bar .lnk:hover { text-decoration: underline; }

.legend { margin: 0 0 3rem; display: grid; grid-template-columns: 230px 1fr; }
.legend dt { padding: 13px 16px 13px 0; border-top: 1px solid var(--line); line-height: 1.7; }
.legend dt a { text-decoration: none; }
.legend dt a:hover { text-decoration: underline; }
.legend dd { margin: 0; padding: 13px 0; border-top: 1px solid var(--line); color: var(--ink-2); font-size: 0.95rem; }

.apps { margin-bottom: 1.8rem; }
.apps h3 { margin-bottom: 0.5rem; }

/* ---------- стек ---------- */

.layers { margin: 0; display: grid; grid-template-columns: 210px 1fr; }
.layers dt {
  color: var(--muted);
  padding: 14px 16px 14px 0;
  border-top: 1px solid var(--line);
}
.layers dd {
  margin: 0; padding: 14px 0;
  border-top: 1px solid var(--line);
  color: var(--ink-2);
}
.layers dt:first-of-type, .layers dd:first-of-type { border-top: none; padding-top: 0; }

/* ---------- принципы ---------- */

.principles { margin: 0; padding: 0; list-style: none; counter-reset: pr; display: grid; gap: 2rem; }
.principles li { counter-increment: pr; padding-left: 46px; position: relative; max-width: 72ch; }
.principles li::before {
  content: counter(pr, decimal-leading-zero);
  position: absolute; left: 0; top: 2px;
  font-family: var(--mono); font-size: 0.82rem; color: var(--accent);
}
.principles p { margin: 0; color: var(--ink-2); }

/* ---------- услуги ---------- */

.services { margin: 0; padding: 0; list-style: none; }
.services li {
  padding: 16px 0; border-top: 1px solid var(--line);
  color: var(--ink-2); max-width: 78ch;
}
.services li:first-child { border-top: none; padding-top: 0; }
.services strong { color: var(--ink); font-weight: 600; }

/* ---------- контакты, подвал ---------- */

.contacts { margin: 0; display: grid; grid-template-columns: 110px 1fr; row-gap: 10px; }
.contacts dt { color: var(--muted); }
.contacts dd { margin: 0; }

.foot { border-top: 1px solid var(--line); padding: 22px 0; color: var(--muted); font-size: 0.9rem; }
.foot__in { display: flex; justify-content: space-between; gap: 16px; }

/* ---------- адаптив ---------- */

@media (max-width: 860px) {
  .grid-2 { grid-template-columns: 1fr; }
  .layers { grid-template-columns: 1fr; }
  .layers dt { padding: 14px 0 0; border-top: 1px solid var(--line); }
  .layers dd { padding: 2px 0 14px; border-top: none; }
  .layers dd:first-of-type { padding-top: 2px; }
  .shot, .shot:nth-child(1), .shot:nth-child(2),
  .shot:nth-child(3), .shot:nth-child(4) {
    width: 100%; margin-left: 0; margin-bottom: 1.4rem;
  }
  .shot img { box-shadow: none; }
  .legend { grid-template-columns: 1fr; }
  .legend dt { padding: 13px 0 0; }
  .legend dd { padding: 2px 0 13px; border-top: none; }
}

@media (max-width: 720px) {
  .nav { display: none; }
  .top__in { justify-content: space-between; }
  body { font-size: 16px; }
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}
