/* BoxSea Notes — editorial journal theme */

:root {
  --paper: #f3efe6;
  --paper-soft: #f8f5ee;
  --paper-deep: #eae4d7;
  --ink: #171a17;
  --ink-soft: #4b514b;
  --muted: #7d837b;
  --forest: #163f35;
  --forest-2: #0f2d26;
  --rust: #bd5d3d;
  --rust-soft: #f0ddd2;
  --line: rgba(23, 26, 23, 0.14);
  --line-strong: rgba(23, 26, 23, 0.28);
  --sans: "HarmonyOS Sans SC", "PingFang SC", "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
  --serif: Georgia, "Times New Roman", "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --radius: 3px;
  --ease: cubic-bezier(0.22, 0.8, 0.3, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  background-image:
    radial-gradient(900px 520px at 92% 0%, rgba(189, 93, 61, 0.07), transparent 65%),
    radial-gradient(720px 480px at 0% 40%, rgba(22, 63, 53, 0.05), transparent 65%);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.65'/%3E%3C/svg%3E");
}
::selection { color: var(--paper-soft); background: var(--forest); }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--rust); }
img { max-width: 100%; height: auto; display: block; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
p { margin: 0; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.2; }
ul, ol { margin: 0; padding: 0; list-style: none; }
figure { margin: 0; }
main { display: block; min-height: 50vh; }
:focus-visible { outline: 2px solid var(--rust); outline-offset: 3px; }
.screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed; top: 10px; left: 10px; z-index: 999; padding: 10px 16px;
  color: var(--paper-soft); background: var(--ink); transform: translateY(-160%);
  transition: transform 0.2s;
}
.skip-link:focus { transform: none; }
.container { width: min(1240px, calc(100% - 64px)); margin-inline: auto; }
body.no-scroll { overflow: hidden; }
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.post-card-cover-link, .featured-cover-link { display: block; }
.featured-cover-link { height: 100%; }
.site-toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 200; max-width: calc(100vw - 32px);
  padding: 10px 16px; color: var(--paper-soft); background: rgba(23, 26, 23, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.12); border-radius: var(--radius);
  font-size: 12px; opacity: 0; pointer-events: none; transform: translate(-50%, 8px);
  transition: opacity .2s var(--ease), transform .2s var(--ease);
}
.site-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.comment-author img { border-radius: 50%; }
.comment-list .children { list-style: none; }
.comment-form .form-submit { margin-top: 2px; }
.comment-reply-title { margin-top: 18px; font-family: var(--serif); font-size: 23px; font-weight: 500; }
.comment-reply-title small { font-family: var(--sans); font-size: 10px; font-weight: 400; }
.auth-form .check-label { margin: 15px 0 18px; }
.auth-form .submit { text-decoration: none; }
.article-side .favorite-button:disabled { opacity: .6; cursor: wait; }

.eyebrow, .kicker {
  display: inline-flex; align-items: center; gap: 9px;
  color: var(--rust); font-family: var(--mono); font-size: 11px;
  font-weight: 600; letter-spacing: 0.15em; text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 22px; height: 1px; background: currentColor; }
.rule { border: 0; border-top: 1px solid var(--line); margin: 0; }
.muted { color: var(--muted); }
.serif { font-family: var(--serif); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(243, 239, 230, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 28px;
  min-height: 82px;
}
.brand { display: inline-flex; align-items: baseline; gap: 9px; flex: none; }
.brand-word {
  font-family: var(--serif); font-size: 27px; font-weight: 700;
  letter-spacing: -0.055em; line-height: 1;
}
.brand-cn {
  padding: 2px 6px; color: var(--rust); border: 1px solid rgba(189, 93, 61, 0.45);
  border-radius: 2px; font-size: 9px; font-weight: 600; letter-spacing: 0.16em; line-height: 1.5;
}
.nav-list { display: flex; align-items: center; gap: clamp(18px, 3vw, 38px); font-size: 13px; }
.nav-list a { position: relative; display: inline-block; color: var(--ink-soft); padding: 5px 0; }
.nav-list a::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px;
  background: var(--rust); transform: scaleX(0); transform-origin: right;
  transition: transform 0.25s var(--ease);
}
.nav-list a:hover, .nav-list .current-menu-item > a, .nav-list .current_page_item > a { color: var(--ink); }
.nav-list a:hover::after, .nav-list .current-menu-item > a::after, .nav-list .current_page_item > a::after { transform: scaleX(1); transform-origin: left; }
.header-actions { display: flex; align-items: center; gap: 10px; flex: none; }
.icon-button {
  display: inline-grid; place-items: center; width: 38px; height: 38px;
  border: 1px solid var(--line); border-radius: 50%; transition: 0.25s var(--ease);
}
.icon-button:hover { color: var(--paper-soft); background: var(--ink); border-color: var(--ink); }
.icon-button svg { width: 16px; height: 16px; }
.text-link { padding: 6px 2px; font-size: 12.5px; color: var(--ink-soft); }
.text-link:hover { color: var(--ink); }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 43px; padding: 0 20px; color: var(--paper-soft); background: var(--ink);
  border: 1px solid var(--ink); border-radius: var(--radius); font-size: 12.5px;
  letter-spacing: 0.03em; transition: 0.25s var(--ease);
}
.btn:hover { color: #fff; background: var(--forest); border-color: var(--forest); transform: translateY(-1px); }
.btn-ghost { color: var(--ink); background: transparent; border-color: var(--line-strong); }
.btn-ghost:hover { color: var(--paper-soft); background: var(--ink); border-color: var(--ink); }
.btn-rust { background: var(--rust); border-color: var(--rust); }
.btn-rust:hover { background: #a84c2f; border-color: #a84c2f; }
.btn-wide { width: 100%; }
.btn-small { min-height: 36px; padding-inline: 14px; font-size: 11.5px; }
.user-chip { display: flex; align-items: center; gap: 8px; padding: 2px; }
.avatar-letter {
  display: inline-grid; place-items: center; width: 34px; height: 34px;
  color: var(--paper-soft); background: var(--forest); border-radius: 50%;
  font-family: var(--serif); font-size: 14px;
}
.avatar-letter.size-lg { width: 70px; height: 70px; font-size: 24px; }
.avatar-letter.size-sm { width: 24px; height: 24px; font-size: 10px; }
.mobile-toggle { display: none; }

/* Search */
.search-layer {
  position: fixed; inset: 0; z-index: 60; display: grid; place-items: start center;
  padding-top: min(28vh, 220px); background: rgba(23, 26, 23, 0.32);
  backdrop-filter: blur(6px); animation: fade 0.2s ease both;
}
.search-layer[hidden] { display: none; }
.search-box {
  width: min(680px, calc(100vw - 40px)); padding: 12px; background: var(--paper-soft);
  border: 1px solid var(--line); box-shadow: 0 30px 80px rgba(14, 27, 22, 0.22);
}
.search-field { display: flex; align-items: center; gap: 14px; padding: 13px 16px; border: 1px solid var(--line-strong); }
.search-field span { font-family: var(--mono); font-size: 10px; color: var(--muted); }
.search-field input {
  flex: 1; min-width: 0; padding: 0; background: transparent; border: 0; outline: 0;
  font-family: var(--serif); font-size: clamp(18px, 2.2vw, 25px);
}
.search-tip { margin: 12px 4px 2px; color: var(--muted); font-size: 11px; }
.search-close { position: absolute; top: 28px; right: 30px; color: var(--paper-soft); font-size: 12px; }

/* Hero */
.home-hero {
  display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(250px, 0.5fr);
  gap: 60px; padding-block: clamp(60px, 9vw, 118px) clamp(48px, 7vw, 90px);
}
.hero-title {
  max-width: 800px; margin-top: 25px; font-family: var(--serif);
  font-size: clamp(46px, 7.4vw, 104px); font-weight: 500; line-height: 1.06;
  letter-spacing: -0.055em;
}
.hero-title em { color: var(--rust); font-weight: 400; }
.hero-lead {
  max-width: 490px; margin-top: 32px; color: var(--ink-soft);
  font-size: 14px; line-height: 1.9;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 34px; }
.hero-aside {
  display: flex; flex-direction: column; justify-content: space-between;
  min-height: 300px; padding-top: 10px; border-left: 1px solid var(--line);
  padding-left: 30px;
}
.aside-index { display: flex; align-items: baseline; justify-content: space-between; color: var(--muted); font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; }
.aside-index strong { color: var(--ink); font-family: var(--serif); font-size: 34px; font-weight: 400; letter-spacing: -0.04em; }
.aside-quote { margin-top: 44px; font-family: var(--serif); font-size: 20px; font-style: italic; line-height: 1.65; color: var(--ink-soft); }
.aside-meta { display: flex; flex-direction: column; gap: 8px; margin-top: 38px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.aside-meta span { display: flex; justify-content: space-between; gap: 16px; }
.aside-meta b { color: var(--ink); font-weight: 500; }

/* Section heading */
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 24px; padding-bottom: 15px; border-bottom: 1px solid var(--line-strong); }
.section-head h2 { margin-top: 10px; font-family: var(--serif); font-size: clamp(28px, 3.5vw, 42px); font-weight: 500; letter-spacing: -0.035em; }
.section-link { font-family: var(--mono); font-size: 10px; letter-spacing: 0.08em; color: var(--ink-soft); white-space: nowrap; }
.section-link:hover { color: var(--rust); }

/* Covers */
.post-cover {
  position: relative; display: flex; flex-direction: column; justify-content: space-between;
  aspect-ratio: 1.55 / 1; overflow: hidden; padding: 22px; color: var(--paper-soft);
  background: var(--forest); isolation: isolate;
}
.post-cover::before, .post-cover::after { content: ""; position: absolute; z-index: -1; }
.post-cover--tech { background: var(--forest); }
.post-cover--tech::before {
  width: 74%; aspect-ratio: 1; right: -18%; top: -38%; border: 1px solid rgba(243, 239, 230, 0.3); border-radius: 50%;
  box-shadow: 0 0 0 28px rgba(243, 239, 230, 0.045), 0 0 0 58px rgba(243, 239, 230, 0.035);
}
.post-cover--tech::after {
  inset: 0; background-image: linear-gradient(rgba(243,239,230,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(243,239,230,.08) 1px, transparent 1px);
  background-size: 34px 34px; mask-image: linear-gradient(135deg, transparent 15%, #000 90%);
}
.post-cover--life { color: var(--ink); background: var(--rust-soft); }
.post-cover--life::before {
  width: 58%; aspect-ratio: 1; border-radius: 50%; right: -8%; bottom: -32%;
  background: var(--rust); opacity: 0.9;
}
.post-cover--life::after {
  width: 42%; aspect-ratio: 1; border-radius: 50%; right: 22%; bottom: 6%;
  border: 1px solid rgba(23, 26, 23, 0.45);
}
.post-cover--default { color: var(--ink); background: var(--paper-deep); }
.post-cover--default::before { inset: 12px; border: 1px solid var(--line-strong); }
.cover-top { display: flex; justify-content: space-between; gap: 12px; font-family: var(--mono); font-size: 9px; letter-spacing: 0.12em; opacity: 0.8; }
.cover-center { display: flex; align-items: end; justify-content: space-between; gap: 10px; }
.cover-mark { font-family: var(--serif); font-size: clamp(46px, 8vw, 100px); font-weight: 400; line-height: 0.8; letter-spacing: -0.07em; opacity: 0.92; }
.cover-category { font-family: var(--mono); font-size: 9px; letter-spacing: 0.12em; padding-bottom: 6px; }
.post-cover.has-image { padding: 0; color: var(--paper-soft); background: var(--ink); }
.post-cover.has-image img { width: 100%; height: 100%; object-fit: cover; }
.post-cover.has-image .cover-top, .post-cover.has-image .cover-center { position: absolute; inset-inline: 22px; z-index: 1; text-shadow: 0 1px 10px rgba(0,0,0,.3); }
.post-cover.has-image .cover-top { top: 22px; }
.post-cover.has-image .cover-center { bottom: 22px; }

/* Featured */
.featured { padding-bottom: clamp(56px, 8vw, 100px); }
.featured-card {
  display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(0, 0.82fr);
  gap: clamp(24px, 4vw, 54px); align-items: stretch; padding-top: 28px;
}
.featured-cover { height: 100%; min-height: 420px; aspect-ratio: auto; }
.featured-copy { display: flex; flex-direction: column; justify-content: space-between; padding-block: 10px; }
.post-meta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; color: var(--muted); font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.06em; text-transform: uppercase; }
.category-pill { display: inline-flex; align-items: center; gap: 6px; color: var(--rust); font-family: var(--sans); font-size: 10px; font-weight: 600; letter-spacing: 0.08em; text-transform: none; }
.category-pill::before { content: ""; width: 5px; height: 5px; background: currentColor; border-radius: 50%; }
.featured-title { margin-top: 25px; font-family: var(--serif); font-size: clamp(31px, 4vw, 54px); font-weight: 500; line-height: 1.15; letter-spacing: -0.045em; }
.featured-title a:hover { color: var(--rust); }
.featured-excerpt { max-width: 520px; margin-top: 18px; color: var(--ink-soft); font-size: 13.5px; line-height: 1.9; }
.featured-foot { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.read-arrow { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font-family: var(--mono); font-size: 10px; letter-spacing: 0.06em; }
.read-arrow svg { width: 15px; height: 15px; transition: transform .25s var(--ease); }
.featured-card:hover .read-arrow svg { transform: translateX(4px); }

/* Latest grid */
.latest { padding-bottom: clamp(60px, 8vw, 110px); }
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 26px; }
.post-card { display: flex; flex-direction: column; min-width: 0; }
.post-card .post-cover { margin-bottom: 18px; transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.post-card:hover .post-cover { transform: translateY(-4px); box-shadow: 0 18px 34px rgba(22, 26, 23, 0.1); }
.post-card .post-meta-row { margin-bottom: 10px; }
.post-card-title { font-family: var(--serif); font-size: clamp(20px, 2vw, 25px); font-weight: 500; line-height: 1.3; letter-spacing: -0.025em; }
.post-card-title a:hover { color: var(--rust); }
.post-card-excerpt { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 10px; color: var(--muted); font-size: 12px; line-height: 1.8; }
.post-card-foot { display: flex; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 15px; color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: 0.04em; }
.post-card--list { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 20px; padding-block: 18px; border-bottom: 1px solid var(--line); }
.post-card--list .post-cover { margin: 0; aspect-ratio: 1.4/1; padding: 14px; }
.post-card--list .cover-mark { font-size: 44px; }

/* Quote + join */
.quote-band {
  position: relative; overflow: hidden; padding-block: clamp(65px, 9vw, 110px);
  color: var(--paper-soft); background: var(--forest);
}
.quote-band::before {
  content: ""; position: absolute; width: 62vw; aspect-ratio: 1; right: -20vw; top: -30vw;
  border: 1px solid rgba(243,239,230,.12); border-radius: 50%;
  box-shadow: 0 0 0 5vw rgba(243,239,230,.025), 0 0 0 10vw rgba(243,239,230,.025);
}
.quote-inner { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: end; }
.quote-cn { font-family: var(--serif); font-size: clamp(32px, 4.5vw, 60px); font-weight: 400; line-height: 1.35; letter-spacing: -0.03em; }
.quote-cn em { color: #d9a88f; font-weight: 400; }
.quote-note { max-width: 360px; margin-left: auto; color: rgba(243,239,230,.65); font-size: 12.5px; line-height: 1.95; }
.quote-note span { display: block; margin-bottom: 14px; font-family: var(--mono); font-size: 9px; letter-spacing: .12em; opacity: .7; }
.join-panel { display: flex; align-items: center; justify-content: space-between; gap: 30px; padding-block: clamp(55px, 7vw, 90px); }
.join-copy h2 { margin-top: 12px; font-family: var(--serif); font-size: clamp(28px, 3.4vw, 44px); font-weight: 500; letter-spacing: -0.035em; }
.join-copy p { max-width: 490px; margin-top: 12px; color: var(--muted); font-size: 13px; }
.join-actions { display: flex; align-items: center; gap: 10px; flex: none; }

/* Archive / search */
.archive-head { padding-block: clamp(56px, 8vw, 100px) 45px; border-bottom: 1px solid var(--line-strong); }
.archive-head h1 { max-width: 900px; margin-top: 20px; font-family: var(--serif); font-size: clamp(40px, 6vw, 80px); font-weight: 500; line-height: 1.1; letter-spacing: -0.05em; }
.archive-desc { max-width: 580px; margin-top: 18px; color: var(--muted); font-size: 13px; }
.archive-count { margin-top: 22px; color: var(--muted); font-family: var(--mono); font-size: 9.5px; letter-spacing: .08em; }
.archive-grid { padding-block: 44px clamp(60px, 8vw, 100px); }
.empty-state { padding-block: 70px; color: var(--muted); font-size: 14px; }
.pagination { display: flex; gap: 8px; align-items: center; margin-top: 45px; font-family: var(--mono); font-size: 11px; }
.pagination .page-numbers { display: grid; place-items: center; min-width: 34px; height: 34px; border: 1px solid var(--line); }
.pagination .current, .pagination a:hover { color: var(--paper-soft); background: var(--ink); border-color: var(--ink); }

/* Single */
.article-wrap { padding-bottom: 80px; }
.article-head { padding-block: clamp(50px, 7vw, 88px) 30px; }
.breadcrumb { display: flex; align-items: center; gap: 8px; color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: .08em; text-transform: uppercase; }
.breadcrumb a:hover { color: var(--rust); }
.article-title { max-width: 1030px; margin-top: 22px; font-family: var(--serif); font-size: clamp(38px, 6vw, 78px); font-weight: 500; line-height: 1.12; letter-spacing: -0.055em; }
.article-dek { max-width: 720px; margin-top: 21px; color: var(--ink-soft); font-family: var(--serif); font-size: 17px; line-height: 1.8; }
.article-byline { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 30px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.byline-author { display: flex; align-items: center; gap: 8px; color: var(--ink); }
.article-main-cover { margin-bottom: 44px; }
.article-main-cover .post-cover { aspect-ratio: 2.15/1; padding: clamp(22px, 4vw, 44px); }
.article-main-cover .cover-mark { font-size: clamp(60px, 12vw, 150px); }
.article-layout { display: grid; grid-template-columns: minmax(0, 760px) 210px; gap: clamp(40px, 6vw, 90px); align-items: start; }
.article-side { position: sticky; top: 110px; padding-top: 7px; }
.side-label { color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: .1em; text-transform: uppercase; }
.favorite-button { display: flex; align-items: center; gap: 9px; width: 100%; margin-top: 10px; padding: 12px 0; border-block: 1px solid var(--line); font-size: 12px; color: var(--ink-soft); }
.favorite-button svg { width: 16px; height: 16px; }
.favorite-button.is-active { color: var(--rust); }
.favorite-button.is-active svg { fill: currentColor; }
.side-share { display: flex; gap: 12px; margin-top: 15px; color: var(--muted); font-size: 11px; }
.side-share a:hover { color: var(--rust); }
.article-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 24px; }
.article-tag { padding: 5px 9px; border: 1px solid var(--line); color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: .04em; }
.article-tag:hover { border-color: var(--ink); color: var(--ink); }

.entry-content { color: #292e29; font-size: 15.5px; line-height: 2; }
.entry-content > * + * { margin-top: 1.35em; }
.entry-content h2 { margin-top: 2.1em; font-family: var(--serif); font-size: clamp(26px, 3vw, 34px); font-weight: 500; line-height: 1.35; letter-spacing: -0.035em; }
.entry-content h3 { margin-top: 1.8em; font-family: var(--serif); font-size: 23px; font-weight: 500; letter-spacing: -0.02em; }
.entry-content a { color: var(--rust); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.entry-content strong { color: var(--ink); }
.entry-content ul, .entry-content ol { padding-left: 22px; list-style: disc; }
.entry-content ol { list-style: decimal; }
.entry-content li + li { margin-top: 6px; }
.entry-content blockquote {
  margin: 2.2em 0; padding: 6px 0 6px 24px; color: var(--forest);
  border-left: 2px solid var(--rust); font-family: var(--serif);
  font-size: clamp(20px, 2.5vw, 27px); line-height: 1.6; letter-spacing: -0.02em;
}
.entry-content blockquote p { margin: 0; }
.entry-content code { padding: 2px 5px; background: var(--paper-deep); font-family: var(--mono); font-size: .85em; }
.entry-content pre { overflow-x: auto; padding: 20px; color: #e8e4da; background: var(--forest-2); font-family: var(--mono); font-size: 12px; line-height: 1.7; }
.entry-content pre code { padding: 0; background: transparent; color: inherit; font-size: inherit; }
.entry-content img { margin-block: 2em; }
.entry-content hr { margin-block: 2.5em; border: 0; border-top: 1px solid var(--line); }
.article-signoff { margin-top: 46px; padding-top: 26px; border-top: 1px solid var(--line-strong); }
.author-card { display: flex; gap: 16px; align-items: center; margin-top: 24px; padding: 22px; background: var(--paper-soft); border: 1px solid var(--line); }
.author-card p { margin-top: 3px; color: var(--muted); font-size: 11px; }
.author-card strong { font-family: var(--serif); font-size: 17px; font-weight: 500; }
.article-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding-block: 32px; border-top: 1px solid var(--line-strong); }
.post-nav-label { color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: .1em; }
.post-nav-title { margin-top: 8px; font-family: var(--serif); font-size: 18px; line-height: 1.5; }
.post-nav-link.next { text-align: right; }

/* Comments */
.comments-area { margin-top: 48px; padding-top: 34px; border-top: 1px solid var(--line-strong); }
.comments-title { display: flex; align-items: baseline; gap: 10px; font-family: var(--serif); font-size: 27px; font-weight: 500; letter-spacing: -0.03em; }
.comments-title span { color: var(--muted); font-family: var(--mono); font-size: 10px; }
.comment-list { margin-top: 24px; }
.comment-body { padding: 20px 0; border-top: 1px solid var(--line); }
.comment-meta { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 10px; }
.comment-author { display: flex; align-items: center; gap: 8px; color: var(--ink); font-size: 12px; font-weight: 600; }
.comment-content { margin-top: 12px; font-size: 13.5px; line-height: 1.9; }
.comment-content p + p { margin-top: 10px; }
.comment-list .children { margin-left: 30px; padding-left: 22px; border-left: 1px solid var(--line); }
.reply { margin-top: 8px; font-size: 10px; }
.comment-form { margin-top: 24px; }
.comment-form .form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 14px; }
.form-field label { color: var(--ink-soft); font-family: var(--mono); font-size: 9px; letter-spacing: .08em; text-transform: uppercase; }
.form-field input, .form-field textarea {
  width: 100%; padding: 12px 13px; color: var(--ink); background: var(--paper-soft);
  border: 1px solid var(--line-strong); border-radius: var(--radius); outline: 0; transition: border-color .2s;
}
.form-field input:focus, .form-field textarea:focus { border-color: var(--forest); }
.form-field textarea { min-height: 120px; resize: vertical; }
.comment-form .submit, .auth-form .submit, .profile-form .submit {
  display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 22px;
  color: var(--paper-soft); background: var(--ink); border: 1px solid var(--ink);
  border-radius: var(--radius); font-size: 12px; transition: .25s var(--ease);
}
.comment-form .submit:hover, .auth-form .submit:hover, .profile-form .submit:hover { background: var(--forest); border-color: var(--forest); }
.comment-note { margin-top: 18px; padding: 18px; color: var(--muted); background: var(--paper-soft); border: 1px solid var(--line); font-size: 12px; }
.comment-note a { color: var(--rust); text-decoration: underline; text-underline-offset: 3px; }
.form-notice { margin-bottom: 16px; padding: 10px 12px; color: #7f2d16; background: #f4ded3; border-left: 2px solid var(--rust); font-size: 11.5px; }
.form-notice.success { color: var(--forest); background: #e4ede7; border-color: var(--forest); }

/* Static pages */
.page-wrap { padding-block: clamp(55px, 8vw, 100px) 80px; }
.page-head { padding-bottom: 30px; border-bottom: 1px solid var(--line-strong); }
.page-head h1 { max-width: 900px; margin-top: 18px; font-family: var(--serif); font-size: clamp(40px, 6vw, 72px); font-weight: 500; line-height: 1.12; letter-spacing: -0.05em; }
.page-body { display: grid; grid-template-columns: minmax(0, 720px) 210px; gap: clamp(40px, 6vw, 90px); padding-top: 40px; }
.page-side { color: var(--muted); font-size: 11px; }
.page-side strong { display: block; margin-bottom: 8px; color: var(--ink); font-family: var(--serif); font-size: 16px; font-weight: 500; }
.page-nav { display: flex; flex-direction: column; gap: 7px; margin-top: 20px; }
.page-nav a:hover { color: var(--rust); }

/* Auth */
.auth-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(400px, 480px); gap: 0; min-height: calc(100vh - 82px); }
.auth-visual { display: flex; flex-direction: column; justify-content: space-between; padding: 54px clamp(34px, 7vw, 100px); color: var(--paper-soft); background: var(--forest); position: relative; overflow: hidden; }
.auth-visual::before { content: ""; position: absolute; width: 55vw; aspect-ratio: 1; right: -24vw; top: -18vw; border: 1px solid rgba(243,239,230,.2); border-radius: 50%; box-shadow: 0 0 0 4vw rgba(243,239,230,.03), 0 0 0 9vw rgba(243,239,230,.025); }
.auth-visual .brand-word { color: var(--paper-soft); }
.auth-quote { position: relative; max-width: 490px; margin-block: auto; padding-block: 80px; font-family: var(--serif); font-size: clamp(30px, 4vw, 53px); font-weight: 400; line-height: 1.35; letter-spacing: -0.04em; }
.auth-quote em { color: #d6a68d; font-weight: 400; }
.auth-visual-foot { position: relative; color: rgba(243,239,230,.55); font-family: var(--mono); font-size: 9px; letter-spacing: .12em; }
.auth-panel { display: flex; flex-direction: column; justify-content: center; padding: 50px clamp(24px, 5vw, 70px); background: var(--paper-soft); }
.auth-panel-inner { width: min(100%, 360px); margin-inline: auto; }
.auth-panel h1 { margin-top: 18px; font-family: var(--serif); font-size: clamp(34px, 4vw, 48px); font-weight: 500; letter-spacing: -0.04em; }
.auth-sub { margin-top: 10px; color: var(--muted); font-size: 12px; line-height: 1.75; }
.auth-form { margin-top: 28px; }
.auth-field { position: relative; }
.auth-field input { width: 100%; padding: 14px 14px; background: transparent; border: 1px solid var(--line-strong); border-radius: var(--radius); outline: 0; font-size: 13px; }
.auth-field input:focus { border-color: var(--forest); }
.auth-field + .auth-field { margin-top: 11px; }
.password-toggle { position: absolute; right: 12px; top: 14px; color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: .05em; }
.form-row-between { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 13px 0 18px; color: var(--muted); font-size: 10.5px; }
.check-label { display: flex; align-items: flex-start; gap: 8px; color: var(--muted); font-size: 10.5px; line-height: 1.6; }
.check-label input { margin-top: 4px; accent-color: var(--rust); }
.auth-form .submit { width: 100%; min-height: 46px; margin-top: 4px; color: var(--paper-soft); background: var(--ink); border-color: var(--ink); }
.auth-form .submit:hover { background: var(--forest); border-color: var(--forest); }
.auth-alt { margin-top: 18px; color: var(--muted); font-size: 11.5px; }
.auth-alt a { color: var(--rust); text-decoration: underline; text-underline-offset: 3px; }
.auth-notice { margin-top: 18px; padding: 11px 12px; border-left: 2px solid var(--forest); color: var(--forest); background: #e5eee8; font-size: 11px; }
.auth-notice.error { color: #7f2d16; background: #f3ddd2; border-color: var(--rust); }
.auth-back { margin-top: 30px; color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: .08em; }
.auth-back a:hover { color: var(--ink); }
.activation-wrap { min-height: calc(100vh - 82px); display: grid; place-items: center; padding: 60px 20px; }
.activation-card { width: min(520px, 100%); padding: 42px; text-align: center; background: var(--paper-soft); border: 1px solid var(--line); }
.activation-card h1 { margin-top: 18px; font-family: var(--serif); font-size: 38px; font-weight: 500; letter-spacing: -.04em; }
.activation-card p { margin-top: 12px; color: var(--muted); font-size: 12.5px; line-height: 1.8; }

/* Account */
.account-wrap { padding-block: clamp(50px, 7vw, 85px) 90px; }
.account-head { display: flex; align-items: center; gap: 20px; padding-bottom: 30px; border-bottom: 1px solid var(--line-strong); }
.account-head h1 { margin-top: 5px; font-family: var(--serif); font-size: clamp(29px, 4vw, 42px); font-weight: 500; letter-spacing: -.04em; }
.account-head p { margin-top: 4px; color: var(--muted); font-size: 11px; }
.account-head .account-action { margin-left: auto; display: flex; gap: 8px; }
.account-grid { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 50px; padding-top: 34px; align-items: start; }
.account-nav { display: flex; flex-direction: column; gap: 3px; position: sticky; top: 110px; }
.account-nav a, .account-nav button { display: block; width: 100%; padding: 8px 0; color: var(--muted); font-family: var(--mono); font-size: 10px; letter-spacing: .03em; text-align: left; }
.account-nav a:hover, .account-nav button:hover, .account-nav .is-active { color: var(--ink); }
.account-section + .account-section { margin-top: 45px; padding-top: 35px; border-top: 1px solid var(--line); }
.account-section h2 { font-family: var(--serif); font-size: 28px; font-weight: 500; letter-spacing: -.035em; }
.account-section > p { margin-top: 8px; color: var(--muted); font-size: 12px; }
.account-post-list { margin-top: 20px; }
.account-post { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-block: 15px; border-bottom: 1px solid var(--line); }
.account-post h3 { font-family: var(--serif); font-size: 19px; font-weight: 500; }
.account-post small { color: var(--muted); font-size: 10px; }
.account-post .remove-favorite { color: var(--muted); font-family: var(--mono); font-size: 9px; white-space: nowrap; }
.account-post .remove-favorite:hover { color: var(--rust); }
.account-comment { padding-block: 15px; border-bottom: 1px solid var(--line); color: var(--ink-soft); font-size: 12.5px; }
.account-comment a { color: var(--ink); }
.account-comment small { display: block; margin-top: 5px; color: var(--muted); font-size: 9.5px; }
.profile-form { max-width: 480px; margin-top: 22px; }
.profile-form .form-field input, .profile-form .form-field textarea { background: transparent; }
.account-empty { margin-top: 18px; padding: 22px; color: var(--muted); border: 1px solid var(--line); font-size: 12px; }

/* Footer */
.site-footer { margin-top: auto; padding-top: 50px; border-top: 1px solid var(--line-strong); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 50px; padding-bottom: 44px; }
.footer-brand p { max-width: 300px; margin-top: 15px; color: var(--muted); font-size: 11.5px; line-height: 1.8; }
.footer-col h3 { margin-bottom: 12px; color: var(--muted); font-family: var(--mono); font-size: 9px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; }
.footer-col a, .footer-col button { display: block; padding: 3px 0; color: var(--ink-soft); font-size: 11.5px; text-align: left; }
.footer-col a:hover, .footer-col button:hover { color: var(--rust); }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 17px; border-top: 1px solid var(--line); color: var(--muted); font-family: var(--mono); font-size: 9px; letter-spacing: .02em; }
.footer-bottom a:hover { color: var(--rust); }
.site-footer .brand-word { font-size: 22px; }

/* Motion */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@keyframes fade { from { opacity: 0 } to { opacity: 1 } }

/* Responsive */
@media (max-width: 1000px) {
  .container { width: min(100% - 44px, 900px); }
  .home-hero { grid-template-columns: 1fr; gap: 34px; }
  .hero-aside { min-height: 0; max-width: 560px; border-left: 0; border-top: 1px solid var(--line); padding: 22px 0 0; }
  .aside-quote { margin-top: 20px; }
  .featured-card { grid-template-columns: 1fr; gap: 24px; }
  .featured-cover { min-height: 330px; }
  .featured-copy { padding-block: 0; }
  .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-layout, .page-body { grid-template-columns: 1fr; }
  .article-side { position: static; display: flex; align-items: center; gap: 20px; order: 2; padding-top: 24px; border-top: 1px solid var(--line); }
  .article-side .side-label { display: none; }
  .favorite-button { width: auto; margin: 0; border: 0; }
  .side-share { margin: 0 0 0 auto; }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-visual { display: none; }
  .auth-panel { min-height: calc(100vh - 82px); }
  .account-grid { grid-template-columns: 1fr; gap: 30px; }
  .account-nav { position: static; flex-direction: row; gap: 20px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; gap: 30px; }
}
@media (max-width: 760px) {
  .container { width: calc(100% - 36px); }
  .header-inner { min-height: 70px; }
  .desktop-nav { position: fixed; inset: 70px 0 auto; display: none; padding: 20px 18px 26px; background: var(--paper-soft); border-bottom: 1px solid var(--line-strong); box-shadow: 0 24px 35px rgba(23,26,23,.08); }
  .desktop-nav.is-open { display: block; }
  .nav-list { align-items: stretch; flex-direction: column; gap: 0; }
  .nav-list a { display: block; padding: 13px 4px; border-bottom: 1px solid var(--line); font-family: var(--serif); font-size: 21px; }
  .nav-list a::after { display: none; }
  .mobile-toggle { display: inline-grid; }
  .header-actions .text-link, .header-actions .header-cta, .header-actions .user-chip span.username { display: none; }
  .header-actions .user-chip { padding: 0; }
  .header-actions { gap: 5px; }
  .home-hero { padding-block: 55px 46px; }
  .hero-title { font-size: clamp(43px, 13vw, 70px); }
  .hero-lead { margin-top: 23px; font-size: 13px; }
  .hero-actions .btn { min-height: 41px; }
  .post-grid { grid-template-columns: 1fr; gap: 34px; }
  .post-card .post-cover { aspect-ratio: 1.7/1; }
  .quote-inner { grid-template-columns: 1fr; gap: 28px; }
  .quote-note { margin-left: 0; max-width: 460px; }
  .join-panel { flex-direction: column; align-items: flex-start; gap: 23px; }
  .section-head h2 { font-size: 32px; }
  .article-title { font-size: clamp(35px, 9vw, 56px); }
  .article-dek { font-size: 15px; }
  .article-main-cover { margin-bottom: 32px; }
  .article-main-cover .post-cover { aspect-ratio: 1.3/1; }
  .entry-content { font-size: 15px; line-height: 1.95; }
  .article-nav { grid-template-columns: 1fr; gap: 24px; }
  .post-nav-link.next { text-align: left; }
  .comments-area { margin-top: 36px; }
  .comment-form .form-grid { grid-template-columns: 1fr; gap: 0; }
  .page-body { padding-top: 30px; }
  .page-side { display: none; }
  .account-head { align-items: flex-start; flex-wrap: wrap; }
  .account-head .account-action { width: 100%; margin-left: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; padding-bottom: 32px; }
  .footer-brand { grid-column: 1 / -1; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 6px; padding-block: 15px 22px; }
  .search-layer { padding-top: 18vh; }
  .search-close { top: 18px; right: 18px; }
}
@media (max-width: 420px) {
  .brand-word { font-size: 24px; }
  .hero-title { font-size: 41px; }
  .post-card .post-cover { aspect-ratio: 1.45/1; }
  .auth-panel { padding-inline: 20px; }
  .activation-card { padding: 30px 20px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 26px 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
