/* On Opening — ported from the Claude Design comp (EB Garamond, earthy tones, light) */

body {
  margin: 0;
  background: #faf6ed;
  color: #2a241c;
  -webkit-font-smoothing: antialiased;
  font-family: "EB Garamond", Georgia, serif;
}
a { color: #a9522f; text-decoration: underline; text-decoration-color: #dcb49e; text-underline-offset: 3px; }
a:hover { color: #7c3a20; text-decoration-color: #a9522f; }
::selection { background: #eae0c6; }
input, textarea, button, select { font-family: "EB Garamond", Georgia, serif; }
input:focus, textarea:focus { outline: 1px solid #6b7a5e; outline-offset: 1px; }

.page { min-height: 100vh; display: flex; flex-direction: column; }

/* Header */
header.site { position: relative; text-align: center; padding: clamp(36px, 7vw, 64px) 24px 0; }
.writer-door {
  position: absolute; top: 18px; right: 22px; cursor: pointer;
  font-size: 19px; color: #b9ac92; line-height: 1; padding: 6px;
  background: none; border: none;
}
.writer-door:hover { color: #a9522f; }
.masthead { cursor: pointer; display: inline-block; }
.masthead .byline { font-size: 15px; letter-spacing: 0.32em; text-transform: uppercase; color: #8a7c64; }
.masthead h1 { margin: 6px 0 0; font-size: clamp(42px, 8vw, 64px); font-weight: 500; letter-spacing: 0.01em; line-height: 1.05; }
nav.site {
  display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 28px;
  margin: 22px auto 0; padding: 14px 8px;
  border-top: 1px solid #e4dac6; border-bottom: 1px solid #e4dac6; max-width: 640px;
}
nav.site .nav-item {
  cursor: pointer; font-size: 16px; letter-spacing: 0.18em; text-transform: uppercase;
  color: #5a5140; border-bottom: 1px solid transparent; padding-bottom: 2px;
  text-decoration: none;
}
nav.site .nav-item:hover { color: #a9522f; }
nav.site .nav-item.active { color: #a9522f; border-bottom-color: #c98a6b; }

main { flex: 1; width: 100%; max-width: 680px; margin: 0 auto; padding: clamp(32px, 6vw, 56px) 24px 64px; box-sizing: border-box; }

/* Shared pieces */
.kicker { font-size: 15px; letter-spacing: 0.28em; text-transform: uppercase; font-weight: 500; color: #6b7a5e; margin: 0 0 10px; text-align: center; }
.kicker-tight { margin-bottom: 18px; }
.subtitle { text-align: center; color: #8a7c64; font-size: 16.5px; font-style: italic; margin: 0 0 18px; }
.ornament { text-align: center; color: #b98a2f; font-size: 19px; }
.link-quiet { cursor: pointer; color: #a9522f; text-decoration: underline; text-decoration-color: #dcb49e; text-underline-offset: 3px; }
.link-caps { cursor: pointer; font-size: 15px; letter-spacing: 0.2em; text-transform: uppercase; color: #a9522f; text-decoration: none; }

/* Post lists */
.post-row { padding: 22px 0; border-bottom: 1px solid #ebe2cf; }
.post-row .row-top { display: flex; justify-content: space-between; align-items: baseline; gap: 6px 16px; flex-wrap: wrap; }
.post-row h3 { margin: 0; font-size: clamp(22px, 3.4vw, 26px); font-weight: 500; cursor: pointer; line-height: 1.25; }
.post-row h3:hover { color: #7c3a20; }
.post-row .cat { font-size: 14px; letter-spacing: 0.14em; text-transform: uppercase; color: #6b7a5e; white-space: nowrap; }
.post-row .date { font-size: 14.5px; letter-spacing: 0.1em; color: #8a7c64; margin-top: 5px; }
.post-row .excerpt { margin: 10px 0 0; font-size: 17.5px; line-height: 1.65; color: #4a4234; }

/* Intro (home) */
.intro { font-size: clamp(19px, 2.6vw, 21px); line-height: 1.8; color: #3a3226; }
.intro p { margin: 0 0 1.2em; }
.intro p:last-child { margin: 0; }
.intro .intro-signoff { margin-top: 1.4em; }

/* Archive */
.archive-group { margin-bottom: 40px; }
.archive-group .group-head { display: flex; align-items: baseline; gap: 12px; border-bottom: 1px solid #d9cdb2; padding-bottom: 8px; margin-bottom: 6px; }
.archive-group h3 { margin: 0; font-size: 22px; font-weight: 600; letter-spacing: 0.04em; }
.archive-group .count { font-size: 15px; color: #8a7c64; font-style: italic; }
.archive-row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 11px 0; border-bottom: 1px solid #f0e8d6; }
.archive-row .t { cursor: pointer; font-size: 19px; line-height: 1.35; }
.archive-row .t:hover { color: #7c3a20; }
.archive-row .d { font-size: 14px; color: #8a7c64; white-space: nowrap; }

/* Start here */
.starter { display: flex; align-items: baseline; gap: 14px; margin-bottom: 34px; }
.starter .num { font-size: 18px; color: #b98a2f; font-style: italic; min-width: 24px; }
.starter h3 { margin: 0; font-size: clamp(22px, 3.4vw, 25px); font-weight: 500; cursor: pointer; line-height: 1.3; }
.starter h3:hover { color: #7c3a20; }
.starter .cat { font-size: 14px; letter-spacing: 0.14em; text-transform: uppercase; color: #6b7a5e; margin-top: 4px; }
.starter .note { margin: 8px 0 0; font-size: 17.5px; line-height: 1.6; color: #4a4234; font-style: italic; }

/* Post page */
.post-header { text-align: center; margin-bottom: 40px; }
.post-header h2 { margin: 0; font-size: clamp(30px, 6vw, 42px); font-weight: 500; line-height: 1.2; }
.post-header .sub { margin: 10px 0 0; font-size: clamp(18px, 2.6vw, 21px); font-style: italic; color: #8a7c64; line-height: 1.4; }
.post-header .date { font-size: 15px; letter-spacing: 0.16em; text-transform: uppercase; color: #8a7c64; margin-top: 14px; }
.post-body { font-size: clamp(19px, 2.6vw, 21px); line-height: 1.8; color: #2f2920; display: flow-root; }
.post-body p { margin: 0 0 1.25em; }
.post-body p + p { text-indent: 1.6em; } /* book-style first-line indent */
.dropcap { float: left; font-size: 3.35em; line-height: 0.82; padding: 4px 10px 0 0; color: #a9522f; font-style: italic; }
.verse { white-space: pre-line; margin: 0 0 1.4em; line-height: 1.9; padding-left: clamp(0px, 4vw, 28px); }
blockquote { margin: 0 0 1.25em; padding: 2px 0 2px 22px; border-left: 2px solid #c9bc9c; font-style: italic; color: #4a4234; }
.post-body .break { text-align: center; color: #b98a2f; font-size: 18px; margin: 1.8em 0; }
figure.floated { width: clamp(210px, 46%, 330px); margin: 4px 0 16px 26px; }
figure.floated.right { float: right; }
figure.floated.left { float: left; margin: 4px 26px 16px 0; }
figure.floated img { width: 100%; display: block; }
figure.full { margin: 2em 0; }
figure.full img { width: 100%; display: block; }
.img-placeholder {
  width: 100%; height: 240px; box-sizing: border-box;
  background: #efe7d3; border: 1px solid #ddd2b8;
  display: flex; align-items: center; justify-content: center;
  color: #9a8d72; font-style: italic; font-size: 15.5px; text-align: center; padding: 16px;
}
figcaption { font-size: 15.5px; font-style: italic; color: #8a7c64; margin-top: 8px; line-height: 1.45; }
.post-end { text-align: center; color: #b98a2f; font-size: 19px; margin: 52px 0 0; }
.back-link { margin-top: 40px; }

/* Writer-only tools (visible after the ✎ door) */
.writer-tools { margin-top: 26px; text-align: center; font-size: 15.5px; font-style: italic; color: #8a7c64; }
.writer-tools .tool { cursor: pointer; color: #a9522f; margin: 0 8px; text-decoration: underline; text-decoration-color: #dcb49e; text-underline-offset: 3px; }
.writer-tools .tool:hover { color: #7c3a20; }
.comment .del { cursor: pointer; font-size: 14px; font-style: italic; color: #a9522f; }
.comment .del:hover { color: #7c3a20; }

/* Start Here curation (writer only) */
.curate { margin-top: 54px; border-top: 1px solid #e4dac6; padding-top: 30px; }
.curate h3 { font-size: 14px; letter-spacing: 0.26em; text-transform: uppercase; font-weight: 500; color: #6b7a5e; margin: 0 0 12px; text-align: center; }
.curate .hint { font-size: 15.5px; font-style: italic; color: #8a7c64; text-align: center; margin: 0 0 18px; line-height: 1.5; }
.curate-row { display: flex; align-items: baseline; gap: 10px; padding: 9px 0; border-bottom: 1px solid #f0e8d6; flex-wrap: wrap; }
.curate-row .t { flex: 1 1 180px; font-size: 18px; }
.curate-row .rank { width: 54px; text-align: center; }
.curate-row .note { flex: 2 1 220px; }
.curate .actions { display: flex; justify-content: center; margin-top: 20px; }
.curate .compose-status { margin-top: 12px; }

/* Comments */
.margins { margin-top: 44px; border-top: 1px solid #e4dac6; padding-top: 32px; }
.margins h3 { font-size: 14px; letter-spacing: 0.26em; text-transform: uppercase; font-weight: 500; color: #6b7a5e; margin: 0 0 22px; }
.comment { margin-bottom: 22px; }
.comment .head { display: flex; align-items: baseline; gap: 10px; }
.comment .name { font-size: 17px; font-weight: 600; font-style: italic; }
.comment .when { font-size: 14px; color: #8a7c64; }
.comment p { margin: 5px 0 0; font-size: 17px; line-height: 1.6; color: #4a4234; }
.no-comments { font-size: 16.5px; font-style: italic; color: #8a7c64; margin: 0 0 22px; }
.comment-form { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }

/* Inputs & buttons */
.field {
  border: 1px solid #d9cdb2; background: #fffdf7; border-radius: 2px;
  padding: 10px 12px; font-size: 16px; color: #2a241c;
}
textarea.field { resize: vertical; }
.field-name { max-width: 280px; }
.btn {
  cursor: pointer; border: 1px solid #a9522f; background: transparent; color: #a9522f;
  padding: 9px 22px; border-radius: 2px; font-size: 15px; letter-spacing: 0.14em; text-transform: uppercase;
}
.btn:hover { background: #a9522f; color: #faf6ed; }
.btn.green { border-color: #6b7a5e; color: #556349; }
.btn.green:hover { background: #6b7a5e; color: #faf6ed; }
.btn.ghost { border: none; background: transparent; color: #8a7c64; padding: 9px 10px; font-size: 15px; font-style: italic; letter-spacing: 0; text-transform: none; }
.btn.ghost:hover { background: transparent; color: #7c3a20; }
.btn[disabled] { opacity: 0.55; cursor: default; }
.btn[disabled]:hover { background: transparent; color: #a9522f; }

/* Compose */
.compose { display: flex; flex-direction: column; gap: 22px; }
.compose .title-field {
  border: none; border-bottom: 1px solid #d9cdb2; background: transparent;
  padding: 6px 2px 10px; font-size: clamp(26px, 4vw, 32px); font-weight: 500; color: #2a241c; text-align: center;
}
.compose .subtitle-field {
  border: none; border-bottom: 1px solid #d9cdb2; background: transparent;
  padding: 4px 2px 8px; font-size: clamp(17px, 2.6vw, 20px); font-style: italic; color: #4a4234; text-align: center;
}
.compose .filed { display: flex; justify-content: center; align-items: baseline; gap: 12px 14px; flex-wrap: wrap; }
.compose input[type="date"] { border: 1px solid #d9cdb2; background: #fffdf7; border-radius: 2px; padding: 6px 10px; font-size: 16px; color: #2a241c; }
.compose .label { font-size: 14px; letter-spacing: 0.18em; text-transform: uppercase; color: #6b7a5e; }
.compose select { border: 1px solid #d9cdb2; background: #fffdf7; border-radius: 2px; padding: 7px 10px; font-size: 16px; color: #2a241c; }
.compose textarea { border: 1px solid #d9cdb2; background: #fffdf7; border-radius: 2px; padding: 16px 18px; font-size: 19px; line-height: 1.8; color: #2f2920; }
.compose .img-box { display: flex; flex-direction: column; gap: 10px; }
.compose input[type="file"] { font-size: 15px; color: #8a7c64; }
.compose .preview img { max-width: min(320px, 100%); border: 1px solid #e4dac6; display: block; margin-bottom: 6px; }
.compose .remove { cursor: pointer; font-size: 15px; font-style: italic; color: #a9522f; }
.compose .actions { display: flex; justify-content: center; margin-top: 8px; }
.compose .btn { padding: 11px 34px; font-size: 16px; letter-spacing: 0.16em; }
.compose-status { text-align: center; font-style: italic; color: #a9522f; font-size: 16.5px; }
.compose-status.ok { color: #556349; }

/* Published confirmation */
.published { text-align: center; padding: 40px 0; }
.published h2 { font-size: clamp(26px, 4vw, 34px); font-weight: 500; margin: 18px 0 10px; }
.published p { font-size: 18px; line-height: 1.7; color: #4a4234; font-style: italic; }

/* Footer */
footer.site { border-top: 1px solid #e4dac6; background: #f4eddc; padding: 44px 24px 36px; text-align: center; }
footer.site .inner { max-width: 480px; margin: 0 auto; }
footer.site .head { font-size: 14px; letter-spacing: 0.26em; text-transform: uppercase; color: #6b7a5e; }
footer.site .blurb { font-size: 17px; line-height: 1.6; color: #4a4234; margin: 12px 0 20px; }
.subscribe-row { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.subscribe-row input { width: min(260px, 70vw); padding: 10px 14px; }
.subscribed-msg { font-size: 17px; font-style: italic; color: #556349; margin: 0; }
footer.site .fine { font-size: 14px; color: #8a7c64; margin-top: 30px; }

/* Password modal */
.pass-overlay {
  position: fixed; inset: 0; background: rgba(42, 36, 28, 0.45);
  display: flex; align-items: center; justify-content: center; padding: 24px; z-index: 50;
}
.pass-card {
  background: #faf6ed; border: 1px solid #e4dac6; border-radius: 2px;
  padding: 36px 34px 30px; max-width: 340px; width: 100%; text-align: center;
  box-shadow: 0 12px 40px rgba(42, 36, 28, 0.25);
}
.pass-card .head { font-size: 14px; letter-spacing: 0.26em; text-transform: uppercase; color: #6b7a5e; }
.pass-card .sub { font-size: 16.5px; font-style: italic; color: #8a7c64; margin: 10px 0 20px; }
.pass-card input { width: 100%; box-sizing: border-box; text-align: center; }
.pass-card .error { font-size: 15px; font-style: italic; color: #a9522f; margin: 10px 0 0; }
.pass-card .actions { display: flex; justify-content: center; gap: 14px; margin-top: 20px; }
.hidden { display: none !important; }
