/* TicketFact — local, dependency-free administrative interface. */
.review-form, .review-fields { display: grid; gap: 18px; }
.fiscal-card { max-width: 760px; }
.portal-card h2 { margin-top: 8px; }
.portal-note { margin: 16px 0; color: var(--muted); }
.portal-prepare { margin-top: 20px; }
.portal-run { display: grid; gap: 12px; padding-top: 20px; margin-top: 20px; border-top: 1px solid var(--line); overflow-wrap: anywhere; }
.portal-run summary { cursor: pointer; color: var(--sage-text); }
.portal-evidence { display: block; margin-top: 12px; width: 100%; border: 1px solid var(--line); border-radius: 8px; }
.qr-panel { display: grid; gap: 14px; padding: 16px; background: var(--mint); border: 1px solid var(--line); border-radius: 8px; min-width: 0; }
.qr-code { min-width: 0; font-size: 12px; }
.qr-code pre { white-space: pre-wrap; overflow-wrap: anywhere; user-select: text; padding: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 6px; }
.qr-history { margin-top: 16px; }
.review-intro, .field-help, .field-source, .field-evidence { color: var(--muted); font-size: 12px; }
.review-intro { margin: 12px 0 20px; }
.review-field { min-width: 0; display: grid; gap: 7px; }
.review-field label { font-weight: 600; }
.review-field textarea, .review-field select { width: 100%; min-width: 0; font: inherit; color: var(--ink); background: var(--surface); padding: 12px; border: 1px solid var(--line); border-radius: 8px; }
.review-field textarea { resize: vertical; }
.field-group { border-top: 1px solid var(--line); padding-top: 16px; }
.field-group > summary { font-weight: 650; color: var(--petroleum); margin-bottom: 16px; }
.review-card summary, .history-panel summary, .audit-diff summary { cursor: pointer; overflow-wrap: anywhere; }
.field-evidence p { padding: 10px; background: var(--mint); white-space: pre-wrap; overflow-wrap: anywhere; }
.review-warnings { background: var(--warning-bg); color: var(--warning); padding: 16px; border-radius: 8px; margin: 18px 0; overflow-wrap: anywhere; }
.review-warnings ul { padding-left: 20px; }
.review-message { margin-bottom: 20px; }
.ready-checkbox { display: flex; align-items: flex-start; gap: 10px; }
.review-complete { color: var(--sage-text); margin: 16px 0; }
.extraction-action { margin-bottom: 20px; }
.extraction-action p { margin-top: 10px; }
.extraction-action button:disabled { color: var(--muted); background: var(--bg); }
.receipt-preview { display: block; padding: 0; background: transparent; cursor: zoom-in; max-width: 100%; margin: auto; }
body:has(.receipt-dialog[open]) { overflow: hidden; }
.receipt-dialog { width: calc(100vw - 32px); max-width: 1400px; max-height: calc(100dvh - 32px); padding: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); }
.receipt-dialog::backdrop { background: rgb(18 35 43 / 80%); }
.receipt-dialog-content { display: flex; flex-direction: column; height: calc(100dvh - 64px); }
.receipt-dialog-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.receipt-dialog-actions { display: flex; gap: 10px; }
.receipt-dialog-stage { flex: 1; min-height: 0; overflow: auto; padding: 16px; background: var(--bg); text-align: center; }
.receipt-dialog-stage img { display: block; width: 100%; height: 100%; object-fit: contain; }
.receipt-dialog-stage.is-zoomed img { width: auto; height: auto; max-width: none; margin: 0 auto; }
.audit-diff { margin-top: 12px; font-size: 12px; }
.audit-diff pre { max-height: 400px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; padding: 14px; background: var(--bg); border: 1px solid var(--line); border-radius: 8px; }
.extraction-attempt { border-top: 1px solid var(--line); padding: 18px 24px; }
.attempt-body { margin-top: 16px; font-size: 12px; }
.attempt-body p + p { margin-top: 8px; }
.extraction-empty { padding: 0 24px 24px; color: var(--muted); }
.merchant-preview { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.deadline-overview { margin-bottom: 24px; }
.deadline-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; padding: 0 24px 24px; }
.deadline-stat { display: flex; gap: 16px; align-items: center; padding: 18px; border: 1px solid var(--line); border-radius: 14px; color: inherit; text-decoration: none; }
.deadline-stat strong { display: block; font-size: 28px; }
.deadline-stat span, .deadline-stat small { display: block; }
.deadline-stat small { margin-top: 5px; }
.deadline-tabs { display: flex; gap: 12px; margin-bottom: 20px; }
.deadline-tabs [aria-current="page"] { text-decoration: underline; text-underline-offset: 5px; }
@media (max-width: 600px) { .deadline-metrics { grid-template-columns: 1fr; padding: 0 16px 16px; } }

.batch-submit, .batch-counts { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; margin: 20px 0; }
.batch-counts { justify-content: flex-start; color: var(--petroleum); }
.batch-history { margin-top: 24px; }
.batch-submit button:disabled { opacity: .55; }

.report-filters { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin: 20px 0; }
.report-filters input { width: 100%; min-width: 0; }
.report-filter-actions { display: flex; flex-wrap: wrap; gap: 12px; grid-column: 1 / -1; }
.report-summary, .report-section { margin-top: 24px; }
.report-breakdowns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.report-empty { padding: 24px; color: var(--muted); }
@media (max-width: 1000px) { .report-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .report-filters, .report-breakdowns { grid-template-columns: 1fr; } }

:root {
  color-scheme: light;
  --petroleum: #203B4A;
  --sage: #749B91;
  --mint: #E9F2F0;
  --bg: #F7F9F9;
  --surface: #fff;
  --ink: #26383D;
  --muted: #5F7278;
  --line: #DEE7E5;
  --primary: var(--petroleum);
  --primary-hover: #294B5D;
  --sage-text: #44665F;
  --sidebar: var(--petroleum);
  --on-dark-muted: #BDCFD0;
  --warning: #806127;
  --warning-bg: #FAF5E9;
  --danger: #A24940;
  --danger-bg: #FCF1EF;
  --radius: 14px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); line-height: 1.5; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button, a, input { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
button, input { border-radius: 8px; }
button { border: 0; }
img { max-width: 100%; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-weight: 650; }
h1 { font-size: clamp(26px, 2.4vw, 34px); line-height: 1.3; letter-spacing: -.8px; }
h2 { font-size: 16px; letter-spacing: -.25px; }
h3 { font-size: 14px; }
input:not([type=hidden]):not([type=checkbox]) { display: block; width: 100%; padding: 13px 14px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); }
input::placeholder { color: var(--muted); }
input[type=checkbox] { accent-color: var(--primary); width: 17px; height: 17px; flex: 0 0 auto; }
:focus-visible { outline: 3px solid var(--sage); outline-offset: 4px; }
input:focus-visible { outline-offset: 1px; }
[x-cloak] { display: none !important; }
.icon { width: 19px; height: 19px; flex: 0 0 auto; vertical-align: middle; }
.sr-only, .skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link:focus { position: fixed; top: 12px; left: 12px; z-index: 100; padding: 12px; background: white; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 9px; min-height: 42px; padding: 10px 17px; font-size: 13px; font-weight: 600; border: 1px solid transparent; border-radius: 8px; white-space: nowrap; transition: background .15s, border-color .15s; }
.button-primary { color: #fff; background: var(--primary); }
.button-primary:hover { background: var(--primary-hover); }
.button-secondary, .button-white { background: var(--surface); color: var(--petroleum); border-color: var(--line); }
.button-secondary:hover, .button-white:hover { background: var(--mint); border-color: var(--sage); }
.button-small { min-height: 35px; padding: 7px 12px; font-size: 12px; }
.text-link { display: inline-flex; align-items: center; gap: 7px; color: var(--petroleum); font-size: 12px; font-weight: 600; white-space: nowrap; }
.text-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.text-link .icon { width: 16px; }

/* Navigation and persistent workspace chrome. */
.sidebar { width: 244px; position: fixed; inset: 0 auto 0 0; display: flex; flex-direction: column; padding: 32px 18px 0; background: var(--sidebar); color: var(--mint); z-index: 30; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; padding: 0 12px; }
.brand-mark { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 37px; height: 39px; background: var(--mint); color: var(--petroleum); border-radius: 10px; font-size: 32px; font-weight: 750; letter-spacing: -3px; line-height: 1; padding: 0 3px 6px 0; }
.brand-mark > span { color: var(--sage); }
.brand-name { font-size: 22px; font-weight: 650; letter-spacing: -.8px; }
.brand-caption { display: block; font-size: 8px; letter-spacing: .9px; font-weight: 500; color: var(--on-dark-muted); margin-top: 3px; }
.workspace { display: flex; align-items: center; gap: 10px; padding: 15px 11px; margin: 32px 0 28px; border: 1px solid #ffffff16; border-radius: 10px; background: #ffffff04; }
.workspace-avatar, .user-avatar { display: grid; place-items: center; flex: 0 0 auto; width: 32px; height: 32px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--mint); background: #355260; }
.workspace > span:nth-child(2) { min-width: 0; }
.workspace strong { display: block; max-width: 133px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 550; color: var(--mint); }
.workspace small { display: block; color: var(--on-dark-muted); font-size: 11px; margin-top: 2px; }
.workspace-dot { height: 5px; width: 5px; background: var(--sage); border-radius: 50%; flex-shrink: 0; margin-left: auto; }
.nav-label { font-size: 10px; letter-spacing: 1.5px; color: var(--on-dark-muted); padding: 0 13px; margin-bottom: 11px; }
.side-nav { display: grid; gap: 6px; }
.nav-link { display: flex; align-items: center; gap: 13px; padding: 12px 13px; border-radius: 8px; font-size: 13px; color: var(--on-dark-muted); }
.nav-link.active { color: var(--mint); background: #355260; box-shadow: inset 3px 0 var(--sage); }
.nav-link:hover { background: #ffffff0b; color: white; }
.nav-link.active:hover { background: #3D5C68; }
.nav-link .icon { width: 18px; height: 18px; opacity: .85; }
.sidebar-bottom { margin-top: auto; padding-top: 45px; }
.sidebar-tip { border: 1px solid #ffffff12; border-radius: 10px; padding: 15px; margin-bottom: 22px; background: #ffffff03; }
.sidebar-tip > .icon { color: var(--sage); margin-bottom: 10px; width: 21px; height: 21px; }
.sidebar-tip strong { display: block; font-size: 12px; line-height: 1.5; font-weight: 550; }
.sidebar-tip p { color: var(--on-dark-muted); font-size: 11px; line-height: 1.8; margin-top: 6px; }
.user-card { display: flex; align-items: center; gap: 9px; padding: 18px 0 22px; border-top: 1px solid #ffffff12; }
.user-avatar { border-radius: 50%; width: 31px; height: 31px; background: var(--mint); color: var(--petroleum); }
.user-info { flex: 1; min-width: 0; }
.user-info strong { display: block; color: var(--mint); font-size: 12px; font-weight: 550; }
.user-info > span { display: block; font-size: 11px; color: var(--on-dark-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 2px; }
.logout-button { display: grid; place-items: center; background: transparent; color: var(--on-dark-muted); width: 32px; height: 36px; }
.logout-button:hover { background: #ffffff10; color: white; }
.app-main { margin-left: 244px; min-height: 100dvh; display: flex; flex-direction: column; }
.topbar { height: 71px; background: #ffffffd9; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 36px; gap: 15px; }
.topbar-title { display: flex; align-items: center; gap: 14px; color: var(--muted); font-size: 12px; }
.topbar-title strong { color: var(--ink); font-weight: 500; }
.breadcrumb-divider { color: #c8cfd1; }
.environment-label { display: flex; align-items: center; gap: 7px; color: var(--sage-text); font-size: 11px; border: 1px solid var(--line); padding: 5px 10px; border-radius: 20px; white-space: nowrap; }
.environment-label > span, .live-label > span { background: var(--sage); border-radius: 50%; width: 5px; height: 5px; display: inline-block; }
.main-content { width: 100%; max-width: 1600px; margin: 0 auto; padding: 35px 36px 32px; flex: 1; }
.app-footer { display: flex; justify-content: space-between; gap: 15px; margin: 0 36px; border-top: 1px solid var(--line); padding: 20px 0; font-size: 11px; color: var(--muted); }
.footer-dot { padding: 0 6px; }
.icon-button { background: transparent; padding: 6px; color: var(--ink); }
.menu-button, .sidebar-overlay { display: none; }

/* Dashboard. */
.eyebrow { font-size: 10px; font-weight: 600; letter-spacing: 1.4px; color: var(--muted); margin-bottom: 9px; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 24px; margin-bottom: 28px; }
.page-description { color: var(--muted); font-size: 13px; margin-top: 10px; line-height: 1.7; }
.metrics-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 16px; margin-bottom: 23px; }
.metric-card { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); padding: 21px 20px; }
.metric-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 12px; font-weight: 500; }
.metric-icon { display: grid; place-items: center; width: 31px; height: 31px; border-radius: 8px; }
.metric-icon .icon { width: 17px; height: 17px; }
.green { background: var(--mint); color: var(--sage-text); }
.blue { background: var(--bg); color: var(--petroleum); }
.amber { background: var(--warning-bg); color: var(--warning); }
.rose { background: var(--danger-bg); color: var(--danger); }
.metric-value { display: block; font-size: 34px; font-weight: 600; line-height: 1.25; letter-spacing: -1px; margin: 11px 0 5px; font-variant-numeric: tabular-nums; }
.metric-card p { color: var(--muted); font-size: 11px; line-height: 1.7; }
.capture-banner { display: flex; align-items: center; gap: 19px; background: var(--mint); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; margin-bottom: 27px; }
.banner-symbol { display: grid; place-items: center; width: 46px; height: 46px; border: 1px solid var(--line); border-radius: 10px; color: var(--sage-text); background: var(--surface); flex: 0 0 auto; }
.banner-symbol .icon { width: 22px; height: 22px; }
.capture-banner h2 { color: var(--ink); font-size: 15px; }
.capture-banner p { color: var(--sage-text); font-size: 12px; margin-top: 5px; }
.capture-banner .button { margin-left: auto; font-size: 12px; color: var(--petroleum); }
.overview-columns { display: grid; grid-template-columns: minmax(0,1fr) 255px; gap: 22px; align-items: start; }
.surface { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 23px; border-bottom: 1px solid var(--line); }
.section-heading h2 { font-size: 15px; }
.section-heading p { font-size: 12px; color: var(--muted); margin-top: 5px; }
.section-heading > .icon { color: var(--sage); }
.section-footer { padding: 16px 22px; display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 11px; border-top: 1px solid var(--line); }
.section-footer > .icon { width: 13px; height: 13px; }
.live-label { display: inline-flex; align-items: center; gap: 7px; color: var(--sage-text); font-size: 11px; white-space: nowrap; }
.workflow-card { border-radius: var(--radius); padding: 24px 22px; background: var(--surface); border: 1px solid var(--line); }
.workflow-card h2 { font-size: 19px; letter-spacing: -.5px; }
.workflow-list { margin: 26px 0 0; padding: 0; list-style: none; }
.workflow-list li { position: relative; display: flex; gap: 13px; padding-bottom: 25px; }
.workflow-list li:not(:last-child)::before { content: ""; position: absolute; left: 12px; top: 29px; bottom: 5px; width: 1px; background: var(--line); }
.workflow-list li > span { display: grid; place-items: center; flex-shrink: 0; width: 26px; height: 26px; border: 1px solid var(--line); color: var(--muted); background: var(--bg); border-radius: 50%; font-size: 11px; }
.workflow-list .workflow-current > span { color: var(--sage-text); border-color: var(--line); background: var(--mint); }
.workflow-list strong { font-size: 12px; color: var(--ink); font-weight: 600; display: block; margin-top: 4px; }
.workflow-list p { color: var(--muted); font-size: 12px; line-height: 1.8; margin-top: 5px; }
.workflow-note { display: flex; align-items: flex-start; gap: 8px; border-top: 1px solid var(--line); padding-top: 18px; font-size: 11px; color: var(--muted); line-height: 1.8; }
.workflow-note .icon { width: 14px; height: 14px; margin-top: 2px; }
.data-note { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 11px; margin-top: 22px; }
.data-note > .icon { width: 13px; height: 13px; }

/* Tables, badges and empty states. */
.table-scroll { overflow-x: auto; position: relative; }
.data-table { width: 100%; border-collapse: collapse; text-align: left; }
.data-table th { font-size: 11px; font-weight: 550; color: var(--muted); background: var(--bg); padding: 14px 18px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.data-table td { padding: 17px 18px; border-bottom: 1px solid var(--line); font-size: 12px; vertical-align: middle; }
.data-table td:first-child, .data-table th:first-child { padding-left: 22px; }
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: var(--bg); }
.ticket-cell { display: flex; align-items: center; gap: 11px; white-space: nowrap; }
.ticket-cell strong { font-size: 12px; font-weight: 600; }
.ticket-cell small { display: block; color: var(--muted); font-size: 11px; margin-top: 4px; }
.thumb-frame { background: var(--bg); width: 34px; height: 42px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 5px; flex: 0 0 auto; padding: 4px; }
.thumb-frame img { max-height: 100%; object-fit: contain; }
.date-cell { color: var(--muted); white-space: nowrap; font-size: 11px !important; font-variant-numeric: tabular-nums; }
.table-arrow { color: var(--sage-text); display: inline-grid; place-items: center; width: 30px; height: 32px; border-radius: 6px; }
.table-arrow:hover { color: var(--petroleum); background: var(--mint); }
.table-arrow > .icon { width: 15px; }
.badge { display: inline-flex; align-items: center; gap: 5px; border: 1px solid transparent; border-radius: 5px; padding: 4px 8px; font-size: 11px; line-height: 1.5; font-weight: 550; white-space: nowrap; }
.badge-dot { width: 4px; height: 4px; background: currentColor; border-radius: 50%; }
.badge-success { background: var(--mint); color: var(--sage-text); border-color: var(--line); }
.badge-warning { background: var(--warning-bg); color: var(--warning); border-color: #EAE0C9; }
.badge-danger { background: var(--danger-bg); color: var(--danger); border-color: #F0DCD7; }
.badge-neutral { background: var(--bg); color: var(--muted); border-color: var(--line); }
.table-title { display: flex; align-items: center; gap: 12px; }
.section-icon { width: 35px; height: 35px; display: grid; place-items: center; background: var(--mint); color: var(--sage-text); border: 1px solid var(--line); border-radius: 8px; }
.pagination { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 18px 22px; font-size: 12px; color: var(--muted); border-top: 1px solid var(--line); }
.pagination > div { display: flex; gap: 8px; }
.empty-state { text-align: center; padding: 55px 28px; }
.empty-icon { display: grid; place-items: center; margin: 0 auto 17px; width: 60px; height: 60px; color: var(--sage-text); background: var(--mint); border: 1px solid var(--line); border-radius: 14px; }
.empty-icon > .icon { width: 26px; height: 26px; }
.empty-state h3 { font-size: 16px; margin-bottom: 8px; }
.empty-state > p { max-width: 350px; margin: auto; font-size: 13px; color: var(--muted); line-height: 1.8; }
.empty-hint { display: inline-flex; align-items: center; gap: 7px; font-size: 11px; color: var(--sage-text); margin-top: 23px; }
.empty-hint .icon { width: 14px; }

/* Receipt evidence and activity. */
.back-link { display: inline-flex; gap: 7px; align-items: center; font-size: 12px; color: var(--muted); margin-bottom: 20px; }
.back-link > .icon { width: 15px; }
.detail-grid { display: grid; grid-template-columns: minmax(0,1.4fr) minmax(300px,1fr); gap: 24px; align-items: start; }
.image-stage { min-height: 400px; padding: 34px; background: var(--bg); display: flex; align-items: flex-start; justify-content: center; }
.image-stage > a { display: block; }
.receipt-image { max-height: 680px; object-fit: contain; display: block; border: 1px solid var(--line); background: var(--surface); }
.file-type { font-size: 11px; color: var(--muted); }
.image-panel .section-footer { justify-content: center; }
@media (min-width: 1001px) {
 .detail-grid > .image-panel { position: sticky; top: 16px; display: grid; grid-template-rows: auto minmax(0,1fr) auto; height: calc(100dvh - 32px); max-height: 980px; }
 .image-panel .image-stage { min-height: 0; padding: 16px; }
 .image-panel .receipt-preview { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
 .image-panel .receipt-image { width: auto; height: auto; max-width: 100%; max-height: 100%; }
}
.detail-aside { display: grid; gap: 20px; }
.detail-card { padding: 23px; }
.detail-card h2 { font-size: 14px; margin-bottom: 22px; }
.status-list { margin: 0; }
.status-list > div { display: flex; justify-content: space-between; align-items: center; gap: 15px; margin: 17px 0; }
dt { font-size: 12px; color: var(--muted); }
dd { margin: 0; font-size: 12px; }
.soft-notice { display: flex; gap: 9px; background: var(--mint); color: var(--sage-text); padding: 17px; border-radius: 8px; margin-top: 23px; }
.soft-notice .icon { width: 16px; height: 16px; margin-top: 2px; }
.soft-notice strong { color: var(--ink); font-size: 12px; }
.soft-notice p { font-size: 12px; line-height: 1.8; margin-top: 5px; }
.metadata-list { display: grid; gap: 15px; margin: 0; }
.metadata-list dd { margin-top: 4px; color: var(--ink); overflow-wrap: anywhere; }
.mono { font-family: ui-monospace, SFMono-Regular, monospace; font-size: 11px; }
.hash-details { margin-top: 22px; padding-top: 17px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; }
.hash-details summary { cursor: pointer; }
.hash-details code { display: block; margin-top: 10px; overflow-wrap: anywhere; }
.history-panel { margin-top: 24px; }
.timeline { padding: 26px; margin: 0; list-style: none; }
.timeline > li { display: grid; grid-template-columns: 29px minmax(0,1fr); gap: 15px; position: relative; padding-bottom: 26px; }
.timeline > li:last-child { padding-bottom: 0; }
.timeline > li:not(:last-child)::before { content: ""; position: absolute; left: 14px; top: 31px; bottom: 4px; width: 1px; background: var(--line); }
.timeline-marker { width: 29px; height: 29px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--mint); color: var(--sage-text); border-radius: 50%; }
.timeline-marker .icon { width: 13px; }
.event-heading { display: flex; justify-content: space-between; gap: 20px; padding-top: 4px; }
.event-heading h3 { font-size: 12px; }
.event-heading time { font-size: 11px; color: var(--muted); flex-shrink: 0; }
.timeline li p { color: var(--muted); font-size: 12px; margin-top: 7px; overflow-wrap: anywhere; }

/* Capture inbox and actions. */
.capture-info { display: flex; align-items: center; gap: 10px; color: var(--sage-text); background: var(--mint); border: 1px solid var(--line); border-radius: 10px; padding: 16px 18px; margin-bottom: 23px; font-size: 12px; }
.capture-info > .icon { width: 16px; }
.capture-list { display: grid; gap: 18px; }
.capture-card-header { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 22px 24px; }
.capture-title { display: flex; align-items: center; gap: 14px; }
.capture-title h2 { font-size: 13px; }
.capture-title p { font-size: 11px; color: var(--muted); margin-top: 5px; }
.inline-dot { padding: 0 7px; color: #b8c1c3; }
.capture-icon { width: 39px; height: 39px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 10px; color: var(--sage-text); background: var(--mint); }
.capture-icon.warning { color: var(--warning); border-color: #EAE0C9; background: var(--warning-bg); }
.capture-icon.danger { color: var(--danger); background: var(--danger-bg); border-color: #F0DCD7; }
.capture-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 17px 24px; border-top: 1px solid var(--line); background: var(--surface); }
.source-label { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; }
.source-label .icon { width: 13px; }
.capture-card-footer > div { display: flex; align-items: center; gap: 16px; }
.duplicate-review { background: var(--warning-bg); border: 1px solid #EAE0C9; margin: 0 24px 20px; padding: 18px; border-radius: 10px; }
.duplicate-review > div { display: flex; align-items: flex-start; gap: 10px; color: var(--warning); }
.duplicate-review > div > .icon { width: 16px; margin-top: 2px; }
.duplicate-review strong { color: var(--warning); font-size: 12px; font-weight: 600; }
.duplicate-review p { font-size: 12px; line-height: 1.8; color: #756649; margin-top: 5px; }
.duplicate-review form { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 15px; border-top: 1px solid #eee7d7; padding-top: 14px; }
.checkbox-label { display: flex; align-items: flex-start; gap: 9px; font-size: 12px; color: #756649; cursor: pointer; }
.checkbox-label input { margin: 1px 0 0; }
.alert { display: flex; align-items: flex-start; gap: 10px; border-radius: 8px; padding: 13px 16px; font-size: 12px; line-height: 1.7; }
.alert > .icon { width: 16px; margin-top: 2px; }
.alert-danger { color: var(--danger); border: 1px solid #F0DCD7; background: var(--danger-bg); }
.alert-warning { color: var(--warning); border: 1px solid #EAE0C9; background: var(--warning-bg); }
.capture-card > .alert { margin: 0 24px 18px; }

/* Login. */
.login-page { display: grid; grid-template-columns: 1fr 1fr; min-height: 100dvh; background: #fff; }
.login-story { display: flex; flex-direction: column; background: var(--petroleum); color: #fff; padding: 50px 65px 30px; position: relative; overflow: hidden; }
.login-story .brand { padding: 0; }
.login-story-content { margin: auto 0; padding: 65px 0 30px; position: relative; z-index: 1; }
.story-tag { color: var(--on-dark-muted); font-size: 11px; letter-spacing: 1.5px; }
.login-story h1 { font-size: clamp(38px,4vw,64px); line-height: 1.15; letter-spacing: -2.2px; margin-top: 20px; font-weight: 500; }
.login-story-content > p { color: var(--on-dark-muted); max-width: 340px; font-size: 15px; line-height: 1.9; margin-top: 25px; }
.story-footer { font-size: 11px; color: var(--on-dark-muted); }
.login-form-area { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 55px 45px 25px; }
.login-card { width: 100%; max-width: 355px; margin: auto; }
.login-lock { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; color: var(--sage-text); margin-bottom: 28px; }.login-lock .icon { width: 15px; }
.login-card h2 { font-size: 29px; letter-spacing: -1px; font-weight: 600; }
.login-card > p { margin-top: 9px; font-size: 13px; color: var(--muted); }
.login-form { margin-top: 30px; }
.login-form label { display: block; color: var(--ink); font-size: 13px; font-weight: 550; margin: 19px 0 8px; }
.login-submit { width: 100%; margin-top: 27px; padding: 13px; justify-content: space-between; }
.login-note { display: flex; gap: 8px; align-items: flex-start; color: var(--muted); font-size: 11px; line-height: 1.9; border-top: 1px solid var(--line); margin-top: 28px; padding-top: 20px; }
.login-note .icon { width: 13px; height: 13px; margin-top: 3px; }
.login-card .alert { margin-top: 20px; }
.login-footer { padding-top: 35px; font-size: 11px; color: var(--muted); }

@media (min-width: 1600px) { .main-content { padding-top: 45px; } .metric-card { padding: 24px; } .overview-columns { grid-template-columns: minmax(0,1fr) 310px; } }
@media (max-width: 1250px) { .overview-columns { grid-template-columns: minmax(0,1fr); } .workflow-card { display: none; } .metric-card { padding: 16px; } .main-content { padding: 28px; } .topbar { padding: 0 28px; } .metrics-grid { gap: 12px; } .metric-card p { line-height: 1.7; } .detail-grid { grid-template-columns: minmax(0,1fr) 300px; gap: 18px; } }
@media (max-width: 1000px) { .sidebar { width: 215px; padding-left: 13px; padding-right: 13px; } .app-main { margin-left: 215px; } .metrics-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } .page-heading { align-items: flex-start; } .page-heading > .button { margin-top: 20px; } .capture-banner { flex-wrap: wrap; } .capture-banner .button { margin-left: 65px; } .detail-grid { grid-template-columns: 1fr; } .detail-aside { grid-template-columns: 1fr 1fr; } .duplicate-review form { align-items: flex-start; flex-direction: column; } .login-story { padding: 40px; } }
@media (max-width: 760px) {
 .sidebar { width: 244px; transform: translateX(-100%); visibility: hidden; transition: transform .2s ease; }.sidebar.is-open { transform: translateX(0); visibility: visible; }
 .sidebar-overlay { display: block; position: fixed; inset: 0; z-index: 25; width: 100%; border-radius: 0; background: #203B4A66; }
 .app-main { margin-left: 0; }.menu-button { display: inline-grid; place-items: center; }.topbar { height: 61px; padding: 0 18px; }.topbar-title { gap: 9px; }.topbar-title > span:first-of-type, .breadcrumb-divider { display: none; }
 .main-content { padding: 25px 18px; }.app-footer { margin: 0 18px; flex-wrap: wrap; font-size: 11px; }
 .page-heading { flex-direction: column; gap: 16px; margin-bottom: 23px; }.page-heading > .button { margin-top: 0; }h1 { font-size: 28px; }.page-description { font-size: 12px; }
 .metrics-grid { gap: 10px; }.metric-top { font-size: 12px; }.metric-icon { width: 27px; height: 27px; }.metric-value { font-size: 30px; }.metric-card { padding: 15px; }.metric-card p { font-size: 11px; }
 .capture-banner { padding: 18px; gap: 12px; }.capture-banner > div:nth-child(2) { flex: 1 1 calc(100% - 58px); }.capture-banner h2 { font-size: 13px; }.capture-banner p { line-height: 1.7; }.capture-banner .button { margin-left: 58px; }
 .section-heading { padding: 19px 16px; }.section-heading > .live-label { display: none; }.section-heading p { max-width: 230px; }.section-footer { padding: 13px 16px; }.section-footer > span:last-child:not(:first-child) { display: none; }
 .data-table td, .data-table th { padding-left: 13px; padding-right: 13px; }.data-table td:first-child, .data-table th:first-child { padding-left: 16px; }.data-table { min-width: 580px; }.recent-section .data-table { min-width: 540px; }
 .detail-aside { grid-template-columns: 1fr; }.image-stage { padding: 25px; min-height: 300px; }.file-type { font-size: 11px; }.image-panel h2 { font-size: 13px; }.image-panel .section-icon { display: none; }
 .event-heading { flex-direction: column; gap: 5px; }.timeline { padding: 20px; }
 .capture-card-header { padding: 18px; align-items: flex-start; flex-wrap: wrap; }.capture-title { gap: 10px; }.capture-title p { font-size: 11px; }.capture-title h2 { font-size: 13px; }
 .duplicate-review { margin: 0 18px 18px; padding: 15px; }.capture-card-footer { padding: 15px 18px; flex-wrap: wrap; }.capture-card > .alert { margin: 0 18px 18px; }.capture-card-footer > div { flex-wrap: wrap; }.pagination { padding: 16px 12px; font-size: 11px; }.empty-state { padding: 38px 23px; }
 .login-page { grid-template-columns: 1fr; }.login-story { padding: 25px; }.login-story-content, .story-footer { display: none; }.login-form-area { padding: 45px 25px 25px; }.login-lock { margin-bottom: 22px; }.login-card h2 { font-size: 27px; }.login-card { max-width: 390px; }.login-footer { margin-top: 25px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }
