@font-face {
  font-display: swap;
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 400 500;
  src: url("fonts/CormorantGaramond-Variable.ttf") format("truetype");
}

@font-face {
  font-display: swap;
  font-family: "Manrope";
  font-style: normal;
  font-weight: 400 500;
  src: url("fonts/Manrope-Variable.ttf") format("truetype");
}

:root {
  color-scheme: light;
  --paper: #fbf7ef;
  --paper-deep: #f1e8dc;
  --paper-soft: #f7f0e7;
  --ink: #2f2927;
  --muted: #766b66;
  --wine: #6f2944;
  --wine-deep: #552033;
  --wine-soft: #ead8dd;
  --line: #d8cabe;
  --gold: #a77c4d;
  --success: #49644f;
  --white: #fffdf9;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: #e9e2d9;
  color: var(--ink);
  font-family: Manrope, Arial, sans-serif;
  font-weight: 400;
  margin: 0;
}
a { color: inherit; }
button, input, textarea { font: inherit; }
strong, b { font-weight: 500; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

.site-shell {
  background: radial-gradient(circle at 5% 2%, rgb(234 216 221 / 70%), transparent 25rem), var(--paper);
  margin: 16px auto;
  max-width: 1180px;
  min-height: calc(100vh - 32px);
  overflow: hidden;
}
.site-header {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: 24px;
  grid-template-columns: auto 1fr;
  padding: 18px clamp(18px, 4vw, 50px);
}
.brand {
  color: var(--wine);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 24px;
  font-weight: 500;
  letter-spacing: .08em;
  text-decoration: none;
  text-transform: uppercase;
}
.site-nav { align-items: center; display: flex; flex-wrap: wrap; gap: clamp(14px, 3vw, 32px); justify-content: flex-end; }
.site-nav a { border-bottom: 1px solid transparent; color: var(--muted); padding: 8px 0; text-decoration: none; }
.site-nav a:hover { border-bottom-color: var(--wine); color: var(--wine); }
.site-nav .random-link { background: var(--wine); border: 1px solid var(--wine); color: var(--white); padding: 10px 15px; }
.site-nav .random-link:hover { background: var(--wine-deep); }

.page { min-height: 660px; padding: clamp(34px, 7vw, 82px) clamp(18px, 6vw, 76px) 72px; }
.eyebrow { color: var(--wine); font-size: 13px; letter-spacing: .14em; margin: 0 0 14px; text-transform: uppercase; }
h1, h2, h3 { font-family: "Cormorant Garamond", Georgia, serif; font-weight: 400; }
.hero { display: grid; gap: clamp(32px, 7vw, 86px); grid-template-columns: minmax(0, 1.55fr) minmax(240px, .7fr); }
.hero h1 { font-size: clamp(50px, 8vw, 88px); letter-spacing: -.035em; line-height: .92; margin: 0; }
.hero-copy { color: var(--muted); font-family: "Cormorant Garamond", Georgia, serif; font-size: clamp(23px, 3vw, 30px); line-height: 1.25; margin: 26px 0 0; max-width: 680px; }
.hero-side, .article-aside { border-top: 1px solid var(--line); padding-top: 20px; }
.hero-side strong { display: block; font-family: "Cormorant Garamond", Georgia, serif; font-size: 27px; font-weight: 500; margin-bottom: 10px; }
.hero-side p { color: var(--muted); line-height: 1.65; margin: 0 0 18px; }
.text-link, .back-link { color: var(--wine); text-underline-offset: 4px; }

.journal-section { margin-top: clamp(58px, 9vw, 104px); }
.section-heading { align-items: end; border-bottom: 1px solid var(--line); display: flex; gap: 20px; justify-content: space-between; padding-bottom: 17px; }
.section-heading h2 { font-size: clamp(34px, 5vw, 52px); line-height: 1; margin: 0; }
.topic-filter { display: flex; flex-wrap: wrap; gap: 10px; margin: 24px 0 20px; }
.topic-filter a { border: 1px solid var(--line); padding: 8px 12px; text-decoration: none; }
.topic-filter a:hover { background: var(--wine-soft); border-color: var(--wine); }

.search-form { margin: 20px 0 30px; max-width: 520px; }
.search-form label { display: block; margin-bottom: 7px; }
.search-form div { display: flex; }
.search-form input { background: var(--white); border: 1px solid var(--line); min-width: 0; padding: 11px 12px; width: 100%; }
.search-form button, .primary-button { background: var(--wine); border: 1px solid var(--wine); color: var(--white); cursor: pointer; padding: 11px 18px; }
.search-form button:hover, .primary-button:hover { background: var(--wine-deep); }

.entry-grid { display: grid; gap: 28px 34px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.entry-card { border-top: 1px solid var(--line); display: flex; flex-direction: column; min-height: 260px; min-width: 0; overflow-wrap: anywhere; padding-top: 18px; }
.entry-card:first-child { background: var(--paper-soft); border-left: 3px solid var(--gold); border-top: 0; grid-column: 1 / -1; min-height: 0; padding: clamp(22px, 4vw, 38px); }
.entry-meta { color: var(--muted); display: flex; flex-wrap: wrap; font-size: 13px; gap: 8px 15px; letter-spacing: .04em; text-transform: uppercase; }
.entry-meta a { color: var(--wine); }
.entry-card h2 { font-size: clamp(30px, 4vw, 44px); line-height: 1.05; margin: 15px 0 13px; }
.entry-card h2 a { text-decoration: none; }
.entry-card h2 a:hover { color: var(--wine); }
.entry-card p { color: var(--muted); line-height: 1.7; }
.card-footer { align-items: center; display: flex; gap: 16px; justify-content: space-between; margin-top: auto; }
.card-footer .text-link { font-weight: 500; }
.card-footer span { color: var(--muted); font-size: 13px; }
.empty-state { border-top: 1px solid var(--line); color: var(--muted); grid-column: 1 / -1; padding: 28px 0; }

.page-header { border-bottom: 1px solid var(--line); margin-bottom: 34px; padding-bottom: 26px; }
.page-header h1 { font-size: clamp(46px, 7vw, 76px); line-height: .98; margin: 0; }
.page-header p { color: var(--muted); line-height: 1.7; max-width: 720px; }
.topic-grid { display: grid; gap: 18px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.topic-card { background: var(--paper-soft); border: 1px solid var(--line); display: flex; flex-direction: column; min-height: 180px; padding: 22px; text-decoration: none; }
.topic-card:hover { border-color: var(--wine); }
.topic-card strong { font-family: "Cormorant Garamond", Georgia, serif; font-size: 30px; font-weight: 500; margin-bottom: 18px; }
.topic-card span { color: var(--muted); line-height: 1.5; }
.topic-card small { color: var(--wine); margin-top: auto; padding-top: 18px; }

.year-block { border-top: 1px solid var(--line); padding: 24px 0 40px; }
.year-block > h2 { color: var(--wine); font-size: 52px; margin: 0 0 22px; }
.year-block > h3 { color: var(--muted); font-size: 23px; }
.archive-list { list-style: none; margin: 0 0 28px; padding: 0; }
.archive-list li { align-items: baseline; border-bottom: 1px solid var(--line); display: grid; gap: 18px; grid-template-columns: 130px 1fr auto; padding: 15px 0; }
.archive-list time, .archive-list span { color: var(--muted); }
.archive-list a { font-family: "Cormorant Garamond", Georgia, serif; font-size: 21px; overflow-wrap: anywhere; text-decoration: none; }
.archive-list a:hover { color: var(--wine); }

.preview-notice, .success-message { background: #e7efe8; border-left: 3px solid var(--success); padding: 14px 18px; }
.article-layout { display: grid; gap: clamp(36px, 7vw, 90px); grid-template-columns: minmax(0, 760px) minmax(180px, 1fr); min-width: 0; }
.article-layout > * { min-width: 0; }
.article-header h1 { font-size: clamp(48px, 8vw, 82px); letter-spacing: -.025em; line-height: .94; margin: 18px 0 34px; }
.article-header h1, .article-body, .afterword, .comment { overflow-wrap: anywhere; }
.article-body { font-family: "Cormorant Garamond", Georgia, serif; font-size: clamp(22px, 3vw, 28px); line-height: 1.58; min-width: 0; }
.article-body p { margin: 0 0 1.15em; }
.article-body a { overflow-wrap: anywhere; }
.article-body pre { max-width: 100%; overflow-wrap: anywhere; white-space: pre-wrap; }
.article-body table { display: block; max-width: 100%; overflow-x: auto; }
.article-body img, .entry-media img, .entry-media video { height: auto; max-width: 100%; }
.article-aside { padding-top: 18px; }
.article-aside strong { display: block; font-family: "Cormorant Garamond", Georgia, serif; font-size: 25px; font-weight: 500; margin-bottom: 16px; }
.article-aside a { border-bottom: 1px solid var(--line); display: block; padding: 12px 0; text-decoration: none; }
.article-aside a:hover { color: var(--wine); }
.afterword { background: var(--paper-soft); border-left: 3px solid var(--gold); margin-top: 48px; padding: 24px; }
.afterword h2 { font-size: 32px; margin-top: 0; }
.afterword > div { font-family: "Cormorant Garamond", Georgia, serif; font-size: clamp(20px, 2.5vw, 24px); line-height: 1.58; }
.entry-media { margin: 32px 0; }
.entry-media figcaption { color: var(--muted); font-size: 14px; line-height: 1.5; margin-top: 8px; }
.media-missing { background: var(--paper-deep); color: var(--muted); margin: 32px 0; padding: 24px; }

.discussion { border-top: 1px solid var(--line); margin-top: 62px; padding-top: 32px; }
.discussion > h2 { font-size: clamp(34px, 5vw, 50px); margin: 0 0 14px; }
.read-note { background: var(--paper-deep); border-left: 3px solid var(--gold); color: var(--muted); line-height: 1.6; padding: 15px 18px; }
.comment-list { list-style: none; margin: 0; padding: 0; }
.comment { border-bottom: 1px solid var(--line); display: grid; gap: 15px; grid-template-columns: 48px 1fr; padding: 22px 0; }
.comment > * { min-width: 0; }
.comment-avatar { align-items: center; background: var(--wine-soft); border-radius: 50%; color: var(--wine-deep); display: flex; height: 44px; justify-content: center; width: 44px; }
.comment-head { align-items: baseline; display: flex; flex-wrap: wrap; gap: 6px 12px; justify-content: space-between; }
.comment-head time { color: var(--muted); font-size: 13px; }
.comment p { line-height: 1.65; }
.comment-form-wrap { background: var(--paper-soft); margin-top: 36px; padding: clamp(20px, 4vw, 34px); }
.comment-form-wrap h3 { font-size: 34px; margin: 0 0 10px; }
.comment-form-wrap > p { color: var(--muted); line-height: 1.6; }
.field { display: block; margin-bottom: 18px; }
.field span { display: block; margin-bottom: 7px; }
.field input, .field textarea { background: var(--white); border: 1px solid var(--line); color: var(--ink); padding: 12px; width: 100%; }
.field textarea { min-height: 130px; resize: vertical; }
.errorlist { color: #8a1f3d; }
.honeypot { height: 1px; left: -10000px; overflow: hidden; position: absolute; width: 1px; }

.narrow-page { max-width: 920px; }
.results-heading { border-bottom: 1px solid var(--line); font-size: 32px; padding-bottom: 16px; }
.site-footer { align-items: center; border-top: 1px solid var(--line); color: var(--muted); display: flex; gap: 16px; justify-content: space-between; padding: 24px clamp(18px, 4vw, 50px); }
.site-footer a { color: var(--wine); overflow-wrap: anywhere; text-underline-offset: 3px; }
.site-footer a:hover { color: var(--wine-deep); }

.feedback-page { max-width: 832px; }
.feedback-header { margin-top: 28px; }
.feedback-form { max-width: 680px; }
.feedback-note, .field-help { color: var(--muted); font-size: 14px; line-height: 1.55; }
.feedback-note { background: var(--paper-soft); border-left: 3px solid var(--gold); margin: 0 0 24px; padding: 12px 15px; }
.feedback-form .field { margin-bottom: 20px; }
.feedback-form label, .feedback-captcha > p { display: block; margin: 0 0 7px; }
.feedback-form input, .feedback-form textarea { background: var(--white); border: 1px solid var(--line); color: var(--ink); padding: 12px; width: 100%; }
.feedback-form textarea { min-height: 180px; resize: vertical; }
.field-error { color: #8a1f3d; line-height: 1.5; margin: 7px 0 0; }
.feedback-captcha altcha-widget { display: block; max-width: 360px; width: 100%; }
.feedback-service-error { background: var(--wine-soft); border-left: 3px solid var(--wine); line-height: 1.55; margin: 20px 0; padding: 14px 18px; }
.feedback-submit { min-height: 44px; }
.feedback-submit[disabled] { cursor: wait; opacity: .75; }
.feedback-progress { color: var(--muted); margin: 10px 0 0; }
.feedback-success { max-width: 680px; padding-top: 50px; }
.feedback-success h1 { font-size: clamp(46px, 7vw, 76px); line-height: .98; margin: 0 0 20px; }
.feedback-success > p { color: var(--muted); line-height: 1.7; }
.feedback-link-button { display: inline-block; text-decoration: none; }

@media (max-width: 820px) {
  .hero, .article-layout { grid-template-columns: 1fr; }
  .article-aside { display: none; }
  .topic-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .site-shell { margin: 0; min-height: 100vh; }
  .site-header { gap: 12px; grid-template-columns: 1fr; }
  .site-nav { justify-content: flex-start; }
  .entry-grid, .topic-grid { grid-template-columns: 1fr; }
  .entry-card:first-child { grid-column: auto; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .archive-list li { grid-template-columns: 88px 1fr; }
  .archive-list span { grid-column: 2; }
  .site-footer { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 380px) {
  .brand { font-size: 22px; }
  .page { padding-inline: 18px; }
  .hero h1 { font-size: 48px; }
  .comment { grid-template-columns: 40px 1fr; }
  .comment-avatar { height: 38px; width: 38px; }
}
