@font-face{font-family:Manrope;src:url("/assets/manrope.woff2") format("woff2");font-weight:400 800;font-style:normal;font-display:swap}
@font-face{font-family:Fraunces;src:url("/assets/fraunces.woff2") format("woff2");font-weight:400 700;font-style:normal;font-display:swap}

:root {
  color-scheme: dark;
  --ink: #f9edf4;
  --muted: #c8b7cc;
  --soft: #af9db8;
  --accent: #ffc0d5;
  --rose: #ff9dbf;
  --line: #e9bddc26;
  --panel: #211927e8;
  --rail-width: 186px;
  --radius: 19px;
  --display: Fraunces, "Songti SC", "SimSun", "Noto Serif CJK SC", Georgia, serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: #100e19;
  font: 500 15px/1.6 Manrope, "Microsoft YaHei UI", "PingFang SC", "Noto Sans CJK SC", "Segoe UI", sans-serif;
}
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button, input, textarea, select { color: inherit; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--rose); outline-offset: 4px; }
.sr-only, .trap { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: fixed; z-index: 20; top: 12px; left: 12px; padding: 10px 16px; background: #201325; transform: translateY(-160%); }
.skip:focus { transform: none; }

.wallpaper {
  position: fixed;
  z-index: -2;
  inset: 0;
  background: linear-gradient(110deg, #140f20dd 0%, #17122770 52%, #130c2160 100%),
    linear-gradient(0deg, #100e19 0%, #19132b2e 85%), url("/assets/moonrise.webp") center 47%/cover no-repeat;
}
.no-wallpaper .wallpaper { background: radial-gradient(ellipse at 70% 0%, #3e233d, #100e19 68%); }
.sidebar {
  position: fixed;
  z-index: 4;
  inset: 0 auto 0 0;
  width: var(--rail-width);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 33px 20px 22px 19px;
  background: #120f1ce8;
  border-right: 1px solid #eed0ec20;
  backdrop-filter: blur(14px);
  overflow-y: auto;
}
.avatar {
  width: 69px;
  height: 69px;
  display: grid;
  place-items: center;
  flex: none;
  margin: 0 0 27px 13px;
  border-radius: 50%;
  border: 1px solid #faacd38c;
  background: linear-gradient(145deg, #53334e, #2b2139 77%);
  box-shadow: inset 0 0 0 4px #eeb2d21a, 0 0 26px #e78cac31;
}
.avatar img { padding: 7px; object-fit: contain; }
.site-nav { display: grid; width: 100%; gap: 17px; }
.nav-group { display: grid; gap: 3px; }
.nav-group a {
  display: flex; gap: 11px; align-items: center;
  min-height: 42px; padding: 7px 11px;
  border: 1px solid transparent; border-radius: 10px;
  color: #d8c8dc; font-weight: 700; font-size: 13px;
}
.nav-group a:hover { background: #f3b8dc11; color: var(--accent); }
.nav-group a[aria-current="page"] { background: #efaed723; border-color: #efadd837; color: var(--accent); }
.nav-icon { width: 19px; flex: none; text-align: center; font: 600 17px/1 "Segoe UI Symbol", sans-serif; color: #efabc9; }
.nav-small { border-top: 1px solid var(--line); padding-top: 13px; }
.nav-small a { min-height: 34px; padding-left: 15px; color: var(--soft); font-weight: 600; }
.menu-toggle { display: none; }

.page { width: calc(100% - var(--rail-width)); margin-left: var(--rail-width); padding: 0 clamp(26px, 4.35vw, 78px); }
.page > * { max-width: 1260px; margin-inline: auto; }
.masthead { min-height: 123px; display: flex; align-items: center; justify-content: space-between; gap: 14px; position: relative; }
.masthead-home { min-height: 244px; align-items: start; padding-top: 36px; }
.wordmark { padding-top: 22px; }
.kicker { color: var(--accent); display: flex; align-items: center; gap: 9px; font-size: 10px; font-weight: 800; letter-spacing: .23em; }
.kicker span { display: block; width: 18px; height: 1px; background: var(--rose); box-shadow: 0 0 7px #fd9ec7a0; }
.wordmark h1 { font: 650 clamp(56px, 7.2vw, 115px)/1.03 var(--display); letter-spacing: .035em; text-shadow: 0 10px 42px #1009159c; margin: 6px 0 11px; }
.wordmark h1 em, .compact-brand em, .footer em { color: var(--rose); font-style: normal; }
.wordmark p:last-child { color: #ebdbec; font-weight: 600; font-size: clamp(13px, 1.25vw, 17px); }
.compact-brand a { font: 650 40px/1 var(--display); letter-spacing: -.05em; }
.tools { display: flex; gap: 9px; }
.round {
  width: 41px; height: 41px;
  display: grid; place-items: center; flex: none;
  border-radius: 50%; border: 1px solid #f2c6e044;
  background: #241a2cdb; color: var(--accent);
  box-shadow: 0 4px 14px #0f081d50;
}
.round:hover, .round[aria-expanded="true"] { background: #56334c; border-color: #ffb7d589; }
.wallpaper-toggle { font: 20px "Segoe UI Symbol", sans-serif; }
.wallpaper-toggle[aria-pressed="false"] { color: var(--soft); }
.magnifier { position: relative; display: block; width: 13px; height: 13px; border: 1.5px solid currentColor; border-radius: 50%; margin: -2px 2px 0 0; }
.magnifier::after { content: ""; position: absolute; width: 6px; height: 1.5px; background: currentColor; transform: rotate(45deg); right: -4px; bottom: -2px; border-radius: 1px; }
.search-panel { position: absolute; top: 88px; right: 0; z-index: 5; display: flex; gap: 8px; padding: 10px; background: #241a2c; border: 1px solid var(--line); border-radius: 13px; box-shadow: 0 10px 34px #0b0717a8; }
.search-panel input { min-width: 0; width: min(250px, 49vw); }

.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding-bottom: 12px; margin-bottom: 18px; border-bottom: 1px solid #eed1ee29; }
.section-heading h1, .section-heading h2 { font: 600 clamp(24px, 3vw, 35px)/1.15 var(--display); letter-spacing: -.033em; }
.section-heading a { white-space: nowrap; font-size: 12px; font-weight: 750; color: var(--accent); }
.section-heading a:hover, .read-more:hover { text-decoration: underline; text-underline-offset: 4px; }
.section-description { margin: -2px 0 20px; color: var(--muted); }
.column-layout { display: grid; grid-template-columns: minmax(0, 1fr) 232px; gap: clamp(16px, 2vw, 29px); align-items: start; }
.column-layout:has(.post-list:last-child) { display: block; max-width: 940px; }
.post-list, .widgets { display: grid; gap: 20px; }
.post-card, .panel, .widgets section {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 12px 32px #0a06102f;
}
.post-card { padding: clamp(16px, 2.15vw, 28px); backdrop-filter: blur(12px); }
.post-heading { display: flex; align-items: start; justify-content: space-between; gap: 10px; margin-bottom: 17px; }
.post-heading-text { min-width: 0; }
.category {
  display: inline-flex; align-items: center;
  background: #f8acd41b; border: 1px solid #e8a0c82b;
  border-radius: 5px; color: var(--accent); padding: 3px 8px;
  font-size: 9px; font-weight: 800; line-height: 1.5; letter-spacing: .10em; text-transform: uppercase;
}
.category:hover, .tag-cloud a:hover { background: #f8acd436; }
.post-heading h3, .post-heading h2, .post-heading h1 { font: 650 clamp(25px, 3.4vw, 46px)/1.08 var(--display); letter-spacing: -.041em; margin: 8px 0 9px; overflow-wrap: anywhere; }
.post-heading h3 a:hover, .post-heading h2 a:hover { color: var(--accent); }
.post-meta { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 11px; color: var(--muted); }
.post-meta .dot { color: var(--rose); }
.post-meta a:hover, .breadcrumb a:hover { color: var(--accent); }
.post-tags { display: flex; gap: 5px; flex-wrap: wrap; }
.post-tags a { color: #dfaec8; }
.date-stamp { display: grid; justify-items: center; align-content: center; margin-top: 4px; flex: none; min-width: 59px; min-height: 62px; border: 1px solid #e7b7d739; border-radius: 11px; color: var(--accent); background: #d89cc614; }
.date-stamp span { white-space: nowrap; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; }
.date-stamp strong { font: 550 29px/1.03 var(--display); }
.date-stamp small { font-size: 9px; color: var(--muted); padding-top: 3px; }
.cover-link { display: block; overflow: hidden; border-radius: 11px; }
.cover { width: 100%; aspect-ratio: 2.12; object-fit: cover; object-position: center 53%; border-radius: 11px; background: #33263d; }
.cover-link:hover .cover { filter: brightness(1.08); }
.post-summary { margin-top: 14px; display: grid; gap: 11px; color: #ddcede; font-size: 13px; line-height: 1.65; }
.read-more { color: var(--accent); width: max-content; font-size: 12px; font-weight: 800; }
.read-more span { margin-left: 4px; }
.widgets { gap: 14px; }
.widgets section { padding: 17px 16px 15px; }
.widgets h2 { font: 600 18px/1.2 var(--display); letter-spacing: -.01em; }
.widgets ul, .archive ul, .admin-posts ul { list-style: none; margin: 9px 0 0; padding: 0; }
.widgets li { padding: 8px 0 7px; color: var(--muted); font-size: 12px; line-height: 1.4; overflow-wrap: anywhere; }
.widgets li + li { border-top: 1px solid var(--line); }
.widgets li a { color: var(--ink); font-weight: 700; }
.widgets li a:hover { color: var(--accent); }
.widgets li time { display: block; color: var(--soft); font-size: 10px; margin-top: 2px; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px; color: var(--muted); font-size: 12px; }
.tag-cloud a { display: inline-block; background: #e1afcd15; color: var(--accent); padding: 3px 7px; border-radius: 4px; font-size: 10px; }
.pagination { display: flex; justify-content: space-between; gap: 12px; align-items: start; }
.pagination a, .footer span a { color: var(--accent); font-size: 12px; font-weight: 700; }
.pagination a { padding: 7px 14px; border: 1px solid var(--line); border-radius: 8px; background: #241a2ccb; }
.footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px 0 24px; margin-top: 32px; border-top: 1px solid var(--line); }
.footer > a { font: 600 24px var(--display); letter-spacing: -.03em; }
.footer span { display: flex; gap: 15px; }
.mascot { position: fixed; z-index: 6; bottom: 16px; left: 27px; display: flex; align-items: end; pointer-events: none; }
.mascot button { padding: 3px; background: transparent; border: 0; filter: drop-shadow(0 2px 7px #1a0d28); transition: transform .2s; pointer-events: auto; }
.mascot button:hover { transform: translateY(-4px) rotate(-6deg); }
.mascot img { object-fit: contain; }
.mascot p { position: absolute; z-index: 1; left: 66px; bottom: 47px; width: max-content; max-width: min(210px, 48vw); padding: 8px 11px; border-radius: 10px 10px 10px 2px; border: 1px solid #f5a9cf7c; color: #ffdbeb; background: #2d1d33; font-size: 12px; box-shadow: 0 5px 20px #0906128c; }
.back-to-top { position: fixed; right: 15px; bottom: 17px; z-index: 5; font-size: 20px; }

.panel { padding: clamp(17px, 3vw, 30px); }
.panel > a, .prose a, .reply-link { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.prose { font-size: 16px; line-height: 1.8; color: #eee0ef; overflow-wrap: anywhere; }
.prose > * + * { margin-top: 1.05em; }
.prose h2, .prose h3, .panel h2 { color: var(--ink); font-family: var(--display); line-height: 1.25; }
.prose h2 { font-size: 27px; }
.prose h3 { font-size: 21px; }
.prose img { border-radius: 8px; }
.prose [data-article-image] { width: 100%; margin-inline: auto; }
.prose [data-article-image][data-size="small"] { width: min(100%, 360px); }
.prose [data-article-image][data-size="medium"] { width: min(84%, 620px); }
.prose [data-article-image][data-align="left"] { margin-left: 0; }
.prose [data-article-image][data-align="right"] { margin-right: 0; }
.prose [data-article-image] img { width: 100%; height: auto; }
.prose figcaption { text-align: center; margin-top: .45em; color: var(--muted); font-size: .83em; }
.prose [data-article-columns] { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: clamp(14px,3vw,28px); align-items: start; }
.prose [data-article-columns][data-layout="left-wide"] { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); }
.prose [data-article-columns][data-layout="right-wide"] { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); }
.prose [data-article-column] > * + * { margin-block-start: 1em; }
.prose .tableWrapper { max-width: 100%; overflow: auto; }
.prose table { border-collapse: collapse; width: 100%; }
.prose th, .prose td { min-width: 65px; border: 1px solid #eab6d53d; padding: .48em .6em; vertical-align: top; text-align: start; }
.prose th { background: #8b547339; }
.prose tr:nth-child(even) td { background: #f1b2d808; }
@media (max-width: 600px) {
  .prose [data-article-columns][data-layout] { grid-template-columns: minmax(0,1fr); }
  .prose [data-article-image][data-size="medium"] { width: 100%; }
}
.prose code { border-radius: 3px; padding: .08em .3em; background: #0e0b16; color: #ffcae1; }
.prose pre { overflow-x: auto; padding: 12px; background: #0e0b16; border-radius: 7px; }
.prose blockquote { margin-inline: 0; padding-left: 15px; border-left: 2px solid var(--rose); }
.breadcrumb { display: flex; gap: 8px; color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.full-post, .discussion, .adjacent, .archive, .page > main > .prose { max-width: 940px; }
.full-post .cover { margin-bottom: 22px; }
.adjacent, .discussion { margin-top: 19px; }
.archive section + section { margin-top: 22px; }
.archive li { display: grid; grid-template-columns: 72px minmax(0,1fr) auto; gap: 12px; align-items: baseline; padding: 10px 0; }
.archive li + li, .admin-posts li + li { border-top: 1px solid var(--line); }
.archive time { color: var(--muted); font-size: 13px; }
.archive li a:hover { color: var(--accent); text-decoration: underline; }
.sitemap-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(205px, 100%), 1fr)); gap: 24px; }
.sitemap-grid ul { list-style: none; margin: 8px 0 0; padding: 0; }
.sitemap-grid li + li { margin-top: 6px; }
.discussion > p { color: var(--muted); margin-top: 8px; }
.comment-list, .replies { padding-inline-start: 0; list-style: none; }
.replies { margin: 12px 0 0 13px; border-left: 1px solid var(--line); padding-left: 13px; }
.comment { padding: 9px 0; overflow-wrap: anywhere; }
.comment + .comment { border-top: 1px solid var(--line); }
.comment > div { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; }
.comment time, .reply-link { color: var(--muted); font-size: 12px; }
.comment p, .moderation p { white-space: pre-wrap; overflow-wrap: anywhere; margin: 5px 0; }
.stack-form { display: grid; gap: 12px; max-width: 780px; }
.discussion .stack-form { margin-top: 24px; }
.stack-form label { display: grid; gap: 5px; min-width: 0; font-size: 13px; font-weight: 700; }
input, textarea, select {
  width: 100%; background: #120d1ac7; border: 1px solid #ead0e840;
  border-radius: 7px; padding: 8px 11px;
}
textarea { resize: vertical; }
button[type="submit"], .form-actions button, .search-panel button { width: max-content; border: 1px solid #f2b2d559; border-radius: 7px; color: var(--accent); background: #56314e; padding: 7px 12px; font-size: 13px; font-weight: 750; }
button[type="submit"]:hover, .form-actions button:hover, .search-panel button:hover { background: #773c65; }
.notice, .error { padding: 7px 11px; background: #57395470; border-left: 2px solid var(--rose); color: #ffe1ee !important; }
.error { border-left-color: #ff7e85; }
.admin-page { width: min(900px, 100% - 32px); margin: 0 auto; padding: 18px 0 50px; }
.admin-page > header { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 6px 0 22px; }
.admin-brand { font: 600 24px var(--display); }
.admin-page nav { display: flex; flex-wrap: wrap; gap: 14px; font-size: 13px; color: var(--accent); }
.admin-page .notice, .admin-page .error { margin: 0 0 13px; }
.admin-posts li { display: flex; gap: 10px; justify-content: space-between; padding: 8px 0; }
.admin-posts li span, .moderation span { color: var(--muted); font-size: 12px; }
.admin-posts li a { color: var(--accent); }
.form-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.form-pair { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 12px; }
.moderation article + article { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 12px; }
.moderation form { margin-top: 7px; }

@media (min-width: 1550px) {
  :root { --rail-width: 204px; }
}
@media (max-width: 1120px) {
  :root { --rail-width: 153px; }
  .sidebar { padding-inline: 13px; }
  .page { padding-inline: 30px; }
  .column-layout { grid-template-columns: minmax(0, 1fr) 190px; }
}
@media (max-width: 900px) {
  .column-layout { grid-template-columns: minmax(0, 1fr); }
  .widgets { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .masthead-home { min-height: 206px; }
}
@media (max-width: 640px) {
  .sidebar { position: relative; inset: auto; width: auto; min-height: 57px; display: flex; flex-flow: row wrap; justify-content: space-between; align-items: center; padding: 9px 14px; border-right: 0; border-bottom: 1px solid var(--line); overflow: visible; }
  .avatar { width: 39px; height: 39px; margin: 0; }
  .avatar img { width: 34px; height: 34px; padding: 4px; }
  .menu-toggle { display: flex; align-items: center; gap: 7px; padding: 6px 9px; border-radius: 6px; background: #321f37; border: 1px solid var(--line); color: var(--accent); font-size: 12px; }
  .site-nav { display: none; padding-top: 10px; }
  .site-nav.open { display: grid; }
  .page { width: 100%; margin: 0; padding-inline: 15px; }
  .masthead { min-height: 80px; }
  .masthead-home { min-height: 181px; padding-top: 18px; }
  .wordmark { padding-top: 19px; }
  .wordmark h1 { font-size: clamp(48px, 12vw, 72px); }
  .masthead-home .tools { position: absolute; right: 0; top: 12px; }
  .round { height: 34px; width: 34px; }
  .search-panel { top: 55px; }
  .post-heading h3, .post-heading h2 { font-size: clamp(22px, 6.5vw, 31px); }
  .date-stamp { min-width: 46px; min-height: 53px; }
  .date-stamp strong { font-size: 25px; }
  .cover { aspect-ratio: 1.68; }
  .mascot { left: auto; right: 50px; bottom: 10px; }
  .mascot img { width: 44px; height: 44px; }
  .mascot p { right: 5px; left: auto; bottom: 46px; border-radius: 10px 10px 2px 10px; }
  .back-to-top { right: 9px; bottom: 12px; }
  .archive li { grid-template-columns: 55px minmax(0,1fr); gap: 4px 8px; }
  .archive li .category { grid-column: 2; justify-self: start; }
}
@media (max-height: 685px) and (min-width: 641px) {
  .mascot { left: auto; right: 63px; }
  .mascot p { left: auto; right: 36px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
