[data-v4-cabinet-label][hidden], [data-v4-signed-only][hidden], [data-v4-guest-only][hidden] {
  display: none !important;
}

header.v4-shell-header {
  --shell-ink: #101d32;
  --shell-muted: #4e617a;
  --shell-paper: #fff;
  --shell-line: #cddbeb;
  --shell-surface: #edf3f9;
  display: grid;
  grid-template-columns: minmax(0,1fr) auto auto;
  grid-template-areas: "brand download tools";
  align-items: center;
  gap: 6px 12px;
  box-sizing: border-box;
  position: relative;
  z-index: 20;
  inset: auto;
  inline-size: min(100%,1172px);
  max-inline-size: 1172px;
  min-block-size: 60px;
  padding: 8px 20px;
  margin: 0 auto;
  border: 0;
  border-block-end: 1px solid var(--shell-line);
  background: var(--shell-surface);
  color: var(--shell-ink);
  font: 700 14px/1.2 system-ui,sans-serif;
  font-synthesis: none;
}

html[data-theme="dark"] header.v4-shell-header {
  --shell-ink: #e9eef6;
  --shell-muted: #adbbce;
  --shell-paper: #142136;
  --shell-line: #31435c;
  --shell-surface: #0e1626;
}

header.v4-shell-header[data-v4-tariff-header] {
  position: sticky;
  inset-block-start: 0;
}

.v4-shell-header *, .v4-shell-header *::before, .v4-shell-header *::after {
  box-sizing: border-box;
}

.v4-shell-brand {
  grid-area: brand;
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 8px;
  min-block-size: 44px;
  color: var(--shell-ink) !important;
  text-decoration: none;
  white-space: nowrap;
}

.v4-web-mark {
  inline-size: 38px;
  block-size: 38px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 38px;
  border-radius: 10px;
  background: #111c2e;
  border: 1px solid #31435c;
}

.v4-web-mark img {
  display: block;
  inline-size: 28px;
  block-size: 28px;
  object-fit: contain;
  border-radius: 0;
}

.v4-shell-header .v4-wordmark {
  font: 800 14px/1.2 system-ui,sans-serif !important;
}
.v4-shell-header .v4-wordmark b {
  color: var(--shell-muted);
  font-weight: 650;
}

.v4-shell-tools {
  grid-area: tools;
  display: grid;
  grid-template-columns: 44px minmax(min-content,1fr) 44px 44px;
  align-items: center;
  gap: 6px;
  min-inline-size: 0;
}

.v4-shell-header .v4-shell-tools [data-language-control] {
  display: block;
  inline-size: 44px;
  block-size: 44px;
  min-block-size: 0;
  margin: 0;
  padding: 0;
  border: 0;
  line-height: 0;
}

.v4-shell-header :is(.v4-shell-download,.v4-shell-account,.v4-compact-control,.v4-shell-drawer > summary) {
  display: flex;
  align-items: center;
  justify-content: center;
  min-block-size: 44px;
  block-size: 44px;
  padding: 4px 8px;
  border: 1px solid var(--shell-line);
  border-radius: 12px;
  background: var(--shell-paper);
  color: var(--shell-ink);
  text-decoration: none;
  font: 700 14px/1.2 system-ui,sans-serif;
  text-align: center;
  margin: 0;
}

header.v4-shell-header .v4-shell-download {
  grid-area: download;
  gap: 7px;
  padding-inline: 12px;
  border-color: #1558c5;
  background: #1558c5;
  color: #fff !important;
  white-space: nowrap;
}

header.v4-shell-header .v4-shell-account {
  color: var(--shell-ink) !important;
  white-space: normal;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: none;
}

.v4-shell-header :is(.v4-compact-control,.v4-shell-drawer > summary) {
  position: relative;
  inline-size: 44px;
  block-size: 44px;
}

.v4-shell-header .v4-compact-control > span {
  display: block;
  font: 700 14px/1.2 system-ui,sans-serif;
  color: inherit;
}

.v4-shell-header .v4-compact-control select {
  position: absolute;
  inset: 0;
  inline-size: 100%;
  block-size: 100%;
  opacity: 0;
  cursor: pointer;
}

.v4-shell-header :is(a,summary,button):focus-visible, .v4-compact-control:focus-within {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

.v4-shell-header .v4-shell-drawer {
  display: block;
  position: static;
  background: transparent;
  margin: 0;
  padding: 0;
  border: 0;
}

.v4-shell-drawer > summary { list-style: none; cursor: pointer; }
.v4-shell-drawer > summary::-webkit-details-marker { display: none; }

.v4-shell-header .v4-shell-drawer nav {
  position: absolute;
  inset-inline: auto 20px;
  inset-block-start: 100%;
  z-index: 20;
  overflow: auto;
  max-block-size: 67vh;
  inline-size: min(20rem,calc(100vw - 40px));
  padding: .5rem;
  background: var(--shell-paper);
  color: var(--shell-ink);
  border: 1px solid var(--shell-line);
  border-radius: 12px;
  box-shadow: 0 8px 24px #0002;
  display: block;
}

.v4-shell-header .v4-shell-drawer:not([open]) nav { display: none; }

.v4-shell-header .v4-shell-drawer nav :is(a,button) {
  display: flex;
  align-items: center;
  color: var(--shell-ink);
  min-block-size: 44px;
  padding: 6px 10px;
  text-align: start;
  text-decoration: none;
  font: inherit;
}

.v4-shell-header .v4-shell-drawer nav h2 {
  margin: .5rem 10px .15rem;
  font-size: .8rem;
}

.v4-tariff-context { margin-block: .75rem; }
body.client-design:has(> .v4-shell-header) .z-login-brand { display: none; }

@media (max-width: 760px) {
  header.v4-shell-header {
    grid-template-columns: minmax(0,1fr) auto;
    grid-template-areas: "brand download" "tools tools";
  }
}

footer.v4-shared-footer {
  color: var(--v4-text, var(--text, var(--tx)));
  max-inline-size: 1120px;
  margin: 1rem auto 0;
  padding: 1.25rem 1rem;
  border-block-start: 1px solid var(--v4-line, var(--line, var(--bd)));
}

.v4-shared-footer .site-footer-brand {
  font-weight: 800;
  margin-block-end: .75rem;
}

.v4-shared-footer :is(.site-footer-actions,.site-footer-groups) {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(min(100%,12rem),1fr));
  gap: .65rem;
  margin-block-end: .65rem;
}

.v4-shared-footer .site-footer-actions a,
.v4-shared-footer .site-footer-group summary,
.v4-shared-footer .site-footer-group-links a {
  display: flex;
  align-items: center;
  min-block-size: 44px;
  padding: .45rem .65rem;
  color: inherit;
}

.v4-shared-footer .site-footer-group {
  border: 1px solid var(--v4-line, var(--line, var(--bd)));
  border-radius: .75rem;
  background: var(--v4-card, var(--card, var(--bg2)));
}

.v4-shared-footer .site-footer-group summary {
  cursor: pointer;
  font-weight: 650;
}

.v4-shared-footer .footer-download {
  color: #fff !important;
  background: #1558c5;
  border-radius: .75rem;
}

html[data-v4-web-tariff][data-theme=light] {
  --zpw-card: #fff;
  --zpw-bg: #f3f6fa;
  --zpw-text: #0e1626;
  --zpw-muted: #5b6b80;
  --zpw-faint: #56647b;
  --zpw-line: #d5dde8;
  --zpw-primary: #1558c5;
  --zpw-green: #0d7956;
  --zpw-green-bg: #e3f6ee;
  --zpw-red: #b52c25;
  --zpw-red-bg: #fdeae6;
  --zpw-track: #e1e7ef;
  --zpw-scrim: rgb(14 22 38 / .28);
  --zpw-shadow: 0 18px 44px rgb(14 22 38 / .22);
  --zpw-glow: rgb(21 116 245 / .12);
}

/* 30.11.2026: светлая тема — кнопка скачивания и номер версии были почти не видны */
html[data-theme="light"] .release-card .button-primary{background:#1761C7;border-color:#1761C7;color:#fff;box-shadow:none}
html[data-theme="light"] .release-card .button-primary:hover{background:#12509f;border-color:#12509f;color:#fff}
html[data-theme="light"] .release-meta .release-version{color:#0e1626}
