:root { --page:#eef4f0; --surface:#fbfdfb; --surface2:#f3f8f4; --green:#28785c; --green2:#dceee3; --ink:#1b3027; --muted:#63776b; --line:#d6e4da; --danger:#a64b42; --shadow:0 10px 30px rgba(31,73,49,.06); }
* { box-sizing:border-box; }
[hidden] { display:none !important; }
body { margin:0; background:var(--page); color:var(--ink); font:15px/1.45 -apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif; }
button,input,select,textarea { font:inherit; }
button { cursor:pointer; }
.topbar { min-height:76px; padding:16px 30px; display:flex; align-items:center; justify-content:space-between; gap:18px; background:var(--surface); border-bottom:1px solid var(--line); }
.brand,.top-actions { display:flex; align-items:center; gap:14px; }
.brand { font-size:18px; font-weight:800; white-space:nowrap; }
.brand-mark { width:34px; height:34px; display:grid; place-items:center; border-radius:11px; background:var(--green); color:#fff; font-size:23px; }
.brand-divider { height:23px; width:1px; background:var(--line); }
.brand-sub { color:var(--muted); font-size:15px; font-weight:600; }
.local-label { color:var(--muted); font-size:13px; }
.button { border:1px solid var(--line); border-radius:12px; padding:10px 15px; background:var(--surface); color:var(--ink); font-weight:700; white-space:nowrap; }
.button:hover,.tool:hover { background:var(--green2); }
.button:active,.tool:active { transform:scale(.98); }
.button.primary { background:var(--green); border-color:var(--green); color:#fff; }
.button.primary:hover { background:#20694f; }
.workspace { max-width:1600px; min-height:calc(100dvh - 76px); margin:auto; display:grid; grid-template-columns:250px minmax(520px,1fr) 340px; }
.rail,.preview { padding:28px 22px; }
.rail { border-right:1px solid var(--line); }
.rail-title h1 { margin:0; font-size:23px; }
.rail-title p,.preview-heading p,.steps-heading p { margin:5px 0 25px; color:var(--muted); font-size:13px; }
.rail label { display:block; margin:20px 0 8px; font-size:13px; font-weight:700; color:var(--muted); }
select,input,textarea { width:100%; border:1px solid var(--line); border-radius:11px; padding:11px 12px; background:var(--surface); color:var(--ink); outline:none; }
select:focus,input:focus,textarea:focus,button:focus-visible { border-color:var(--green); box-shadow:0 0 0 3px rgba(40,120,92,.12); outline:none; }
.rail-note { margin-top:34px; padding:17px; background:var(--green2); border-radius:14px; color:var(--green); }
.rail-note p { margin:7px 0 0; font-size:13px; line-height:1.6; }
.editor { min-width:0; padding:28px 30px 60px; }
.editor-heading,.steps-heading,.photo-heading { display:flex; align-items:flex-end; justify-content:space-between; gap:16px; }
.eyebrow { color:var(--green); font-size:12px; font-weight:800; letter-spacing:.04em; }
h2 { margin:4px 0 0; font-size:23px; line-height:1.25; }
#saveState { color:var(--muted); font-size:13px; white-space:nowrap; }
.field-grid { margin-top:25px; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:17px; }
.field-grid label,.step-editor-copy label { display:block; color:var(--muted); font-size:13px; font-weight:700; }
.field-grid input,.field-grid select { display:block; margin-top:7px; color:var(--ink); }
.wide { grid-column:1/-1; }
.steps-heading { margin-top:42px; padding-top:26px; border-top:1px solid var(--line); }
.steps-heading p { margin-bottom:0; }
.step-tabs { margin:20px 0 16px; display:flex; gap:9px; flex-wrap:wrap; }
.step-tab { border:1px solid var(--line); border-radius:11px; padding:9px 13px; background:var(--surface); color:var(--muted); font-weight:700; }
.step-tab.active { background:var(--green2); color:var(--green); border-color:#b2d7c1; }
.step-editor { background:var(--surface); border:1px solid var(--line); border-radius:19px; padding:20px; box-shadow:var(--shadow); }
.step-editor-copy textarea { margin-top:8px; resize:vertical; min-height:105px; }
.step-editor-copy p,.canvas-hint { margin:8px 0 0; color:var(--muted); font-size:12px; }
.photo-editor { margin-top:24px; }
.photo-heading { align-items:center; margin-bottom:13px; }
.photo-heading strong,.photo-heading small { display:block; }
.photo-heading small { margin-top:3px; color:var(--muted); font-size:12px; }
.upload-label { display:inline-block; }
.canvas-wrap { position:relative; min-height:250px; display:flex; align-items:center; justify-content:center; overflow:hidden; border-radius:14px; background:#e7eee9; }
#photoCanvas { width:auto; height:auto; max-width:100%; max-height:520px; touch-action:none; display:none; }
.empty-photo { padding:30px; color:var(--muted); text-align:center; }
.annotation-tools { margin-top:12px; display:flex; gap:8px; flex-wrap:wrap; }
.tool { border:1px solid var(--line); border-radius:10px; padding:8px 12px; background:var(--surface2); color:var(--ink); font-weight:700; }
.tool.active { color:#fff; background:var(--green); border-color:var(--green); }
.tool.subtle { color:var(--muted); }
.notice { min-height:22px; margin-top:16px; color:var(--green); font-size:13px; }
.notice.error { color:var(--danger); }
.preview { background:#e7f0e9; border-left:1px solid var(--line); }
.preview-heading p { margin-bottom:20px; }
.preview-route { min-height:330px; padding:20px; background:var(--surface); border-radius:22px; box-shadow:var(--shadow); }
.preview-route h3 { margin:0 0 5px; font-size:18px; line-height:1.4; }
.preview-meta { margin:0 0 18px; color:var(--muted); font-size:12px; }
.preview-step { padding:13px 0; border-top:1px solid var(--line); }
.preview-step strong { color:var(--green); font-size:13px; }
.preview-step p { margin:5px 0 0; color:var(--ink); font-size:13px; line-height:1.6; }
.preview-step img { display:block; width:100%; margin-top:9px; border-radius:9px; }
.preview-empty { color:var(--muted); font-size:13px; line-height:1.6; }
@media (max-width:1200px) { .workspace { grid-template-columns:220px minmax(0,1fr); } .preview { grid-column:2; border-left:0; border-top:1px solid var(--line); } }
@media (max-width:720px) { .topbar { padding:12px 16px; align-items:flex-start; flex-direction:column; } .top-actions { width:100%; gap:8px; } .local-label { display:none; } .workspace { display:block; } .rail,.editor,.preview { padding:20px 16px; border:0; border-bottom:1px solid var(--line); } .rail-title p { margin-bottom:12px; } .rail-note { display:none; } .field-grid { grid-template-columns:1fr; } .wide { grid-column:auto; } .editor-heading { align-items:flex-start; } }
/* Login and review pages */
.login-page{min-height:100vh;display:grid;place-items:center;background:#f2f6f3;padding:24px}
.login-card{width:min(440px,100%);background:#fff;padding:36px;border:1px solid #dce8df;border-radius:20px;box-shadow:0 24px 70px #1e4a2b16}
.login-card h1{font-size:30px;margin:28px 0 8px}.login-card p{color:#607268}.login-card form{display:grid;gap:18px;margin-top:28px}
.login-card form label{display:grid;gap:8px;font-weight:600}.login-card input{width:100%;padding:12px;border:1px solid #ccd9d0;border-radius:10px;font:inherit}
.login-card button{width:100%;justify-content:center}.login-card #message{min-height:1.5em;color:#b43a35;margin:0}
.review-page{min-height:100vh;background:#f3f6f3}.review-workspace{display:grid;grid-template-columns:minmax(340px,420px) minmax(0,1fr);gap:24px;max-width:1440px;margin:0 auto;padding:28px}
.review-queue,.review-detail{background:#fff;border:1px solid #e0e9e1;border-radius:18px;min-height:calc(100vh - 120px);padding:26px}.review-heading h1{font-size:30px;margin:8px 0}.review-heading p{color:#718076;margin:0 0 22px}
.review-types{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:14px}.review-type{border:1px solid #d6e4d9;background:#fff;color:#496252;padding:12px;border-radius:10px;cursor:pointer;font:inherit;font-weight:700}.review-type.active{background:#e5f3e9;border-color:#80bf96;color:#1b6845}
.review-filters{display:flex;gap:8px;border-bottom:1px solid #e2eae3;padding-bottom:14px}.filter{border:0;background:transparent;color:#64766a;padding:10px 12px;cursor:pointer;border-radius:8px;font:inherit}.filter.active{background:#e5f3e9;color:#1b6845;font-weight:700}
.review-message{min-height:24px;color:#a04337}.feedback-list{display:grid;gap:10px}.feedback-card{width:100%;text-align:left;background:#fff;border:1px solid #e2eae3;border-radius:12px;padding:16px;cursor:pointer;font:inherit}.feedback-card:hover,.feedback-card.active{border-color:#53a478;background:#f6fbf7}.feedback-card strong,.feedback-card span{display:block}.feedback-card span{font-size:12px;color:#849188;margin-top:8px}.feedback-card p{color:#52665a;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin:10px 0 0}
.pagination{display:flex;gap:12px;align-items:center;justify-content:space-between;margin-top:20px}.review-detail{padding:32px}.detail-empty{display:grid;place-items:center;min-height:50vh;color:#8b9b90}.detail-top{display:flex;justify-content:space-between;align-items:center}.status-pill{padding:5px 12px;border-radius:30px;background:#e8f4eb;color:#28714c;font-size:13px}.review-detail h2{font-size:28px;margin:12px 0}.detail-meta{color:#8a968d;font-size:12px}.detail-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;border-block:1px solid #e6ece7;padding:22px 0}.detail-fields div{min-width:0}.detail-fields dt{color:#8c9b90;font-size:13px}.detail-fields dd{margin:8px 0 0;word-break:break-word}.detail-block{padding:16px 0;border-bottom:1px solid #edf1ed}.detail-block h3{font-size:16px;margin:0 0 10px}.detail-block p{white-space:pre-wrap;line-height:1.7;color:#394d41}.review-photos{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.review-photos img{display:block;width:100%;height:180px;object-fit:cover;border-radius:10px;border:1px solid #e2e9e3}.decision-box{padding-top:22px}.decision-box label{display:block;font-weight:700;margin-bottom:8px}.decision-box textarea{width:100%;border:1px solid #ccd9d0;border-radius:10px;padding:12px;font:inherit;resize:vertical}.decision-actions{display:flex;justify-content:flex-end;gap:12px;margin-top:14px}.decision-hint{color:#829287;font-size:13px;line-height:1.5}
@media(max-width:850px){.review-workspace{grid-template-columns:1fr;padding:14px}.review-queue,.review-detail{min-height:auto;padding:20px}.review-photos{grid-template-columns:repeat(2,minmax(0,1fr))}.review-page .top-actions{gap:8px}.review-page #operator{display:none}}
