/* Additive, feature-gated scrapbook surfaces; shared masthead/layout stay untouched. */
.community-editor, .community-comments, .community-post-card, [data-community-post-content] {
  --community-paper: #fffaf0;
  --community-edge: #d5c3a6;
  --community-orange: #a5461d;
  --community-ink: #473829;
  color: var(--community-ink);
  min-width: 0;
  overflow-wrap: anywhere;
}
.community-editor { max-width: 980px; margin-inline: auto; }
.community-editor__sheet { min-width: 0; border: 1px solid var(--community-edge); border-top: 4px solid var(--community-orange); padding: clamp(18px, 4vw, 44px); background: linear-gradient(115deg, #fffdf7, var(--community-paper)); box-shadow: 5px 7px 0 #e8ddca; border-radius: 4px 20px 6px 4px; display: grid; gap: 22px; }
.community-editor__sheet > legend { padding: 4px 14px; font: 700 clamp(23px, 4vw, 32px)/1.35 var(--font-editorial); background: #fffaf0; }
.community-editor .form-field { gap: 8px; }
.community-editor input, .community-editor textarea, .community-editor select { max-width: 100%; }
.community-editor textarea { min-height: 300px; background: repeating-linear-gradient(#fffdf8, #fffdf8 31px, #eae1cf 32px); }
.community-editor__location { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding-block: 22px; border-block: 1px dashed var(--community-edge); }
.community-editor__location > div { display: grid; gap: 12px; min-width: 0; }
.community-editor__photos h2 { margin: 0 0 10px; font: 700 25px/1.35 var(--font-editorial); }
.community-editor__photos { min-width: 0; }
.community-editor .cu-list, .community-comments .cu-list { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.community-editor .cu-item-actions button, .community-comments .cu-item-actions button { min-height: 44px; min-width: 44px; }
.community-editor .form-actions { padding-top: 10px; }
.community-editor .form-actions > *, .community-comments button { min-height: 44px; }
.community-editor :focus-visible, .community-comments :focus-visible, .community-post-card :focus-visible { outline: 3px solid #a5461d; outline-offset: 4px; }
.community-post-card { border: 1px solid var(--community-edge); padding: 12px; background: #fffdf7; box-shadow: 3px 5px 0 #e8ddca; border-radius: 3px 10px 4px 3px; height: 100%; }
.community-post-card__photos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; aspect-ratio: 4 / 3; overflow: hidden; background: #f1e7d3; border-radius: 2px; }
.community-post-card__photos .community-photo:first-child { grid-row: span 2; }
.community-post-card__photos .community-photo:only-child { grid-column: 1 / -1; }
.community-post-card__photos .community-photo:nth-child(n+4) { display: none; }
.community-photo { margin: 0; min-width: 0; overflow: hidden; background: #eee3cf; }
.community-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.community-post-card__body { padding: 17px 8px 10px; }
.community-post-card h3 { margin: 0 0 14px; font: 700 clamp(22px, 2vw, 27px)/1.3 var(--font-editorial); }
.community-post-card h3 a { color: inherit; }
.community-post-card__excerpt { line-height: 1.75; font-size: 15px; margin: 14px 0; }
.community-byline { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; font-size: 13px; line-height: 1.5; color: #685541; }
.community-author { display: inline-flex; align-items: center; gap: 9px; min-width: 0; }
.community-author .avatar { flex-shrink: 0; object-fit: cover; }
.community-author a { color: #573621; font-weight: 600; }
.community-location { padding-left: 12px; border-left: 3px solid var(--community-orange); font-size: 14px; line-height: 1.65; margin-block: 16px; }
.community-location--detail { font-size: 18px; margin-block: 24px; }
.community-photo-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; padding: 12px; background: #fffaf0; border: 1px solid var(--community-edge); margin-block: 24px 36px; }
.community-photo-grid .community-photo { aspect-ratio: 4 / 3; }
.community-photo-grid .community-photo:first-child { grid-column: 1 / -1; aspect-ratio: 16 / 9; }
.community-photo-grid .community-photo img { object-fit: contain; }
.community-comments { max-width: 860px; padding-block: 32px; margin-block: 24px; border-top: 1px solid var(--community-edge); }
.community-comments .section-title { max-width: 22ch; margin-bottom: 24px; }
.community-comment-list { list-style: none; margin: 0; padding: 0; }
.community-comment { min-width: 0; padding: 20px 0; border-top: 1px dashed var(--community-edge); scroll-margin-top: 110px; }
.community-comment:target { background: #f7e7c5; outline: 2px solid #a5461d; outline-offset: 5px; }
.community-comment--depth-1, .community-comment--depth-2, .community-comment--depth-3 { border-left: 2px solid #e1c5a2; padding-left: 20px; }
.community-comment--depth-1 { margin-left: 24px; }
.community-comment--depth-2 { margin-left: 48px; }
.community-comment--depth-3 { margin-left: 72px; }
.community-comment__context { margin: 10px 0 6px; color: #845536; font-size: 13px; }
.community-comment__body { white-space: pre-wrap; line-height: 1.8; font-size: 16px; margin: 12px 0; max-width: 72ch; }
.community-comment__body:empty { display: none; }
.community-comment__photos { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; max-width: 620px; }
.community-comment__photos .community-photo { aspect-ratio: 1; border: 4px solid #fffdf7; box-shadow: 0 1px 3px #765c3926; }
.community-comment__actions { display: flex; flex-wrap: wrap; gap: 8px; }
.community-comment__actions button { border: 0; padding: 10px 12px; background: transparent; color: #8c3c1d; font: 600 14px/1.4 var(--font-body); cursor: pointer; text-decoration: underline; text-underline-offset: 4px; }
.community-comment-form { margin-block: 24px; }
.community-comment-form fieldset { min-width: 0; display: grid; gap: 14px; padding: 20px; border: 1px solid var(--community-edge); border-radius: 4px 15px 4px 4px; background: linear-gradient(125deg, #fffaf0, #f7eedc); }
.community-comment-form legend { padding-inline: 8px; font: 700 21px/1.4 var(--font-editorial); }
.community-comments [data-community-comments-status] { margin-block: 14px; }
@media (max-width: 600px) {
  .community-editor__sheet { box-shadow: 2px 4px 0 #e8ddca; gap: 18px; }
  .community-editor__location { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .community-editor .form-actions { align-items: stretch; }
  .community-editor .form-actions > button { flex: 1 1 100%; }
  .community-editor .cu-list, .community-comments .cu-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .community-editor .cu-item, .community-comments .cu-item { padding: 7px; }
  .community-comment--depth-1 { margin-left: 10px; }
  .community-comment--depth-2 { margin-left: 20px; }
  .community-comment--depth-3 { margin-left: 30px; }
  .community-comment--depth-1, .community-comment--depth-2, .community-comment--depth-3 { padding-left: 10px; }
  .community-comment__photos { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .community-comment-form fieldset { padding: 14px; }
  .community-photo-grid { gap: 8px; padding: 8px; }
}
