:root {
  color-scheme: light;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  line-height: 1.55;
  color: #203334;
  background: #f4f5f1;
  --ink: #203334;
  --muted: #546965;
  --line: #d1dcd5;
  --paper: #fff;
  --accent: #176e61;
  --mint: #a0e8d2;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select, textarea { font: inherit; }
button, a { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .55; }
button, input, select, textarea { max-width: 100%; min-width: 0; }
a { color: #17685e; text-underline-offset: 4px; }
a, button, p, dd, strong, small, h1, h2, h3 { overflow-wrap: anywhere; }
:focus-visible { outline: 3px solid #127e70; outline-offset: 4px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.8rem, 2.6vw, 2.6rem); font-weight: 650; letter-spacing: -.05em; line-height: 1.15; }
h2 { font-size: 1.1rem; letter-spacing: -.025em; line-height: 1.35; font-weight: 650; }
h3 { font-size: 1rem; font-weight: 600; line-height: 1.4; }
[hidden] { display: none !important; }
.skip { position: fixed; top: 10px; left: 10px; z-index: 30; background: #fff; padding: 14px 18px; border: 1px solid var(--line); transform: translateY(-180%); }
.skip:focus { transform: none; }
.masthead { min-height: 94px; padding: 20px max(28px, calc((100vw - 1416px) / 2)); background: #fff; display: flex; align-items: center; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 13px; min-height: 44px; color: var(--ink); text-decoration: none; font-size: 1.85rem; font-weight: 850; font-style: italic; letter-spacing: -.075em; }
.brand-caption { font-size: .66rem; letter-spacing: .13em; margin-left: 15px; padding-left: 22px; border-left: 1px solid #afc2b8; font-style: normal; font-weight: 600; color: var(--muted); }
.brand-mark { position: relative; display: block; width: 28px; height: 26px; border-top: 6px solid #256c60; border-bottom: 6px solid #256c60; transform: skewX(-16deg); }
.brand-mark::before { content: ""; position: absolute; top: 4px; left: 5px; width: 22px; border-top: 6px solid #256c60; }
.local-label { color: #536961; font-size: .68rem; letter-spacing: .08em; font-weight: 600; }
#navigation { padding: 0 max(28px, calc((100vw - 1416px) / 2)); min-height: 61px; background: #fff; display: flex; gap: 6px; align-items: stretch; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
#navigation a { min-height: 52px; display: inline-flex; align-items: center; padding: 11px 13px; font-size: .77rem; text-decoration: none; color: #50695f; border-bottom: 3px solid transparent; }
#navigation a:hover { color: #143e32; background: #f2f7f2; }
#navigation a[aria-current=page] { border-bottom-color: #1b7563; color: #173c31; font-weight: 650; }
#menu-button { display: none; min-height: 44px; min-width: 68px; background: #eef5ee; color: var(--ink); border: 1px solid #abc2b3; padding: 10px 14px; border-radius: 5px; font-size: .8rem; }
.storage-status { padding: 11px max(28px, calc((100vw - 1416px) / 2)); background: #eaf4e9; border-bottom: 1px solid #c9deca; color: #375e42; font-size: .73rem; }
.storage-status.warning { background: #e4f0f3; color: #284c5a; border-color: #bad1d7; }
main { max-width: 1472px; margin: auto; padding: 34px 28px 28px; outline: none; }
#screen { display: grid; gap: 22px; min-width: 0; }
#notice { padding: 14px 18px; border-left: 3px solid #218674; margin-bottom: 20px; background: #e3f3ed; font-size: .8rem; line-height: 1.75; color: #244e40; }
#notice:empty { display: none; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; margin-bottom: 2px; }
.page-heading > div:first-child { max-width: 790px; min-width: 0; }
.page-heading > .actions { padding-top: 26px; justify-content: flex-end; }
.eyebrow { color: #587265; font-size: .67rem; font-weight: 650; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 11px; }
.muted { color: var(--muted); font-size: .8rem; line-height: 1.75; }
.page-heading .muted { margin-top: 12px; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.button { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; padding: 11px 16px; border: 1px solid transparent; border-radius: 5px; font-size: .78rem; font-weight: 650; line-height: 1.4; text-decoration: none; text-align: center; }
.primary { background: #1b6f5d; color: #fff; border-color: #135c4d; }
.primary:hover { background: #125943; }
.secondary { background: #fff; border-color: #a9bfb1; color: #295246; }
.secondary:hover { background: #e7f3e8; }
.quiet { background: transparent; color: #426156; text-decoration: underline; text-underline-offset: 4px; }
.quiet:hover { color: #152f26; }
.text-link, .back-link { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; font-size: .78rem; font-weight: 550; }
.back-link { justify-self: start; }
.panel { min-width: 0; padding: 25px; border: 1px solid var(--line); background: #fff; border-radius: 8px; }
.panel > h2 { margin-bottom: 10px; }
.panel > .muted { margin-bottom: 16px; }
.panel > .actions { margin-top: 18px; }
.desk-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 22px; }
.timer-panel { background: #172e2d; color: #f2f8f3; border-color: #172e2d; padding: 29px; position: relative; overflow: hidden; }
.timer-panel::before { content: ""; position: absolute; inset: 0 0 auto; height: 4px; background: repeating-linear-gradient(90deg, #92d3c2 0 2px, transparent 2px 30px); opacity: .65; }
.timer-panel h2 { color: #d2e7df; }
.timer-panel .muted, .timer-panel .field > small { color: #bcd1c7; }
.timer-panel .field label { color: #e7f1ea; }
.timer-panel .quiet { color: #d6e9dc; }
.timer-panel > h3 { font-size: 1.05rem; margin-bottom: 12px; }
.timer-panel .primary { background: #b1ead1; border-color: #b1ead1; color: #15382a; }
.timer-panel .primary:hover { background: #cff5dc; }
.timer-panel .secondary { background: #fff; color: #203e30; border-color: #fff; }
.timer-state { margin-top: 14px; color: #b9eed8 !important; background: #23483f !important; border-color: #4b7b68 !important; }
.clock { font-family: ui-monospace, "Cascadia Mono", "DejaVu Sans Mono", monospace; font-variant-numeric: tabular-nums; font-size: clamp(2.2rem, 5.5vw, 4.2rem); font-weight: 500; letter-spacing: -.065em; color: #bcebd6; padding: 17px 0 19px; line-height: 1.2; overflow-wrap: anywhere; }
.timer-panel > .actions { margin: 24px 0; }
.timer-start-form { padding: 0 !important; border: 0 !important; background: transparent !important; margin-top: 24px; }
.timer-start-form > .button { justify-self: start; }
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); background: #fff; border-radius: 6px; margin: 0; }
.facts > div { padding: 18px; min-width: 0; border-right: 1px solid var(--line); }
.facts > div:last-child { border-right: 0; }
.facts dt { color: var(--muted); font-size: .72rem; }
.facts dd { margin: 7px 0 0; color: #254e40; font-size: .91rem; font-weight: 650; font-variant-numeric: tabular-nums; }
.totals { display: grid; gap: 18px; margin: 19px 0; min-width: 0; }
.desk-grid .totals .facts { grid-template-columns: 1fr; border: 0; }
.desk-grid .totals .facts > div { padding: 14px 0; border: 0; border-bottom: 1px solid var(--line); display: flex; align-items: baseline; gap: 15px; justify-content: space-between; }
.desk-grid .totals .facts dd { font-size: 1.45rem; margin: 0; }
.currency-totals { padding: 15px 0 0; border-top: 1px solid var(--line); }
.currency-totals > p:not(.muted) { font-size: 1.1rem; font-weight: 600; color: #285b46; font-variant-numeric: tabular-nums; margin-bottom: 7px; }
.currency-totals > .muted { font-size: .73rem; line-height: 1.8; }
.week-chart { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 16px; margin: 29px 0 24px; min-width: 0; }
.day-bar { display: flex; flex-direction: column; align-items: center; gap: 12px; min-width: 0; }
.day-label { min-width: 44px; display: inline-flex; align-items: center; justify-content: center; min-height: 44px; font-size: .78rem; font-weight: 550; }
.day-track { display: flex; align-items: flex-end; height: 150px; width: 32px; max-width: 100%; background: repeating-linear-gradient(0deg, #ecf2ec 0 1px, transparent 1px 30px), #f3f6f1; border-bottom: 1px solid #8aac9b; }
.day-track i { display: block; width: 100%; height: var(--level, 0%); background: #2c8e77; border-radius: 3px 3px 0 0; }
.day-bar > span { font-family: ui-monospace, monospace; color: #4b6757; font-size: .76rem; text-align: center; }
.empty { padding: 27px; border: 1px dashed #a8bfb1; background: #fff; border-radius: 7px; min-width: 0; }
.empty h2 { font-size: 1.2rem; margin-bottom: 12px; }
.empty .actions { margin-top: 20px; }
.empty-line { width: 47px; height: 7px; border-top: 2px solid #3d8d71; border-bottom: 2px solid #a9cbbb; margin: 0 0 22px; transform: skewX(-22deg); }
.record-list { display: grid; gap: 13px; margin-top: 18px; }
.entity-card { padding: 18px 20px; border: 1px solid var(--line); border-radius: 6px; background: #fff; min-width: 0; }
.entity-card .muted { font-size: .77rem; margin: 6px 0; }
.record-link { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; font-size: .9rem; font-weight: 600; color: #1d493a; text-decoration-color: #b2cdbd; }
.badge { display: inline-flex; align-items: center; border: 1px solid #cad6d3; background: #edf2ed; color: #4d665c; border-radius: 3px; padding: 3px 7px; font-size: .7rem; margin-left: 7px; line-height: 1.5; }
.badge.reviewed { color: #23603d; background: #e4f5e6; border-color: #bdddbd; }
.entry-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(160px, .4fr); align-items: start; gap: 20px; padding: 17px 20px; border: 1px solid var(--line); border-radius: 6px; background: #fff; min-width: 0; }
.entry-row .muted { font-size: .74rem; margin-top: 5px; }
.entry-amount { display: flex; align-items: flex-end; flex-direction: column; gap: 7px; padding-top: 10px; text-align: right; }
.entry-amount > strong { font-family: ui-monospace, monospace; font-size: 1.25rem; font-weight: 550; letter-spacing: -.04em; }
.entry-amount > span:not(.badge) { color: #4d6657; font-size: .76rem; }
.filters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; align-items: start; margin: 18px 0 22px; }
.field { display: grid; align-content: start; gap: 7px; min-width: 0; }
.field label { color: #2e4d3f; font-size: .77rem; font-weight: 600; line-height: 1.5; }
.field input, .field select, .field textarea { min-width: 0; width: 100%; min-height: 44px; border: 1px solid #a2b8a9; border-radius: 4px; padding: 11px 12px; color: #213f31; background: #fff; font-size: .85rem; line-height: 1.5; }
.field textarea { resize: vertical; min-height: 130px; }
.field input[type=checkbox] { width: 44px; height: 44px; accent-color: #246d50; cursor: pointer; padding: 0; }
.field input[type=file] { padding: 8px; font-size: .75rem; }
.field input[type=file]::file-selector-button { min-height: 44px; padding: 9px; border: 1px solid #a2b8a9; border-radius: 3px; color: var(--ink); background: #ecf3eb; font: inherit; margin-right: 10px; }
.field > small { font-size: .72rem; line-height: 1.75; color: var(--muted); }
.field > small:empty { display: none; }
.field [aria-invalid=true] { border: 2px solid #a12e2b; }
.field-error, .form-error { color: #a12e2b; font-size: .78rem; line-height: 1.75; }
.field-error:empty, .form-error:empty { display: none; }
.form-error { background: #fff0ed; border-left: 3px solid #b64e44; padding: 12px 15px; }
.editor { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; max-width: 1040px; min-width: 0; }
.editor > .field:has(textarea), .editor > .form-error, .editor > .button { grid-column: 1 / -1; }
.editor > .button { justify-self: start; }
.interval { color: #31523d; font-family: ui-monospace, monospace; font-size: .8rem; margin-top: 20px; line-height: 1.8; }
.history-row { padding: 16px 0; border-bottom: 1px solid var(--line); font-size: .85rem; }
.history-row .muted { font-size: .73rem; margin-top: 6px; }
.print-sheet { min-width: 0; }
.print-sheet > h2 { font-size: 1.4rem; margin-bottom: 10px; }
.print-sheet > h3 { margin-top: 27px; }
.print-only { display: none; }
footer { max-width: 1472px; margin: 0 auto; padding: 24px 28px 32px; border-top: 1px solid var(--line); color: #5a6c60; font-size: .73rem; line-height: 1.85; }
footer strong { font-weight: 600; }
footer button { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 0; color: #1d6650; font-size: .73rem; background: transparent; border: 0; text-decoration: underline; text-underline-offset: 4px; margin-left: 12px; }
.fallback { padding: 28px; background: white; border: 1px solid var(--line); border-radius: 7px; }
.fallback p { margin-top: 18px; font-size: .9rem; line-height: 1.9; color: var(--muted); }
@media (min-width: 1600px) {
  .timer-panel { padding: 34px; }
  .clock { font-size: 4.5rem; }
}
@media (max-width: 1100px) {
  .brand-caption { display: none; }
  .desk-grid { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); }
  .page-heading { flex-wrap: wrap; }
  .page-heading > .actions { padding-top: 0; justify-content: flex-start; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts > div { border-bottom: 1px solid var(--line); }
  .facts > div:nth-child(even) { border-right: 0; }
}
@media (max-width: 800px) {
  .masthead { padding: 16px 23px; min-height: 78px; }
  .local-label { display: none; }
  #navigation { padding: 6px 20px; gap: 2px; min-height: 0; }
  #navigation a { min-height: 44px; border-bottom-width: 2px; }
  body.app-ready #menu-button { display: block; }
  body.app-ready #navigation { display: none; }
  body.app-ready.menu-open #navigation { display: flex; }
  .storage-status { padding: 11px 23px; }
  main { padding: 27px 23px 24px; }
  .desk-grid { grid-template-columns: 1fr; }
  .desk-grid .totals .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 15px; }
  .desk-grid .totals .facts > div { display: block; padding: 4px 0 14px; }
  .desk-grid .totals .facts dd { margin-top: 9px; font-size: 1.25rem; }
  .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .week-chart { gap: 9px; }
}
@media (max-width: 600px) {
  .masthead { padding-inline: 19px; }
  .brand { font-size: 1.65rem; }
  .brand-mark { transform: scale(.85) skewX(-16deg); }
  .storage-status { padding-inline: 19px; font-size: .73rem; }
  main { padding: 25px 19px 20px; }
  #screen { gap: 18px; }
  .page-heading > .actions { margin-top: 20px; }
  .page-heading { display: block; }
  .eyebrow { font-size: .65rem; }
  .panel, .timer-panel { padding: 21px; }
  .timer-panel > .actions .button { flex: 1 1 auto; }
  .editor { grid-template-columns: 1fr; gap: 20px; }
  .editor > * { grid-column: 1 / -1; }
  .desk-grid .totals .facts { grid-template-columns: 1fr; gap: 0; }
  .desk-grid .totals .facts > div { display: flex; padding: 13px 0; }
  .entry-row { grid-template-columns: 1fr; gap: 12px; padding: 17px; }
  .entry-amount { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 10px; text-align: left; padding-top: 0; }
  .entry-amount > strong { font-size: 1.1rem; }
  .entry-amount .badge { margin-left: 0; }
  .week-chart { grid-template-columns: 1fr; margin-top: 20px; gap: 8px; }
  .day-bar { display: grid; grid-template-columns: minmax(38px, .6fr) minmax(0, 1.8fr) minmax(73px, 1fr); gap: 12px; align-items: center; }
  .day-track { width: 100%; height: 12px; border: 0; background: #eaf1e9; align-items: stretch; }
  .day-track i { width: var(--level, 0%); height: 100%; border-radius: 2px; }
  .day-label { justify-content: flex-start; }
  .day-bar > span { text-align: right; font-size: .75rem; }
  .facts > div { padding: 15px; }
  .facts dd { font-size: .85rem; }
  .entity-card { padding: 16px; }
  footer { padding: 20px 19px 25px; }
  footer button { display: flex; margin: 8px 0 0; }
  .badge { font-size: .7rem; }
}
@media (max-width: 420px) {
  .filters { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; }
  .facts > div { border-right: 0; }
  .facts > div:last-child { border-bottom: 0; }
  .actions > .button { flex: 1 1 auto; }
  .day-bar { grid-template-columns: minmax(0, .7fr) minmax(0, 1.4fr) minmax(0, 1.3fr); }
  .clock { font-size: 2.6rem; }
  .timer-panel { padding: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media print {
  @page { margin: 14mm; }
  body { color: black; background: white; font-size: 11pt; }
  .masthead, #navigation, .storage-status, #notice, footer, .skip, .screen-only, .actions, .button, .back-link, #screen > :not(.print-sheet) { display: none !important; }
  main { padding: 0; max-width: none; }
  #screen { display: block; }
  .print-sheet { display: block !important; padding: 0; border: 0; background: white; }
  .print-only { display: table; border-collapse: collapse; width: 100%; margin-top: 20px; font-size: 8pt; table-layout: fixed; }
  .print-only th, .print-only td { text-align: left; vertical-align: top; padding: 7px 4px; border-bottom: 1px solid #aaa; overflow-wrap: anywhere; }
  .print-only caption { text-align: left; font-weight: bold; margin-bottom: 10px; }
  .print-only tr, .facts { break-inside: avoid; }
  .facts, .panel { border-color: #aaa; }
  .muted, .facts dt, .facts dd, .currency-totals > p:not(.muted) { color: black; }
  .text-link { color: black; }
}

/* A timing instrument beside a dated source ledger, rather than an empty activity chart. */
.instrument-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.2fr);gap:24px;align-items:start;}
.instrument-layout .timer-panel{border-radius:0;border-top:5px solid #628f82;box-shadow:0 14px 35px #18362c12;}
.instrument-layout .clock{font-size:clamp(2.4rem,5vw,4.8rem);font-variant-numeric:tabular-nums;letter-spacing:-.04em;border-block:1px solid #74958c;padding:22px 0;margin:18px 0;}
.work-quote{font-size:.9rem;line-height:1.7;padding:16px;border:1px solid #638b80;background:#24443f;color:#eaf9f1;margin:16px 0;}
.day-journal{border-radius:0;background:#fffef8;}
.day-journal>.field{max-width:280px;margin:20px 0;}
.time-timeline{list-style:none;padding:0;margin:24px 0 0;}
.time-timeline>li{border-top:1px solid #afc3b8;padding:18px 0;}
.time-stamp{font-family:ui-monospace,monospace;font-size:.9rem;letter-spacing:.02em;margin-bottom:10px;}
.time-timeline .entry-row{border:0;padding:0;box-shadow:none;background:transparent;}
.repeat-work-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px;margin-top:24px;}
.repeat-work{padding:20px;border-left:2px solid #6f9485;background:#f2f5f0;min-width:0;display:grid;gap:12px;}
.repeat-work h3{font-size:1.05rem;}
@media(max-width:1100px){.instrument-layout{grid-template-columns:1fr;}.repeat-work-grid{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:560px){.repeat-work-grid{grid-template-columns:1fr;}.time-timeline .entry-row{display:block;}.time-timeline .entry-amount{text-align:left;margin-top:16px;}.instrument-layout .clock{font-size:2.8rem;}.work-quote{padding:12px;}}
