:root { color-scheme: light; --ink: #222824; --muted: #66736b; --line: #d4ded7; --brand: #247767; --bg: #f3f5f2; --danger: #b32e38; }
.pic-metadata { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 18px; margin-top: 18px; }
.pic-metadata label, .pic-edit label { display: grid; gap: 6px; margin-bottom: 14px; align-content: start; }
#newspicReview input:not([type=checkbox]) { width: 100%; padding: 9px; border: 1px solid var(--line); border-radius: 4px; }
.pic-options { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; margin: 10px 0 22px; }
.pic-options label { display: inline-flex; gap: 8px; align-items: center; }
.pic-workspace { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; border-top: 1px solid var(--line); padding-top: 24px; }
.pic-preview { min-width: 0; }
.pic-preview img { width: 100%; height: auto; aspect-ratio: 3 / 4; display: block; object-fit: contain; background: white; }
.pic-preview nav { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; }
.pic-edit { min-width: 0; }
.pic-order { margin-bottom: 20px; border-bottom: 1px solid var(--line); padding-bottom: 15px; }
.pic-order > div { display: grid; grid-template-columns: minmax(0, 1fr) 38px 38px; gap: 6px; margin-bottom: 6px; }
.pic-select { text-align: left; justify-content: flex-start; overflow-wrap: anywhere; }
.pic-select.selected { border-color: var(--brand); background: #eaf4ef; }
#picSave { margin-top: 16px; }
#picProgressBox { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; padding: 16px 0; }
#picProgress { width: 180px; height: 14px; accent-color: var(--brand); }
@media (max-width: 740px) { .pic-metadata, .pic-workspace { grid-template-columns: minmax(0, 1fr); } }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif; }
button, input, textarea, select { font: inherit; }
button, .review-actions a { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 13px; border: 1px solid var(--line); border-radius: 5px; color: var(--ink); background: #fff; cursor: pointer; text-decoration: none; }
button:disabled { opacity: .48; cursor: not-allowed; }
button.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
button:hover:not(:disabled) { filter: brightness(.95); }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid #bf732d; outline-offset: 3px; }
button svg, label svg { width: 18px; height: 18px; flex: 0 0 18px; }
a { color: var(--brand); }
h1 { font-size: 25px; line-height: 1.5; margin: 0; overflow-wrap: anywhere; }
h2 { font-size: 18px; margin: 0; line-height: 1.5; overflow-wrap: anywhere; }
p { margin: 7px 0; }
[hidden] { display: none !important; }
.review-app { max-width: 1180px; margin: auto; padding: 20px 20px 140px; }
.review-header { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 18px; color: var(--muted); border-bottom: 1px solid var(--line); }
.review-heading { padding: 24px 0; }
.review-heading p { color: var(--muted); }
.review-actions { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
#reviewMessage, #editorMessage { color: var(--danger); padding: 10px; background: #fff1f1; border-left: 3px solid var(--danger); }
.review-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.review-card { background: #fff; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.review-card header { padding: 14px; display: flex; gap: 12px; align-items: baseline; }
.review-card header span { color: var(--brand); white-space: nowrap; font-size: 13px; }
.review-card img { display: block; width: 100%; height: auto; object-fit: contain; background: #eef1ef; }
.card-actions { display: flex; flex-wrap: wrap; gap: 10px; padding: 14px; }
.review-submit { position: fixed; bottom: 0; left: 0; right: 0; display: flex; justify-content: flex-end; align-items: center; gap: 14px; padding: 16px max(20px, calc((100% - 1140px) / 2)); background: #fff; border-top: 1px solid var(--line); z-index: 2; }
#submitStatus { margin-right: auto; color: var(--muted); font-size: 13px; }
dialog { padding: 0; border: 1px solid var(--line); border-radius: 6px; width: min(1260px, calc(100vw - 28px)); max-width: none; max-height: 94dvh; background: #fff; }
dialog::backdrop { background: #15241db0; }
.dialog-heading { display: flex; justify-content: space-between; gap: 14px; align-items: center; padding: 13px 18px; border-bottom: 1px solid var(--line); }
.icon-button { width: 38px; height: 38px; padding: 8px; flex: 0 0 38px; }
.edit-workspace { display: grid; grid-template-columns: minmax(0, 1fr) 290px; max-height: 70dvh; overflow: auto; }
.image-workspace { min-width: 0; background: #e9eeeb; }
.image-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding: 10px; border-bottom: 1px solid var(--line); background: #fff; }
.image-toolbar label { display: flex; gap: 7px; align-items: center; font-size: 13px; }
select { min-width: 0; max-width: 100%; padding: 7px; border: 1px solid var(--line); border-radius: 4px; background: #fff; }
.zoom-label input { width: 100px; }
.zoom-label output { min-width: 38px; }
.canvas-viewport { height: 58dvh; min-height: 300px; overflow: auto; padding: 15px; }
canvas { display: block; max-width: none; touch-action: none; cursor: crosshair; }
.text-controls { padding: 14px; min-width: 0; border-left: 1px solid var(--line); }
fieldset { border: 0; padding: 0 0 18px; margin: 0 0 16px; border-bottom: 1px solid var(--line); min-width: 0; }
legend { font-weight: 700; padding: 0; margin-bottom: 8px; }
.inline-check { display: flex; align-items: center; gap: 8px; font-size: 13px; margin: 7px 0; }
input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--brand); }
textarea { width: 100%; resize: vertical; min-height: 86px; padding: 9px; border: 1px solid var(--line); border-radius: 4px; }
.color-controls { display: flex; gap: 12px; align-items: flex-end; margin: 10px 0; }
.color-controls label { font-size: 12px; }
input[type=color] { display: block; width: 48px; height: 35px; border: 1px solid var(--line); padding: 2px; background: #fff; cursor: pointer; }
.size-label { display: flex; align-items: center; gap: 8px; font-size: 13px; }
input[type=number] { width: 80px; padding: 6px; border: 1px solid var(--line); border-radius: 4px; }
.region-bounds { font-size: 12px; display: block; color: var(--muted); margin-top: 8px; }
.dialog-actions { border-top: 1px solid var(--line); padding: 12px 18px; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
.comparison { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; padding: 15px; overflow: auto; max-height: 70dvh; }
figure { margin: 0; min-width: 0; }
figure img { width: 100%; height: auto; display: block; }
figcaption { padding: 7px 0; font-weight: 600; }
@media (max-width: 740px) {
    .review-app { padding: 14px 12px 180px; }
    h1 { font-size: 21px; }
    .review-grid { grid-template-columns: 1fr; gap: 16px; }
    .review-header { font-size: 12px; }
    .review-submit { flex-wrap: wrap; padding: 12px; gap: 9px; }
    #submitStatus { width: 100%; }
    #approveReview { flex: 1; font-size: 13px; }
    dialog { width: calc(100vw - 12px); max-height: 97dvh; }
    .edit-workspace { grid-template-columns: 1fr; max-height: 74dvh; }
    .canvas-viewport { height: 40dvh; min-height: 230px; }
    .text-controls { border-left: 0; }
    .comparison { gap: 8px; padding: 8px; }
    .dialog-actions { padding: 10px; }
    .dialog-actions button { font-size: 13px; }
}
