:root {
  --font-sans: "Helvetica Neue", Helvetica, Arial, "Microsoft Yahei", "Hiragino Sans GB", "Heiti SC", "WenQuanYi Micro Hei", "Segoe UI", Roboto, sans-serif;
  --font-serif: "Noto Serif SC", "Noto Serif", Georgia, "Times New Roman", serif;
  --text: #202124;
  --heading: #111315;
  --muted: #687076;
  --faint: #9aa3aa;
  --line: #e7eaee;
  --line-soft: rgba(219, 224, 230, 0.7);
  --surface: #ffffff;
  --surface-soft: #f6f7f9;
  --surface-raised: rgba(255, 255, 255, 0.82);
  --ink: #101214;
  --accent: #2f6f9f;
  --accent-soft: #eef6fb;
  --green: #4d8a72;
  --shadow-card: 0 1px 2px rgba(16, 18, 20, 0.04), 0 18px 45px rgba(16, 18, 20, 0.06);
  --shadow-hover: 0 24px 58px rgba(16, 18, 20, 0.1);
  --radius: 8px;
  --sidebar-width: clamp(210px, 18vw, 292px);
  --content-width: min(78vw, 920px);
  --wide-width: min(82vw, 1120px);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  background: #f8f8f6;
  color: var(--text);
  font-family: var(--font-sans);
  min-height: 100%;
  text-rendering: optimizeLegibility;
}

body {
  background:
    linear-gradient(90deg, rgba(238, 241, 243, 0.9) 0, rgba(238, 241, 243, 0.9) var(--sidebar-width), transparent var(--sidebar-width)),
    #f8f8f6;
  min-height: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
  max-width: 100%;
}

button,
input,
textarea {
  font: inherit;
}

code {
  background: #f3f5f6;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: #4c5358;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 0.92em;
  padding: 0.12em 0.34em;
}

pre {
  background: #f5f7f8;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin: 18px 0;
  overflow: hidden;
}

pre code {
  background: transparent;
  border: 0;
  display: block;
  overflow-x: auto;
  padding: 16px;
}

::selection {
  background: rgba(47, 111, 159, 0.16);
}

.sidebar {
  align-items: stretch;
  display: flex;
  flex-direction: column;
  gap: 34px;
  height: 100vh;
  left: 0;
  padding: 38px clamp(24px, 3vw, 46px);
  position: fixed;
  top: 0;
  width: var(--sidebar-width);
  z-index: 10;
}

.brand {
  align-items: center;
  display: flex;
  gap: 12px;
  min-height: 48px;
}

.brand-avatar {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 50%;
  box-shadow: 0 10px 28px rgba(17, 19, 21, 0.08);
  height: 42px;
  object-fit: cover;
  width: 42px;
}

.brand strong {
  color: var(--heading);
  display: block;
  font-size: 21px;
  font-weight: 720;
  line-height: 1;
}

.nav-list {
  display: grid;
  gap: 8px;
}

.nav-item {
  align-items: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: #4c5358;
  display: flex;
  gap: 12px;
  min-height: 46px;
  padding: 8px 10px;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.nav-item:hover,
.nav-item.active {
  background: rgba(255, 255, 255, 0.7);
  border-color: rgba(16, 18, 20, 0.08);
  color: var(--heading);
}

.nav-item:hover {
  transform: translateX(2px);
}

.nav-item.active {
  font-weight: 700;
}

.nav-icon {
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--heading);
  display: inline-flex;
  flex: 0 0 auto;
  height: 30px;
  justify-content: center;
  width: 30px;
}

.nav-item.active .nav-icon {
  background: var(--ink);
  border-color: var(--ink);
  color: #ffffff;
}

.nav-icon svg {
  fill: currentColor;
  height: 15px;
  width: 15px;
}

.nav-title {
  font-size: 16px;
  line-height: 1;
}

.mobile-nav {
  display: none;
}

.page-shell {
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  padding: 38px 0 58px;
}

.content-column,
.articlelist-container,
.article-container {
  margin-left: clamp(28px, 5vw, 76px);
  width: var(--content-width);
}

.articlelist-container {
  width: var(--wide-width);
}

.page-stack {
  display: grid;
  gap: 18px;
}

.page-header {
  align-items: end;
  border-bottom: 1px solid var(--line-soft);
  display: flex;
  gap: 20px;
  justify-content: space-between;
  padding: 0 2px 18px;
}

.eyebrow {
  color: var(--green);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: 0;
  margin-bottom: 7px;
  text-transform: uppercase;
}

.page-header h1 {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 52px;
  font-weight: 720;
  letter-spacing: 0;
  line-height: 1;
}

.post-list {
  display: grid;
  gap: 18px;
}

.post-card,
.article-card,
.featured-article,
.empty-state,
.article-container,
.post-detail {
  background: var(--surface-raised);
  border: 1px solid rgba(16, 18, 20, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.post-card,
.article-card,
.featured-article {
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.post-card:hover,
.article-card:hover,
.featured-article:hover {
  border-color: rgba(47, 111, 159, 0.24);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.post-card-link,
.article-card a {
  display: block;
  height: 100%;
}

.post-card-link {
  padding: 22px 24px;
}

.post-meta-row,
.article-author {
  align-items: center;
  display: flex;
  gap: 12px;
  margin-bottom: 18px;
}

.avatar {
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 50%;
  flex: 0 0 auto;
  height: 36px;
  object-fit: cover;
  width: 36px;
}

.post-meta-copy,
.article-author span {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.post-meta-copy strong,
.article-author strong {
  color: var(--heading);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
}

.post-meta-copy time,
.article-author time {
  color: var(--faint);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
}

.post-content-preview {
  border-left: 2px solid var(--line);
  color: #4d555b;
  margin-left: 17px;
  padding-left: 30px;
}

.post-content-preview h2 {
  color: var(--heading);
  font-size: 22px;
  font-weight: 720;
  line-height: 1.25;
  margin-bottom: 8px;
  overflow-wrap: anywhere;
}

.post-content-preview p {
  font-size: 15px;
  line-height: 1.7;
}

.post-images {
  margin: 22px 0 0 49px;
}

.post-images.single {
  max-height: 420px;
}

.post-images.single img {
  border-radius: var(--radius);
  height: auto;
  max-height: 420px;
  object-fit: contain;
  object-position: left center;
  width: auto;
}

.post-images.grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
  max-width: 660px;
}

.post-images.grid img {
  aspect-ratio: 1;
  border-radius: var(--radius);
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.post-card-footer {
  align-items: center;
  color: var(--faint);
  display: flex;
  flex-wrap: wrap;
  font-size: 12px;
  font-weight: 650;
  gap: 10px;
  margin: 20px 0 0 49px;
}

.post-card-footer span:not(.card-arrow) + span:not(.card-arrow)::before,
.article-inline-meta span + span::before {
  color: #d3d8dc;
  content: "/";
  margin-right: 10px;
}

.card-arrow {
  align-items: center;
  background: var(--accent-soft);
  border: 1px solid rgba(47, 111, 159, 0.18);
  border-radius: 999px;
  color: var(--accent);
  display: inline-flex;
  font-size: 12px;
  height: 24px;
  justify-content: center;
  line-height: 1;
  width: 24px;
}

.post-card-footer .card-arrow {
  margin-left: auto;
}

.featured-article-copy .card-arrow,
.article-card-desc .card-arrow {
  margin-top: 4px;
}

.text-link,
.articlelist-more,
.back-link {
  color: var(--accent);
  font-weight: 700;
}

.back-link {
  align-items: center;
  display: inline-flex;
  font-size: 14px;
  gap: 6px;
}

.featured-article-link {
  display: grid;
  gap: 0;
  grid-template-columns: minmax(320px, 1.05fr) minmax(360px, 0.95fr);
  min-height: 340px;
}

.featured-article-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 34px 38px;
}

.article-category {
  color: var(--green);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: 0;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.featured-article h2 {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 52px;
  font-weight: 720;
  letter-spacing: 0;
  line-height: 1.08;
  margin-bottom: 18px;
  overflow-wrap: anywhere;
}

.featured-article p:not(.article-category) {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
  margin-bottom: 20px;
  max-width: 34rem;
}

.article-inline-meta {
  color: var(--faint);
  display: flex;
  flex-wrap: wrap;
  font-size: 12px;
  font-weight: 650;
  gap: 10px;
  margin-bottom: 16px;
}

.featured-article-media {
  background: var(--surface-soft);
  border-left: 1px solid var(--line-soft);
  min-height: 300px;
  overflow: hidden;
}

.featured-article-media img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.article-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.article-card a {
  padding: 0;
}

.article-card-media {
  background: var(--surface-soft);
  border-bottom: 1px solid var(--line-soft);
  height: 190px;
  overflow: hidden;
}

.article-card-media img {
  height: 100%;
  object-fit: cover;
  transition: transform 0.22s ease;
  width: 100%;
}

.article-card:hover .article-card-media img,
.featured-article:hover .featured-article-media img {
  transform: scale(1.025);
}

.article-card-body {
  padding: 20px 22px 22px;
}

.article-card-desc {
  border-left: 2px solid var(--line);
  padding-left: 28px;
}

.article-card-desc h2 {
  color: var(--heading);
  display: -webkit-box;
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 10px;
  overflow: hidden;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.article-card-desc p:not(.article-category) {
  color: var(--muted);
  display: -webkit-box;
  font-size: 14px;
  line-height: 1.65;
  margin-bottom: 14px;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.site-footer {
  color: rgba(104, 112, 118, 0.82);
  font-size: 12px;
  line-height: 1.6;
  margin-left: var(--sidebar-width);
  padding: 0 5% 28px;
  text-align: center;
}

.icp-link {
  display: inline-flex;
  transition: color 0.18s ease;
}

.icp-link:hover {
  color: var(--accent);
}

.article-container {
  margin-bottom: 16px;
  padding-top: 1px;
}

.article-back {
  margin: 20px 2rem 0;
}

.article-post {
  margin: 0 auto;
  max-width: 760px;
  padding: 0 2rem;
  text-align: center;
}

.detail-category {
  margin-top: 26px;
}

.article-title {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 58px;
  font-weight: 720;
  letter-spacing: 0;
  line-height: 1.12;
  margin: 10px 0 1rem;
  overflow-wrap: anywhere;
}

.article-meta {
  display: flex;
  flex-direction: column;
  font-size: 0.875rem;
}

.article-meta div {
  color: var(--faint);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 18px;
  text-align: center;
}

.article-meta span {
  color: var(--faint);
  margin: 0 3px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin: -2px 0 24px;
}

.tag-row span {
  background: var(--accent-soft);
  border: 1px solid rgba(47, 111, 159, 0.18);
  border-radius: 999px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  padding: 5px 10px;
}

.article-thumbnail {
  align-items: center;
  background: #fbfcfd;
  border-bottom: 1px solid var(--line-soft);
  border-top: 1px solid var(--line-soft);
  display: flex;
  justify-content: center;
  margin: 0 24px 20px;
  max-height: 520px;
  min-height: 240px;
  overflow: hidden;
  padding: 10px;
  width: calc(100% - 48px);
}

.article-thumbnail img {
  border-radius: calc(var(--radius) - 2px);
  height: auto;
  max-height: 100%;
  max-width: 100%;
  object-fit: scale-down;
  width: auto;
}

.markdown-body {
  color: #33383c;
  font-size: 16px;
  line-height: 1.82;
  margin: 24px auto 40px;
  max-width: 760px;
  overflow-wrap: break-word;
  padding: 0 2rem;
}

.markdown-body > * {
  margin-bottom: 12px;
}

.markdown-body h1,
.markdown-body h2 {
  color: var(--heading);
  font-family: var(--font-serif);
  line-height: 1.3;
  margin-top: 30px;
}

.markdown-body h1 {
  font-size: 30px;
}

.markdown-body h2 {
  border-bottom: 1px solid var(--line-soft);
  font-size: 25px;
  padding-bottom: 8px;
}

.markdown-body h3,
.markdown-body h4 {
  color: var(--heading);
  line-height: 1.35;
  margin-top: 22px;
}

.markdown-body p {
  padding-bottom: 4px;
}

.markdown-body a {
  color: var(--accent);
  font-weight: 700;
}

.markdown-body ul,
.markdown-body ol {
  padding-left: 1.5rem;
}

.markdown-body li {
  margin-bottom: 6px;
}

.markdown-body blockquote {
  background: #f3f8fb;
  border-left: 3px solid rgba(47, 111, 159, 0.22);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--muted);
  padding: 12px 14px;
}

.markdown-body table {
  border-collapse: collapse;
  display: block;
  margin: 18px 0;
  overflow-x: auto;
  width: 100%;
}

.markdown-body th,
.markdown-body td {
  border: 1px solid var(--line);
  padding: 9px 11px;
  text-align: left;
}

.markdown-body th {
  background: #f6f7f9;
  color: var(--heading);
  font-weight: 700;
}

.markdown-body img {
  border-radius: var(--radius);
  height: auto;
  margin: 18px auto;
  width: 100%;
}

.moment-body {
  margin-left: 49px;
  margin-right: 49px;
  max-width: none;
  padding: 0;
}

.post-detail {
  padding: 22px 24px 28px;
}

.moment-detail-header h1 {
  color: var(--heading);
  font-size: 30px;
  font-weight: 720;
  line-height: 1.25;
  margin: 0 49px 18px;
  overflow-wrap: anywhere;
}

.detail-meta {
  margin: 20px 0;
}

.detail-images {
  padding-left: 49px;
}

.adjacent-links {
  border-top: 1px solid var(--line-soft);
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 12px 2rem 0;
  padding: 18px 0 24px;
}

.adjacent-links a {
  background: #fbfcfd;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  display: grid;
  gap: 4px;
  min-height: 84px;
  padding: 14px 16px;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.adjacent-links a:hover {
  background: #f5f9fb;
  border-color: rgba(47, 111, 159, 0.24);
}

.adjacent-links span {
  color: var(--faint);
  font-size: 12px;
  font-weight: 760;
  letter-spacing: 0;
  text-transform: uppercase;
}

.adjacent-links strong {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.moment-adjacent {
  margin: 24px 49px 0;
  padding-bottom: 0;
}

.empty-state {
  padding: 36px;
  text-align: center;
}

.empty-state h2 {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 700;
}

.not-found {
  margin: 5% 10%;
  max-width: 720px;
}

.not-found h1 {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 84px;
  font-weight: 720;
  line-height: 1;
  margin-bottom: 18px;
}

.not-found-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.console-shell {
  padding-right: clamp(24px, 4vw, 56px);
}

.console-layout {
  margin-left: clamp(28px, 5vw, 76px);
  max-width: 1280px;
}

.console-gate {
  align-items: center;
  display: flex;
  justify-content: center;
  min-height: min(72vh, 760px);
  padding: 24px 0;
}

.console-card {
  background: var(--surface-raised);
  border: 1px solid rgba(16, 18, 20, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  width: min(440px, 100%);
}

.console-gate-card {
  display: grid;
  gap: 14px;
  padding: 28px 26px;
}

.console-login-card {
  display: flex;
  flex-direction: column;
}

.console-card h1 {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 34px;
  font-weight: 720;
  line-height: 1.05;
}

.console-card .eyebrow {
  margin-bottom: -8px;
}

.console-card-hint {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 4px;
}

.console-status {
  color: var(--faint);
  font-size: 12px;
  font-weight: 700;
  min-height: 18px;
  text-align: center;
}

.console-login-card .console-status {
  padding: 0 18px 16px;
}

.console-status[data-state="error"] {
  color: #b42318;
}

.console-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 12px;
}

.console-tab {
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
  min-height: 38px;
}

.console-tab.active {
  background: var(--ink);
  border-color: var(--ink);
  color: #ffffff;
}

.console-form {
  border-top: 1px solid var(--line-soft);
  display: none;
  gap: 14px;
  padding: 18px;
}

.console-form.active {
  display: grid;
}

.console-card label {
  display: grid;
  gap: 7px;
}

.console-card label span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.console-card input {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  min-height: 40px;
  padding: 10px 11px;
  width: 100%;
}

.console-card input:disabled {
  background: #f4f6f7;
  color: var(--faint);
  cursor: not-allowed;
}

.console-card input:focus {
  border-color: rgba(47, 111, 159, 0.55);
  outline: 2px solid rgba(47, 111, 159, 0.1);
}

.console-button {
  background: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 999px;
  color: #ffffff;
  cursor: pointer;
  font-weight: 700;
  min-height: 40px;
  padding: 0 18px;
}

.console-button:disabled {
  background: #d8dde3;
  border-color: #d8dde3;
  color: #6d767d;
  cursor: not-allowed;
}

.console-config-warning {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: var(--radius);
  color: #9a3412;
  padding: 13px 14px;
}

.console-config-warning strong {
  color: #7c2d12;
  display: block;
  font-size: 14px;
  margin-bottom: 5px;
}

.console-config-warning p {
  font-size: 13px;
  line-height: 1.45;
}

.console-config-warning code {
  background: rgba(154, 52, 18, 0.08);
  border-color: rgba(154, 52, 18, 0.14);
  color: #7c2d12;
}

.console-stage {
  background: #101214;
  inset: 0;
  position: fixed;
  z-index: 1000;
}

.console-stage .console-frame {
  background: #101214;
  border: 0;
  display: block;
  height: 100%;
  width: 100%;
}

.console-exit {
  background: rgba(16, 18, 20, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  color: #ffffff;
  cursor: pointer;
  font-weight: 700;
  min-height: 36px;
  padding: 0 18px;
  position: fixed;
  right: 14px;
  top: 14px;
  z-index: 1001;
}

.console-exit:hover {
  background: rgba(16, 18, 20, 0.9);
}

.console-gate[hidden],
.console-stage[hidden] {
  display: none;
}

.admin-shell {
  padding-right: clamp(24px, 4vw, 56px);
}

.admin-layout {
  margin-left: clamp(28px, 5vw, 76px);
  max-width: 1180px;
}

.admin-header {
  align-items: end;
  border-bottom: 1px solid var(--line-soft);
  display: flex;
  justify-content: space-between;
  margin-bottom: 18px;
  padding-bottom: 18px;
}

.admin-header h1 {
  color: var(--heading);
  font-family: var(--font-serif);
  font-size: 52px;
  font-weight: 720;
  letter-spacing: 0;
  line-height: 1;
}

.admin-actions,
.editor-actions {
  align-items: center;
  display: flex;
  gap: 10px;
}

.admin-board {
  display: grid;
  gap: 18px;
  grid-template-columns: 320px minmax(0, 1fr);
}

.admin-config-error {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: var(--radius);
  color: #9a3412;
  margin-bottom: 18px;
  padding: 16px 18px;
}

.admin-config-error strong {
  color: #7c2d12;
  display: block;
  font-size: 15px;
  margin-bottom: 6px;
}

.admin-config-error p {
  line-height: 1.5;
  margin: 0;
}

.admin-config-error code {
  background: rgba(154, 52, 18, 0.08);
  border-radius: 6px;
  color: #7c2d12;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  padding: 2px 5px;
}

.admin-panel {
  background: var(--surface-raised);
  border: 1px solid rgba(16, 18, 20, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.admin-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 12px;
}

.admin-tab {
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
  min-height: 38px;
}

.admin-tab.active {
  background: var(--ink);
  border-color: var(--ink);
  color: #ffffff;
}

.entry-list {
  border-top: 1px solid var(--line-soft);
  display: grid;
  max-height: 70vh;
  overflow-y: auto;
}

.entry-list-item {
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line-soft);
  color: var(--muted);
  cursor: pointer;
  display: grid;
  gap: 5px;
  padding: 14px 16px;
  text-align: left;
}

.entry-list-item:hover,
.entry-list-item.active {
  background: #f5f8fa;
  color: var(--heading);
}

.entry-list-item strong {
  color: var(--heading);
  font-size: 15px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.entry-list-item span,
.admin-empty,
.admin-status {
  color: var(--faint);
  font-size: 12px;
  font-weight: 650;
}

.admin-empty {
  padding: 18px 16px;
}

.entry-form {
  padding: 20px;
}

.form-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-grid label {
  display: grid;
  gap: 7px;
}

.form-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 760;
}

.form-grid input,
.form-grid textarea {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  min-height: 40px;
  padding: 10px 11px;
  width: 100%;
}

.form-grid input:focus,
.form-grid textarea:focus {
  border-color: rgba(47, 111, 159, 0.55);
  outline: 2px solid rgba(47, 111, 159, 0.1);
}

.form-grid input[readonly] {
  background: #f6f7f9;
  color: var(--muted);
}

.wide-field,
.content-field {
  grid-column: 1 / -1;
}

.content-field textarea {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  line-height: 1.55;
  min-height: 330px;
  resize: vertical;
}

.editor-actions {
  border-top: 1px solid var(--line-soft);
  justify-content: flex-end;
  margin-top: 18px;
  padding-top: 16px;
}

.admin-status {
  margin-right: auto;
}

.admin-status[data-state="error"] {
  color: #b42318;
}

.admin-button {
  background: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 999px;
  color: #ffffff;
  cursor: pointer;
  font-weight: 700;
  min-height: 38px;
  padding: 0 16px;
}

.admin-button.secondary {
  background: #ffffff;
  color: var(--ink);
}

.admin-button.danger {
  background: #ffffff;
  border-color: #f0c9c4;
  color: #b42318;
}

.button-link {
  align-items: center;
  background: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 999px;
  color: #ffffff;
  display: inline-flex;
  font-weight: 700;
  min-height: 40px;
  padding: 0 18px;
}

.button-link.secondary {
  background: #ffffff;
  color: var(--ink);
}

::-webkit-scrollbar {
  height: 8px;
  width: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: #d8dde3;
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: #c2c9d1;
}

@media screen and (min-width: 550px) and (max-width: 1180px) {
  :root {
    --sidebar-width: 78px;
  }

  .sidebar {
    align-items: center;
    padding: 30px 14px;
  }

  .brand {
    justify-content: center;
    width: 50px;
  }

  .brand span,
  .nav-title {
    display: none;
  }

  .nav-list {
    justify-items: center;
    width: 100%;
  }

  .nav-item {
    height: 50px;
    justify-content: center;
    padding: 0;
    width: 50px;
  }

  .content-column,
  .articlelist-container,
  .article-container {
    margin-left: clamp(24px, 4vw, 48px);
    width: min(86vw, 940px);
  }

  .article-grid {
    grid-template-columns: 1fr;
  }

  .admin-board {
    grid-template-columns: 1fr;
  }

  .entry-list {
    max-height: 320px;
  }
}

@media (max-width: 900px) {
  .page-header h1,
  .featured-article h2 {
    font-size: 40px;
  }

  .article-title {
    font-size: 44px;
  }

  .featured-article-link {
    grid-template-columns: 1fr;
  }

  .featured-article-media {
    border-left: 0;
    border-top: 1px solid var(--line-soft);
    min-height: 220px;
    order: 2;
  }

  .page-header {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 768px) {
  .post-content-preview,
  .article-card-desc,
  .moment-body,
  .moment-detail-header h1,
  .post-card-footer {
    border-left: 0;
    margin-left: 0;
    padding-left: 0;
    padding-right: 0;
  }

  .post-images,
  .detail-images {
    margin-left: 0;
    padding-left: 0;
  }

  .post-images.grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .article-thumbnail {
    min-height: 180px;
  }

  .adjacent-links,
  .moment-adjacent {
    grid-template-columns: 1fr;
    margin-left: 0;
    margin-right: 0;
  }
}

@media (max-width: 549px) {
  html,
  body {
    background: #f8f8f6;
  }

  .sidebar {
    display: none;
  }

  .mobile-nav {
    align-items: center;
    background: rgba(255, 255, 255, 0.96);
    border-top: 1px solid var(--line);
    bottom: 0;
    display: flex;
    height: 9vh;
    justify-content: space-around;
    left: 0;
    min-height: 62px;
    padding-bottom: env(safe-area-inset-bottom);
    position: fixed;
    width: 100%;
    z-index: 20;
  }

  .mobile-nav a {
    align-items: center;
    color: #7b848b;
    display: flex;
    flex-direction: column;
    gap: 4px;
    justify-content: center;
    min-height: 54px;
    min-width: 88px;
  }

  .mobile-nav span {
    align-items: center;
    border: 1px solid currentColor;
    border-radius: 8px;
    display: inline-flex;
    height: 28px;
    justify-content: center;
    width: 28px;
  }

  .mobile-nav svg {
    fill: currentColor;
    height: 15px;
    width: 15px;
  }

  .mobile-nav small {
    font-size: 11px;
    font-weight: 700;
  }

  .mobile-nav .active {
    color: var(--accent);
  }

  .mobile-nav .active span {
    background: var(--accent-soft);
  }

  .page-shell {
    margin-left: 0;
    padding: 0 0 calc(9vh + 28px + env(safe-area-inset-bottom));
  }

  .site-footer {
    margin-left: 0;
    padding: 12px 20px calc(9vh + 18px + env(safe-area-inset-bottom));
  }

  .content-column,
  .articlelist-container,
  .article-container,
  .admin-layout,
  .console-layout {
    margin-left: 0;
    width: 100%;
  }

  .admin-shell,
  .console-shell {
    padding-right: 0;
  }

  .admin-header {
    align-items: stretch;
    flex-direction: column;
    gap: 14px;
    padding: 22px 20px 18px;
  }

  .admin-header h1 {
    font-size: 40px;
  }

  .admin-board {
    gap: 0;
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .admin-panel {
    border-left: 0;
    border-radius: 0;
    border-right: 0;
  }

  .entry-form {
    padding: 18px 16px;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .page-stack {
    gap: 0;
  }

  .page-header {
    padding: 22px 20px 18px;
  }

  .post-card,
  .article-card,
  .article-container,
  .post-detail,
  .featured-article {
    border-left: 0;
    border-radius: 0;
    border-right: 0;
  }

  .post-card-link {
    padding: 18px 16px;
  }

  .featured-article-copy {
    padding: 22px 18px;
  }

  .featured-article h2 {
    font-size: 32px;
  }

  .featured-article-media,
  .article-card-media {
    border-radius: 0;
  }

  .article-card-body {
    padding: 18px 16px;
  }

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

  .post-images.single img {
    height: auto;
    width: 100%;
  }

  .post-detail {
    padding: 18px 16px 30px;
  }

  .article-post {
    padding: 0 1rem;
  }

  .article-back {
    margin-left: 1rem;
  }

  .article-thumbnail {
    margin: 0 0 20px;
    min-height: 160px;
    padding: 8px 16px;
    width: 100%;
  }

  .markdown-body {
    margin: 18px 0 28px;
    padding: 0 16px;
  }

  .moment-body {
    margin: 18px 0 20px;
    padding: 0;
  }

  .moment-detail-header h1 {
    font-size: 28px;
    margin-bottom: 18px;
  }

  .not-found {
    margin: 48px 24px;
  }

  .not-found h1 {
    font-size: 48px;
  }
}
