.notes-main {max-width:850px;}
.notes-heading {display:flex;align-items:center;justify-content:space-between;gap:18px;}
.notes-heading h1 {font-size:40px;margin-bottom:10px;}
.notes-heading .action {width:auto;margin:0;flex-shrink:0;}
.notes-heading .description {margin:0 0 14px;}
.note-filters {display:flex;flex-wrap:wrap;gap:8px;margin:22px 0;}
.note-filters button {padding:9px 15px;border:1px solid var(--line);border-radius:999px;background:#fff8ef;color:var(--brown);font-size:13px;}
.note-filters [aria-pressed=true] {background:#edd5bf;border-color:#d6b89d;}
.notes-empty {padding:30px;border:1px solid var(--line);border-radius:20px;background:#f6e7d7;color:var(--muted);line-height:1.8;}
.notes-timeline {list-style:none;margin:0;padding:0 0 0 27px;position:relative;}
.notes-timeline:before {content:"";position:absolute;width:1px;top:26px;bottom:26px;left:8px;background:#ddc3aa;}
.notes-timeline>li {position:relative;margin-bottom:14px;}
.notes-timeline>li:before {content:"";position:absolute;left:-24px;top:26px;width:9px;height:9px;border-radius:50%;background:#ac7959;border:2px solid var(--cream);}
.note-card {display:flex;align-items:center;justify-content:space-between;gap:18px;width:100%;padding:19px 21px;text-align:left;border:1px solid var(--line);border-radius:19px;background:#fff8ef;color:var(--brown);font:inherit;}
.note-card:hover {border-color:#c9a98b;background:#fffaf5;}
.note-card-body {min-width:0;flex:1;padding:0;border:0;background:none;color:inherit;font:inherit;text-align:left;cursor:pointer;}
.note-photo-strip {display:flex;gap:8px;flex:0 0 auto;}
.note-thumb[hidden] {display:none;}
.note-card-body:focus-visible,.note-thumb:focus-visible {outline:3px solid #bd8060;outline-offset:4px;}
.note-card h2 {font:normal 21px/1.4 Georgia,serif;margin:7px 0;overflow-wrap:anywhere;}
.note-date {font-size:12px;line-height:1.6;color:var(--muted);margin:0;}
.note-preview {font-size:14px;line-height:1.7;margin:8px 0;overflow-wrap:anywhere;white-space:pre-wrap;}
.note-meta {display:flex;flex-wrap:wrap;gap:6px;align-items:center;}
.note-category,.note-tag {font-size:11px;padding:4px 9px;background:#f2ddc9;color:#815a45;border-radius:999px;overflow-wrap:anywhere;}
.note-tag {background:#f6eadf;}
.note-thumb {width:72px;height:72px;flex:0 0 72px;position:relative;padding:0;border:0;border-radius:12px;background:#f2ddc9;cursor:pointer;}
.note-thumb img {display:block;width:72px;height:72px;border-radius:12px;object-fit:cover;}
.note-photo-count {position:absolute;bottom:4px;right:4px;background:#604638df;color:white;font-size:10px;padding:3px 5px;border-radius:6px;}
#noteEditor,#noteDetails,#noteDeleteConfirm {width:calc(100% - 32px);max-width:640px;max-height:90vh;overflow:auto;padding:28px;border:1px solid var(--line);border-radius:22px;background:var(--cream);color:var(--brown);}
#noteDeleteConfirm {max-width:440px;}
#noteEditor::backdrop,#noteDetails::backdrop,#noteDeleteConfirm::backdrop {background:#39271d55;}
#noteEditor h2,#noteDetails h2,#noteDeleteConfirm h2 {font:normal 28px/1.4 Georgia,serif;margin:0 0 15px;overflow-wrap:anywhere;}
#noteForm label {margin-top:16px;}
#noteText {width:100%;padding:14px;border:1px solid #d9c6b3;border-radius:12px;background:#fffaf3;color:var(--brown);font:inherit;line-height:1.7;resize:vertical;}
#noteText:focus-visible {outline:3px solid #bd8060;outline-offset:3px;}
.note-hint {font-size:12px;line-height:1.7;color:var(--muted);}
.note-error {font-size:13px;line-height:1.7;color:#954f39;}
.note-error:empty {display:none;}
.note-draft-photos {display:flex;flex-wrap:wrap;gap:12px;}
.note-draft-photos>div {width:100px;}
.note-draft-photos img {width:100px;height:100px;object-fit:cover;border-radius:12px;}
.note-draft-photos button {font-size:11px;}
.note-editor-actions {display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin-top:20px;}
.note-editor-actions .action {width:auto;flex:1;min-width:150px;margin:0;}
.note-full-text {white-space:pre-wrap;overflow-wrap:anywhere;font-size:15px;line-height:1.85;}
.note-summary {padding:14px;background:#f3e2d2;border-radius:12px;font-size:14px;line-height:1.7;white-space:pre-wrap;}
#noteGallery {margin:20px 0;}
#detailPhoto {display:block;width:100%;max-height:420px;object-fit:contain;border-radius:15px;background:#f2e4d6;}
.note-gallery-controls {display:flex;justify-content:space-between;align-items:center;gap:10px;margin-top:10px;font-size:12px;}
button:disabled {cursor:default;}
@media(max-width:520px){.notes-heading{align-items:flex-start;}.notes-heading h1{font-size:34px;}.notes-heading .action{padding:12px;min-height:44px;font-size:13px;}.note-card{padding:16px;gap:12px;}.note-preview{font-size:13px;}.note-filters button{padding:8px 12px;}#noteEditor,#noteDetails,#noteDeleteConfirm{padding:22px;}.note-thumb,.note-thumb img{width:72px;height:72px;}}

.note-pets-field {margin:18px 0 0;padding:14px;border:1px solid var(--line);border-radius:12px;min-width:0;}
.note-pets-field legend {font-size:14px;color:var(--brown);padding:0 5px;}
.note-pets-field .note-hint {margin:0 0 10px;}
.note-pet-options {display:flex;flex-wrap:wrap;gap:8px;}
#noteForm .note-pet-choice {display:flex;align-items:center;gap:8px;margin:0;padding:9px 12px;border-radius:12px;background:#f3e2d2;cursor:pointer;max-width:100%;min-height:44px;font-size:13px;}
.note-pet-choice span {overflow-wrap:anywhere;min-width:0;}
.note-pet-choice input {width:17px;height:17px;min-height:17px;padding:0;flex:0 0 17px;margin:0;accent-color:#a66f55;}
.note-pet {font-size:11px;padding:4px 9px;background:#f6eadf;color:#815a45;border-radius:999px;overflow-wrap:anywhere;}
