:root{--ivory:#f7f5ee;--forest:#173e33;--terra:#b95b40;--line:#ddd8c7;--card:#fffdf8;--muted:#5a6b63}
*{box-sizing:border-box}
body{margin:0;background:var(--ivory);color:var(--forest);font:16px/1.5 system-ui,-apple-system,'Segoe UI',Roboto,Arial,sans-serif}
h1,h2,h3{font-family:Georgia,'Times New Roman',serif;line-height:1.15}
button,input,textarea,select{font:inherit}
[hidden]{display:none!important}
.site-header{display:flex;flex-wrap:wrap;gap:8px 20px;align-items:center;justify-content:space-between;padding:14px 20px;border-bottom:1px solid var(--line)}
.brand{display:flex;align-items:center;gap:10px;font-size:1.2rem}
.brand-mark{display:grid;place-items:center;width:32px;height:32px;border-radius:8px;background:var(--forest);color:var(--ivory);font-family:Georgia,serif}
.tagline{margin:0;color:var(--muted);font-size:.9rem}
.btn{display:inline-block;border:1px solid var(--forest);background:transparent;color:var(--forest);padding:9px 15px;border-radius:8px;cursor:pointer;min-height:42px}
.btn:hover{background:rgba(23,62,51,.08)}
.btn.primary{background:var(--forest);color:var(--ivory)}
.btn.primary:hover{background:#0f2c24}
.btn.accent{background:var(--terra);border-color:var(--terra);color:#fff}
.btn.accent:hover{background:#9f4a31}
.btn:focus-visible,.link:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:3px solid var(--terra);outline-offset:2px}
.link{background:none;border:0;color:var(--forest);text-decoration:underline;cursor:pointer;padding:6px}
.hero{display:grid;grid-template-columns:1.1fr .9fr;gap:40px;align-items:center;max-width:1100px;margin:0 auto;padding:48px 20px}
.hero h1{font-size:clamp(2.2rem,5vw,3.8rem);margin:0 0 16px}
.lead{font-size:1.15rem;max-width:34em}
.cta-row{display:flex;flex-wrap:wrap;gap:12px;margin:20px 0}
.features{padding-left:20px;margin:0 0 20px}
.features li{margin-bottom:8px}
.upgrade-box{border:1px dashed var(--terra);border-radius:10px;padding:14px;background:var(--card)}
.upgrade-box p{margin:0 0 10px}
.mock{display:flex;justify-content:center}
.mock-page{position:relative;width:min(320px,100%);background:#fff;border:1px solid var(--line);border-radius:6px;padding:20px;box-shadow:0 14px 34px rgba(23,62,51,.16);transform:rotate(2deg)}
.mock-head{display:flex;align-items:center;gap:10px;margin-bottom:16px}
.mock-head span{width:34px;height:34px;border-radius:8px;background:var(--forest)}
.mock-head b{height:10px;width:50%;background:var(--terra);border-radius:4px}
.mock-line{height:8px;background:#e6e2d3;border-radius:4px;margin-bottom:8px}
.w80{width:80%}.w60{width:60%}
.mock-photos{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:14px 0}
.mock-photos i{height:80px;border-radius:6px;background:linear-gradient(135deg,#cfd8d2,#9fb3a9)}
.mock-check{display:flex;align-items:center;gap:8px;margin-bottom:8px}
.mock-check em{width:14px;height:14px;border:2px solid var(--forest);border-radius:3px;background:var(--forest)}
.mock-check span{height:8px;flex:1;background:#e6e2d3;border-radius:4px}
.mock-stamp{position:absolute;right:14px;bottom:14px;border:2px solid var(--terra);color:var(--terra);padding:2px 8px;border-radius:4px;font-size:.75rem;text-transform:uppercase;letter-spacing:.06em;transform:rotate(-6deg)}
.workspace{display:grid;grid-template-columns:280px 1fr;min-height:70vh}
.sidebar{border-right:1px solid var(--line);padding:16px;background:#f1eee3}
.side-actions,.backup{display:flex;flex-direction:column;gap:8px;margin-bottom:16px}
#jobs{display:flex;flex-direction:column;gap:6px;margin-bottom:16px}
#jobs button,#jobs a{display:block;text-align:left;width:100%;border:1px solid var(--line);background:var(--card);color:var(--forest);padding:10px;border-radius:8px;cursor:pointer}
#jobs [aria-current='true'],#jobs .active{border-color:var(--forest);box-shadow:inset 3px 0 0 var(--terra)}
.file-btn{text-align:center}
#backup-import{position:absolute;width:1px;height:1px;opacity:0;overflow:hidden}
#backup-import:focus-visible+*{outline:3px solid var(--terra)}
.main-pane{min-width:0;padding:16px 20px}
.toolbar{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-bottom:16px;position:sticky;top:0;background:var(--ivory);padding:6px 0;z-index:2}
#save-status{margin-right:auto;color:var(--muted);font-size:.9rem}
.editor h2{font-size:1.8rem;margin:0 0 12px}
.editor section,.section-card{background:var(--card);border:1px solid var(--line);border-radius:12px;padding:16px;margin-bottom:16px}
.editor section h3{margin:0 0 10px}
.stage-badge{display:inline-block;background:var(--forest);color:var(--ivory);border-radius:999px;padding:2px 10px;font-size:.78rem;text-transform:uppercase;letter-spacing:.05em}
.stage-badge.after{background:var(--terra)}
.field{display:flex;flex-direction:column;gap:4px;margin-bottom:12px}
.field label{font-weight:600;font-size:.92rem}
.field input,.field textarea,.field select,textarea,input[type=text],input[type=date],select{width:100%;padding:9px 10px;border:1px solid #b8b29c;border-radius:8px;background:#fff;color:var(--forest)}
input[type=color]{width:64px;height:40px;padding:2px}
.row{display:flex;flex-wrap:wrap;gap:12px;align-items:flex-end}
.row>.field{flex:1 1 200px}
.check-row{display:flex;align-items:center;gap:10px;padding:8px 0;border-bottom:1px solid var(--line)}
.check-row input[type=checkbox]{width:22px;height:22px;accent-color:var(--forest)}
.photos-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:12px}
.photo-card{background:#fff;border:1px solid var(--line);border-radius:10px;padding:8px;display:flex;flex-direction:column;gap:6px}
.photo-card img{width:100%;aspect-ratio:4/3;object-fit:cover;border-radius:6px;background:#e6e2d3}
.editor label{display:block;margin-bottom:10px;font-weight:500}
.editor>div>label{margin-bottom:14px}
.photo{min-width:0;border:1px solid var(--line);border-radius:10px;background:#fff;padding:12px;margin-bottom:12px}
.photo img{width:100%;max-height:250px;object-fit:contain;border-radius:6px;background:#e6e2d3}
.photo button,.task button,.editor section>button,.editor>div>button,.capture-repeat{border:1px solid var(--forest);background:var(--ivory);color:var(--forest);padding:8px 12px;border-radius:7px;margin:4px;cursor:pointer;min-height:42px}
.task{display:grid;grid-template-columns:1.5fr 100px 1.5fr auto;gap:10px;align-items:center;border-top:1px solid var(--line);padding:10px 0}
.task label{margin:0}
.task input{min-width:0}
button:disabled{opacity:.5;cursor:default}
input[type=file]{max-width:100%}
.reference-card{border:2px dashed var(--terra);border-radius:10px;padding:10px;background:#fbf1ec}
.reference-card img{width:100%;max-height:200px;object-fit:contain}
.camera-stage,.video-stage{position:relative;background:#000;height:60vh;border-radius:10px;overflow:hidden}
.camera-stage video,.video-stage video{width:100%;height:100%;object-fit:contain;display:block}
.camera-stage img,.video-stage img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;opacity:.4;pointer-events:none}
.camera-actions,.actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}
dialog{width:min(560px,92vw);max-width:92vw;max-height:90vh;overflow:auto;border:1px solid var(--forest);border-radius:14px;background:var(--ivory);color:var(--forest);padding:20px}
dialog::backdrop{background:rgba(23,62,51,.55)}
dialog h2{margin-top:0}
#preview-dialog{width:min(900px,92vw)}
#pdf-preview{width:100%;height:65vh;border:1px solid var(--line);background:#fff}
.dialog-actions{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px;margin-top:16px}
.note{color:var(--muted);font-size:.9rem}
#toast{position:fixed;left:50%;bottom:20px;transform:translate(-50%,20px);background:var(--forest);color:var(--ivory);padding:10px 18px;border-radius:8px;opacity:0;pointer-events:none;transition:.2s;max-width:90vw;z-index:50}
#toast.show,#toast:not(:empty){opacity:1;transform:translate(-50%,0)}
.site-footer{display:flex;flex-wrap:wrap;gap:8px 20px;justify-content:space-between;align-items:center;padding:16px 20px;border-top:1px solid var(--line);color:var(--muted);font-size:.85rem}
.site-footer p{margin:0;max-width:60em}
@media (max-width:800px){
.hero{grid-template-columns:1fr;padding:28px 16px;gap:28px}
.workspace{grid-template-columns:1fr}
.task{grid-template-columns:1fr 100px}
.sidebar{border-right:0;border-bottom:1px solid var(--line)}
.side-actions,.backup{flex-direction:row;flex-wrap:wrap}
.side-actions .btn,.backup .btn{flex:1 1 140px}
.toolbar .btn{flex:1 1 45%}
.toolbar{position:static}
#save-status{flex-basis:100%}
.camera-stage,.video-stage{height:60vh}
.dialog-actions .btn,.cta-row .btn,.row .btn{flex:1 1 100%}
}
@media (prefers-reduced-motion:reduce){*{transition:none!important}}
.site-header nav{display:flex;flex-wrap:wrap;gap:12px;align-items:center;max-width:100%}
a{color:var(--forest);text-underline-offset:3px}
.article{max-width:800px;padding:40px 24px 64px;margin:auto;color:#253b32;font-size:1.06rem;line-height:1.75;overflow-wrap:anywhere}
.article h1{font-size:clamp(2rem,4vw,3.2rem);margin:24px 0}
.article h2{font-size:1.7rem;margin-top:40px}.article h3{font-size:1.3rem;margin-top:26px}
.article table{width:100%;border-collapse:collapse;font-size:.92rem;margin:24px 0}
.article th,.article td{border:1px solid var(--line);text-align:left;padding:12px;vertical-align:top;overflow-wrap:anywhere}
.article th{background:#e6ecdf}.article caption{font-weight:600;text-align:left;margin-bottom:8px}
.article .callout,.article .guide-card{background:var(--card);border:1px solid var(--line);border-radius:12px;padding:24px;margin:28px 0}
.article .byline,.article .eyebrow{font-size:.9rem;color:var(--muted)}
.article figure{margin:28px 0}.article img{max-width:100%;height:auto;border-radius:10px}
.article blockquote{border-left:4px solid var(--terra);margin:20px 0;padding:12px 20px;background:#f0eee3}

