:root { --paper:#f7f5f0; --rail:#f1eee7; --ink:#171814; --muted:#6f706a; --rule:#d8d4ca; --green:#214b3d; --red:#a84431; --blue:#365b6b; --ochre:#b27c2c; --gray:#6f7970; --plum:#776278; }
* { box-sizing:border-box; }
html,body { margin:0; min-height:100%; }
body { color:var(--ink); background:var(--paper); font-family:"Noto Serif SC","Songti SC",SimSun,serif; font-size:16px; line-height:1.5; }
a { color:inherit; text-decoration:none; }
button,input,select,textarea { color:inherit; font:inherit; }
a,button { transition:color 160ms ease,background-color 160ms ease,border-color 160ms ease; }
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible { outline:2px solid var(--red); outline-offset:3px; }
.sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; }
.site-frame { min-height:100vh; display:grid; grid-template-columns:255px minmax(0,1fr); }
.site-header { min-height:100vh; display:flex; flex-direction:column; padding:42px 28px 30px; background:var(--rail); border-right:1px solid var(--rule); }
.wordmark { display:flex; align-items:center; gap:14px; width:max-content; }
.wordmark-mark { width:50px; height:50px; display:grid; place-items:center; color:#fff; background:var(--green); font-family:Georgia,serif; font-size:30px; }
.wordmark strong { display:block; font-size:23px; font-weight:700; line-height:1.1; letter-spacing:0; }
.wordmark small { display:block; margin-top:4px; font-family:Arial,sans-serif; font-size:10px; letter-spacing:1.2px; }
.site-nav { margin-top:66px; }
.nav-group { display:grid; gap:6px; }
.nav-item { display:flex; align-items:center; gap:16px; min-height:43px; padding:0 11px; font-size:18px; }
.nav-item:hover,.nav-item.active { color:#fff; background:var(--green); }
.nav-symbol { display:inline-grid; width:20px; place-items:center; font-family:Arial,sans-serif; font-size:21px; line-height:1; }
.nav-divider { height:1px; margin:26px 9px 25px; background:var(--rule); }
.nav-caption { margin:0 10px 10px; color:var(--muted); font-family:Arial,sans-serif; font-size:12px; }
.sidebar-bottom { margin-top:auto; padding:27px 9px 0; border-top:1px solid var(--rule); color:var(--muted); font-size:13px; line-height:1.65; }
.sidebar-account { display:flex; align-items:center; justify-content:space-between; margin-top:20px; color:var(--ink); font-family:Arial,sans-serif; font-size:13px; }
.sidebar-account form { margin:0; }
.icon-button { width:30px; height:30px; border:0; background:transparent; cursor:pointer; font-size:18px; }
.page-main { min-width:0; padding:43px 46px 30px; overflow:hidden; }
.home-top { display:flex; align-items:flex-start; justify-content:space-between; padding-bottom:17px; border-bottom:1px solid var(--rule); }
.kicker { margin:0 0 10px; color:var(--red); font-family:Arial,sans-serif; font-size:12px; font-weight:700; letter-spacing:1.5px; }
.home-top h1 { margin:0; font-size:24px; font-weight:600; }
.home-top time { display:grid; justify-items:end; font-family:Georgia,serif; font-size:26px; line-height:1; }
.home-top time small { margin-top:11px; font-family:Arial,sans-serif; font-size:10px; }
.hero-grid { display:grid; grid-template-columns:minmax(400px,1fr) minmax(330px,.7fr); gap:48px; align-items:center; padding:39px 0 27px; }
.hero-grid h2 { margin:0; font-size:48px; line-height:1.38; font-weight:700; letter-spacing:0; }
.hero-grid p { margin:18px 0 0; color:#565650; font-size:17px; line-height:1.7; }
.search-box,.library-search { display:flex; align-items:center; gap:15px; min-height:63px; padding:0 18px; background:#efebe3; }
.search-box span,.library-search span { font-family:Arial,sans-serif; font-size:34px; transform:rotate(-20deg); }
.search-box input,.library-search input { min-width:0; flex:1; border:0; outline:0; background:transparent; font-size:17px; }
.search-box kbd { color:var(--muted); font-family:Arial,sans-serif; font-size:12px; }
.category-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:10px; }
.category-card { min-height:214px; display:flex; flex-direction:column; padding:25px 29px 20px; color:#fff; cursor:pointer; }
.category-card:hover { filter:brightness(.94); }
.category-card.green,.dot.green { background:var(--green); }.category-card.red,.dot.red { background:var(--red); }.category-card.blue,.dot.blue { background:var(--blue); }.category-card.ochre,.dot.ochre { background:var(--ochre); }.category-card.gray,.dot.gray { background:var(--gray); }.category-card.plum,.dot.plum { background:var(--plum); }
.card-symbol { font-family:Arial,sans-serif; font-size:39px; font-weight:300; line-height:1; }
.category-card strong { margin-top:23px; font-size:20px; }
.card-rule { height:1px; margin:24px 0 19px; background:rgba(255,255,255,.2); }
.category-card small { margin-top:auto; font-size:14px; }
.home-lower { display:grid; grid-template-columns:minmax(0,1.8fr) minmax(290px,.9fr); gap:30px; margin-top:32px; }
.recent-panel,.stats-panel { border:1px solid var(--rule); background:rgba(255,255,255,.2); }
.recent-panel { padding:18px 20px 12px; }
.panel-head { display:flex; justify-content:space-between; align-items:center; padding-bottom:13px; border-bottom:1px solid var(--rule); }
.panel-head h2,.stats-panel h2 { margin:0; font-size:17px; }
.panel-head a { font-size:13px; }
.sample-row { display:grid; grid-template-columns:34px minmax(0,1fr) 75px 65px; align-items:center; gap:12px; min-height:50px; border-bottom:1px solid #e4e0d8; }
.sample-row:last-child { border:0; }
.file-type-icon { width:30px; height:30px; display:grid; place-items:center; border:1px solid currentColor; color:var(--green); font-family:Arial,sans-serif; font-size:9px; font-weight:700; letter-spacing:.3px; }
.file-type-md { color:var(--blue); }.file-type-json { color:var(--ochre); }
.sample-name { min-width:0; display:grid; gap:2px; }
.sample-name strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:14px; font-weight:400; }
.sample-name small,.sample-meta { color:var(--muted); font-size:12px; }
.sample-meta,.sample-open { text-align:right; }
.sample-open { color:var(--red); font-size:13px; }
.home-aside { display:grid; gap:11px; }
.stats-panel { min-height:192px; display:grid; grid-template-columns:1fr 1.25fr; grid-template-rows:auto 1fr; padding:21px 25px 17px; }
.stats-panel h2 { grid-column:1/-1; }
.stat-number { align-self:end; font-family:Georgia,serif; font-size:46px; line-height:1; }
.stats-panel > small { align-self:end; margin:0 0 1px -73px; color:var(--muted); font-size:12px; transform:translateY(20px); }
.stats-panel ul { grid-row:2; grid-column:2; align-self:end; display:grid; gap:4px; margin:7px 0 0; padding:0; list-style:none; font-size:12px; }
.stats-panel li { display:flex; justify-content:space-between; gap:10px; }.stats-panel li span { display:flex; gap:8px; align-items:center; }.stats-panel li small { white-space:nowrap; }
.dot { width:9px; height:9px; border-radius:50%; }.quote-panel { display:grid; gap:14px; padding:21px 25px; background:#e8e2ea; font-size:14px; }.quote-panel a { justify-self:end; font-size:13px; }
.empty { color:var(--muted); padding:32px 0; }
.form-layout { width:min(815px,100%); margin:0 auto; padding-top:40px; }.form-head { margin-bottom:38px; }.form-head h1,.library-layout h1,.detail-layout h1 { margin:0; font-size:48px; line-height:1.15; }.form-head p:not(.kicker) { color:var(--muted); font-size:17px; }
.form-body { display:grid; gap:23px; }.form-body label { display:grid; gap:8px; font-family:Arial,sans-serif; font-size:14px; font-weight:700; }.form-body input,.form-body select,.form-body textarea { width:100%; padding:8px 0 11px; border:0; border-bottom:1px solid var(--ink); outline:0; background:transparent; font-family:"Noto Serif SC",SimSun,serif; font-size:18px; font-weight:400; }.form-body textarea { min-height:130px; padding:12px; border:1px solid var(--rule); resize:vertical; }
.form-body input[type=file] { font-family:Arial,sans-serif; font-size:15px; }.button { width:max-content; min-height:46px; padding:0 22px; border:1px solid var(--ink); background:var(--ink); color:#fff; cursor:pointer; font-family:Arial,sans-serif; font-size:15px; font-weight:700; }.button:hover { background:var(--green); border-color:var(--green); }.button:disabled { opacity:.6; cursor:wait; }.button-light { background:transparent; color:var(--ink); }.button-light:hover { color:#fff; }.form-error,.setup-note { padding:13px 15px; font-family:Arial,sans-serif; font-size:14px; }.form-error { border-left:4px solid var(--red); background:#f4ddd8; }.setup-note { border-left:4px solid var(--green); background:#e7ebdf; white-space:pre-wrap; word-break:break-all; }
.library-layout { width:min(1100px,100%); margin:0 auto; padding-top:18px; }.page-heading { display:grid; gap:23px; padding-bottom:31px; }.library-search { border-top:1px solid var(--ink); border-bottom:3px solid var(--ink); background:transparent; }.library-search input[type=hidden] { display:none; }.result-heading { margin:0; padding:30px 0 27px; border-bottom:1px solid var(--ink); font-size:39px; font-weight:500; }.library-results { border-bottom:1px solid var(--rule); }.library-result { display:grid; grid-template-columns:50px minmax(0,1fr) 84px 76px; align-items:center; gap:16px; min-height:100px; border-bottom:1px solid var(--rule); }.library-result:last-child { border:0; }.library-result .file-type-icon { width:42px; height:42px; font-size:11px; }.library-result strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:21px; font-weight:500; }.library-result small { display:block; margin-top:5px; color:var(--muted); font-size:15px; }.result-size { color:var(--muted); font-size:14px; text-align:right; }.result-link { color:var(--red); font-family:Arial,sans-serif; font-size:17px; text-align:right; }.back-top { display:block; margin-top:25px; text-align:right; color:var(--muted); font-size:14px; }
.detail-layout { width:min(920px,100%); margin:0 auto; padding-top:18px; }.detail-head { display:flex; align-items:flex-start; justify-content:space-between; gap:25px; padding:18px 0 24px; border-bottom:1px solid var(--ink); }.detail-head > div { min-width:0; }.detail-head .file-type-icon { float:left; width:48px; height:48px; margin:5px 16px 0 0; font-size:12px; }.detail-head h1 { font-size:37px; }.detail-head p { margin:10px 0 0; color:var(--muted); }.detail-meta { display:flex; flex-wrap:wrap; gap:9px; margin:20px 0; }.detail-meta span { padding:4px 10px; background:#ece9e1; font-size:13px; }.detail-tools { display:grid; gap:14px; padding:18px 0 24px; border-bottom:1px solid var(--rule); }.detail-tools .form-body { width:min(680px,100%); }.detail-tools .form-body label { font-size:13px; }.detail-tools .form-body input { font-size:16px; }.detail-tools .form-body button { margin-top:2px; }.detail-tools > form:last-child { margin:0; }.button-danger { border-color:var(--red); background:transparent; color:var(--red); }.button-danger:hover { border-color:var(--red); background:var(--red); color:#fff; }.reader { padding:25px 0; border-top:1px solid var(--rule); }.reader pre { margin:0; white-space:pre-wrap; overflow-wrap:anywhere; font-family:"Noto Serif SC",SimSun,serif; font-size:17px; line-height:1.9; }.detail-note { padding:16px 18px; background:#eee9e0; }
.auth-page { min-height:100vh; display:grid; place-items:center; padding:30px; background:#eeeae2; }.auth-card { width:min(810px,100%); min-height:610px; padding:62px; border:1px solid var(--ink); background:#fbfaf6; }.auth-card .kicker { margin-top:71px; }.auth-card h1 { margin:0; font-size:48px; }.auth-intro { margin:11px 0 35px; color:var(--muted); font-size:18px; }.auth-card .form-body { width:min(680px,100%); }
@media (max-width:1100px) { .category-grid { grid-template-columns:repeat(3,1fr); }.home-lower { grid-template-columns:1fr; }.home-aside { grid-template-columns:1fr 1fr; }.hero-grid { grid-template-columns:1fr; gap:25px; }.page-main { overflow:visible; } }
@media (max-width:760px) { .site-frame { display:block; }.site-header { min-height:0; padding:18px; border-right:0; border-bottom:1px solid var(--rule); }.wordmark-mark { width:39px; height:39px; font-size:24px; }.wordmark strong { font-size:19px; }.site-nav { margin-top:17px; overflow-x:auto; }.nav-group { display:flex; width:max-content; }.nav-item { min-height:38px; padding:0 8px; font-size:15px; }.nav-symbol { display:none; }.nav-divider,.nav-caption,.sidebar-bottom { display:none; }.page-main { padding:24px 20px 32px; overflow:visible; }.home-top h1 { font-size:19px; }.home-top time { font-size:20px; }.hero-grid { padding:25px 0; }.hero-grid h2 { font-size:33px; }.hero-grid p { font-size:15px; }.search-box { min-height:54px; }.search-box kbd { display:none; }.category-grid { grid-template-columns:repeat(2,1fr); gap:7px; }.category-card { min-height:145px; padding:18px; }.card-symbol { font-size:27px; }.category-card strong { margin-top:15px; font-size:18px; }.card-rule { margin:13px 0; }.home-aside { grid-template-columns:1fr; }.sample-row { grid-template-columns:32px minmax(0,1fr) 55px; }.sample-meta { display:none; }.sample-name strong { font-size:13px; }.sample-open { font-size:13px; }.form-layout,.library-layout,.detail-layout { padding-top:8px; }.form-head h1,.library-layout h1 { font-size:38px; }.result-heading { font-size:31px; }.library-result { grid-template-columns:43px minmax(0,1fr) 63px; gap:10px; min-height:86px; }.library-result .result-size { display:none; }.library-result strong { font-size:17px; }.library-result small { font-size:13px; }.result-link { font-size:15px; }.detail-head { display:grid; }.detail-head h1 { font-size:29px; }.auth-page { padding:18px; }.auth-card { min-height:0; padding:34px 28px 39px; }.auth-card .kicker { margin-top:48px; }.auth-card h1 { font-size:39px; } }

/* Fixed icon geometry and the desktop-only, single-workspace home view. */
.ui-icon { width:18px; height:18px; display:block; flex:0 0 auto; }
.brand-icon { width:27px; height:27px; }
.nav-symbol { height:20px; }
.card-symbol .ui-icon { width:39px; height:39px; }
.search-icon { width:25px; height:25px; }
.icon-button { display:grid; place-items:center; }
.icon-button .ui-icon { width:17px; height:17px; }
.search-box span,.library-search span { transform:none; }

.stats-panel { display:grid; grid-template-columns:minmax(90px,.8fr) minmax(175px,1.2fr); grid-template-rows:auto 1fr auto; }
.stats-panel h2 { grid-column:1 / -1; }
.stat-number { grid-column:1; grid-row:2; align-self:end; }
.stats-panel > small { grid-column:1; grid-row:3; align-self:start; margin:4px 0 0; transform:none; }
.stats-panel ul { grid-column:2; grid-row:2 / span 2; align-self:center; margin:12px 0 0; }
.home-aside { align-content:start; grid-auto-rows:max-content; }
.nav-logout { display:block; margin:0; }
.nav-logout .nav-item { width:100%; border:0; background:transparent; text-align:left; cursor:pointer; }
.nav-logout .nav-item:hover { color:#fff; background:var(--green); }
.home-top time { gap:7px; }
.home-top time .date-primary { font-family:Georgia,serif; font-size:31px; line-height:1; letter-spacing:.02em; }
.home-top time small { margin-top:0; font-size:12px; color:var(--ink); }
.stats-panel { grid-template-columns:minmax(120px,.85fr) minmax(220px,1.15fr); grid-template-rows:auto 1fr; }
.stats-panel .stat-summary { grid-column:1; grid-row:2; align-self:center; justify-self:center; display:grid; justify-items:center; gap:7px; }
.stats-panel .stat-summary .stat-number { grid-column:auto; grid-row:auto; align-self:auto; justify-self:auto; font-family:Georgia,serif; font-size:54px; line-height:1; font-weight:400; }
.stats-panel .stat-summary span { color:var(--muted); font-size:14px; }
.stats-panel ul { grid-column:2; grid-row:2; align-self:center; display:grid; grid-template-rows:repeat(6, 18px); gap:5px; margin:0; font-size:15px; line-height:18px; }
.stats-panel li { min-height:18px; line-height:18px; }
.stats-panel li span,.stats-panel li small { line-height:18px; }
.stats-panel li small { font-size:14px; }

@media (min-width:761px) {
  .site-frame { height:100vh; min-height:700px; overflow:hidden; }
  .site-header { height:100vh; min-height:700px; }
  .page-main { height:100vh; overflow-y:auto; }
  .page-main.home-main { overflow:hidden; padding-top:32px; padding-bottom:22px; }
  .home-main .home-top { padding-bottom:14px; }
  .home-main .hero-grid { padding:27px 0 21px; }
  .home-main .hero-grid h2 { font-size:43px; line-height:1.28; }
  .home-main .hero-grid p { margin-top:12px; font-size:16px; line-height:1.55; }
  .home-main .category-card { min-height:190px; }
  .home-main .home-lower { align-items:start; margin-top:22px; }
  .home-main .stats-panel { height:208px; min-height:208px; }
  .home-main .quote-panel { min-height:82px; }
}

@media (min-width:761px) and (max-height:900px) {
  .page-main.home-main { padding-top:22px; padding-bottom:16px; }
  .home-main .site-nav { margin-top:46px; }
  .home-main .hero-grid { padding:20px 0 16px; }
  .home-main .hero-grid h2 { font-size:39px; }
  .home-main .category-card { min-height:166px; padding-top:19px; padding-bottom:16px; }
  .home-main .home-lower { margin-top:16px; }
  .home-main .stats-panel { height:188px; min-height:188px; padding-top:16px; padding-bottom:12px; }
  .home-main .quote-panel { min-height:66px; padding-top:14px; padding-bottom:14px; }
  .home-main .sample-row { min-height:42px; }
  .home-main .sample-row:nth-of-type(n + 5) { display:none; }
}

@media (max-width:760px) {
  .site-frame,.site-header,.page-main,.page-main.home-main { height:auto; min-height:0; overflow:visible; }
  .card-symbol .ui-icon { width:27px; height:27px; }
  .stats-panel { grid-template-columns:minmax(90px,.8fr) minmax(145px,1.2fr); }
  .stats-panel .stat-summary .stat-number { font-size:45px; }
  .stats-panel ul { font-size:14px; }
  .stats-panel li small { font-size:13px; }
}
