@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,opsz,wght@0,8..60,400;0,8..60,500;1,8..60,400&family=Inter:wght@400;500&display=swap');

:root {
  --paper: #faf9f5;
  --paper-raised: #ffffff;
  --ink: #1e1c19;
  --ink-soft: #6e6a62;
  --ink-faint: #a9a59a;
  --rule: #e2dfd6;
  --stamp: #395144;
  --stamp-soft: #7c9186;
  --max: 640px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Inter', -apple-system, sans-serif;
  line-height: 1.6;
}

a {
  color: var(--stamp);
  text-decoration: none;
}
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--stamp);
  outline-offset: 2px;
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

/* header, shared across pages */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 3rem;
}
.site-header .name {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
}
.site-header .streak {
  font-size: 13px;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}
.site-header .streak strong {
  color: var(--stamp);
  font-weight: 500;
}

/* archive list */
.entry-list { list-style: none; margin: 0; padding: 0; }

.entry-row {
  display: block;
  padding: 1.5rem 0;
  border-top: 1px solid var(--rule);
}
.entry-row:last-child { border-bottom: 1px solid var(--rule); }

.entry-row a { color: inherit; display: block; }

.entry-meta {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 0.5rem;
}
.entry-meta .no { color: var(--ink-faint); }

.entry-excerpt {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.entry-text { min-width: 0; flex: 1; }

.entry-excerpt p {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 18px;
  line-height: 1.5;
  margin: 0;
  color: var(--ink);
}

.entry-preview {
  font-family: 'Inter', sans-serif;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-soft);
  margin: 6px 0 0;
}

.entry-thumb {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  object-fit: cover;
  border: 1px solid var(--rule);
}

.entry-row:hover .entry-excerpt p { color: var(--stamp); }

/* empty state */
.empty {
  padding: 3rem 0;
  color: var(--ink-soft);
  font-size: 15px;
}

/* single post view */
.back-link {
  display: inline-block;
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 2rem;
}
.back-link:hover { color: var(--stamp); }

.post-meta {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 1.25rem;
}
.post-meta .no { color: var(--ink-faint); }

.post-prompt {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-size: 22px;
  line-height: 1.5;
  color: var(--ink);
  margin: 0 0 1.75rem;
}

.post-image {
  width: 100%;
  height: auto;
  border: 1px solid var(--rule);
  margin-bottom: 1.75rem;
  display: block;
}

.post-body {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 17px;
  line-height: 1.75;
  color: var(--ink);
  white-space: pre-wrap;
}

.post-footer {
  margin-top: 3rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
  font-size: 13px;
  color: var(--ink-soft);
}

.on-this-day {
  margin-top: 0.5rem;
}

.loading, .error-state {
  padding: 3rem 0;
  color: var(--ink-soft);
  font-size: 15px;
}

@media (max-width: 480px) {
  .wrap { padding: 2rem 1.25rem 3rem; }
  .post-prompt { font-size: 20px; }
  .entry-excerpt p { font-size: 17px; }
}
