:root {
  color-scheme: light;
  --ink: #26342e;
  --muted: #5e6b63;
  --paper: #f8f8f3;
  --surface: #fffefa;
  --line: #d9dfd5;
  --accent: #29483a;
  --tint: #e7ede5;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: "Segoe UI", Arial, sans-serif; font-size: 16px; line-height: 1.55; }
a { color: inherit; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid #a96939; outline-offset: 3px; }
.skip-link { position: absolute; top: -4rem; left: 1rem; z-index: 2; background: var(--ink); color: white; padding: .6rem 1rem; }
.skip-link:focus { top: 1rem; }
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.header-inner { max-width: 1180px; height: 74px; margin: auto; padding: 0 30px; display: flex; justify-content: space-between; align-items: center; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font-family: Georgia, serif; font-size: 1.27rem; font-weight: bold; letter-spacing: -.03em; text-decoration: none; }
.wordmark-icon { display: grid; place-items: center; width: 32px; height: 32px; background: var(--accent); color: white; border-radius: 50%; font: 1.3rem/1 Georgia, serif; }
.private-label, .text-button { color: var(--muted); font-size: .83rem; }
.text-button { border: 0; background: none; padding: 8px 0; text-decoration: underline; text-underline-offset: 4px; }
.page { min-height: calc(100vh - 148px); max-width: 1180px; margin: 0 auto; padding: 72px 30px 110px; }
.site-footer { border-top: 1px solid var(--line); color: var(--muted); font-size: .76rem; }
.site-footer div { max-width: 1180px; margin: auto; padding: 23px 30px; }
h1, h2, h3, p { margin-top: 0; }
h1, h2 { font-family: Georgia, serif; font-weight: 400; letter-spacing: -.04em; line-height: 1.13; }
h1 { font-size: clamp(2.5rem, 5vw, 4rem); margin-bottom: 16px; }
h2 { font-size: 1.7rem; }
.eyebrow { color: #526c5d; font-size: .68rem; font-weight: 700; letter-spacing: .15em; margin-bottom: 17px; }
.muted, .field-help, .help-text { color: var(--muted); }
.button { display: inline-flex; align-items: center; justify-content: center; gap: .7rem; min-height: 46px; padding: 10px 19px; border: 1px solid transparent; border-radius: 4px; font-size: .88rem; font-weight: 600; text-decoration: none; }
.primary { background: var(--accent); color: white; }
.primary:hover { background: #1d392c; }
.button:disabled { cursor: wait; opacity: .7; }
.create-error { color: #71371f; max-width: 220px; margin: 8px 0 0; font-size: .8rem; }
.secondary { background: var(--surface); border-color: #b9c6ba; color: var(--ink); }
.secondary:hover { background: var(--tint); }
.page-heading, .section-heading, .editor-heading, .edit-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; }
.page-heading { align-items: flex-end; margin-bottom: 74px; }
.page-heading p:last-child { margin-bottom: 0; }
.section-heading { align-items: baseline; border-bottom: 1px solid var(--line); padding-bottom: 16px; }
.section-heading h2 { font-size: 1.4rem; margin: 0; }
.section-heading span { font-size: .78rem; }
.rental-list { list-style: none; padding: 0; margin: 0; }
.rental-row { display: flex; align-items: center; gap: 19px; min-height: 100px; padding: 18px 8px; border-bottom: 1px solid var(--line); text-decoration: none; }
.rental-row:hover { background: #eff3ec; }
.row-symbol, .empty-symbol { flex: none; display: grid; place-items: center; color: var(--accent); background: var(--tint); border-radius: 50%; }
.row-symbol { width: 47px; height: 47px; font: 1.45rem Georgia, serif; }
.row-content { display: grid; gap: 3px; min-width: 0; flex: 1; }
.row-content strong { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: .98rem; font-weight: 600; }
.row-content small { color: var(--muted); font-size: .78rem; }
.row-arrow { color: var(--muted); font-size: 1.2rem; }
.empty-state { padding: 70px 20px; text-align: center; border-bottom: 1px solid var(--line); }
.empty-symbol { width: 56px; height: 56px; margin: 0 auto 21px; font: 1.65rem Georgia, serif; }
.empty-state h3 { font: 1.35rem Georgia, serif; margin-bottom: 10px; }
.empty-state p { max-width: 360px; margin: auto; color: var(--muted); font-size: .9rem; }
.login-layout { display: grid; grid-template-columns: 1fr minmax(320px, 430px); gap: 12%; align-items: center; padding: 40px 0 20px; }
.login-intro p:last-child { max-width: 390px; color: var(--muted); font-size: 1.05rem; }
.login-panel { padding: 38px; border: 1px solid var(--line); background: var(--surface); }
.login-panel h2 { margin-bottom: 8px; }
.login-panel .muted { font-size: .9rem; margin-bottom: 25px; }
.login-form { display: grid; gap: 8px; }
.login-form label, .notes-panel label { font-size: .87rem; font-weight: 600; }
.login-form input { width: 100%; min-height: 48px; padding: 10px 12px; margin-bottom: 12px; border: 1px solid #b9c6ba; border-radius: 3px; background: white; }
.login-form .button { margin-top: 4px; }
.help-text { font-size: .77rem; margin: 22px 0 0; }
.alert, .save-error { background: #faede6; border-left: 3px solid #a14d2a; color: #71371f; padding: 12px 14px; font-size: .85rem; }
.edit-top { align-items: center; border-bottom: 1px solid var(--line); padding-bottom: 22px; margin-bottom: 58px; }
.back-link { color: var(--muted); font-size: .85rem; text-decoration: none; }
.back-link:hover { text-decoration: underline; }
.editor { max-width: 900px; margin: auto; }
.editor-heading { margin-bottom: 29px; }
.editor-heading h1 { font-size: clamp(2.5rem, 4vw, 3.4rem); }
.editor-heading p:last-child { margin-bottom: 0; }
.save-area { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 12px; padding-top: 20px; }
.save-indicator { color: #486655; font-size: .8rem; white-space: nowrap; }
.notes-panel { padding: 27px; background: var(--surface); border: 1px solid var(--line); }
.photo-panel { margin-top: 20px; padding: 27px; background: var(--surface); border: 1px solid var(--line); }
.photo-panel h2 { margin-bottom: 10px; }
.photo-panel label { display: block; font-size: .87rem; font-weight: 600; margin-bottom: 8px; }
.photo-panel input { max-width: 100%; }
.photo-list { list-style: none; margin: 0; padding: 0; }
.photo-list li { display: flex; gap: 16px; align-items: flex-start; border-top: 1px solid var(--line); padding: 16px 0; }
.photo-list img { width: 92px; height: 72px; object-fit: cover; background: var(--tint); }
.approval .photo-list img { object-fit: contain; }
.photo-info { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.photo-info strong, .photo-info small, .photo-info code { display: block; }
.photo-info small, .photo-info code { color: var(--muted); font-size: .75rem; margin-top: 4px; }
.photo-buttons { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.photo-buttons .button { min-height: 38px; padding: 7px 10px; font-size: .78rem; }
.field-help { font-size: .82rem; margin: 5px 0 17px; }
textarea { display: block; width: 100%; min-height: 310px; resize: vertical; padding: 16px; border: 1px solid #b9c6ba; border-radius: 3px; background: #fff; color: var(--ink); line-height: 1.65; }
textarea:disabled { background: #f1f3ee; }
.save-error { margin: 15px 0 0; }
.conflict-panel { margin-top: 20px; padding: 27px; border: 1px solid #c8a984; background: #fffaf3; }
.conflict-panel h2 { margin-bottom: 10px; }
.conflict-panel h3 { font-size: .85rem; margin-bottom: 8px; }
.conflict-panel p { font-size: .9rem; }
.conflict-panel pre { white-space: pre-wrap; overflow-wrap: anywhere; font: inherit; background: white; padding: 16px; border: 1px solid #ddd3c5; }
.conflict-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.privacy-note { color: var(--muted); font-size: .78rem; margin-top: 20px; }
.message-page { max-width: 550px; }
@media (max-width: 700px) {
  .header-inner { height: 64px; padding: 0 20px; }
  .page { padding: 48px 20px 80px; }
  .site-footer div { padding: 20px; }
  .page-heading, .editor-heading { flex-direction: column; gap: 18px; }
  .page-heading { align-items: stretch; margin-bottom: 52px; }
  .page-heading form, .page-heading .button { width: 100%; }
  .login-layout { grid-template-columns: 1fr; gap: 35px; padding-top: 0; }
  .login-panel { padding: 26px; }
  .edit-top { margin-bottom: 42px; }
  .save-area { padding-top: 0; justify-content: flex-start; }
  .notes-panel, .photo-panel, .conflict-panel { padding: 20px; }
}
.draft-copy { white-space: pre-wrap; overflow-wrap: anywhere; font: inherit; }
.review-intro { color: var(--muted); font-size: .9rem; margin-bottom: 20px; }
.editor:has(.ad-grid) { max-width: 1080px; }
.page:has(.ad-grid) { padding-top: 28px; }
.edit-top:has(+ .editor .ad-grid) { margin-bottom: 22px; padding-bottom: 14px; }
.editor:has(.ad-grid) .editor-heading { margin-bottom: 16px; }
.editor:has(.ad-grid) .editor-heading h1 { font-size: clamp(2rem, 3vw, 2.7rem); margin-bottom: 7px; }
.ad-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.draft-panel, .details-panel, .generation-panel { margin-bottom: 20px; padding: 27px; border: 1px solid var(--line); background: var(--surface); }
.draft-heading { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px; }
.draft-heading h2 { margin-bottom: 18px; }
.draft-status { color: var(--muted); font-size: .78rem; }
.draft-panel label, .detail-field > label:first-child, .generation-panel label { display: block; margin-bottom: 6px; font-size: .85rem; font-weight: 600; }
.draft-panel input, .detail-field input[data-detail-value], .generation-panel select { width: 100%; min-height: 44px; padding: 9px 12px; border: 1px solid #b9c6ba; border-radius: 3px; background: white; color: var(--ink); }
.draft-panel input { margin-bottom: 18px; }
.draft-panel textarea { min-height: 210px; }
.generation-panel { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; }
.generation-panel > div:first-child { flex: 1 1 240px; }
.generation-panel .field-help { flex-basis: 100%; margin: 0; }
.generation-panel .field-help:empty { display: none; }
.details-panel h2 { margin-bottom: 10px; }
.detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 24px; }
.detail-field { min-width: 0; padding: 17px 0; border-top: 1px solid var(--line); }
.detail-field .field-help { margin: 5px 0; }
.detail-evidence, .detail-issue, .review-warning { margin: 6px 0; font-size: .8rem; overflow-wrap: anywhere; }
.detail-evidence { color: var(--muted); }
.detail-issue, .review-warning { color: #71371f; }
.detail-evidence:empty, .detail-issue:empty { display: none; }
.confirm-label { display: inline-flex; align-items: center; gap: 7px; margin-top: 8px; font-size: .82rem; }
.confirm-label input { width: 17px; height: 17px; }
.notes-panel { margin-top: 20px; }
.notes-panel h2 { margin-bottom: 15px; }
[data-after-extraction].details-panel { margin-top: 20px; }
[data-optional-details] summary { cursor: pointer; padding: 12px 0; font-weight: 600; }
.reextract { margin-top: 15px; }
.draft-panel [data-approve-url] { margin-top: 16px; }
.detail-field [data-omit-detail] { display: block; }
.approval-form > label { display: block; font-weight: 600; }
.approval-form > input { width: 100%; min-height: 44px; padding: 9px 12px; border: 1px solid #b9c6ba; }
.approval-form fieldset { margin: 16px 0; padding: 12px; border: 1px solid var(--line); }
.approval-form fieldset label { display: block; margin: 8px 0; }
.approval-fields { display: grid; grid-template-columns: minmax(120px, 1fr) 3fr; gap: 8px; overflow-wrap: anywhere; }
.approval-fields dt { font-weight: 600; }
.approval-fields dd { margin: 0; }
dialog { width: min(500px, calc(100% - 32px)); padding: 28px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
dialog::backdrop { background: rgba(26, 38, 30, .55); }
@media (max-width: 700px) {
  .ad-grid { grid-template-columns: 1fr; gap: 0; }
  .draft-panel, .details-panel, .generation-panel { padding: 20px; }
  .detail-grid { grid-template-columns: 1fr; }
  .generation-panel .button { width: 100%; }
}
