/* MossStack — layout measured from sspai.com @ 1280px
   Original MossStack content. No sspai logo, π wordmark, or Matrix branding. */

:root {
  --bg: #ffffff;
  --band: #F7F8F9;
  --ink: #000000;
  --meta: #6F7174;
  --line: #ECECEC;
  --blue: #0F88EB;
  --red: #D8232A;
  --header-h: 57px;
  --page: 960px;
  --rail: 180px;
  --feed: 520px;
  --side: 220px;
  --gap: 20px;
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Noto Sans CJK SC", "Noto Sans SC", helvetica, Arial, sans-serif;
  --mono: "SFMono-Regular", Menlo, Consolas, "Noto Sans Mono CJK SC", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; background: none; border: 0; cursor: pointer; padding: 0; color: inherit; }
code, kbd, pre { font-family: var(--mono); }

.skip {
  position: absolute; left: 12px; top: -40px; z-index: 80;
  background: var(--ink); color: #fff; padding: 8px 12px; border-radius: 6px;
}
.skip:focus { top: 10px; }

.page {
  width: var(--page);
  margin-inline: auto;
}

/* Header chrome lives in header.css */

/* ——— Hero band ——— */
.hero-band {
  background: #fff;
  padding: 16px 0 12px;
}
.hero-well {
  background: var(--band);
  border-radius: 8px;
  padding: 0;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: var(--rail) var(--feed) var(--side);
  column-gap: var(--gap);
  align-items: stretch;
}
.hero-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
  height: 400px;
}
.mini-card {
  position: relative;
  flex: 1;
  min-height: 110px;
  border-radius: 8px;
  overflow: hidden;
  background: #e8e9ea;
  display: block;
}
.mini-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.mini-card .cap {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 10px 10px 8px;
  background: linear-gradient(transparent, rgba(0,0,0,.62));
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.35;
}
.hero-main {
  position: relative;
  display: block;
  height: 400px;
  border-radius: 8px;
  overflow: hidden;
  background: #111;
}
.hero-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-overlay {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 28px 22px 20px;
  background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,.72) 100%);
  color: #fff;
}
.hero-overlay h2 {
  margin: 0 0 6px;
  font-size: 22px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0.01em;
}
.hero-overlay p {
  margin: 0;
  font-size: 13px;
  color: rgba(255,255,255,.82);
}

/* ——— Three-column home ——— */
.home-layout {
  display: grid;
  grid-template-columns: var(--rail) var(--feed) var(--side);
  column-gap: var(--gap);
  align-items: start;
  padding: 12px 0 96px;
}

/* Left rail */
.left-rail {
  position: sticky;
  top: calc(var(--header-h) + 16px);
}
.rail-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  font-size: 14px;
  color: var(--meta);
}
.rail-nav a svg { width: 16px; height: 16px; flex: 0 0 16px; }
.rail-nav a.is-active {
  color: #000;
  font-weight: 600;
}
.rail-nav a:hover { color: #000; }
.rail-copy {
  margin: 28px 0 0;
  font-size: 12px;
  color: #B4B6B8;
  line-height: 1.6;
}

/* Article rows — text left, thumb right. No card chrome. */
.feed { min-width: 0; width: 520px; }
.feed-item {
  display: flex;
  gap: 24px;
  align-items: flex-start;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  min-height: 188px;
  color: inherit;
}
.feed > .feed-item:first-of-type { border-top: 1px solid var(--line); }
.item-body {
  flex: 1 1 auto;
  width: 306px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 124px;
}
.item-title {
  margin: 0;
  font-size: 20px;
  font-weight: 500;
  line-height: 34px;
  color: #000;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.feed-item:hover .item-title { color: #111; }
.item-excerpt {
  margin: 6px 0 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--meta);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.item-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 12px;
  font-size: 13px;
  color: var(--meta);
  line-height: 1;
}
.avatar {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 9px;
  font-weight: 600;
  color: #fff;
  flex-shrink: 0;
  line-height: 1;
}
.avatar.a-mang { background: #c45c4a; }
.avatar.a-ed { background: #5a6b7a; }
.avatar.lg {
  width: 32px;
  height: 32px;
  font-size: 13px;
}
.chip {
  display: inline-block;
  font-size: 12px;
  color: var(--meta);
  background: #F4F5F6;
  border-radius: 3px;
  padding: 2px 6px;
  line-height: 1.3;
}
.thumb {
  width: 166px;
  height: 124px;
  flex: 0 0 166px;
  border-radius: 4px;
  overflow: hidden;
  background: #eee;
  margin-top: 4px;
}
.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Right sidebar */
.right-side { min-width: 0; }
.watching-title {
  margin: 0 0 4px;
  font-size: 18px;
  font-weight: 600;
  color: #000;
}
.watch-item {
  display: block;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.watch-item .t {
  margin: 0;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
  color: #000;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.watch-item .m {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--meta);
}
.watch-item:hover .t { color: var(--blue); }
.promos { margin-top: 18px; display: flex; flex-direction: column; gap: 12px; }
.promo {
  display: block;
  width: 198px;
  height: 92px;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  background: #ddd;
}
.promo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.promo .promo-cap {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 8px 10px;
  background: linear-gradient(transparent, rgba(0,0,0,.6));
  color: #fff;
  font-size: 12px;
  font-weight: 500;
}

/* Archives filters */
.filters {
  display: flex;
  gap: 20px;
  padding: 8px 0 16px;
  border-bottom: 1px solid var(--line);
  margin-bottom: -1px;
}
.filter {
  font-size: 14px;
  color: var(--meta);
  padding: 4px 0;
}
.filter.is-on { color: #000; font-weight: 500; }
.filter:hover { color: #000; }

.feed-heading {
  margin: 8px 0 4px;
  font-size: 20px;
  font-weight: 600;
  color: #000;
  line-height: 1.35;
}
.feed-heading + .filters { padding-top: 12px; }
.list-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 28px 0 8px;
  font-size: 13px;
  color: var(--meta);
}
.list-pager a { color: var(--ink); }
.list-pager a:hover { color: var(--blue); }
.empty-feed {
  margin: 0;
  padding: 40px 0;
  font-size: 14px;
  color: var(--meta);
}
.thumb.is-empty {
  background: #eee;
  background-image: linear-gradient(135deg, #eee 25%, #e4e5e6 25%, #e4e5e6 50%, #eee 50%, #eee 75%, #e4e5e6 75%);
  background-size: 16px 16px;
}
.item-meta .avatar.photo {
  width: 16px;
  height: 16px;
}

/* Footer (minimal; copyright lives in left rail on home) */
.site-footer {
  display: none;
}

/* Floating help / top */
.float-btns {
  position: fixed;
  right: 28px;
  bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 45;
}
.float-btns a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 2px 10px rgba(0,0,0,.08);
  display: grid;
  place-items: center;
  color: var(--meta);
}
.float-btns a:hover { color: #000; }
.float-btns svg { width: 16px; height: 16px; }

/* ——— Article reading (lives in the 520px feed, same chrome as archives) ——— */
.reading-layout {
  padding-bottom: 120px;
}
.reading .article-date {
  margin: 4px 0 8px;
}
.reading .article-title {
  margin: 0 0 16px;
  font-size: 28px;
  font-weight: 600;
  line-height: 1.36;
  letter-spacing: -0.01em;
  color: #000;
}
.article-date {
  margin: 0 0 10px;
  font-size: 13px;
  color: var(--meta);
}
.article-title {
  margin: 0 0 20px;
  font-size: 28px;
  font-weight: 600;
  line-height: 1.36;
  letter-spacing: -0.01em;
  color: #000;
}
.byline {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 20px;
}
.byline-name {
  font-size: 14px;
  font-weight: 500;
  color: #000;
}
.follow {
  height: 22px;
  padding: 0 8px;
  margin-left: 2px;
  border: 1px solid var(--red);
  color: var(--red);
  border-radius: 4px;
  font-size: 12px;
  line-height: 20px;
  font-weight: 500;
}
.follow:hover {
  background: var(--red);
  color: #fff;
}
.byline-rest {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--meta);
}
.byline-rest .dot { color: #C8C9CB; }
.byline-rest .like-n {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}
.byline-rest .like-n svg { width: 14px; height: 14px; }

.cover-full {
  margin: 0 0 22px;
  border-radius: 4px;
  overflow: hidden;
  background: #eee;
  width: 100%;
  height: 240px;
}
.cover-full img {
  width: 100%;
  height: 240px;
  object-fit: cover;
}

.reading .prose {
  font-size: 15px;
  line-height: 1.85;
  color: #1a1a1a;
}
.prose {
  font-size: 15px;
  line-height: 1.85;
  color: #1a1a1a;
}
.prose h2 {
  margin: 1.7em 0 0.5em;
  font-size: 18px;
  font-weight: 600;
  color: #000;
}
.prose p { margin: 0 0 1.1em; }
.prose ul { margin: 0 0 1.2em; padding-left: 1.25em; }
.prose li { margin: 0.3em 0; }
.prose a { color: var(--blue); }
.prose code {
  font-size: 0.88em;
  background: #F4F5F6;
  padding: 1px 5px;
  border-radius: 3px;
}

.reading .flow {
  display: grid;
  grid-template-columns: 1fr 16px 1fr 16px 1fr;
  gap: 4px;
  align-items: stretch;
  margin: 4px 0 22px;
  padding: 10px 8px;
  background: var(--band);
  border-radius: 8px;
}
.flow {
  display: grid;
  grid-template-columns: 1fr 16px 1fr 16px 1fr;
  gap: 4px;
  align-items: stretch;
  margin: 4px 0 22px;
  padding: 10px 8px;
  background: var(--band);
  border-radius: 8px;
}
.flow-node {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 8px 8px;
}
.flow-num {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--blue);
  margin-bottom: 3px;
}
.flow-node h3 { margin: 0 0 4px; font-size: 13px; font-weight: 600; color: #000; }
.flow-node p { margin: 0; font-size: 11.5px; line-height: 1.5; color: var(--meta); }
.flow-arrow { display: grid; place-items: center; color: #c0c0c0; font-size: 14px; }

.codebox {
  margin: 0 0 1.4em;
  background: #F7F8F9;
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
}
.codebox header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px 0;
  color: var(--meta);
  font-size: 12px;
}
.copy {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--meta);
  border-radius: 4px;
  height: 24px;
  padding: 0 8px;
  font-size: 12px;
}
.copy:hover { color: #000; }
.codebox pre {
  margin: 0;
  padding: 10px 14px 14px;
  overflow: auto;
  font-size: 12.5px;
  line-height: 1.7;
  color: #2b2b2b;
}
.codebox .cmt { color: #8a8a8a; }
.codebox .cmd { color: var(--blue); font-weight: 600; }

.pullquote {
  margin: 0 0 1.3em;
  padding: 2px 0 2px 14px;
  border-left: 3px solid #111;
  font-size: 15.5px;
  line-height: 1.75;
  color: #111;
  font-weight: 500;
}
.pullquote code {
  font-size: 0.88em;
  background: #F4F5F6;
  padding: 1px 5px;
  border-radius: 3px;
  font-weight: 400;
}

.callout {
  margin: 0 0 1.3em;
  padding: 12px 14px;
  background: #F4F8FD;
  border-radius: 6px;
  color: #1a1a1a;
  font-size: 13.5px;
  line-height: 1.7;
}

.layer-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.4em;
  font-size: 13px;
  line-height: 1.5;
}
.layer-table th,
.layer-table td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.layer-table th {
  font-weight: 500;
  color: var(--meta);
  background: var(--band);
  font-size: 12px;
}
.layer-table td:first-child {
  font-weight: 500;
  color: #000;
  white-space: nowrap;
  width: 56px;
}
.layer-table code {
  font-size: 12px;
  background: #F4F5F6;
  padding: 1px 4px;
  border-radius: 3px;
}

.inline-fig {
  margin: 0 0 1.4em;
}
.inline-fig img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 4px;
  background: #eee;
}
.inline-fig figcaption {
  margin-top: 8px;
  font-size: 12px;
  color: var(--meta);
  line-height: 1.55;
}

.check-list {
  list-style: none;
  margin: 0 0 1.2em;
  padding: 12px 14px;
  background: var(--band);
  border-radius: 6px;
}
.check-list li {
  position: relative;
  margin: 0;
  padding: 6px 0 6px 22px;
  font-size: 13.5px;
  line-height: 1.6;
  color: #1a1a1a;
}
.check-list li + li { border-top: 1px solid #E4E5E6; }
.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 11px;
  width: 12px;
  height: 12px;
  border: 1.5px solid #B4B6B8;
  border-radius: 3px;
  background: #fff;
}

.article-foot {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tag {
  font-size: 13px;
  color: var(--meta);
  background: var(--band);
  border-radius: 4px;
  padding: 4px 10px;
}
.tag:hover { color: var(--blue); }

.pager-rows {
  margin-top: 20px;
  border-top: 1px solid var(--line);
}
.pager-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.pager-row img {
  width: 72px;
  height: 54px;
  object-fit: cover;
  border-radius: 4px;
  flex: 0 0 72px;
  background: #eee;
}
.pager-kicker {
  flex: 0 0 42px;
  font-size: 12px;
  color: var(--meta);
}
.pager-title {
  font-size: 14px;
  font-weight: 500;
  color: #000;
  line-height: 1.4;
}
.pager-row:hover .pager-title { color: var(--blue); }

.block-title {
  margin: 24px 0 12px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 16px;
  font-weight: 600;
  color: #000;
}

.related-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.related-card {
  display: block;
  min-width: 0;
}
.related-card img {
  width: 100%;
  height: 110px;
  object-fit: cover;
  border-radius: 4px;
  background: #eee;
}
.related-title {
  margin: 8px 0 4px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  color: #000;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.related-meta {
  margin: 0;
  font-size: 12px;
  color: var(--meta);
}
.related-card:hover .related-title { color: var(--blue); }

.composer {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.composer input {
  flex: 1;
  min-width: 0;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 0 14px;
  font-size: 13px;
  font-family: inherit;
  background: var(--band);
  color: #000;
  outline: none;
}
.composer input::placeholder { color: #B4B6B8; }
.composer input:focus { border-color: #D0D0D0; background: #fff; }
.composer-send {
  height: 32px;
  padding: 0 12px;
  border-radius: 16px;
  background: #111;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
}
.composer-send:hover { background: #333; }

.comment-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.comment {
  display: flex;
  gap: 10px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.comment .avatar.lg { margin-top: 2px; }
.comment-who {
  margin: 0 0 4px;
  font-size: 13px;
  font-weight: 500;
  color: #000;
}
.comment-body {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.7;
  color: #1a1a1a;
}
.comment-body code {
  font-size: 0.88em;
  background: #F4F5F6;
  padding: 1px 5px;
  border-radius: 3px;
}
.comment-meta {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--meta);
}

/* Bottom pill */
.action-pill {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  height: 48px;
  background: #fff;
  border-radius: 24px;
  box-shadow: 0 6px 28px rgba(0,0,0,.12);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  padding: 0 10px 0 16px;
  z-index: 50;
  min-width: 420px;
}
.action-pill .say {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--meta);
  font-size: 14px;
  flex: 1;
  min-width: 180px;
  padding-right: 16px;
}
.action-pill .say svg { width: 16px; height: 16px; }
.action-pill .sep {
  width: 1px;
  height: 18px;
  background: var(--line);
  margin: 0 4px;
}
.action-pill .pill-btn {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  color: var(--meta);
  position: relative;
}
.action-pill .pill-btn:hover { color: #000; }
.action-pill .pill-btn svg { width: 18px; height: 18px; }
.action-pill .n {
  position: absolute;
  top: 6px;
  right: 4px;
  font-size: 10px;
  color: var(--meta);
}

@media (max-width: 1020px) {
  .page { width: calc(100% - 32px); }
  .hero-grid, .home-layout { grid-template-columns: 1fr; }
  .hero-stack, .hero-main { height: auto; min-height: 160px; }
  .hero-main { height: 280px; }
  .left-rail { position: static; display: flex; gap: 16px; align-items: center; }
  .rail-copy { display: none; }
  .feed { width: 100%; }
  .cover-full, .cover-full img { width: 100%; height: auto; aspect-ratio: 520 / 240; }
  .related-grid { grid-template-columns: 1fr; }
  .action-pill { min-width: 0; width: calc(100% - 96px); }
}

/* ——— Halo article HTML + comments + avatar photo ——— */
.skip-link { position: absolute; left: 12px; top: -40px; z-index: 80; background: var(--ink); color: #fff; padding: 8px 12px; border-radius: 6px; }
.skip-link:focus { top: 10px; }

.avatar.photo {
  overflow: hidden;
  background: #eee;
}
.avatar.photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.reading .prose h1 { font-size: 22px; margin: 1.4em 0 0.5em; }
.reading .prose h3, .reading .prose h4 {
  margin: 1.4em 0 0.45em;
  font-size: 16px;
  font-weight: 600;
  color: #000;
}
.reading .prose ol { margin: 0 0 1.2em; padding-left: 1.25em; }
.reading .prose img {
  width: 100%;
  border-radius: 4px;
  margin: 0.4em 0 1em;
}
.reading .prose figure { margin: 0 0 1.4em; }
.reading .prose figcaption {
  margin-top: 8px;
  font-size: 12px;
  color: var(--meta);
}
.reading .prose pre {
  margin: 0 0 1.4em;
  background: #F7F8F9;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px 14px;
  overflow: auto;
  font-size: 12.5px;
  line-height: 1.7;
  position: relative;
}
.reading .prose pre .copy-code {
  position: absolute;
  top: 8px;
  right: 8px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--meta);
  border-radius: 4px;
  height: 24px;
  padding: 0 8px;
  font-size: 12px;
}
.reading .prose blockquote {
  margin: 0 0 1.3em;
  padding: 2px 0 2px 14px;
  border-left: 3px solid #111;
  font-size: 15.5px;
  line-height: 1.75;
  color: #111;
  font-weight: 500;
}
.reading .prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.4em;
  font-size: 13px;
}
.reading .prose th,
.reading .prose td {
  text-align: left;
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.reading .prose th {
  font-weight: 500;
  color: var(--meta);
  background: var(--band);
  font-size: 12px;
}
.reading .prose hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 1.8em 0;
}
.reading .prose iframe {
  width: 100%;
  border: 0;
  border-radius: 4px;
  margin: 0 0 1.2em;
}

.comment-mount {
  margin-top: 8px;
}
.comment-mount halo-comment, .comment-mount .comment-widget {
  display: block;
  width: 100%;
}

.byline-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  overflow: hidden;
  background: #c45c4a;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 600;
  flex-shrink: 0;
}
.byline-avatar img { width: 100%; height: 100%; object-fit: cover; }

.cover-fallback { background: #e8e9ea; }

/* ——— Night + narrow article (0.3.2) ——— */
html.night {
  --bg: #111111;
  --band: #1a1a1a;
  --ink: #e5e5e5;
  --meta: #a1a1aa;
  --line: #2a2a2a;
  --blue: #6cb6f3;
  color-scheme: dark;
}
html.night body { background: #111; color: #e5e5e5; }
html.night .article-title,
html.night .reading .article-title,
html.night .byline-name,
html.night .watching-title,
html.night .watch-item .t,
html.night .pager-title,
html.night .related-title,
html.night .block-title,
html.night .item-title,
html.night .feed-heading,
html.night .filter.is-on,
html.night .list-pager a,
html.night .prose,
html.night .reading .prose,
html.night .prose h2,
html.night .prose h3,
html.night .reading .prose h3,
html.night .reading .prose h4,
html.night .flow-node h3,
html.night .rail-nav a.is-active,
html.night .rail-nav a:hover,
html.night .layer-table td:first-child,
html.night .comment-who,
html.night .comment-body,
html.night .pullquote { color: #e5e5e5; }
html.night .rail-nav a,
html.night .article-date,
html.night .byline-rest,
html.night .watch-item .m,
html.night .related-meta,
html.night .pager-kicker,
html.night .tag,
html.night .item-meta,
html.night .item-excerpt,
html.night .filter,
html.night .list-pager,
html.night .empty-feed { color: #a1a1aa; }
html.night .flow,
html.night .flow-node,
html.night .tag,
html.night .codebox,
html.night .reading .prose pre,
html.night .check-list,
html.night .callout,
html.night .composer input,
html.night .float-btns a,
html.night .action-pill { background: #1a1a1a; }
html.night .prose code,
html.night .reading .prose pre .copy-code,
html.night .copy,
html.night .chip { background: #222; color: #e5e5e5; border-color: var(--line); }
html.night .codebox pre,
html.night .reading .prose pre { color: #d4d4d8; border-color: var(--line); }
html.night .layer-table th,
html.night .reading .prose th { background: #1a1a1a; color: #a1a1aa; }
html.night .cover-full,
html.night .thumb,
html.night .related-card img,
html.night .pager-row img { background: #1a1a1a; }
html.night .action-pill,
html.night .float-btns a,
html.night .flow-node { border-color: var(--line); }
html.night .action-pill .say,
html.night .action-pill .pill-btn { color: #a1a1aa; }
html.night .action-pill .pill-btn:hover,
html.night .float-btns a:hover { color: #e5e5e5; }
html.night .pullquote,
html.night .reading .prose blockquote { border-left-color: #e5e5e5; }
html.night .watch-item:hover .t,
html.night .pager-row:hover .pager-title,
html.night .related-card:hover .related-title,
html.night .tag:hover { color: var(--blue); }
html.night .composer-send { background: #e5e5e5; color: #111; }
html.night .callout,
html.night .check-list li,
html.night .reading .prose,
html.night .reading .prose blockquote { color: #e5e5e5; }
html.night .check-list li + li { border-top-color: var(--line); }
html.night .check-list li::before { background: #1a1a1a; border-color: #555; }
html.night .related-card,
html.night .watch-item,
html.night .promo,
html.night .codebox,
html.night .callout { background: #1a1a1a; border-color: var(--line); }
html.night .reading .prose pre,
html.night .reading .prose pre code,
html.night .prose pre.shiki,
html.night pre.shiki,
html.night .shiki {
  background: #1a1a1a !important;
  color: #d4d4d8;
}
html.night .reading .prose pre .copy-code,
html.night .copy {
  background: #222;
  color: #d4d4d8;
  border-color: var(--line);
}


@media (max-width: 1020px) {
  .left-rail { display: none; }
  .right-side { margin-top: 28px; }
  .promo { width: 100%; max-width: 280px; }
}

@media (max-width: 860px) {
  .flow,
  .reading .flow {
    grid-template-columns: 1fr;
  }
  .flow-arrow { transform: rotate(90deg); }
  .action-pill {
    width: calc(100% - 24px);
    min-width: 0;
    bottom: 12px;
    height: 44px;
  }
  .float-btns { right: 12px; bottom: 68px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
