@font-face {
  font-family: "DM Sans";
  src: url("/keeper-brand/dm-sans.woff2") format("woff2");
  font-weight: 100 1000;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Condensed";
  src: url("/keeper-brand/barlow-condensed-black.woff2") format("woff2");
  font-weight: 900;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("/keeper-brand/ibm-plex-mono.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
:root {
  --body: "DM Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --serif: Georgia, serif;
  --ink: #1a171a;
  --cream: #f4ede0;
  --paper: #f2ebdd;
  --cobalt: #5033c8;
  --blue: #5336cf;
  --blue-deep: #3e299e;
  --blue-wash: #e5dff8;
  --panel: #f8f1e5;
  --rule: #cdc2b2;
  --dt-coal: #171416;
  --dt-vermilion: #ff5b31;
  --dt-violet: #7152ff;
  --dt-sulfur: #d7f665;
}
:root[data-theme="dark"] {
  --ink: #f2ebdd;
  --muted: #c2b9bc;
  --cream: #171416;
  --rule: #4c4346;
  --cobalt: #bdadff;
}
body[data-pane] {
  --index-ink: #943324;
  --rail-paper: #e3dac9;
  --list-paper: #ebe2d2;
  --house-stock: url("/keeper-brand/paper-grain.webp");
  --ink-ribbon: url("/keeper-brand/ink-ribbon.webp");
  font-family: var(--body);
}
:root[data-theme="dark"] body[data-pane] {
  --index-ink: #ff997c;
  --rail-paper: #242023;
  --list-paper: #2b2529;
  --house-stock: none;
}
body[data-pane] .mast {
  color: #f2ebdd;
  background: var(--dt-coal);
  border: 0;
}
body[data-pane] .mast::after, .nb-desk .nd-cover::before {
  background-image: var(--ink-ribbon);
  background-size: max(720px,105%) auto;
  background-repeat: repeat-x;
  animation: keeper-print-drift 24s ease-in-out infinite alternate;
}
body[data-pane] .mast::after { height: 5px; bottom: 0; }
@keyframes keeper-print-drift {
  from { background-position: 15% 37%; }
  to { background-position: 82% 63%; }
}
body[data-pane] .product-mark {width: 38px; height: 38px}
body[data-pane] .product-name img {display: block; height: 31px; width: auto; max-width: 110px}
body[data-pane] .byline {color: #e0d8d0; font: 9px/1 var(--mono)}
body[data-pane] .byline img {width: auto; height: 12px}
body[data-pane] .mast-actions :is(a,button,.theme-picker,select) {color: #f2ebdd}
body[data-pane] .mast-actions select option {color: var(--ink)}
body[data-pane] .mast-actions button:hover,
body[data-pane] .mast-actions a:hover {background: #373039}
body[data-pane] .mast-actions #session-clock {color: #d7f665}
body[data-pane] .rail {
  color: var(--ink);
  background: var(--rail-paper);
  border-right: 1px solid var(--rule);
}
body[data-pane] .rail::before {content: none}
body[data-pane] .rail h1, body[data-pane] #list-title, body[data-pane] .dialog-head h2,
body[data-pane] .note-title, body[data-pane] #reference-title,
.nb-desk :is(.nd-title,.nd-next,.nd-section-title), .nts-dialog .nts-goal {
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -.012em;
}
body[data-pane] .rail :is(.side-item,.side-item i,.count,.end) {color: var(--ink)}
body[data-pane] .rail :is(.taxonomy h2,.side-item[data-filter="logs"] i) {color: var(--index-ink)}
body[data-pane] .rail .side-item {border-radius: 0}
body[data-pane] .rail .side-item:hover {background: color-mix(in srgb, var(--rail-paper),var(--ink) 10%)}
body[data-pane] .rail .side-item.active,
body[data-pane] .rail .side-item.active :is(i,.count,.end) {
  background: var(--dt-coal);
  color: #f2ebdd;
  box-shadow: none;
}
body[data-pane] .rail .side-item.active {box-shadow: inset 3px 0 var(--dt-sulfur)}
body[data-pane] .new-note {background: var(--dt-coal); color: #f2ebdd; border-radius: 0}
body[data-pane] .new-note:hover {background: #3d303b}
body[data-pane] .rail :is(a,button):focus-visible {outline: 2px solid var(--cobalt); outline-offset: 2px}
body[data-pane] .mast :is(a,button,select):focus-visible {outline: 2px solid #d7f665; outline-offset: 2px}

body[data-pane] .library {background: var(--list-paper)}
body[data-pane] .sheet, body[data-pane] .nb-desk, body[data-pane] .nts-dialog {
  background-color: var(--cream);
  background-image: var(--house-stock);
  background-size: 290px auto;
}
body[data-pane] .note-row[aria-current=true] {
  border-radius: 0;
  background: var(--dt-coal);
  color: #f2ebdd;
  border-color: var(--dt-coal);
  box-shadow: inset 3px 0 var(--dt-sulfur);
}
body[data-pane] .note-row[aria-current=true] :is(.row-preview,.row-meta,.row-title i) { color: #ded4ca; }
body[data-pane] .writing-surface {padding-top: clamp(24px,3vw,48px)}
body[data-pane] .note-title {font-size: clamp(2.55rem,4.6vw,4.65rem);line-height: 1.05}
body[data-pane] .sheet-folder {color: var(--index-ink);font: 600 .72rem/1.3 var(--mono)}
body[data-pane] .connections h3 {font: 600 .73rem/1.45 var(--mono);color:var(--index-ink);text-transform:uppercase}
.keeper-session-entry {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: .7rem 1rem;
  flex-wrap:wrap;
  padding-block:1.1rem;
  margin-top:1.2rem;
  border-top:1px solid var(--rule);
}
.keeper-session-entry img {width:145px;height:auto}
.keeper-session-entry img, .nts-head .nts-signature {filter: brightness(0.1)}
[data-theme="dark"] :is(.keeper-session-entry img,.nts-head .nts-signature) {filter:none}
.keeper-session-entry button {color:var(--cobalt);text-align:start;min-height:38px;text-decoration:underline;text-underline-offset:.22em;font-weight:600}
body.focus-mode .keeper-session-entry {display:none}

body[data-pane] .nb-desk {--nd-ink:var(--ink);--nd-paper:var(--cream);--nd-accent:var(--cobalt);--nd-muted:var(--muted);--nd-rule:var(--rule)}
.nb-desk .nd-cover {
  min-height: clamp(130px,13vw,180px);
  color:#f2ebdd;
  background:var(--dt-coal);
  padding-bottom:clamp(42px,4vw,54px);
}
.nb-desk .nd-cover::before {
  inset:auto 0 0;
  height:clamp(18px,2.5vw,34px);
  transform:none;
}
.nb-desk .nd-cover::after {content:none}
.nb-desk .nd-date {color:var(--dt-sulfur);font-weight:400}
.nb-desk .nd-title {font-size:clamp(3.8rem,6.4vw,6.2rem)}
.nb-desk .nd-kicker {color:var(--index-ink)}
.nb-desk .nd-primary, .nts-dialog .nts-btn.nts-primary {
  border-radius:0;
  background:var(--dt-coal);
  color:#f2ebdd;
  border:1px solid #615361;
  font-weight:600;
}
.nb-desk .nd-primary:hover,.nts-dialog .nts-btn.nts-primary:hover {background:#3c2f4f}
.nts-dialog .nts-head {padding-bottom:1rem;border-bottom:1px solid var(--rule)}
.nts-head .nts-signature {display:block;width:min(184px,46vw);height:auto}
.nts-dialog .nts-field>span,.nts-dialog .nts-length legend {color:var(--index-ink)}
.nts-dialog .nts-clock {
  background:var(--dt-coal);
  border-radius:0;
  border-bottom:6px solid var(--dt-violet);
}
.nts-dialog .nts-clock strong {font: 400 clamp(2.65rem,11vw,4.8rem)/1.12 var(--mono);letter-spacing:-.05em}
.keeper-house-name {display: block; width: 110px; height: auto; max-height: 40px; object-fit: contain}
.keeper-house-icon {display: block; width: 27px; height: auto; flex: none}

.practice-signature {background: linear-gradient(120deg, #171416 25%, #352460 60%, #753826); padding: 9%; object-fit: contain}
@media (max-width:540px) {
  body[data-pane] .product-name img {height: 23px}
  body[data-pane] .product-mark {width: 28px; height: 31px}
  .keeper-house-name {width: 86px}
}
@media (prefers-reduced-motion:reduce) {
  body[data-pane] .mast::after, .nb-desk .nd-cover::before {animation:none}
}
