#postScreen .post-dock .comment-row { margin-top: 16px; flex: 0 0 auto; }
#postScreen .post-dock.is-reply .comment-row { margin-top: 0; }
.reply-x {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--card);
  color: var(--muted);
  cursor: pointer;
  flex: 0 0 auto;
}
.reply-x .ico { width: 20px; height: 20px; }
.comment-row {
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 100%;
}
.comment-row textarea {
  flex: 1;
  min-width: 0;
  margin: 0;
  height: 40px;
  min-height: 40px;
  max-height: 140px;
  padding: 9px 12px;
  box-sizing: border-box;
  resize: none;
  line-height: 20px;
  background: #171a20;
}
html[data-theme="dark"] .comment-row textarea { background: #171a20; }
html[data-theme="light"] .comment-row textarea { background: #ffffff; }
.send-btn {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 0;
  background: var(--accent);
  color: var(--bg);
  display: grid;
  place-items: center;
  padding: 0;
}
.send-btn .ico { width: 20px; height: 20px; }
.sheet::-webkit-scrollbar { display: none; }
#commentList { scrollbar-width: none; }
#commentList::-webkit-scrollbar { display: none; }
.shelf { margin-bottom: 16px; }
.shelf h3 { margin: 0 0 8px; font-size: 15px; }
.empty { color: var(--muted); padding: 24px 8px; text-align: center; }
.post-page #commentList .empty { padding: 24px 8px 48px; }
.spoiler { filter: blur(6px); cursor: pointer; }
.spoiler.open { filter: none; }
.liked-comment { padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.people-list { display: flex; flex-direction: column; gap: 10px; }
.people-list .item { margin: 0; }
.deleted-comment { font-style: italic; font-size: 15px; line-height: 1.45; }
.check-row { display: flex; align-items: center; gap: 8px; margin: 10px 0; }
.check-row input { width: auto; margin: 0; min-height: auto; }
.emoji-pick { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 4px; }
.emoji-btn { font-size: 20px; width: 42px; height: 42px; min-width: 42px; min-height: 42px; padding: 0; display: grid; place-items: center; line-height: 1; transform: none; border: 1px solid var(--line); box-sizing: border-box; }
.emoji-btn.on {
  background: var(--accent-soft);
  color: inherit;
  font-weight: 400;
  font-size: 20px;
  border: 1px solid var(--accent);
  transform: none;
  box-shadow: none;
}
.site { max-width: none; width: 100%; margin: 0 auto; min-height: 100vh; }
.feed, .page { max-width: 710px; margin-left: auto; margin-right: auto; }
.auth-box {
  padding: 28px 22px 22px;
  max-width: 420px;
  width: calc(100% - 32px);
  margin: 0 auto;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
}
.search-bar {
  padding: 8px 10px 12px;
  height: 60px;
  min-height: 60px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
}
.search-bar input { margin: 0; min-height: 40px; height: 40px; padding-right: 42px; }
.profile-tools [title="Выйти"] .ico { transform: rotate(180deg); display: block; margin: 0; }
.sheet-title-actions { display: flex; align-items: center; gap: 6px; }
.clear-ask {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 10px;
  color: var(--text);
  font-size: 14px;
}
.clear-ask .btn-danger,
.clear-ask .btn-side {
  min-height: 34px;
  padding: 6px 12px;
  font-size: 13px;
}
.comment-row { position: relative; }
.comment-clear {
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0;
  display: grid;
  place-items: center;
  align-self: center;
}
.comment-clear .ico { width: 20px; height: 20px; }
#searchResults { display: flex; flex-direction: column; gap: 10px; }
.auth-box .logo, .brand-logo {
  font-family: Caveat, cursive;
  font-size: 40px;
  color: var(--accent);
  text-align: center;
  margin-bottom: 8px;
}
.auth-tabs { padding-left: 0; padding-right: 0; border: 0; }
.compose-tabs { padding: 4px 0 10px; margin: 0 0 4px; min-height: 48px; height: auto; overflow: visible; justify-content: flex-start; }
#authError { color: #ff6b6b; min-height: 18px; margin-top: 12px; }
#authOk { color: var(--accent); min-height: 18px; text-align: center; margin-top: 10px; }
.pass-wrap { position: relative; margin: 8px 0; }
.pass-wrap input { padding-right: 44px; margin: 0; }
.pass-eye {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  width: 34px; height: 34px; border: 0; background: transparent; padding: 0;
  color: var(--muted);
}
.pass-eye .ico { color: var(--muted); width: 20px; height: 20px; }
.profile-tools .icon-btn {
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--muted);
  border-radius: 999px;
  width: 36px;
  height: 36px;
  min-width: 36px;
  padding: 0;
  display: grid;
  place-items: center;
}
.profile-tools .icon-btn .ico,
.profile-tools .icon-btn svg { margin: 0 !important; display: block; }
.settings-actions { flex-direction: row; align-items: stretch; }
.settings-actions .btn-accent,
.settings-actions .btn-wide {
  flex: 1;
  width: auto;
  min-height: 40px;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 700;
}
.settings-actions .btn-wide {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}
.auth-actions { display: flex; gap: 8px; align-items: stretch; margin-top: 16px; }
.auth-actions .primary,
.auth-actions .ghost { flex: 1; min-height: 48px; padding: 12px 16px; font-size: 15px; }
.auth-box > .meta { text-align: center; }
#authScreen.overlay {
  position: fixed; inset: 0; z-index: 30;
  background: rgba(8,10,14,.72);
  overflow: auto;
  display: flex; align-items: center; justify-content: center;
}
.to-top {
  position: fixed;
  right: max(12px, calc(50% - 355px + 12px));
  bottom: 86px;
  z-index: 10;
  width: 42px; height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--card);
  color: var(--accent);
  font-size: 18px;
}
.notfound { text-align: center; padding: 12vh 24px 40px; max-width: 420px; margin: 0 auto; }
.nf-logo {
  width: 84px; height: 84px; margin: 0 auto 10px;
  background: var(--accent);
  -webkit-mask: url("/icons/logo.svg") center / contain no-repeat;
  mask: url("/icons/logo.svg") center / contain no-repeat;
}
.nf-code { font-size: 64px; font-weight: 800; color: var(--accent); line-height: 1; margin: 8px 0; letter-spacing: -0.04em; }
.notfound h1 { margin: 0 0 8px; font-size: 24px; }
.nf-btn {
  display: inline-block; margin-top: 22px; text-decoration: none;
  padding: 12px 22px; border-radius: 999px;
  background: var(--accent); color: var(--bg); font-weight: 700;
  box-shadow: 0 8px 20px color-mix(in srgb, var(--accent) 28%, transparent);
}
.sheet-actions { display: flex; align-items: center; justify-content: flex-start; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
#searchScreen .page { padding: 0; }
.btn-accent {
  flex: 0 0 auto; width: auto; border: 0; background: var(--accent); color: var(--bg);
  font-weight: 700; font-size: 14px; border-radius: 12px; padding: 10px 14px; min-height: 40px;
}
.btn-side {
  border: 1px solid var(--line); background: var(--card); color: var(--text);
  border-radius: 12px; padding: 10px 14px; min-height: 40px; font-size: 14px;
}
.sheet-x {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  min-height: 36px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--card);
  color: var(--muted);
  cursor: pointer;
  flex: 0 0 auto;
}
.sheet-x .ico { width: 20px; height: 20px; }
.btn-danger {
  border: 0; background: #d24a4a; color: #fff;
  font-weight: 700; font-size: 14px; border-radius: 12px; padding: 10px 14px; min-height: 40px;
}
.settings-actions { justify-content: space-between; margin-top: 6px; margin-bottom: 8px; padding-bottom: 0; flex-direction: row; align-items: stretch; }
.note.unread { border-color: var(--accent); }
#notifyList { display: flex; flex-direction: column; gap: 10px; }
#notifyScreen .page { padding: 10px 12px 0; }
#notifyTabs button { position: relative; }
.focus-comment { animation: blinkFocus 1.2s ease 0s 3; border-radius: 8px; }
@keyframes blinkFocus {
  0%, 100% { background-color: transparent; }
  50% { background-color: var(--accent); color: var(--bg); }
}
.profile-tools { display: inline-flex; gap: 6px; margin-left: 8px; }
#notifyScreen .page { padding: 10px 12px 0; }
#notifyList { padding: 0; width: 100%; gap: 10px; }
.ico { width: 20px; height: 20px; display: inline-block; vertical-align: -3px; }
#notifyList.feed { width: 100%; }
.sheet > .btn-accent { width: auto; margin-top: 8px; }
.name-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
#profileTabBox {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.auth-box .logo { font-family: Caveat, cursive; }

.thread { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; margin-bottom: 16px; }
.thread-part { border-left: 2px solid var(--accent); padding: 0 0 0 10px; }
.thread-n { font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.part-box { margin: 8px 0; }
.part-head { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; }
.part-head .part-del { min-height: 28px; padding: 4px 8px; font-size: 12px; margin-left: auto; }
.part-count { margin-left: auto; }

.thread-preview {
  cursor: pointer;
  -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
}
#searchInput {
  background: var(--card);
}
html[data-theme="dark"] #searchInput { background: #171a20; }
html[data-theme="light"] #searchInput { background: #ffffff; }

.thread-head { display: flex; gap: 10px; align-items: center; margin: 0; }
.thread-top {
  position: sticky;
  top: -16px;
  z-index: 30;
  background: var(--sheet);
  margin: -16px -16px 0;
  padding: 16px 16px 6px;
  border-bottom: 1px solid var(--line);
}
.sheet .thread-top + .spoiler-warn { margin-top: 10px; }
.thread-top .sheet-title { margin-bottom: 10px; }
.thread-full { padding: 10px 0 12px; margin: 0; }
.sheet:has(.thread-foot) { padding-bottom: 0; }
.thread-foot {
  position: sticky;
  bottom: 0;
  z-index: 30;
  background: var(--sheet);
  padding: 16px 16px 16px;
  margin: 0 -16px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.thread-foot .workchip { margin: 0; }

.score-line { font-size: 13px; font-weight: 800; margin-top: 2px; }
.score-hi { color: var(--accent); }
.score-mid { color: #e6b325; }
.score-lo { color: #e05656; }

#composeError { margin-top: 10px; }

.brand-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 60px;
}
.back-link {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  border: 0;
  background: transparent;
  color: var(--text);
  font-weight: 700;
  font-size: 14px;
  padding: 6px 8px;
  min-height: 36px;
}
.back-link .ico { width: 20px; height: 20px; }

.tab-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  flex: 0 0 auto;
}
.tab-back .ico { width: 20px; height: 20px; }

a.avatar-hit, a.handle-link { color: inherit; text-decoration: none; cursor: pointer; }

body.post-open { padding-bottom: 0; }
#postScreen { min-height: 100dvh; display: block; }
.post-page {
  flex: 1 0 auto;
  display: block;
  padding-bottom: 0;
}
.post-dock-spacer {
  display: block;
  width: 100%;
  height: calc(13px + var(--dock-h) + var(--hint-h));
  min-height: calc(13px + var(--dock-h) + var(--hint-h));
  pointer-events: none;
}
#commentList { margin-bottom: 0; padding-bottom: 0; }
#postScreen .post-dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  top: auto;
  z-index: 9;
  width: 100%;
  height: max-content;
  min-height: 0;
  flex: none;
  transform: none;
  margin: 0;
  background: var(--bg);
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  padding: 0 max(10px, calc((100% - 690px) / 2)) 16px;
  box-shadow: none;
  box-sizing: border-box;
  overflow: hidden;
}

.stats .report-btn,
.post-tools .report-btn,
.post-slot-actions .report-btn,
.shelf-head .report-btn,
.actions button.report-btn {
  padding: 0;
  width: 36px;
  height: 36px;
  min-width: 36px;
  display: grid;
  place-items: center;
}
.report-btn svg,
.report-btn .ico {
  margin: 0;
  vertical-align: 0;
}
