@import url('https://fonts.googleapis.com/css2?family=Crimson+Text:ital,wght@0,400;0,600;1,400&family=Playfair+Display:wght@400;600&display=swap');

:root {
  --bg: #faf9f6;
  --panel: #ffffff;
  --text: #2c2c2c;
  --muted: #6b6b6b;
  --accent: #8b7355;
  --chip: #f5f3f0;
  --chip-active: #e8e5e0;
  --border: #e0ddd8;
  --link: #7a6b5a;
  --shadow: rgba(0, 0, 0, 0.04);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Crimson Text', Georgia, 'Times New Roman', serif;
  line-height: 1.8;
  font-size: 18px;
}

.container {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

.site-header {
  padding: 48px 0 32px;
  border-bottom: none;
  background: transparent;
}

.site-title {
  margin: 0;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 36px;
  font-weight: 400;
  letter-spacing: 0.5px;
  color: var(--text);
}

.site-subtitle {
  margin: 8px 0 0;
  color: var(--muted);
  font-style: italic;
}

.site-footer {
  margin-top: 80px;
  border-top: 1px solid var(--border);
  padding: 32px 0;
  color: var(--muted);
  font-size: 15px;
  text-align: center;
}

.site-footer a {
  color: var(--link);
  text-decoration: underline;
  text-decoration-color: transparent;
  transition: text-decoration-color 0.2s ease;
}

.site-footer a:hover {
  text-decoration-color: var(--link);
}

.controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px 20px;
  margin: 32px 0 20px;
}

.control-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.control-label {
  color: var(--muted);
  white-space: nowrap;
  font-size: 16px;
}

.control-input {
  width: 100%;
  padding: 8px 12px;
  border-radius: 4px;
  border: 1px solid var(--border);
  background: var(--panel);
  color: var(--text);
  outline: none;
  font-family: 'Crimson Text', Georgia, serif;
  font-size: 16px;
  transition: border-color 0.2s ease;
}

.control-input:focus {
  border-color: var(--accent);
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 12px 0 0;
}

.chip {
  border: 1px solid var(--border);
  background: var(--chip);
  color: var(--text);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 15px;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
  font-family: 'Crimson Text', Georgia, serif;
}

.chip:hover {
  background: var(--chip-active);
  border-color: var(--accent);
}

.chip[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
}

.btn-link {
  margin-top: 12px;
  background: none;
  border: none;
  color: var(--link);
  cursor: pointer;
  padding: 0;
  font-family: 'Crimson Text', Georgia, serif;
  font-size: 15px;
  text-decoration: underline;
  text-decoration-color: transparent;
  transition: text-decoration-color 0.2s ease;
}

.btn-link:hover {
  text-decoration-color: var(--link);
}

.list-meta {
  margin: 24px 0 16px;
  color: var(--muted);
  font-size: 15px;
  font-style: italic;
}

.entries-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 720px) {
  .entries-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.entry-card {
  border: none;
  background: transparent;
  padding: 0;
  border-radius: 0;
  transition: opacity 0.2s ease;
  border-bottom: 1px solid var(--border);
  padding-bottom: 20px;
  text-decoration: none;
}

.entry-card:hover {
  opacity: 0.7;
  text-decoration: none;
}

.entry-title {
  margin: 0 0 8px;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 22px;
  font-weight: 400;
  line-height: 1.4;
}

.entry-tagline {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 15px;
  font-style: italic;
  line-height: 1.6;
}

.entry-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  color: var(--muted);
  font-size: 14px;
  margin-top: 4px;
}

.entry-tags {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.tag {
  display: inline-block;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  font-family: 'Crimson Text', Georgia, serif;
  font-size: 13px;
  padding: 2px 0;
  margin: 0 8px 0 0;
  border-radius: 0;
  font-style: italic;
  white-space: nowrap;
  line-height: 1.6;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.tag:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.entry-meta .tag,
.related-entry-meta .tag {
  border-bottom: none;
  padding: 0;
  margin: 0 6px 0 0;
}

.entry-meta .tag:hover,
.related-entry-meta .tag:hover {
  border-bottom-color: transparent;
}

a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: currentColor;
  transition: opacity 0.2s ease;
}

a:hover {
  opacity: 0.7;
}

.article {
  max-width: 680px;
  margin: 20px auto;
}

.article h1,
.article-title {
  margin: 0;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 42px;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 12px;
}

.article .meta {
  color: var(--muted);
  margin: 0 0 24px;
  font-size: 16px;
}

.article .content {
  padding-top: 0;
  padding-bottom: 60px;
  font-size: 20px;
  line-height: 1.9;
}

.article .content p {
  margin: 0 0 1.5em;
}

.article .content section {
  margin: 0;
}

.poem-with-footnotes {
  position: relative;
  margin-bottom: 2em;
}

.poem-content {
  max-width: 100%;
}

.poem-content p {
  margin: 0 0 1.5em;
  line-height: 1.9;
  position: relative;
}

.footnote-reference {
  padding-right: 220px;
}

.footnote-inline {
  position: absolute;
  right: 0;
  top: 0;
  width: 200px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
  font-style: italic;
  padding-left: 1em;
}

@media (max-width: 1000px) {
  .footnote-reference {
    padding-right: 0;
  }

  .footnote-inline {
    position: static;
    width: 100%;
    margin-top: 0.8em;
    margin-bottom: 0;
    padding-left: 0;
    padding-top: 0;
    border-top: none;
    display: block;
  }
}

.indent-1 {
  display: inline;
  margin-left: 1.5em; /* 3 spaces equivalent */
}

.indent-2 {
  display: inline;
  margin-left: 3em; /* 6 spaces equivalent */
}

.indent-3 {
  display: inline;
  margin-left: 4.5em; /* 9 spaces equivalent */
}

.chat-messages {
  margin-top: 1em;
}

.chat-message {
  margin-bottom: 1.5em;
}

.chat-date {
  display: block;
  font-size: 13px;
  color: var(--muted);
  font-style: italic;
  margin-bottom: 0.3em;
}

.chat-text {
  margin: 0;
  line-height: 1.8;
}

.want-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.want-item {
  margin-bottom: 1.5em;
  padding-bottom: 1em;
  border-bottom: 1px solid var(--border);
}

.want-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.want-meta {
  display: flex;
  gap: 1em;
  margin-bottom: 0.5em;
  font-size: 13px;
  color: var(--muted);
  font-style: italic;
}

.want-added,
.want-completed {
  display: inline-block;
}

.want-text {
  display: inline-block;
  line-height: 1.8;
  font-size: 18px;
}

.want-item.completed .want-text {
  color: #6b8e6b;
  opacity: 0.8;
  position: relative;
}

.want-item.completed .want-text::after {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  width: 100%;
  height: 1px;
  background-color: #6b8e6b;
  opacity: 0.6;
}

.want-comment {
  display: block;
  margin-top: 0.5em;
  font-size: 14px;
  color: var(--muted);
  font-style: italic;
  line-height: 1.6;
}

.footnote {
  margin-top: 2em;
  padding-top: 1em;
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--muted);
  font-style: italic;
  line-height: 1.6;
}

sup a {
  color: var(--link);
  text-decoration: none;
  font-size: 0.7em;
  vertical-align: super;
}

sup a:hover {
  text-decoration: underline;
}

.footnote sup {
  font-size: 0.8em;
  margin-right: 0.3em;
}

.section-spacer {
  text-align: center;
  color: var(--muted);
  font-size: 18px;
  margin: 2.5em 0;
  letter-spacing: 0.3em;
  opacity: 0.5;
}

.related-entries {
  margin-top: 60px;
  padding-top: 40px;
  border-top: 1px solid var(--border);
}

.related-header {
  margin-bottom: 24px;
}

.related-header h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 28px;
  font-weight: 400;
  margin: 0;
  color: var(--text);
}

.related-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.related-entry {
  padding: 0;
}

.related-entry-title {
  margin: 0 0 8px;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 1.4;
}

.related-entry-tagline {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 15px;
  font-style: italic;
  line-height: 1.6;
}

.related-entry-title a {
  color: var(--text);
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.related-entry-title a:hover {
  opacity: 0.7;
}

.related-entry-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  color: var(--muted);
  font-size: 14px;
}

.backlink {
  display: inline-block;
  margin: 0 0 24px;
  color: var(--link);
  font-size: 16px;
  text-decoration: underline;
  text-decoration-color: transparent;
  transition: text-decoration-color 0.2s ease;
}

.backlink:hover {
  text-decoration-color: var(--link);
}

code, pre {
  background: var(--chip);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-family: 'Courier New', monospace;
}

pre {
  padding: 16px;
  overflow: auto;
}

blockquote {
  margin: 24px 0;
  padding-left: 24px;
  border-left: 2px solid var(--accent);
  color: var(--muted);
  font-style: italic;
}


