/* Aspecten — notes on Mac software
   Pieter, Utrecht, 2026 */

:root {
  --paper: #efeae2;
  --sheet: #f7f3ec;
  --ink: #17150f;
  --fade: #5e584e;
  --rule: #d2c9bb;
  --rule2: #b9ae9e;
  --tint: #e4dcd0;
  --nl: #c44700; /* dutch orange, sparingly */
  --nl2: #9a3400;
  --ok: #2c5a3a;
  --mast-h: 58px;
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Avenir Next", Avenir, "Segoe UI", "Helvetica Neue", sans-serif;
  font-size: 1.0125rem;
  line-height: 1.55;
  min-height: 100vh;
}

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

a {
  color: var(--ink);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--nl);
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

h1, h2, h3, h4 {
  font-family: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  font-weight: 600;
  line-height: 1.22;
  letter-spacing: -0.018em;
}

h1 { font-size: 1.85rem; margin: 0 0 0.55em; }
h2 { font-size: 1.38rem; margin: 1.6em 0 0.45em; }
h3 { font-size: 1.12rem; margin: 1.3em 0 0.35em; }

p { margin: 0 0 0.85em; }

ul, ol { margin: 0 0 1em; padding-left: 1.2em; }

code {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.86em;
  background: var(--tint);
  padding: 0.08em 0.28em;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

th, td {
  text-align: left;
  padding: 6px 10px 6px 0;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}

th {
  font-weight: 600;
  color: var(--fade);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--nl);
  outline-offset: 2px;
}

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: var(--ink);
  color: var(--sheet);
  padding: 6px 10px;
  z-index: 80;
}

.skip:focus {
  top: 8px;
  color: var(--sheet);
}

/* ---------- layout ---------- */

.shell {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.shell-n {
  width: min(760px, calc(100% - 32px));
  margin: 0 auto;
}

/* шапка */

.mast {
  border-bottom: 1px solid var(--rule2);
  background: var(--sheet);
}

.mast-in {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  min-height: var(--mast-h);
  padding: 8px 0;
}

.mark {
  font-family: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  font-size: 1.28rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: -0.03em;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.mark:hover { color: var(--ink); }

.mark img {
  width: 28px;
  height: 28px;
  display: block;
}

.tagline {
  display: none;
  color: var(--fade);
  font-size: 12px;
  letter-spacing: 0.02em;
}

.nav-tog {
  order: 2;
  margin-left: auto;
  background: none;
  border: 1px solid var(--rule2);
  width: 36px;
  height: 32px;
  padding: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-tog img { display: block; }

.cats {
  order: 4;
  width: 100%;
  display: none;
  flex-direction: column;
  gap: 0;
  border-top: 1px solid var(--rule);
  padding-top: 8px;
}

.cats a {
  text-decoration: none;
  font-size: 0.92rem;
  padding: 7px 0;
  border-bottom: 1px solid var(--rule);
}

.cats a.is-on,
.cats a[aria-current="page"] {
  color: var(--nl);
}

html:not(.js) .cats,
.cats.is-open {
  display: flex;
}

.who {
  order: 3;
  font-size: 0.92rem;
}

.who a { text-decoration: none; }

.who a:hover { text-decoration: underline; }

/* logged-in example bits — used on account / program */

.who-in {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  white-space: nowrap;
}

.bell {
  position: relative;
  background: none;
  border: 0;
  padding: 4px;
  cursor: pointer;
}

.bell img { display: block; }

.bell-n {
  position: absolute;
  top: -2px;
  right: -4px;
  background: var(--nl);
  color: #fff;
  font-size: 10px;
  line-height: 1;
  padding: 2px 4px;
  min-width: 14px;
  text-align: center;
}

.drop {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: min(320px, 86vw);
  background: var(--sheet);
  border: 1px solid var(--rule2);
  z-index: 40;
  padding: 6px 0;
}

.drop.is-open,
.bell:focus + .drop,
.drop:hover {
  display: block;
}

html.js .bell:focus + .drop,
html.js .drop:hover {
  display: none; /* safari: иначе прыгает — открывает наш бэкенд-скрипт */
}

html.js .drop.is-open { display: block; }

.drop a,
.drop .n-item {
  display: block;
  padding: 8px 12px;
  text-decoration: none;
  font-size: 0.88rem;
  border-bottom: 1px solid var(--rule);
}

.n-item.is-new {
  background: #f3e6d8;
}

.n-item time {
  display: block;
  color: var(--fade);
  font-size: 12px;
  margin-top: 2px;
}

.drop-all {
  text-align: center;
  font-size: 0.85rem;
  padding: 8px;
}

.ava {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

.ava i {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--sheet);
  font-style: normal;
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.04em;
}

.signout {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

/* ---------- meter ---------- */

.meter {
  position: sticky;
  top: 0;
  height: 3px;
  background: transparent;
  z-index: 30;
  pointer-events: none;
}

.meter > i {
  display: block;
  height: 100%;
  width: 0;
  background: var(--nl);
}

/* ---------- listing rows ---------- */

.kicker {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fade);
  margin: 0 0 8px;
}

.lead {
  font-size: 1.06rem;
  max-width: 40em;
}

.crumbs {
  font-size: 0.86rem;
  color: var(--fade);
  margin: 0 0 18px;
}

.crumbs a { color: var(--fade); text-decoration: none; }
.crumbs a:hover { color: var(--nl); }
.crumbs span { margin: 0 0.35em; color: var(--rule2); }

.sec {
  margin: 2.4rem 0 0;
}

.sec-hd {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 6px;
  margin-bottom: 0;
}

.sec-hd h2 {
  margin: 0;
  font-size: 1.2rem;
}

.sec-hd a {
  font-size: 0.88rem;
  white-space: nowrap;
}

.cols {
  display: grid;
  grid-template-columns: 1fr;
}

.row {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) auto;
  grid-template-areas:
    "ico main sz"
    "ico rub sz";
  gap: 2px 12px;
  align-items: center;
  padding: 11px 8px;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
  color: inherit;
}

.row:hover {
  background: var(--sheet);
  color: inherit;
}

.row-ico {
  grid-area: ico;
  width: 56px;
  height: 56px;
  border: 1px solid var(--rule);
  background: #ddd6c8;
}

.row-main {
  grid-area: main;
  min-width: 0;
}

.row-name {
  display: block;
  font-weight: 600;
  overflow-wrap: anywhere;
  line-height: 1.3;
}

.row-ver {
  color: var(--fade);
  font-size: 0.84rem;
  font-weight: 400;
}

.row-rub {
  grid-area: rub;
  font-size: 0.78rem;
  color: var(--fade);
}

.row-sz {
  grid-area: sz;
  font-size: 12px;
  letter-spacing: 0.04em;
  border: 1px solid var(--rule2);
  padding: 2px 6px;
  white-space: nowrap;
  justify-self: end;
}

.row-flag {
  display: inline-block;
  margin-left: 6px;
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--nl);
  border-bottom: 1px solid var(--nl);
}

/* ---------- program head ---------- */

.prog-hd {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  gap: 14px 16px;
  align-items: start;
  margin-bottom: 1.1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--rule2);
}

.prog-ico {
  width: 64px;
  height: 64px;
  border: 1px solid var(--rule);
}

.prog-hd h1 {
  margin: 0 0 0.25em;
  font-size: 1.72rem;
  overflow-wrap: anywhere;
}

.rub-link {
  font-size: 0.86rem;
  color: var(--fade);
}

.ax {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 10px 0 0;
  grid-column: 1 / -1;
}

.ax a {
  text-decoration: none;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid var(--rule2);
  padding: 4px 8px;
}

.ax a:hover {
  border-color: var(--nl);
  color: var(--nl);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 0 0 1.4rem;
}

.btn {
  display: inline-block;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--sheet);
  padding: 8px 14px;
  text-decoration: none;
  font-size: 0.92rem;
  cursor: pointer;
}

.btn:hover { color: var(--sheet); background: var(--nl2); border-color: var(--nl2); }

.btn-ghost {
  background: transparent;
  color: var(--ink);
}

.btn-ghost:hover { color: var(--nl); background: transparent; border-color: var(--nl); }

.btn.is-on {
  border-color: var(--nl);
  color: var(--nl);
  background: transparent;
}

.btn img.ico {
  display: inline-block;
  vertical-align: -3px;
  margin-right: 6px;
}

.btn:not(.btn-ghost) img.ico {
  filter: brightness(0) invert(1);
}

.btn-ghost img.ico {
  /* ink icons sit a hair high in the button */
  margin-top: -1px;
}

.when {
  font-size: 0.86rem;
  color: var(--fade);
  margin-left: auto;
}

/* shots */

.shots {
  position: relative;
  margin: 0 0 1.6rem;
}

.shots-track {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 6px;
}

.shots-track figure {
  margin: 0;
  flex: 0 0 82%;
  scroll-snap-align: start;
  border: 1px solid var(--rule);
  background: var(--tint);
}

.shots-track img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.shots-btn {
  display: none;
  position: absolute;
  top: 42%;
  background: var(--sheet);
  border: 1px solid var(--rule2);
  width: 32px;
  height: 32px;
  cursor: pointer;
  z-index: 2;
}

.shots-btn.prev { left: 6px; }
.shots-btn.next { right: 6px; }

.shots-btn img {
  display: block;
  margin: 0 auto;
}

html.js .shots-btn { display: block; }

/* tabs — без js все панели видны подряд */

.tabs-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border-bottom: 1px solid var(--ink);
  margin: 0 0 1.1rem;
}

.tabs-nav button {
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 8px 14px 8px 0;
  margin-right: 14px;
  cursor: pointer;
  font-size: 0.95rem;
}

.tabs-nav button[aria-selected="true"] {
  border-bottom-color: var(--nl);
}

html:not(.js) .tabs-nav { display: none; }

html:not(.js) .pane[hidden] {
  display: block !important;
}

html:not(.js) .pane + .pane {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--rule);
}

.pane h2:first-child { margin-top: 0; }

/* article type */

.copy {
  font-size: 1.05rem;
  line-height: 1.68;
}

.copy p {
  margin-bottom: 0.95em;
}

.toc {
  background: var(--sheet);
  border: 1px solid var(--rule);
  padding: 12px 16px;
  margin: 0 0 1.4rem;
  font-size: 0.92rem;
}

.toc strong {
  display: block;
  font-family: "Iowan Old Style", Palatino, Georgia, serif;
  margin-bottom: 6px;
}

.toc ol {
  margin: 0;
  padding-left: 1.15em;
}

.toc a { text-decoration: none; }
.toc a:hover { text-decoration: underline; }

.glance {
  margin: 1.2rem 0 1.6rem;
  border: 1px solid var(--rule2);
  padding: 8px 14px 4px;
  background: var(--sheet);
}

.glance caption {
  caption-side: top;
  text-align: left;
  font-family: "Iowan Old Style", Palatino, Georgia, serif;
  font-weight: 600;
  padding: 6px 0 8px;
}

.side {
  margin-top: 2rem;
  border-top: 1px solid var(--ink);
  padding-top: 12px;
}

.facts {
  font-size: 0.9rem;
}

.facts div {
  display: block;
  padding: 8px 0;
  border-bottom: 1px solid var(--rule);
}

.facts div span:last-child {
  display: block;
  margin-top: 2px;
}

.facts dt,
.facts .k {
  color: var(--fade);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* faq */

.faq details {
  border-bottom: 1px solid var(--rule);
  padding: 8px 0;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
}

.faq p { margin: 0.5em 0 0.2em; }

/* comments */

.talk {
  margin-top: 2.4rem;
  border-top: 1px solid var(--ink);
  padding-top: 1rem;
}

.talk-hd {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}

.sort button {
  background: none;
  border: 0;
  padding: 0 0 2px;
  margin-left: 10px;
  cursor: pointer;
  color: var(--fade);
}

.sort button[aria-pressed="true"] {
  color: var(--ink);
  border-bottom: 1px solid var(--nl);
}

.cform textarea {
  width: 100%;
  min-height: 110px;
  border: 1px solid var(--rule2);
  background: var(--sheet);
  padding: 8px 10px;
  display: block;
  margin: 8px 0;
}

.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.hint, .err {
  font-size: 0.86rem;
}

.err { color: #8b1c12; }

.clist { margin-top: 1.2rem; }

.citem {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 10px;
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
}

.citem.is-wait {
  opacity: 0.55;
}

.badge {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border: 1px solid var(--rule2);
  padding: 1px 6px;
  margin-left: 6px;
}

.cmeta {
  font-size: 0.86rem;
  color: var(--fade);
  margin-bottom: 4px;
}

.cfoot {
  margin-top: 6px;
  display: flex;
  gap: 14px;
  font-size: 0.86rem;
}

.cfoot button {
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

.cfoot button.is-on { color: var(--nl); }

.replies {
  grid-column: 2;
  margin-top: 8px;
  padding-left: 8px;
  border-left: 2px solid var(--rule);
}

.void {
  color: var(--fade);
  padding: 1.2rem 0;
}

/* auth */

.form {
  max-width: 420px;
}

.field {
  margin-bottom: 14px;
}

.field label {
  display: block;
  font-size: 0.86rem;
  margin-bottom: 4px;
}

.field input {
  width: 100%;
  border: 1px solid var(--rule2);
  background: var(--sheet);
  padding: 8px 10px;
}

.field .err { margin-top: 4px; }

.check {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 0.92rem;
  margin: 12px 0;
}

.ok-msg {
  border: 1px solid var(--ok);
  color: var(--ok);
  padding: 8px 10px;
  margin-bottom: 12px;
  font-size: 0.92rem;
}

/* account */

.tabs-acc {
  display: flex;
  flex-wrap: wrap;
  gap: 0 18px;
  border-bottom: 1px solid var(--ink);
  margin: 0 0 1.2rem;
}

.tabs-acc a {
  text-decoration: none;
  padding: 8px 0 6px;
}

.tabs-acc a.is-on {
  border-bottom: 2px solid var(--nl);
}

.me-hd {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 1.2rem;
}

.me-hd i {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--sheet);
  font-style: normal;
  display: flex;
  align-items: center;
  justify-content: center;
}

.n-list a {
  display: block;
  padding: 10px 0;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
}

.n-list time {
  display: block;
  color: var(--fade);
  font-size: 12px;
}

/* pager */

.pager {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 1.6rem 0 0;
  align-items: center;
}

.pager a,
.pager strong {
  min-width: 2em;
  text-align: center;
  padding: 4px 8px;
  text-decoration: none;
  border: 1px solid transparent;
}

.pager strong {
  border-color: var(--ink);
}

/* modal — без их скрипта открывается через :target */

.dlg {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(23, 21, 15, 0.42);
  z-index: 60;
  padding: 24px 12px;
  overflow: auto;
}

.dlg:target,
.dlg.is-open {
  display: block;
}

.dlg-box {
  width: min(560px, 100%);
  margin: 8vh auto;
  background: var(--sheet);
  border: 1px solid var(--ink);
  padding: 18px 20px 22px;
  position: relative;
}

.dlg-x {
  position: absolute;
  top: 8px;
  right: 8px;
  background: none;
  border: 0;
  width: 32px;
  height: 32px;
  cursor: pointer;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dlg-x img { display: block; }

.mirrors {
  margin-top: 1rem;
}

.mirrors h3 {
  font-size: 0.95rem;
  margin-top: 1rem;
}

.mirrors a {
  display: inline-block;
  margin: 0 8px 8px 0;
}

/* footer */

.foot {
  margin-top: 3.2rem;
  border-top: 1px solid var(--ink);
  padding: 18px 0 36px;
  font-size: 0.88rem;
}

.foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin-bottom: 10px;
}

.foot a { text-decoration: none; }

.copyr { color: var(--fade); }

.top {
  position: fixed;
  right: 14px;
  bottom: 14px;
  width: 36px;
  height: 36px;
  border: 1px solid var(--rule2);
  background: var(--sheet);
  cursor: pointer;
  display: none;
  z-index: 20;
  padding: 0;
}

.top img {
  display: block;
  margin: 8px auto 0;
}

.top.is-show {
  display: flex;
  align-items: center;
  justify-content: center;
}

.top img { margin: 0; }

/* err pages */

.bang {
  padding: 12vh 0 18vh;
}

.bang h1 { font-size: 2.1rem; }

/* ---------- pages extras ---------- */

.intro-list {
  max-width: 38em;
}

main {
  padding-top: 28px;
}

/* safari: sticky meter поверх шапки на программе */
body.is-read .mast { border-bottom-color: var(--rule); }

/* ---------- media ---------- */

@media (min-width: 640px) {
  h1 { font-size: 2.05rem; }

  .row {
    grid-template-columns: 56px minmax(0, 1fr) 140px 72px;
    grid-template-areas: "ico main rub sz";
    column-gap: 16px;
  }

  .row-rub { justify-self: start; }

  .shots-track figure { flex-basis: 56%; }

  .prog-hd h1 { font-size: 2rem; }
}

@media (min-width: 960px) {
  .nav-tog { display: none; }

  .mast-in {
    display: grid;
    grid-template-columns: auto 1fr auto;
    grid-template-rows: auto auto;
    align-items: center;
    row-gap: 4px;
    padding: 10px 0 8px;
  }

  .mark { grid-column: 1; grid-row: 1; }
  .tagline {
    grid-column: 2;
    grid-row: 1;
    display: block;
    margin: 0 0 0 14px;
  }
  .who {
    grid-column: 3;
    grid-row: 1;
    margin: 0;
    order: 0;
    justify-self: end;
  }
  .nav-tog { display: none; }

  .cats {
    grid-column: 1 / -1;
    grid-row: 2;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    width: 100%;
    order: 0;
    border-top: 1px solid var(--rule);
    padding: 8px 0 2px;
    gap: 6px 18px;
    justify-content: flex-start;
  }

  .cats a {
    border: 0;
    padding: 2px 0;
    font-size: 0.86rem;
  }

  .cols {
    grid-template-columns: 1fr 1fr;
    column-gap: 0;
  }

  .cols .row {
    padding-left: 12px;
    padding-right: 12px;
    border-left: 1px solid var(--rule);
  }

  .cols .row:nth-child(odd) {
    border-left: 0;
    padding-left: 0;
  }

  .layout {
    display: grid;
    grid-template-columns: minmax(0, 760px) 220px;
    gap: 0 48px;
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
  }

  .layout .copy-col { min-width: 0; }

  .side {
    margin-top: 0;
    border-top: 0;
    padding-top: 0;
    border-left: 1px solid var(--rule);
    padding-left: 28px;
  }

  .toc {
    position: sticky;
    top: 18px;
  }
}

/* узкая колонка для служебных */

.page-n main {
  width: min(760px, calc(100% - 32px));
  margin: 0 auto;
}

/* программа: мелкий сдвиг заголовка вкладки What's new */
.pane-new h2 { letter-spacing: -0.01em; }

.page-n .foot .shell {
  width: min(760px, calc(100% - 32px));
}

.me-hd h1 { margin: 0 0 0.15em; font-size: 1.55rem; }

.citem > .ava,
.citem > i.ava {
  width: 36px;
  height: 36px;
}

.dlg-box ol { padding-left: 1.2em; }

@media (min-width: 960px) {
  .cats a.is-on {
    box-shadow: 0 1px 0 var(--nl);
  }
}

/* seo: текст вступления после первого блока программ */
.home-about { margin-top: 32px; margin-bottom: 32px; }
.home-about__body { margin-top: 10px; }

/* ---- натяжка на сайт ---- */
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
/* поиск: в подвале, на странице поиска и на 404 */
.find, .foot-find { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 14px 0 22px; max-width: 34rem; }
.find input, .foot-find input {
  flex: 1 1 14rem; min-width: 0; font: inherit; padding: 8px 10px;
  border: 1px solid var(--rule2); background: var(--sheet); color: var(--ink);
}
.foot-find { margin: 14px 0 10px; }
.foot-find .btn { padding-top: 7px; padding-bottom: 7px; }
/* окно: ссылки зеркал кнопками, группы не слипаются */
.dlg .mirrors { margin-top: 12px; }
.dlg .mirrors + .mirrors { margin-top: 16px; }
.dlg .mirrors a {
  padding: 7px 12px; border: 1px solid var(--rule2); text-decoration: none; color: var(--ink); background: var(--sheet);
}
.dlg .mirrors a:first-of-type { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.dlg .mirrors a:hover { border-color: var(--nl); }
.dlg-body > p { color: var(--fade); }
/* непрочитанные уведомления в кабинете */
.n-list a.is-new { font-weight: 600; }
/* форма DMCA под текстом страницы */
#notice { margin-top: 2.4rem; }
#notice textarea, .cform textarea { width: 100%; min-height: 90px; font: inherit; padding: 8px 10px; border: 1px solid var(--rule2); background: var(--sheet); resize: vertical; }
#notice .check { align-items: flex-start; }
.field textarea { width: 100%; }
.talk .hint a { color: var(--nl2); }
/* программа на телефоне: те же поля, что у остальных страниц */
.layout { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
/* поиск в подвале: поле и кнопка в строку */
.foot-find { flex-wrap: nowrap; }
.foot-find input { flex: 1 1 auto; }
html.js .bell:focus + .drop.is-open, html.js .drop.is-open:hover { display: block; } /* фокус на колокольчике не прячет открытый список */

/* ---- правки по просмотру: ширина, акценты, поиск в шапке ---- */
/* текст «о сайте» и описание рубрики — во всю рабочую ширину */
.home-about .lead, .home-about__body, .home-about__body p, .home-about__body ul { max-width: none; }
/* блок «Nearby» под программой по центру, как остальные */
.shell.sec { margin-left: auto; margin-right: auto; }
.layout + .shell.sec { margin-top: 3rem; }
/* шапка прилипает, поиск всегда под рукой */
.mast { position: sticky; top: 0; z-index: 50; }
.find-tog { order: 2; margin-left: auto; background: none; border: 1px solid var(--rule2); width: 36px; height: 32px; padding: 0; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; color: var(--ink); }
.nav-tog { margin-left: 0; }
.mast-find { order: 5; width: 100%; display: none; gap: 6px; padding-top: 6px; }
.mast-find.is-open { display: flex; }
.mast-find input { flex: 1 1 auto; min-width: 0; font: inherit; padding: 8px 10px; border: 1px solid var(--rule2); background: #fffdf9; color: var(--ink); }
.mast-find input:focus { outline: 2px solid var(--nl); outline-offset: 0; }
.mast-find button { background: var(--ink); color: var(--sheet); border: 1px solid var(--ink); width: 40px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.mast-find button:hover { background: var(--nl2); border-color: var(--nl2); }
@media (min-width: 960px) {
  .find-tog { display: none; }
  .mast-in { grid-template-columns: auto 1fr minmax(220px, 300px) auto; column-gap: 16px; }
  .mast-find { display: flex; grid-column: 3; grid-row: 1; width: auto; padding: 0; order: 0; }
  .who { grid-column: 4; }
  .tagline { margin-left: 4px; }
}
/* «Log in» и «Download» — заметные кнопки */
.who > a:only-child, .who a[href$="/login/"] {
  display: inline-block; background: var(--nl); color: #fff; padding: 6px 14px; border: 1px solid var(--nl);
  font-weight: 600; text-decoration: none; letter-spacing: .01em;
}
.who > a:only-child:hover, .who a[href$="/login/"]:hover { background: var(--nl2); border-color: var(--nl2); color: #fff; text-decoration: none; }
.actions .btn:not(.btn-ghost) {
  background: var(--nl); border-color: var(--nl); color: #fff; padding: 11px 22px; font-size: 1.02rem; font-weight: 600;
  box-shadow: 0 2px 0 var(--nl2);
}
.actions .btn:not(.btn-ghost):hover { background: var(--nl2); border-color: var(--nl2); }
.actions .btn-ghost { background: var(--sheet); padding-top: 11px; padding-bottom: 11px; }
/* страница программы живее: белые карточки на бумаге */
.layout .tabs-nav button[aria-selected="true"] { color: var(--nl2); border-bottom-color: var(--nl); }
.layout .toc { background: #fffdf9; border-color: var(--rule2); border-left: 3px solid var(--nl); }
.side { background: #fffdf9; border: 1px solid var(--rule); padding: 18px 20px; }
.side .kicker { color: var(--nl2); }
.layout .faq details { background: #fffdf9; border: 1px solid var(--rule); padding: 10px 14px; margin-bottom: 8px; }
.talk { background: #fffdf9; border: 1px solid var(--rule); padding: 18px 20px; margin-top: 2rem; }
@media (min-width: 960px) { .side { border-left: 1px solid var(--rule); } }
.row:hover { background: #fffdf9; }

/* ---- скриншоты: «таблица образцов» (с JS); без JS остаётся прокручиваемая лента ---- */
.shots.is-ready .shots-track, .shots.is-ready > .shots-btn { display: none; }
.plate { margin: 0; }
.plate-frame {
  display: block; background: #fffdf9; padding: 10px; border: 1px solid var(--rule2);
  box-shadow: 6px 6px 0 var(--tint); position: relative;
}
.plate-frame::before {
  content: ""; position: absolute; inset: 5px; border: 1px solid var(--rule); pointer-events: none;
}
.plate-frame img { display: block; width: 100%; height: auto; max-height: 430px; object-fit: contain; background: #f2ede4; margin: 0 auto; }
.plate-cap {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; padding: 14px 2px 0;
  font-size: 0.86rem; color: var(--fade);
}
.plate-no { font-variant: small-caps; letter-spacing: .08em; color: var(--nl2); font-weight: 600; white-space: nowrap; }
.plate-txt { flex: 1 1 14rem; min-width: 0; }
.plate-nav { margin-left: auto; display: inline-flex; gap: 14px; }
.plate-nav button { background: none; border: 0; border-bottom: 1px solid var(--rule2); padding: 0 0 1px; font: inherit; color: var(--ink); cursor: pointer; }
.plate-nav button:hover { color: var(--nl); border-bottom-color: var(--nl); }
.plate-rule { display: flex; gap: 5px; margin-top: 12px; }
.plate-rule button { flex: 1 1 0; height: 5px; border: 0; padding: 0; background: var(--rule2); cursor: pointer; }
.plate-rule button:hover { background: var(--fade); }
.plate-rule button.is-on { background: var(--nl); }
@media (max-width: 559px) { .plate-frame { padding: 6px; box-shadow: 4px 4px 0 var(--tint); } .plate-frame::before { inset: 3px; } }

/* ---- выравнивание размеров ---- */
/* шапка: поле, кнопка поиска и «Log in» одной высоты */
.mast-find input, .mast-find button, .who a[href$="/login/"], .who > a:only-child { height: 40px; box-sizing: border-box; }
.who a[href$="/login/"], .who > a:only-child { display: inline-flex; align-items: center; padding: 0 16px; line-height: 1; }
.mast-find input { padding-top: 0; padding-bottom: 0; }
.mast-find button { width: 40px; padding: 0; }
.find-tog, .nav-tog { height: 40px; width: 40px; }
/* кнопки действий программы: одинаковая высота, текст по центру */
.actions .btn { display: inline-flex; align-items: center; justify-content: center; height: 44px; box-sizing: border-box; padding: 0 20px; font-size: 0.98rem; line-height: 1; margin: 0; }
.actions .btn:not(.btn-ghost) { font-weight: 600; box-shadow: none; }
.actions .btn img.ico { margin: 0 8px 0 0; vertical-align: 0; }
.actions .btn span { display: inline; }
/* правая колонка — по высоте содержимого, а не до конца страницы */
.layout { align-items: start; }
.side { align-self: start; }
