* { box-sizing: border-box; }
:root { font-family: system-ui, "Noto Sans TC", sans-serif; color: #17343c; background: #f3f6f2; font-synthesis: none; }
body { margin: 0; min-width: 320px; }
button, input, textarea, select { font: inherit; }
.topbar { max-width: 1180px; margin: auto; padding: 20px 28px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; }
.brand img { border-radius: 13px; }
.brand span { display: grid; gap: 2px; }
.brand strong { font-size: 1.04rem; }
.brand small, .muted-count { color: #73817f; font-size: .78rem; }
.prototype-badge { border: 1px solid #cfe5d6; border-radius: 999px; padding: 7px 12px; background: #e8f4eb; color: #38634c; font-size: .78rem; }
.page-shell { width: min(100% - 44px, 1124px); margin: 18px auto 68px; }
.hero { min-height: 258px; padding: clamp(30px, 5vw, 54px); border-radius: 26px; display: flex; align-items: end; justify-content: space-between; gap: 28px; color: #fff; background: #17343c; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; width: 260px; height: 260px; right: 8%; top: -115px; border: 1px solid rgb(183 230 206 / 18%); border-radius: 50%; box-shadow: 0 0 0 34px rgb(183 230 206 / 5%), 0 0 0 68px rgb(183 230 206 / 4%); pointer-events: none; }
.hero > * { position: relative; z-index: 1; }
.eyebrow { margin: 0 0 9px; color: #4d8267; font-size: .74rem; font-weight: 750; letter-spacing: .11em; }
.hero .eyebrow { color: #b7e6ce; }
h1 { margin: 0; font-size: clamp(2rem, 5vw, 3.25rem); line-height: 1.15; letter-spacing: -.045em; }
.hero-copy { margin: 14px 0 0; color: #d0dedb; line-height: 1.7; }
.hero-note { display: inline-flex; align-items: center; gap: 8px; flex: none; padding: 9px 13px; border: 1px solid #426168; border-radius: 999px; color: #d3e3df; background: #203e45; font-size: .78rem; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #edb568; }
.capture-layout { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 18px; margin-top: 20px; }
.panel { min-width: 0; padding: 25px; border: 1px solid #dfe7e1; border-radius: 20px; background: #fff; box-shadow: 0 8px 28px rgb(28 56 46 / 3%); }
.panel-heading, .records-heading { display: flex; align-items: end; justify-content: space-between; gap: 12px; }
h2 { margin: 0; font-size: 1.38rem; letter-spacing: -.025em; }
.step-mark { color: #d4ded8; font-size: 1.6rem; font-weight: 700; }
.field-label, .select-field > span { display: block; margin: 22px 0 8px; color: #42565b; font-size: .83rem; font-weight: 650; }
textarea, input[type="search"], select { width: 100%; border: 1px solid #d9e2dd; border-radius: 12px; background: #fbfcfa; color: #17343c; outline: none; }
textarea { min-height: 116px; padding: 14px 15px; resize: vertical; line-height: 1.65; }
textarea::placeholder, input::placeholder { color: #9aa7a2; }
textarea:focus, input[type="search"]:focus, select:focus { border-color: #599577; box-shadow: 0 0 0 3px rgb(89 149 119 / 13%); }
.capture-footer { display: flex; align-items: end; gap: 12px; }
.select-field { flex: 1; min-width: 0; }
.select-field > span { margin-top: 15px; }
select { min-height: 44px; padding: 0 36px 0 12px; }
.primary-button { min-height: 44px; flex: none; border: 0; border-radius: 12px; padding: 0 17px; color: #fff; background: #2f7054; font-weight: 650; cursor: pointer; transition: background .15s ease, transform .15s ease; }
.primary-button:hover { background: #245d44; transform: translateY(-1px); }
.primary-button:focus-visible, .category-button:focus-visible { outline: 3px solid #91caaa; outline-offset: 2px; }
.form-note, .section-hint, .sample-note { color: #778581; font-size: .78rem; line-height: 1.6; }
.form-note { margin: 12px 0 0; }
.section-hint { margin: 8px 0 16px; }
.category-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 0; margin: 0; list-style: none; }
.category-button { width: 100%; min-height: 39px; border: 1px solid #e3e9e4; border-radius: 10px; padding: 7px 9px; background: #fbfcfa; color: #50615f; cursor: pointer; font-size: .76rem; text-align: left; transition: .15s ease; }
.category-button:hover { border-color: #afd2bc; background: #f1f8f3; }
.category-button[aria-pressed="true"] { border-color: #73a889; background: #e9f4ec; color: #275c40; font-weight: 700; }
.records-section { margin-top: 42px; }
.records-heading { margin-bottom: 17px; }
.record-count { color: #74827e; font-size: .82rem; }
.filter-bar { display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 10px; margin-bottom: 14px; }
.search-field { position: relative; }
.search-field input { min-height: 46px; padding: 0 14px 0 42px; }
.search-icon { position: absolute; left: 15px; top: 50%; transform: translateY(-52%); color: #83928d; font-size: 1.35rem; pointer-events: none; }
.filter-field select { min-height: 46px; }
.record-list { display: grid; gap: 10px; padding: 0; margin: 0; list-style: none; }
.record-card { padding: 16px 18px; border: 1px solid #e1e8e2; border-radius: 15px; background: #fff; }
.record-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.record-category { display: inline-flex; align-items: center; gap: 7px; color: #397052; font-size: .76rem; font-weight: 700; }
.record-category::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #75aa88; }
.record-time { color: #89958f; font-size: .74rem; }
.record-content { margin: 0; color: #2c4145; line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.empty-state { padding: 30px 18px; border: 1px dashed #cfdad2; border-radius: 15px; color: #697873; text-align: center; }
.sample-note { margin: 13px 2px 0; }
.site-footer { border-top: 1px solid #e0e7e1; padding: 22px; color: #71807b; text-align: center; font-size: .78rem; }
.site-footer span { padding: 0 5px; color: #9fb6a7; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (max-width: 820px) { .capture-layout { grid-template-columns: 1fr; } .category-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 560px) { .topbar { padding: 16px 18px; } .page-shell { width: min(100% - 28px, 1124px); margin-top: 12px; } .hero { min-height: 0; align-items: start; flex-direction: column; gap: 18px; border-radius: 20px; } .panel { padding: 19px; border-radius: 17px; } .category-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .filter-bar { grid-template-columns: 1fr; } .capture-footer { align-items: stretch; flex-direction: column; } .primary-button { width: 100%; } }


/* Local-only multi-input controls */
.capture-tools { display: grid; gap: 12px; margin-top: 18px; }
.input-method { min-width: 0; padding: 15px; border: 1px solid #e3e9e4; border-radius: 14px; background: #fbfcfa; }
.input-method-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.input-method-header h3 { margin: 0; color: #2c4145; font-size: .92rem; }
.local-only-tag { flex: none; color: #397052; font-size: .7rem; font-weight: 700; }
.input-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.secondary-button { min-height: 39px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid #cddbd1; border-radius: 10px; padding: 7px 12px; color: #285b42; background: #f4f8f4; font-size: .8rem; font-weight: 650; cursor: pointer; }
.secondary-button:hover:not(:disabled) { border-color: #8fb99e; background: #eaf4ec; }
.secondary-button:focus-visible, .remove-attachment:focus-visible { outline: 3px solid #91caaa; outline-offset: 2px; }
.secondary-button:disabled { cursor: not-allowed; color: #89958f; background: #f1f3f1; }
.file-action { position: relative; }
.file-action:focus-within { outline: 3px solid #91caaa; outline-offset: 2px; }
.inline-status { margin: 8px 0 0; color: #778581; font-size: .74rem; line-height: 1.55; overflow-wrap: anywhere; }
.link-entry { margin-top: 13px; }
.link-entry .field-label { margin: 0 0 6px; }
.link-entry-controls { display: flex; gap: 8px; }
.link-entry-controls input { min-width: 0; min-height: 40px; flex: 1; border: 1px solid #d9e2dd; border-radius: 10px; padding: 0 11px; color: #17343c; background: #fff; }
.link-entry-controls input:focus { outline: none; border-color: #599577; box-shadow: 0 0 0 3px rgb(89 149 119 / 13%); }
.attachment-list { display: grid; gap: 7px; padding: 0; margin: 12px 0 0; list-style: none; }
.attachment-item { min-width: 0; display: flex; align-items: center; gap: 9px; padding: 7px 9px; border: 1px solid #e3e9e4; border-radius: 10px; background: #fff; }
.attachment-thumb { width: 42px; height: 42px; flex: none; border-radius: 7px; object-fit: cover; background: #edf2ee; }
.attachment-kind { width: 42px; height: 42px; flex: none; display: grid; place-items: center; border-radius: 7px; color: #397052; background: #edf5ef; font-size: .68rem; font-weight: 700; }
.attachment-name { min-width: 0; flex: 1; color: #42565b; font-size: .77rem; overflow-wrap: anywhere; }
.remove-attachment { flex: none; border: 0; padding: 6px 8px; color: #6d7773; background: transparent; font-size: .72rem; cursor: pointer; }
.record-related { display: grid; gap: 4px; padding-left: 18px; margin: 10px 0 0; color: #667671; font-size: .75rem; overflow-wrap: anywhere; }
@media (max-width: 560px) { .input-method { padding: 12px; } .input-actions > .secondary-button { flex: 1 1 auto; } .link-entry-controls { align-items: stretch; flex-direction: column; } .link-entry-controls .secondary-button { width: 100%; } }
