:root {
  --paper:#fbfaf7; --white:#fffefa; --ink:#252a28; --muted:#686d66; --line:#e2e2d9;
  --soft:#f0f0e9; --rust:#934d32; --rust-soft:#f6eae1; --green:#52634e; --sidebar:246px;
}
* {box-sizing:border-box}
html {scroll-behavior:auto; scrollbar-gutter:stable}
body {margin:0; background:var(--paper); color:var(--ink); font:15px/1.55 -apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif}
button,input,select {font:inherit; color:inherit}
button,a,input,select {-webkit-tap-highlight-color:transparent; touch-action:manipulation}
button {cursor:pointer; min-height:44px; background:transparent; border:1px solid var(--line); border-radius:7px; padding:8px 14px}
button:hover {background:var(--soft)}
a {color:inherit}
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible,summary:focus-visible {outline:3px solid var(--rust); outline-offset:3px}
button:disabled {opacity:.55; cursor:wait}
[hidden] {display:none!important}
.muted {color:var(--muted)}
.eyebrow {font-size:11px; font-weight:700; letter-spacing:1.6px; color:var(--rust); margin:0 0 9px}
.skip-link {position:fixed; z-index:100; top:-70px; left:16px; background:var(--ink); color:white; padding:12px 20px}
.skip-link:focus {top:10px}
.sidebar {width:var(--sidebar); position:fixed; inset:0 auto 0 0; border-right:1px solid var(--line); background:#f2f1ea; display:flex; flex-direction:column; padding:34px 22px 20px; z-index:30}
.brand {display:flex; align-items:center; gap:11px; font-weight:650; font-size:16px; margin-bottom:44px; white-space:nowrap}
.brand-mark {display:inline-grid; place-items:center; background:var(--ink); color:var(--paper); font:italic 30px Georgia,serif; width:43px; height:43px; border-radius:11px; padding-bottom:5px; flex-shrink:0}
.brand>div>span {display:block; font-size:8px; letter-spacing:1.8px; color:var(--muted); margin-top:4px}
.nav-item {display:flex; align-items:center; min-height:48px; gap:13px; padding:10px 13px; border-radius:7px; text-decoration:none; color:#62685e; font-size:14px; margin-bottom:5px}
.nav-item>span:first-child {font-size:23px; line-height:1; width:22px}
.nav-item:hover {background:#eaeae2; color:var(--ink)}
.nav-item.active {color:var(--rust); background:#eae5d9; font-weight:650}
.nav-divider {border-top:1px solid var(--line); margin:22px 10px}
.nav-section-label {margin:0 13px 10px; font-size:10px; font-weight:650; letter-spacing:1.2px; text-transform:uppercase; color:var(--muted)}
.sidebar {overflow-y:auto; overscroll-behavior:contain}
.sidebar>.brand,.sidebar>nav,.sidebar>.account {flex-shrink:0}
.external {margin-left:auto; font-size:15px}
.sidebar-note {margin-top:auto; padding:26px 14px 25px}
.tiny-rule {width:26px; border-top:2px solid #a9ae9f; display:block}
.sidebar-note p {font:italic 22px/1.4 Georgia,serif; color:#646c5e}
.sidebar-note>.muted {font-size:11px}
.account {border-top:1px solid var(--line); padding:20px 0 0; display:flex; align-items:center; gap:10px; font-size:11px; min-width:0}
.account strong {font-size:12px; font-weight:600; display:block}
.account>div {min-width:0}
.account>div>span {display:block; overflow:hidden; text-overflow:ellipsis; max-width:130px; color:var(--muted)}
.account-dot {width:9px; height:9px; background:var(--green); border-radius:50%; flex-shrink:0}
.account button {border:0; margin-left:auto; padding:0; width:44px; flex-shrink:0; font-size:20px}
.main {margin-left:var(--sidebar); padding:30px 5.4vw 90px; max-width:1550px}
.preview-banner {display:flex; justify-content:space-between; gap:15px; font-size:11px; color:#6e6357; border-bottom:1px solid var(--line); padding:0 0 16px; margin-bottom:37px}
.preview-banner>span:first-child {font-weight:650; display:flex; align-items:center; gap:8px}
.preview-banner i {background:#a27047; width:6px; height:6px; border-radius:50%}
.page-header {display:flex; align-items:end; justify-content:space-between; gap:20px; margin-bottom:28px}
.page-header h1 {font:normal 45px/1.1 Georgia,'Times New Roman',serif; letter-spacing:-1.3px; margin:0 0 12px}
.page-header p {color:var(--muted); margin:0; font-size:14px}
.page-header .eyebrow {font-size:11px; color:var(--rust); margin-bottom:9px}
.page-index {font-family:Georgia,serif; color:#858b7c; font-size:18px; padding-bottom:3px}
.controls {position:sticky; top:0; z-index:10; background:var(--paper); padding:14px 0 12px; border-bottom:1px solid var(--line); margin-bottom:27px}
.search-box {display:flex; align-items:center; gap:12px; border:1px solid #d7d9cf; border-radius:8px; background:var(--white); padding:0 14px}
.search-box>span {font-size:23px; color:#858b7c; flex-shrink:0}
.search-box input {border:0; width:100%; min-width:0; height:48px; outline:none; background:transparent; font-size:14px}
.search-box:focus-within {outline:2px solid var(--rust); outline-offset:2px}
.search-box input:focus-visible {outline:0}
.search-box>.search-hint {font-size:10px; color:#777b72; white-space:nowrap; border:1px solid var(--line); border-radius:4px; padding:2px 5px}
.filter-row {display:flex; align-items:end; flex-wrap:wrap; gap:10px; margin-top:13px}
.field {display:flex; flex-direction:column; gap:4px; min-width:110px; flex:1}
.field label {font-size:10px; font-weight:650; color:#656c60; letter-spacing:.7px; text-transform:uppercase}
.field select,.field input {width:100%; height:44px; border:1px solid var(--line); border-radius:6px; padding:8px 10px; background:var(--white); font-size:12px; min-width:0}
.field.date-field {max-width:160px}
.field.basis-field {max-width:150px}
.order-button {font-size:12px; white-space:nowrap; background:var(--white); min-width:127px}
.controls:not(.filters-open) .advanced-field {display:none}
.mobile-filter-toggle {display:block; font-size:12px; background:var(--white); padding:7px 12px}
.filter-foot {display:flex; justify-content:space-between; gap:12px; align-items:center; margin-top:12px}
.result-count {font-size:12px; color:var(--muted)}
.text-button {border:0; text-decoration:underline; text-underline-offset:3px; color:var(--rust); padding:3px 8px; font-size:12px; min-height:44px}
.basis-note {font-size:11px; color:var(--muted); line-height:1.55; margin:9px 0 0; max-width:780px}
.date-help {font-size:11px; color:var(--muted); margin:-18px 0 12px}
.date-help summary {cursor:pointer; display:list-item; padding:10px 0; min-height:44px; width:fit-content; text-decoration:underline; text-underline-offset:3px}
.date-help[open] {padding-bottom:5px}
.active-filters {display:flex; flex-wrap:wrap; gap:7px; margin:0 0 18px}
.filter-chip {min-width:0; max-width:100%; min-height:44px; border-color:#d8d7cb; background:var(--soft); font-size:12px; overflow-wrap:anywhere; text-align:left}
.filter-chip:hover {background:var(--rust-soft); border-color:#cbb5a0}
.timeline {position:relative}
.timeline::before {content:''; position:absolute; left:8px; top:12px; bottom:25px; width:1px; background:#d3d7cb}
.day-group {position:relative; margin-bottom:34px}
.day-heading {display:flex; gap:11px; align-items:center; margin:0 0 9px; font-size:15px; letter-spacing:-.1px}
.day-heading>span {font:normal 11px/1.4 -apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif; color:var(--muted); letter-spacing:0}
.day-heading::before {content:''; width:8px; height:8px; border-radius:50%; background:var(--green); margin-left:4px; box-shadow:0 0 0 5px var(--paper); z-index:1; flex-shrink:0}
.day-list {border-left:1px solid #d3d7cb; margin-left:8px; padding:4px 0 2px 30px}
.timeline-entry {display:grid; grid-template-columns:123px minmax(0,1fr); position:relative; padding:19px 0; border-bottom:1px solid var(--line); gap:10px; min-width:0}
.timeline-entry:last-child {border-bottom:0}
.timeline-entry::before {content:''; width:5px; height:5px; position:absolute; left:-33px; top:28px; border-radius:50%; background:#a6ae9a; border:2px solid var(--paper); box-sizing:content-box}
.time-block {font-size:11px; color:var(--muted); padding-top:4px; font-variant-numeric:tabular-nums}
.time-block time {display:block; font-size:11px}
.saved-day {display:block; font-size:10px; color:var(--rust); margin-top:3px}
.late-badge {font-size:9px; border:1px solid #dec9b9; padding:2px 6px; border-radius:3px; color:var(--rust); display:inline-block; margin-top:6px; letter-spacing:.2px}
.entry-main {min-width:0}
.entry-title {font:600 18px/1.35 -apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif; text-decoration:none; display:inline-flex; align-items:center; min-height:44px; letter-spacing:-.25px; margin:-7px 0 -1px; padding:6px 0}
.entry-title:hover {color:var(--rust); text-decoration:underline; text-underline-offset:4px}
.entry-preview {font-size:13px; color:var(--muted); margin:5px 0 12px; line-height:1.65; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; overflow-wrap:anywhere}
.chips {display:flex; gap:7px; align-items:center; flex-wrap:wrap}
.author-chip {color:#53604d; background:#edf0e6; font-size:10px; padding:3px 8px; border-radius:4px}
.subject-chip {font-size:10px; color:#6f655a; border:1px solid #e2ded4; border-radius:4px; padding:5px 8px; min-height:44px; display:inline-flex; align-items:center; text-decoration:none}
.subject-chip:hover {background:var(--rust-soft); border-color:#cbb5a0}
.auth-view {min-height:100vh; display:grid; place-items:center; padding:25px; background:radial-gradient(ellipse at 50% 30%,#edeee3,transparent 60%)}
.auth-card {max-width:460px; text-align:center; padding:44px 32px; background:var(--paper); border:1px solid var(--line); border-radius:14px}
.auth-card .brand-mark {margin-bottom:30px}
.auth-card h1 {font:42px Georgia,serif; letter-spacing:-1px; margin:8px 0 16px}
.auth-card .muted {font-size:15px; margin-bottom:28px}
.auth-card #auth-status {font-size:13px; color:var(--muted); margin:15px 0; overflow-wrap:anywhere}
.primary {background:var(--ink); color:var(--white); border-color:var(--ink); font-weight:550; padding:11px 24px}
.primary:hover {background:#3f4a3b}
.auth-card .primary {width:100%}
#auth-actions {display:grid; gap:10px}
.preview-link {display:block; font-size:12px; color:var(--rust); margin-top:15px; min-height:44px; padding:12px 0}
.auth-foot {border-top:1px solid var(--line); padding-top:22px; margin-top:22px; font-size:10px; color:var(--muted)}
.empty-state {padding:65px 25px; text-align:center; background:#f5f4ee; border:1px dashed #d8dbcf; border-radius:8px}
.empty-state .state-symbol {font:38px Georgia,serif; color:#919780}
.empty-state h2 {font:26px Georgia,serif; margin:12px 0}
.empty-state p {font-size:13px; color:var(--muted); max-width:480px; margin:0 auto 22px}
.mobile-bar,#menu-close {display:none}
.back-link {display:inline-flex; align-items:center; gap:9px; min-height:44px; font-size:12px; color:var(--muted); text-decoration:none; margin-bottom:25px}
.back-link:hover {color:var(--rust)}
.reading {max-width:830px; margin:0 auto}
.reading h1 {font:40px/1.17 Georgia,serif; letter-spacing:-.8px; overflow-wrap:anywhere; margin:12px 0 22px}
.reading .detail-chips {margin-bottom:24px}
.provenance {display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; padding:19px 0; border-top:1px solid var(--line); border-bottom:1px solid var(--line); margin-bottom:38px}
.provenance dt {font-size:10px; font-weight:650; letter-spacing:.7px; text-transform:uppercase; color:var(--muted); margin-bottom:7px}
.provenance dd {margin:0; font-size:12px; overflow-wrap:anywhere}
.provenance small {display:block; font-size:10px; color:var(--muted); margin-top:4px}
.entry-body {font-size:16px; line-height:1.85; overflow-wrap:anywhere; min-width:0}
.entry-body p {margin:0 0 20px}
.entry-body h1,.entry-body h2,.entry-body h3,.entry-body h4,.entry-body h5,.entry-body h6 {font-family:Georgia,serif; font-weight:normal; letter-spacing:-.4px; line-height:1.3; margin:35px 0 16px}
.entry-body h1 {font-size:32px}
.entry-body h2 {font-size:28px}
.entry-body h3 {font-size:23px}
.entry-body ul,.entry-body ol {padding-left:24px}
.entry-body li {padding-left:5px; margin-bottom:6px}
.entry-body blockquote {margin:26px 0; border-left:3px solid #b5bdab; background:#f0f1e9; padding:16px 22px; color:#53604c}
.entry-body blockquote p:last-child {margin-bottom:0}
.entry-body a {color:var(--rust); text-underline-offset:3px}
.entry-body pre {font:12px/1.7 ui-monospace,SFMono-Regular,monospace; background:#eff0e8; border:1px solid var(--line); border-radius:6px; padding:18px; max-width:100%; overflow:auto; white-space:pre}
.entry-body code {font-size:.85em; background:#eff0e8; padding:3px 5px; border-radius:3px; overflow-wrap:anywhere}
.entry-body pre code {padding:0; background:transparent; overflow-wrap:normal}
.table-wrap {overflow-x:auto; width:100%; margin:24px 0; border:1px solid var(--line); border-radius:5px}
.entry-body table {border-collapse:collapse; min-width:500px; width:100%; font-size:13px; text-align:left}
.entry-body th,.entry-body td {padding:12px 15px; border-bottom:1px solid var(--line); vertical-align:top}
.entry-body th {background:#eff0e8; font-weight:600}
.entry-body hr {border:0; border-top:1px solid var(--line); margin:35px 0}
.plain-text {white-space:pre-wrap}
.detail-footer {border-top:1px solid var(--line); margin-top:45px; padding-top:20px; color:var(--muted); font-size:11px; display:flex; justify-content:space-between; gap:15px; align-items:center}
.detail-footer button {font-size:12px}
.subjects-grid {display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:15px}
.subject-card {border:1px solid var(--line); border-radius:8px; padding:24px; text-decoration:none; background:var(--white); min-width:0}
.subject-card:hover {border-color:#b6bda9; background:#f8f8f0}
.subject-card>span {color:var(--rust); font-size:11px}
.subject-card h2 {font:26px Georgia,serif; margin:9px 0 12px; overflow-wrap:anywhere}
.subject-card p {font-size:12px; color:var(--muted); margin:0}
.section-note {color:var(--muted); font-size:12px; margin:20px 0}
.drawer-overlay {display:none}
.spinner {width:22px; height:22px; display:inline-block; border:2px solid #d7dbcd; border-top-color:var(--rust); border-radius:50%; animation:spin .8s linear infinite}
@keyframes spin {to {transform:rotate(360deg)}}
@media(min-width:1500px) {
  .main {padding-left:85px; padding-right:85px}
  .page-header {margin-top:10px}
}
@media(max-width:1100px) {
  :root {--sidebar:218px}
  .sidebar {padding:27px 16px 18px}
  .main {padding:27px 4vw 70px}
  .timeline-entry {grid-template-columns:110px minmax(0,1fr)}
  .field {min-width:120px}
  .page-header h1 {font-size:40px}
  .search-hint {display:none}
}
@media(max-width:760px) {
  html {scrollbar-gutter:auto}
  .mobile-bar {position:sticky; top:0; display:flex; align-items:center; height:62px; gap:10px; background:var(--paper); border-bottom:1px solid var(--line); padding:0 15px; z-index:20; font-size:14px; font-weight:600}
  .mobile-bar button {width:44px; border:0; padding:0; font-size:21px}
  .mobile-label {margin-left:auto; font-size:8px; color:var(--muted); letter-spacing:1.2px}
  .sidebar {transform:translateX(-100%); width:275px; padding:24px 20px}
  .sidebar.open {transform:none}
  .brand {margin-bottom:36px}
  #menu-close {display:block; margin-left:auto; border:0; width:44px; padding:0; font-size:25px}
  .drawer-overlay:not([hidden]) {display:block; position:fixed; inset:0; background:#252a2860; border:0; border-radius:0; z-index:29}
  .main {margin-left:0; padding:22px 22px 65px; max-width:none}
  .preview-banner {margin-bottom:29px; flex-direction:column; gap:5px; padding-bottom:15px; font-size:10px}
  .preview-banner>span:last-child {padding-left:14px}
  .page-header {margin-bottom:20px}
  .page-header h1 {font-size:37px}
  .page-header p {font-size:12px; max-width:250px}
  .page-header .eyebrow {font-size:10px}
  .page-index {display:none}
  .controls {top:62px; padding-top:10px; margin-bottom:24px}
  .controls:not(.filters-open) .advanced-field {display:none}
  .mobile-filter-toggle {display:block; font-size:11px; background:var(--white); padding:7px 10px}
  .filter-foot {gap:6px}
  .filter-foot .result-count {font-size:10px}
  .filter-foot .text-button {font-size:11px}
  .filter-row {gap:8px}
  .field {min-width:calc(50% - 8px); flex:1}
  .field.basis-field,.field.date-field {max-width:none}
  .field select,.field input {font-size:12px}
  .order-button {flex:1; min-width:calc(50% - 8px)}
  .filter-foot {margin-top:5px}
  .basis-note {font-size:10px}
  .day-heading {font-size:14px; flex-wrap:wrap; gap:8px}
  .day-heading>span {font-size:10px}
  .day-list {padding-left:20px}
  .timeline-entry {grid-template-columns:1fr; gap:6px; padding:19px 0}
  .timeline-entry::before {left:-23px; top:28px}
  .time-block {display:flex; gap:9px; align-items:center; padding:0}
  .late-badge {margin-top:0}
  .entry-title {font-size:17px; line-height:1.4; margin-top:0}
  .entry-preview {font-size:12px; margin-top:4px}
  .day-group {margin-bottom:28px}
  .subject-chip {font-size:10px}
  .reading h1 {font-size:33px}
  .provenance {grid-template-columns:1fr; gap:14px; margin-bottom:28px}
  .provenance>div {display:grid; grid-template-columns:90px minmax(0,1fr); gap:7px}
  .provenance dt {padding-top:2px}
  .entry-body {font-size:15px; line-height:1.8}
  .entry-body h2 {font-size:25px}
  .subjects-grid {grid-template-columns:1fr}
  .back-link {margin-bottom:18px}
  .detail-footer {align-items:flex-start; flex-direction:column}
  .empty-state {padding:40px 20px}
}
@media(prefers-reduced-motion:reduce) {
  * {animation:none!important; transition:none!important}
}

/* Copy entry text (14 Nov 2026) */
.entry-actions {display:flex; flex-wrap:wrap; align-items:center; gap:12px 12px; margin:0 0 30px}
.entry-actions button {border-radius:999px; border:1.5px solid var(--ink-950,#252a28); background:var(--paper-050,#fffefa); color:var(--ink); font-weight:600; font-size:13.5px; padding:8px 18px; box-shadow:0 3px 0 var(--ink-950,#252a28); transition:transform 160ms ease-out,box-shadow 160ms ease-out}
.entry-actions button:hover {background:var(--paper-100,#f0f0e9)}
.entry-actions button:active {transform:translateY(3px); box-shadow:0 0 0 var(--ink-950,#252a28)}
.entry-actions button.copied,.entry-actions button.copied:hover {background:var(--ink-950,#252a28); color:var(--paper-050,#fffefa)}
.copy-status {font:500 12px/1.4 var(--mono,ui-monospace,monospace); color:var(--muted)}
.copy-status:empty {display:none}
.manual-copy {margin:-12px 0 30px}
.manual-copy p {margin:0 0 8px; font-size:13px; color:var(--ink)}
.manual-copy textarea {display:block; box-sizing:border-box; width:100%; min-height:180px; font:12.5px/1.6 var(--mono,ui-monospace,monospace); color:var(--ink); background:var(--paper-050,#fffefa); border:2px solid var(--ink-950,#252a28); border-radius:12px; padding:12px; resize:vertical}
@media(max-width:760px) {.entry-actions {margin-bottom:24px}}
