
/* BrainBucket Studio interface (Joseph's 2026-09-23 Studio mockups). The four canonical
   BrainBucket Soft colors keep their exact values; everything else is a quiet neutral. */
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 400; font-display: swap; src: url("/fonts/figtree-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 500; font-display: swap; src: url("/fonts/figtree-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 600; font-display: swap; src: url("/fonts/figtree-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Instrument Serif"; font-style: normal; font-weight: 400; font-display: swap; src: url("/fonts/instrument-serif-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Instrument Serif"; font-style: italic; font-weight: 400; font-display: swap; src: url("/fonts/instrument-serif-latin-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Caveat"; font-style: normal; font-weight: 500; font-display: swap; src: url("/fonts/caveat-latin-500-normal.woff2") format("woff2"); }

:root {
  color-scheme: light;
  --ink: #101114;
  --paper: #F7F5EE;
  --lime: #C7FF3D;
  --neutral: #E7E4DC;
  --muted: #5F6066;
  --white: #FFFFFF;
  --danger: #B42318;

  --bb-card: #FFFFFF;
  --bb-sunk: #EFECE3;
  --bb-line: #E3DFD4;
  --bb-line-strong: #CFCABD;
  --bb-ink-2: #3A3B40;
  --bb-subtle: #6B6C71;
  --bb-avatar: #DCD6C6;
  --bb-lime-hover: #B8F52F;
  --bb-lime-pressed: #A6E51F;
  --bb-lime-ring: rgba(199, 255, 61, 0.55);
  --bb-mark: #E4FF9C;
  --bb-hand-ink: #45484C;

  --bb-font-sans: "Figtree", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
  --bb-font-display: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  /* Decorative handwriting only. */
  --bb-font-hand: "Caveat", "Bradley Hand", "Segoe Print", "Ink Free", "Noteworthy", cursive;
  --bb-font-mono: ui-monospace, "SF Mono", "SFMono-Regular", Menlo, Consolas, monospace;

  --radius-xl: 28px;
  --radius-lg: 24px;
  --radius-md: 20px;
  --radius-sm: 14px;
  --radius-pill: 999px;
  --bb-shadow-card: 0 1px 0 rgba(16, 17, 20, 0.03), 0 30px 60px -30px rgba(16, 17, 20, 0.22);
  --bb-shadow-float: 0 18px 40px -16px rgba(16, 17, 20, 0.3);
  --bb-shadow-original: 0 30px 70px -30px rgba(16, 17, 20, 0.35), 0 0 0 1px rgba(16, 17, 20, 0.06);

  --bb-topbar-height: 84px;
  --bb-content-max: 1312px;
  --bb-page-pad-x: clamp(20px, 4.45vw, 64px);
  --bb-duration-fast: 140ms;
  --bb-duration-ui: 180ms;
  --bb-ease-out: cubic-bezier(0.2, 0.8, 0.2, 1);
  font-family: var(--bb-font-sans);
  font-synthesis: none;
  background: var(--paper);
  color: var(--ink);
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--paper); scroll-behavior: smooth; scroll-padding-block: calc(var(--bb-topbar-height) + 16px) 24px; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: var(--paper); color: var(--ink); font-size: 1rem; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button, input, textarea { font: inherit; }
button { color: inherit; }
[hidden] { display: none !important; }
h1, h2, h3 { color: var(--ink); }

.bb-icon {
  width: 1.25rem;
  height: 1.25rem;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Instrument Serif carries the large human moments only (Joseph's typography decision). */
.bb-display-xl {
  margin: 0;
  font-family: var(--bb-font-display);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 40;
  transform: translateY(-180%);
  min-height: 44px;
  padding: 11px 18px;
  border-radius: var(--radius-pill);
  background: var(--lime);
  color: var(--ink);
  font-weight: 600;
}
.skip-link:focus { transform: translateY(0); }

.app-shell {
  position: relative;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  container-type: inline-size;
  container-name: app-shell;
  background: var(--paper);
}

/* Top bar: wordmark, one pill navigation, and a quiet status/account cluster. */
.app-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: var(--bb-topbar-height);
  padding: 0 40px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  background: rgba(247, 245, 238, 0.94);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
}
.wordmark {
  justify-self: start;
  min-width: 0;
  padding: 4px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 12px;
  text-decoration: none;
}
.brand-mark {
  display: block;
  width: auto;
  height: 38px;
  aspect-ratio: 1319 / 1193;
  object-fit: contain;
}
.brand-wordmark {
  display: block;
  width: auto;
  height: 25px;
  max-width: 100%;
  aspect-ratio: 2987 / 412;
  object-fit: contain;
}
.desktop-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px;
  border-radius: var(--radius-pill);
  background: var(--bb-sunk);
}
.nav-item {
  position: relative;
  min-height: 40px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--bb-ink-2);
  font-size: 0.9375rem;
  font-weight: 500;
  line-height: 1.1;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--bb-duration-ui) var(--bb-ease-out), color var(--bb-duration-ui) var(--bb-ease-out);
}
.nav-item:hover { color: var(--ink); background: rgba(255, 255, 255, 0.55); }
.nav-item-active,
.nav-item-active:hover {
  background: var(--bb-card);
  color: var(--ink);
  box-shadow: 0 1px 2px rgba(16, 17, 20, 0.08), 0 0 0 1px var(--bb-line);
}
.future-destination { color: var(--bb-subtle); padding-inline: 14px; }
.nav-label { display: grid; justify-items: center; gap: 1px; }
.nav-note {
  color: var(--bb-subtle);
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.topbar-actions {
  justify-self: end;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}
.workspace-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
}
.workspace-status::before {
  content: "";
  width: 8px;
  height: 8px;
  flex: none;
  border: 1.5px solid var(--bb-subtle);
  border-radius: 50%;
}
.workspace-status[data-kind="synced"]::before { border-color: var(--ink); background: var(--lime); }
.workspace-status[data-kind="local"]::before { border-color: var(--ink); background: var(--bb-sunk); }
.workspace-status[data-kind="attention"] { color: var(--ink); font-weight: 600; }
.workspace-status[data-kind="attention"]::before { border-color: var(--ink); background: var(--ink); }
.rail-capture {
  min-height: 42px;
  padding: 0 18px 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--lime);
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color var(--bb-duration-ui) var(--bb-ease-out);
}
.rail-capture:hover { background: var(--bb-lime-hover); }
.rail-capture:active { background: var(--bb-lime-pressed); }
/* The Bucket already leads with its composer, so the shortcut only appears elsewhere. */
.app-shell:has(#bucket:not([hidden])) .rail-capture { display: none; }

.account-menu { position: relative; }
.account-menu:not([open]) .account-popover { display: none; }
.account-summary {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  list-style: none;
  cursor: pointer;
}
.account-summary::-webkit-details-marker { display: none; }
.account-avatar {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--bb-avatar);
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 600;
  text-transform: uppercase;
}
.account-menu[open] .account-avatar { box-shadow: 0 0 0 2px var(--paper), 0 0 0 4px var(--ink); }
.account-popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 30;
  width: min(300px, calc(100vw - 32px));
  padding: 14px;
  display: grid;
  gap: 10px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-md);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-float);
}
.account-panel { min-width: 0; padding: 4px 8px 0; }
.account-email { display: block; min-width: 0; color: var(--muted); font-size: 0.875rem; line-height: 1.4; overflow-wrap: anywhere; }
.account-nav { display: grid; gap: 2px; }
.rail-link {
  width: 100%;
  min-height: 44px;
  padding: 0 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 500;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.rail-link:hover { background: var(--bb-sunk); }
.rail-link[aria-current="page"] { background: var(--bb-sunk); font-weight: 600; }
.rail-privacy {
  margin: 0;
  padding: 10px 10px 2px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-top: 1px solid var(--bb-line);
  color: var(--muted);
  font-size: 0.8125rem;
}
.rail-privacy .bb-icon { width: 1rem; height: 1rem; }

.main-panel {
  position: relative;
  min-width: 0;
  width: 100%;
  padding: 48px var(--bb-page-pad-x) 72px;
}
.main-panel:focus { outline: none; }
.workspace, .state-card, .auth-card {
  width: min(var(--bb-content-max), 100%);
  margin: 0 auto;
}
.state-card, .auth-card {
  width: min(560px, 100%);
  margin-top: clamp(24px, 8vh, 96px);
  padding: clamp(24px, 5vw, 44px);
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-xl);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-card);
}
.state-card { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.state-card > div { min-width: 0; }
.state-card .section-label, .state-card h1 { width: 100%; }
.state-card h1, .auth-card h1 {
  margin: 4px 0 0;
  font-family: var(--bb-font-display);
  font-size: clamp(2.25rem, 5vw, 3rem);
  font-weight: 400;
  line-height: 1.02;
}
.status-dot {
  display: inline-block;
  flex: none;
  width: 10px;
  height: 10px;
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  background: var(--lime);
}
.section-label {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.4;
}
.auth-intro, .auth-privacy { max-width: 42ch; color: var(--muted); line-height: 1.6; }
.auth-intro { margin: 16px 0 28px; }
.auth-privacy { margin: 26px 0 0; font-size: 0.9375rem; }

.field { margin-top: 18px; }
.field label { display: block; margin: 0 0 8px; font-size: 0.9375rem; font-weight: 600; }
input, textarea {
  width: 100%;
  max-width: 100%;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-sm);
  outline: none;
  background: var(--bb-card);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.5;
}
input:hover, textarea:hover { border-color: var(--bb-line-strong); }
input:not(:is(:not([type]), [type="text"], [type="search"], [type="email"], [type="password"], [type="url"], [type="tel"], [type="number"])):focus { border-color: var(--ink); }
input::placeholder, textarea::placeholder { color: var(--bb-subtle); opacity: 1; }
input { min-height: 48px; padding: 0 16px; }
textarea { min-height: 120px; padding: 14px 16px; resize: vertical; }
input:not(:is(:not([type]), [type="text"], [type="search"], [type="email"], [type="password"], [type="url"], [type="tel"], [type="number"])):focus-visible, button:focus-visible, a:focus-visible, summary:focus-visible, [tabindex]:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  box-shadow: 0 0 0 6px var(--lime);
}
/* Text-entry focus (BB-P05-T024 acceptance, Joseph): caret-only. A focused text field looks
   exactly like the same field unfocused: no outline, ring, glow, inset line, border-color,
   border-width, background, or size change. The blinking caret is the only sign. The two rules
   above exclude text fields, so each field keeps its resting component styles; buttons, links,
   checkboxes, radios, the file picker, and other controls keep the Ink outline and lime ring. */

.auth-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.button {
  min-height: 48px;
  padding: 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-pill);
  background: var(--bb-card);
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.15;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--bb-duration-ui) var(--bb-ease-out), border-color var(--bb-duration-ui) var(--bb-ease-out);
}
.button .bb-icon { width: 1.125rem; height: 1.125rem; }
.button:disabled, .button[aria-disabled="true"] {
  cursor: not-allowed;
  border-color: var(--bb-line);
  background: var(--bb-sunk);
  color: var(--bb-subtle);
}
.button-primary { background: var(--lime); }
.button-primary:not(:disabled) { border-color: var(--lime); }
.button-primary:hover:not(:disabled) { border-color: var(--bb-lime-hover); background: var(--bb-lime-hover); }
.button-primary:active:not(:disabled) { background: var(--bb-lime-pressed); }
.button-ink { border-color: var(--ink); background: var(--ink); color: var(--white); }
.button-ink:hover:not(:disabled) { background: #2A2B30; }
.button-secondary:hover:not(:disabled) { border-color: var(--bb-line-strong); }
.button-ghost { border-color: transparent; background: transparent; }
.button-ghost:hover:not(:disabled) { background: var(--bb-sunk); }
.button-danger { border-color: var(--danger); background: var(--danger); color: var(--white); }
.text-button {
  width: fit-content;
  min-height: 44px;
  padding: 0 4px;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.form-message { min-height: 1.5em; margin: 14px 0 0; color: var(--muted); font-size: 0.9375rem; }
.form-message[data-kind="failed"], .error-text { color: var(--danger); }

.future-notice {
  width: min(var(--bb-content-max), 100%);
  min-height: 0;
  margin: 0 auto;
  color: var(--bb-ink-2);
  font-size: 0.9375rem;
  line-height: 1.5;
}
.future-notice:not(:empty) {
  margin-bottom: 20px;
  padding: 12px 18px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-sm);
  background: var(--bb-card);
}

/* Bucket */
.mobile-session-row { display: none; }
.workspace-header {
  position: relative;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}
.greeting { position: relative; max-width: 100%; }
.workspace-header h1 {
  max-width: 20ch;
  font-size: clamp(2.75rem, 5.3vw, 4.75rem);
  overflow-wrap: break-word;
}
.workspace-supporting {
  margin: 0;
  color: var(--muted);
  font-size: 1.1875rem;
  line-height: 1.45;
}

.capture-area {
  position: relative;
  margin-top: 38px;
  display: grid;
  justify-items: center;
}
#capture-form {
  position: relative;
  width: min(880px, 100%);
  display: grid;
  gap: 14px;
}
.capture-card {
  position: relative;
  min-width: 0;
  padding: 18px 24px 12px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-xl);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-card);
}
.capture-heading-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 20px;
}
.capture-heading-row h2 {
  margin: 0;
  color: var(--bb-ink-2);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
}
.capture-help, .section-help {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}
.capture-help { font-size: 0.8125rem; }
.composer { min-width: 0; margin-top: 4px; display: grid; gap: 8px; }
#upload-progress { margin: 0; }
#upload-progress:empty { display: none; }
.composer-text, .selected-file { min-width: 0; }
.composer[data-dragging="true"] { border: 1px dashed var(--ink); border-radius: var(--radius-sm); background: var(--bb-sunk); }
.composer-text textarea {
  min-height: 56px;
  max-height: 40vh;
  padding: 6px 0 2px;
  field-sizing: content;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 1.5rem;
  line-height: 1.35;
  resize: none;
}
.composer-actions {
  position: relative;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 12px;
}
.file-capture-row { min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.file-picker { min-height: 44px; padding: 0 16px 0 14px; background: #FBFAF6; font-size: 0.875rem; font-weight: 600; cursor: pointer; }
#capture-form[data-account-deletion="locked"] .file-picker { cursor: not-allowed; background: var(--bb-sunk); color: var(--bb-subtle); }
#file-input:focus-visible + .file-picker {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  box-shadow: 0 0 0 6px var(--lime);
}
.selected-file {
  margin: 4px 0;
  padding: 16px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: 14px;
  border-radius: var(--radius-md);
  background: var(--bb-sunk);
}
.selected-file-icon {
  position: relative;
  width: 76px;
  height: 60px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--bb-line);
  border-radius: 10px;
  background: var(--bb-card);
}
.selected-file-icon[data-kind="pdf"] { color: var(--danger); }
.selected-file-preview { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: contain; background: var(--neutral); }
.selected-file-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 4px 14px; }
.selected-file-actions .text-button { min-height: 44px; }
.selected-file > div { min-width: 0; }
.selected-file strong, .selected-file span { display: block; overflow-wrap: anywhere; }
.selected-file strong { font-size: 1.0625rem; font-weight: 600; }
.selected-file div > span { margin-top: 4px; color: var(--muted); font-size: 0.875rem; }
.selected-file p { margin: 8px 0 0; color: var(--danger); font-size: 0.875rem; line-height: 1.45; }
.selected-file p:empty { display: none; }
.selected-file p[data-tone="note"] { color: var(--muted); }
.save-button { min-height: 44px; padding: 0 8px 0 22px; gap: 10px; font-size: 1rem; }
.button-arrow {
  width: 30px;
  height: 30px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(16, 17, 20, 0.1);
}
.button:disabled .button-arrow { background: rgba(16, 17, 20, 0.06); }
.composer-footnote {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 16px;
  color: var(--bb-subtle);
  font-size: 0.8125rem;
}
.byte-count { margin: 0; font-variant-numeric: tabular-nums; }
.byte-count[data-over-limit="true"] { color: var(--danger); font-weight: 600; }

.mascot-slot { display: grid; place-items: center; flex: none; }
.brand-mascot { display: block; width: 100%; height: 100%; object-fit: contain; }
.mascot-slot[data-mascot-placement="receipt"] { width: 46px; aspect-ratio: 1319 / 1193; }

/* Durable-save receipt. The catch keeps its established motion and state semantics inside
   the compact Studio bar; fixed geometry prevents save state changes from moving layout. */
.save-feedback {
  min-width: 0;
  min-height: 56px;
  padding: 4px 18px 4px 8px;
  display: flex;
  position: relative;
  align-items: center;
  gap: clamp(8px, 1.5vw, 14px);
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.72);
}
.save-feedback[data-kind="idle"][data-receipt-visible="false"] {
  border-color: var(--bb-line);
  background: rgba(255, 255, 255, 0.56);
}
.save-feedback[data-kind="idle"][data-receipt-visible="false"] > :not(.receipt-idle-note) { visibility: hidden; }
.receipt-idle-note {
  position: absolute;
  inset: 0;
  margin: 0;
  padding: 0 18px 0 92px;
  display: none;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  color: var(--muted);
  font-size: 0.9375rem;
  line-height: 1.45;
  text-align: left;
}
.receipt-idle-note .bb-icon { width: 1.125rem; height: 1.125rem; }
.save-feedback[data-kind="idle"][data-receipt-visible="false"] .receipt-idle-note { display: flex; }
.save-feedback[data-kind="failed"] { border-color: rgba(180, 35, 24, 0.55); }
.signature-receipt { width: 72px; height: 46px; position: relative; flex: 0 0 72px; visibility: hidden; isolation: isolate; }
.save-feedback[data-receipt-visible="true"] .signature-receipt { visibility: visible; }
/* BB-P05-T011: the mascot stays visible in its reserved stage before and after saves. */
.save-feedback .receipt-mascot-stage,
.save-feedback[data-kind="idle"][data-receipt-visible="false"] .receipt-mascot-stage { visibility: visible; }
.receipt-mascot-stage {
  width: 50px;
  height: 44px;
  position: absolute;
  right: 0;
  bottom: 0;
  z-index: 2;
  display: grid;
  place-items: end center;
}
.memory-slip {
  width: 32px;
  height: 23px;
  position: absolute;
  top: 2px;
  left: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 2px;
  overflow: hidden;
  opacity: 0;
  border: 1.5px solid var(--ink);
  border-radius: 5px;
  background: var(--paper);
  box-shadow: 2px 2px 0 var(--neutral);
  transform-origin: 50% 50%;
}
.receipt-slip-thumbnail { width: 100%; height: 100%; display: block; object-fit: contain; border-radius: 2px; background: var(--paper); }
.receipt-slip-icon { display: grid; position: relative; flex: none; place-items: center; color: var(--ink); font-weight: 900; line-height: 1; }
.receipt-slip-copy { min-width: 0; display: grid; gap: 1px; line-height: 1; }
.receipt-slip-type, .receipt-slip-name { min-width: 0; max-width: 28px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.receipt-slip-type { font-size: 0.43rem; letter-spacing: 0.03em; }
.save-feedback[data-receipt-stack="true"] .memory-slip { box-shadow: -4px 4px 0 var(--paper), -5px 5px 0 var(--ink), -8px 8px 0 var(--paper), -9px 9px 0 var(--ink); }
.receipt-slip-name { font-size: 0.38rem; }
.save-feedback[data-receipt-variant="text"] .receipt-slip-icon { width: 25px; height: 14px; border-block: 2px solid currentColor; margin-inline: auto; }
.save-feedback[data-receipt-variant="text"] .receipt-slip-icon::after { content: ""; width: 17px; position: absolute; top: 5px; left: 0; border-top: 2px solid currentColor; }
.save-feedback[data-receipt-variant="image"] .memory-slip { width: 32px; height: 23px; padding: 2px; }
.save-feedback[data-receipt-variant="image"] .receipt-slip-icon { width: 27px; height: 18px; border: 2px solid currentColor; border-radius: 2px; margin-inline: auto; }
.save-feedback[data-receipt-variant="image"] .receipt-slip-icon::after { content: ""; width: 9px; height: 9px; position: absolute; right: 2px; bottom: 1px; border-top: 2px solid currentColor; border-left: 2px solid currentColor; transform: rotate(45deg); }
.save-feedback[data-receipt-variant="image"] .receipt-slip-thumbnail:not([hidden]) ~ * { display: none; }
.save-feedback[data-receipt-variant="link"] .memory-slip,
.save-feedback[data-receipt-variant="pdf"] .memory-slip,
.save-feedback[data-receipt-variant="file"] .memory-slip { width: 42px; }
.save-feedback[data-receipt-variant="link"] .receipt-slip-icon { font-size: 1rem; }
.save-feedback[data-receipt-variant="pdf"] .receipt-slip-icon,
.save-feedback[data-receipt-variant="file"] .receipt-slip-icon { display: none; }
.receipt-check {
  width: 18px;
  height: 18px;
  position: absolute;
  right: 0;
  top: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  opacity: 1;
  border: 1.5px solid var(--ink);
  border-radius: 50%;
  background: var(--lime);
  color: var(--ink);
  font-weight: 900;
}
.save-feedback[data-receipt-motion="full"] .memory-slip {
  animation: signature-memory-slip 1100ms cubic-bezier(0.2, 0.72, 0.22, 1) both;
}
.save-feedback[data-receipt-motion="full"] .mascot-slot[data-mascot-placement="receipt"] {
  animation: signature-mascot-catch 1100ms ease-out both;
}
.save-feedback[data-receipt-motion="full"] .receipt-check,
.save-feedback[data-receipt-motion="full"] .save-feedback-copy {
  animation: signature-receipt-resolve 1100ms ease-out both;
}
.save-feedback[data-receipt-motion="compact"] .memory-slip {
  animation: compact-memory-slip 640ms cubic-bezier(0.2, 0.72, 0.22, 1) both;
}
.save-feedback[data-receipt-motion="compact"] .mascot-slot[data-mascot-placement="receipt"] {
  animation: compact-mascot-catch 640ms ease-out both;
}
.save-feedback[data-receipt-motion="compact"] .receipt-check,
.save-feedback[data-receipt-motion="compact"] .save-feedback-copy {
  animation: compact-receipt-resolve 640ms ease-out both;
}
.save-feedback-copy, #save-error {
  min-width: 0;
  flex: 1 1 auto;
  overflow-wrap: anywhere;
}
.save-feedback-copy, #save-error:not([hidden]) {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0 10px;
}
.receipt-icon {
  display: none;
  place-items: center;
  width: 24px;
  height: 24px;
  position: static;
  flex: 0 0 24px;
  z-index: 4;
  border: 1px solid var(--ink);
  border-radius: 50%;
  background: var(--neutral);
  font-weight: 900;
}
.save-feedback[data-kind="saving-local"] .receipt-icon { display: grid; }
.save-feedback[data-kind="saving-local"] .receipt-icon::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--ink); }
.save-feedback[data-kind="failed"] .receipt-icon { display: none; }
.save-primary { margin: 0; font-size: 1rem; font-weight: 600; line-height: 1.4; }
.save-detail { margin: 0; color: var(--muted); font-size: 0.9375rem; line-height: 1.45; }
.save-feedback[data-kind="failed"] #save-error .save-primary { color: var(--danger); }

/* Recently saved: bounded page groups keep DOM and keyboard order top to bottom
   within each column while older pages leave the current columns in place. */
.dashboard-lower {
  min-width: 0;
  margin-top: 64px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  align-items: start;
  gap: 48px;
}
.recent-section { min-width: 0; }
.section-heading-row {
  margin-bottom: 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
}
.recent-section h2, .find-other h2 { margin: 0; font-size: 1.25rem; font-weight: 600; line-height: 1.3; }
.section-help { font-size: 0.875rem; }
.global-find {
  position: relative;
  min-width: min(100%, 15rem);
  flex: 0 1 21.25rem;
  min-height: 46px;
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px 0 16px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-pill);
  background: var(--bb-card);
}
.global-find-icon { color: var(--bb-ink-2); width: 1.125rem; height: 1.125rem; }
.global-find input {
  min-width: 0;
  min-height: 44px;
  flex: 1 1 auto;
  padding: 0 4px;
  border: 0;
  background: transparent;
  font-size: 0.9375rem;
}
.shortcut-hint {
  flex: none;
  padding: 2px 7px;
  border-radius: 7px;
  background: var(--bb-sunk);
  color: var(--muted);
  font: 600 0.75rem/1.4 var(--bb-font-sans);
}
.recent-warning {
  margin: 0 0 16px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid var(--bb-line-strong);
  border-radius: var(--radius-sm);
  background: var(--bb-card);
}
.recent-warning p { margin: 0; line-height: 1.5; }
.recent-state { min-height: 72px; margin: 0; display: flex; align-items: center; gap: 12px; color: var(--muted); }
.empty-state {
  margin: 0;
  padding: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 22px;
  border: 1px dashed var(--bb-line-strong);
  border-radius: var(--radius-lg);
}
.empty-state p { max-width: 42ch; margin: 0; font-family: var(--bb-font-display); font-size: 1.625rem; line-height: 1.15; }
.capture-list { min-width: 0; list-style: none; margin: 0; padding: 0; }
#capture-list { overflow-anchor: none; }
.capture-page-group { list-style: none; margin: 0; padding: 0; }
.capture-page { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 18px; margin: 0; padding: 0; list-style: none; }
.capture-page > .capture-item { margin: 0; }
/* Bucket has a compact template; Detail and collection cards keep their full presentation. */
#capture-list .capture-thumb, #capture-list .bucket-text-preview {
  height: 8.5rem;
  min-height: 0;
  aspect-ratio: auto;
  flex: none;
}
#capture-list .bucket-text-preview {
  display: block;
  padding: 1rem;
  overflow: hidden;
  background: var(--bb-sunk);
}
.bucket-text-excerpt {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--bb-ink-2);
  font-size: 1rem;
  line-height: 1.5;
}
#capture-list .capture-body {
  grid-template-rows: 2.6rem 1.2rem 2.3rem;
  align-items: start;
  gap: 0.375rem;
  padding: 1rem 1rem 0.5rem;
}
#capture-list .capture-text, #capture-list .capture-file-name { font-family: var(--bb-font-sans); font-weight: 600; font-size: 1rem; line-height: 1.3; -webkit-line-clamp: 2; }
#capture-list .bucket-card-source {
  display: block;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.6;
}
#capture-list .bucket-card-context {
  margin: 0;
  padding: 0;
  background: transparent;
  border-radius: 0;
  min-width: 0;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  color: var(--bb-ink-2);
  font-size: 0.8125rem;
  line-height: 1.4;
}
#capture-list .bucket-card-context::before { content: "Your context · "; display: inline; margin: 0; font: inherit; color: var(--muted); }
#capture-list .bucket-card-context .capture-user-context-text { display: inline; }
#capture-list .capture-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: start;
  align-content: start;
  gap: 0 0.5rem;
  min-height: 3.125rem;
  padding: 0.375rem 1rem 0.75rem;
  font-size: 0.6875rem;
  line-height: 1.4;
}
#capture-list .capture-meta > * { max-width: 100%; }
#capture-list .bucket-card-state { min-width: 0; margin-left: auto; padding: 0; overflow-wrap: anywhere; text-align: right; }
#capture-list .capture-sync { display: inline; padding: 0; }
#capture-list .capture-open { position: relative; }
#capture-list .bucket-preview-status {
  position: absolute;
  inset-inline: 0;
  top: 8.5rem;
  transform: translateY(-100%);
  padding: 0.375rem 1rem;
  background: var(--bb-sunk);
  color: var(--bb-ink-2);
  font-size: 0.75rem;
  line-height: 1.4;
  white-space: normal;
  overflow-wrap: anywhere;
}
#capture-list .capture-open:has(.bucket-preview-status) .bucket-text-excerpt { -webkit-line-clamp: 2; }
.bucket-paging { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 18px; }
.bucket-paging .button { max-width: 100%; min-width: 0; white-space: normal; overflow-wrap: anywhere; padding-block: 12px; text-align: center; }
.bucket-page-status { flex-basis: 100%; color: var(--muted); margin: 0; }
.bucket-paging:has(.bucket-page-status:empty) { display: none; }
.bucket-page-status:empty { display: none; }
.collection-memory-list { columns: 3 15rem; column-gap: 18px; }
.capture-item {
  min-width: 0;
  margin: 0 0 18px;
  display: flex;
  flex-direction: column;
  break-inside: avoid;
  overflow: hidden;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-md);
  background: var(--bb-card);
  transition: border-color var(--bb-duration-ui) var(--bb-ease-out);
}
.capture-item:hover { border-color: var(--bb-line-strong); }
.capture-open { min-width: 0; display: flex; flex-direction: column; color: inherit; text-decoration: none; border-radius: var(--radius-md) var(--radius-md) 0 0; }
.capture-open:hover .capture-text, .capture-open:hover .capture-file-name { text-decoration: underline; text-underline-offset: 3px; }
.capture-thumb {
  position: relative;
  width: 100%;
  height: 7.5rem;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--bb-sunk);
  color: var(--bb-ink-2);
}
.capture-thumb .bb-icon { width: 2.25rem; height: 2.25rem; stroke-width: 1.5; }
.capture-thumb[data-kind="image"] { height: 12.5rem; }
.capture-thumb[data-kind="link"] { height: 6rem; }
.capture-thumb[data-preview="image"] {
  height: auto;
  aspect-ratio: var(--media-aspect, 16 / 9);
}
.capture-thumb[data-preview="image"][data-media-aspect="portrait"] { min-height: 18rem; }
.capture-thumb[data-kind="pdf"] { color: var(--danger); }
/* Text memories lead with their own words instead of a tile. */
.capture-item .capture-thumb[data-kind="note"] { display: none; }
.capture-open[data-thumbnail="none"] { grid-template-columns: minmax(0, 1fr); }
.thumb-type-label {
  position: absolute;
  right: 5px;
  bottom: 4px;
  padding: 1px 5px;
  border-radius: 5px;
  background: var(--bb-card);
  color: var(--bb-ink-2);
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  line-height: 1.4;
}
.capture-thumb[data-kind="pdf"] .thumb-type-label { color: var(--danger); }
.domain-tile {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 2px;
  padding: 4px;
  overflow: hidden;
  background: var(--bb-sunk);
  color: var(--ink);
  text-align: center;
}
.domain-tile-letter { font-size: 1.375rem; font-weight: 800; line-height: 1; }
.domain-tile-host { max-width: 100%; overflow: hidden; font-size: 0.5625rem; font-weight: 700; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
.capture-understanding { min-width: 0; display: block; color: var(--muted); font-size: 0.875rem; font-style: italic; line-height: 1.4; }
.capture-understanding[data-kind="failed"] { font-style: normal; }
.capture-body { min-width: 0; padding: 20px 20px 10px; display: grid; gap: 10px; }
.capture-text, .capture-file-name {
  margin: 0;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow-wrap: anywhere;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
}
.capture-text {
  -webkit-line-clamp: 2;
  white-space: pre-wrap;
  font-family: var(--bb-font-display);
  font-size: 1.5rem;
  font-weight: 400;
  line-height: 1.25;
}
.capture-excerpt {
  margin: 0;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  color: var(--muted);
  font-size: 0.875rem;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.capture-file-meta { min-width: 0; display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow-wrap: anywhere; color: var(--muted); font-size: 0.875rem; line-height: 1.45; }
.source-identity { min-width: 0; display: inline-flex; flex-wrap: wrap; align-items: center; gap: 5px 8px; color: var(--muted); font-size: 0.8125rem; }
.source-chip { width: fit-content; padding: 2px 9px; border: 1px solid var(--bb-line-strong); border-radius: var(--radius-pill); background: var(--bb-sunk); color: var(--ink); font-weight: 600; line-height: 1.4; }
.source-publisher { min-width: 0; overflow-wrap: anywhere; }
.capture-image-preview { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; background: transparent; }
.capture-user-context { min-width: 0; display: block; margin-top: 6px; padding: 10px 12px; border-radius: 12px; overflow-wrap: anywhere; white-space: pre-wrap; background: var(--neutral); font-size: 0.875rem; line-height: 1.5; }
.capture-user-context::before { content: "Your context"; display: block; margin-bottom: 3px; color: var(--muted); font-size: 0.75rem; font-weight: 600; }
.capture-user-context-text { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.capture-generated-summary { min-width: 0; display: -webkit-box; margin-top: 6px; overflow: hidden; overflow-wrap: anywhere; color: var(--bb-ink-2); font-size: 0.875rem; line-height: 1.5; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.capture-generated-summary::before { content: "BrainBucket summary"; display: block; color: var(--muted); font-size: 0.75rem; font-weight: 600; }
.detail-original-content { width: min(100%, 42rem); margin-top: 12px; overflow-wrap: anywhere; }
.detail-original-content summary { cursor: pointer; min-height: 44px; padding: 10px 0; text-decoration: underline; text-underline-offset: 3px; }
.detail-original-content p { white-space: pre-wrap; margin: 0; }
.capture-meta {
  min-width: 0;
  padding: 8px 20px 18px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  color: var(--muted);
  font-size: 0.8125rem;
}
.capture-time { display: block; font-variant-numeric: tabular-nums; }
.capture-sync {
  padding: 2px 9px;
  border-radius: var(--radius-pill);
  background: var(--bb-sunk);
  color: var(--ink);
  font-weight: 600;
  line-height: 1.4;
}
.capture-sync[data-kind="synced"] { padding: 0; background: transparent; color: var(--muted); font-weight: 500; }
.capture-sync[data-kind="attention"] { background: var(--ink); color: var(--white); }

.dashboard-side { position: relative; min-width: 0; display: grid; gap: 20px; }
.safety-card {
  min-width: 0;
  padding: 22px 22px 24px;
  display: grid;
  gap: 8px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-lg);
  background: var(--bb-card);
}
.safety-mark {
  width: 52px;
  height: 52px;
  margin-bottom: 8px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--bb-sunk);
}
.safety-mark .bb-icon { width: 1.5rem; height: 1.5rem; }
.safety-card h2 { margin: 0; font-family: var(--bb-font-display); font-size: 1.875rem; font-weight: 400; line-height: 1.08; }
.safety-line { margin: 0; color: var(--muted); font-size: 0.875rem; line-height: 1.5; overflow-wrap: anywhere; }
.safety-line a { color: var(--ink); font-weight: 600; text-underline-offset: 3px; }
.anywhere-card {
  min-width: 0;
  padding: 20px;
  display: grid;
  gap: 14px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-lg);
}
.anywhere-card h2 { margin: 0; font-size: 1rem; font-weight: 600; }
.anywhere-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.anywhere-list li { display: flex; align-items: flex-start; gap: 12px; }
.anywhere-list li > span:last-child { min-width: 0; display: grid; gap: 1px; }
.anywhere-list strong { font-size: 0.875rem; font-weight: 600; }
.anywhere-list li > span:last-child > span { color: var(--muted); font-size: 0.8125rem; line-height: 1.4; }
.anywhere-icon { width: 36px; height: 36px; flex: none; display: grid; place-items: center; border-radius: 10px; background: var(--bb-sunk); }
.anywhere-icon .bb-icon { width: 1.125rem; height: 1.125rem; }
.anywhere-link { width: fit-content; min-height: 44px; display: inline-flex; align-items: center; color: var(--ink); font-size: 0.875rem; font-weight: 600; text-underline-offset: 3px; }

/* Find */
.find-view { width: min(100%, 1120px); margin: 0 auto; padding-top: 8px; }
.find-header { position: relative; text-align: center; }
.find-header h1 { font-size: clamp(2.5rem, 4.2vw, 3.75rem); }
.find-header > #find-helper { max-width: 60ch; margin: 14px auto 0; color: var(--muted); font-size: 1.0625rem; line-height: 1.5; }
.find-form { margin-top: 32px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.find-field { position: relative; grid-area: 1 / 1; min-width: 0; }
.find-field-icon { position: absolute; top: 27px; left: 24px; width: 1.5rem; height: 1.5rem; color: var(--bb-ink-2); pointer-events: none; }
.find-form textarea {
  min-height: 80px;
  max-height: calc(4lh + 48px);
  padding: 22px 150px 22px 62px;
  field-sizing: content;
  resize: none;
  border-color: var(--bb-line);
  border-radius: 26px;
  background: var(--bb-card);
  box-shadow: 0 24px 50px -30px rgba(16, 17, 20, 0.25);
  font-size: 1.375rem;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.find-button { grid-area: 1 / 1; justify-self: end; align-self: start; min-height: 52px; margin: 14px 14px 0 0; padding: 0 26px; font-size: 1rem; }
.find-privacy { grid-column: 1 / -1; margin: 0; color: var(--muted); font-size: 0.875rem; line-height: 1.5; text-align: center; }
.find-status-row { min-width: 0; margin-top: 16px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 4px 16px; }
.find-status { min-height: 1.5em; margin: 0; color: var(--muted); line-height: 1.55; overflow-wrap: anywhere; }
.find-status:empty { display: none; }
.find-status[data-kind="error"] { color: var(--danger); }
.find-jump { font-weight: 600; }
.find-empty { position: relative; margin-top: 24px; padding: 24px 28px; border-radius: var(--radius-lg); background: var(--bb-sunk); }
.find-empty h2 { margin: 0; font-size: 1.0625rem; font-weight: 600; }
.find-empty p { max-width: 64ch; margin: 6px 0 0; color: var(--muted); font-size: 0.9375rem; line-height: 1.55; }
.find-empty-actions { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 10px; }
.find-results { margin-top: 36px; }
.find-results:not([hidden]) { animation: bb-results-settle 220ms var(--bb-ease-out) both; }
.find-top { position: relative; }
.find-top h2 { margin: 0 0 20px; font-family: var(--bb-font-display); font-size: clamp(2rem, 2.8vw, 2.5rem); font-weight: 400; line-height: 1; }
.find-top:has(.find-mascot:not([hidden])) h2 { min-height: 56px; padding-left: 70px; display: flex; align-items: center; }
.find-top h2:focus, .find-other h2:focus { outline: none; }
.find-top-layout { min-width: 0; }
.find-result-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.find-result-item { min-width: 0; }
.find-best {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 400px) minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-xl);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-card);
}
.find-best-thumb {
  position: relative;
  width: 100%;
  min-height: 320px;
  height: 100%;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--bb-sunk);
  color: var(--bb-ink-2);
}
.find-best-thumb .bb-icon { width: 3rem; height: 3rem; stroke-width: 1.5; }
.find-best-thumb[data-kind="pdf"] { color: var(--danger); }
.find-best-thumb[data-preview="image"] { min-height: 0; height: auto; aspect-ratio: var(--media-aspect, 16 / 9); align-self: start; }
.find-best-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; background: transparent; }
.find-best-body { min-width: 0; display: flex; flex-direction: column; }
.find-best > .find-best-body { padding: 34px 40px; gap: 16px; }
.find-best-body > .find-result-meta { order: -1; }
.find-result-title { margin: 0; overflow-wrap: anywhere; font-size: clamp(1.5rem, 2.2vw, 2rem); font-weight: 600; line-height: 1.15; letter-spacing: -0.01em; }
.find-result-meta { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 8px; color: var(--muted); font-size: 0.875rem; }
.find-result-meta > * + *::before { content: "·"; margin-right: 8px; color: var(--bb-subtle); }
.find-evidence { color: var(--bb-ink-2); font-weight: 600; }
.find-local { color: var(--ink); font-weight: 600; }
.find-explanation { margin: 0 0 -16px; padding: 16px 20px 6px; border-radius: 18px 18px 0 0; background: var(--paper); color: var(--muted); font-size: 0.8125rem; font-weight: 600; line-height: 1.4; }
.find-result-snippet { margin: 0; color: var(--ink); white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.55; display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 4; }
.find-best .find-result-snippet { padding: 0 20px 16px; border-radius: 0 0 18px 18px; background: var(--paper); font-size: 1.0625rem; }
.find-best-actions { margin-top: auto; padding-top: 8px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; }
.find-best-actions .button { min-height: 48px; padding: 0 22px; }
.find-why { min-width: 0; }
.find-why summary {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  color: var(--ink);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  list-style: none;
}
.find-why summary::-webkit-details-marker { display: none; }
.find-why p { max-width: 60ch; margin: 4px 0 0; color: var(--bb-ink-2); line-height: 1.55; }
.find-mascot { position: absolute; top: -4px; left: 0; width: 56px; aspect-ratio: 1319 / 1193; pointer-events: none; }
.find-mascot-image { display: block; width: 100%; height: 100%; object-fit: contain; }
.find-other { margin-top: 44px; }
.find-other h2 { margin-bottom: 16px; }
.find-alternate-list { grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); }
.find-alternate {
  position: relative;
  min-width: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-md);
  background: var(--bb-card);
  transition: border-color var(--bb-duration-ui) var(--bb-ease-out);
}
.find-alternate:hover { border-color: var(--bb-line-strong); }
.find-alternate .capture-thumb { height: 10rem; }
.find-alternate .capture-thumb[data-preview="image"] { height: auto; aspect-ratio: var(--media-aspect, 16 / 9); }
.find-alternate .find-best-body { padding: 16px; gap: 6px; }
.find-alternate .find-result-title { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 3; font-size: 1rem; font-weight: 600; line-height: 1.3; }
.find-alternate .find-result-snippet { -webkit-line-clamp: 2; color: var(--muted); font-size: 0.875rem; }
.find-result-link { color: inherit; text-decoration: none; }
.find-result-link::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.find-result-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.find-result-link:focus-visible { outline: none; box-shadow: none; }
.find-alternate:has(.find-result-link:focus-visible) { outline: 3px solid var(--ink); outline-offset: 3px; box-shadow: 0 0 0 6px var(--lime); }
.find-row-arrow { display: none; }

/* Memory Detail: the preserved original is the largest thing on the page. */
.detail-view { min-width: 0; width: min(100%, var(--bb-content-max)); margin: 0 auto; }
.back-link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--bb-ink-2);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
}
.back-link:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.detail-header { margin-top: 12px; }
.detail-header .section-label { margin-bottom: 10px; }
.detail-header h1 { max-width: 20ch; overflow-wrap: anywhere; font-size: clamp(2.5rem, 3.75vw, 3.375rem); }
.detail-header h1:focus { outline: none; }
.detail-meta-row { margin-top: 12px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.detail-meta, .detail-status { margin: 0; line-height: 1.5; overflow-wrap: anywhere; font-size: 0.9375rem; }
.detail-meta { color: var(--muted); }
.detail-status { color: var(--ink); font-weight: 600; }
.detail-status:not(:empty)::before { content: "·"; margin-right: 10px; color: var(--bb-subtle); font-weight: 400; }
.detail-original-layout { min-width: 0; margin-top: 24px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
.detail-content { min-width: 0; display: flow-root; }
.detail-original {
  --detail-note-reserve: 0px;
  position: relative;
  min-width: 0;
  min-height: 360px;
  padding: 28px;
  display: grid;
  grid-template-rows: var(--detail-note-reserve) minmax(min-content, 1fr) auto;
  gap: 16px;
  border-radius: 32px;
  background: var(--bb-sunk);
}
.detail-original-stage {
  grid-row: 2;
  min-width: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
}
.detail-section-head {
  grid-row: 3;
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
}
.detail-section-head > div { min-width: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; }
.detail-original h2 { margin: 0; color: var(--bb-ink-2); font-size: 0.875rem; font-weight: 600; }
.detail-section-help { margin: 0; color: var(--muted); font-size: 0.8125rem; line-height: 1.5; }
.detail-section-head .button { min-height: 42px; padding: 0 16px; font-size: 0.875rem; }
.detail-body {
  min-width: 0;
  width: min(100%, 36rem);
  max-width: 100%;
  margin: 0;
  padding: 28px 32px;
  border-radius: var(--radius-md);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-original);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 1.0625rem;
  line-height: 1.65;
}
.detail-body:empty { display: none; }
.detail-body[data-kind="file"] { padding: 0; border-radius: 0; background: transparent; box-shadow: none; color: var(--muted); font-size: 0.9375rem; text-align: center; }
.detail-body[data-presentation="link-actions"] {
  width: min(100%, 42rem);
  padding: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.detail-body[data-presentation="link-actions"][data-media-aspect="portrait"] { width: min(100%, 21rem); }
.detail-link-actions { min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.detail-link {
  min-height: 40px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex: none;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-pill);
  background: var(--bb-card);
  color: var(--ink);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
}
.detail-link:hover { border-color: var(--bb-line-strong); }
.detail-link .bb-icon, .detail-link-copy .bb-icon { width: 1rem; height: 1rem; }
.detail-link-original { min-width: 0; max-width: 100%; display: block; flex: 1 1 15rem; overflow-wrap: anywhere; color: var(--muted); font-family: var(--bb-font-mono); font-size: 0.8125rem; line-height: 1.45; }
.detail-link-copy {
  min-height: 40px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: none;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--bb-ink-2);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
}
.detail-link-copy:hover { background: var(--bb-card); }
.detail-link-copy-status { width: 100%; min-height: 1.25em; margin: 0; color: var(--muted); font-size: 0.75rem; line-height: 1.35; }
.detail-link-copy-status:empty { display: none; }
.detail-text-link { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; overflow-wrap: anywhere; border-radius: 2px; }
.link-collection-count { margin: 0; color: var(--muted); font-size: 0.875rem; font-weight: 600; }
.link-collection-note { margin-top: 14px; padding: 14px 16px; border-left: 3px solid var(--lime); border-radius: 0 12px 12px 0; background: var(--bb-sunk); }
.link-collection-note strong { font-size: 0.8125rem; }
.link-collection-note p { margin: 5px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.55; }
.link-collection-sources { min-width: 0; margin-top: 14px; display: grid; gap: 10px; }
.link-source-card { min-width: 0; padding: 10px; display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 13px; border: 1px solid var(--bb-line); border-radius: 14px; background: var(--bb-card); }
.link-source-media { position: relative; width: 112px; height: 78px; overflow: hidden; border: 1px solid var(--bb-line); border-radius: 10px; }
.link-source-copy { min-width: 0; display: grid; align-content: start; gap: 5px; }
.link-source-title { color: var(--ink); font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; text-underline-offset: 3px; }
.link-source-copy p { margin: 0; display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; color: var(--muted); font-size: 0.875rem; line-height: 1.45; }
.link-collection-original { margin-top: 14px; }
.link-collection-original summary { min-height: 44px; display: inline-flex; align-items: center; font-size: 0.875rem; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.link-collection-original .detail-text-original { display: block; margin-top: 8px; padding-top: 12px; border-top: 1px dashed var(--bb-line-strong); }
@media (max-width: 440px) {
  .link-source-card { grid-template-columns: minmax(0, 1fr); }
  .link-source-media { width: 100%; height: 140px; }
}
.detail-link-derived { min-width: 0; max-width: 100%; display: block; margin-top: 16px; padding-top: 14px; overflow-wrap: anywhere; border-top: 1px dashed var(--bb-line-strong); color: var(--muted); font-size: 0.94rem; }
.detail-photo-gallery { display: grid; gap: 24px; width: 100%; min-width: 0; }
.detail-photo-gallery:empty { display: none; }
.detail-photo-gallery .button { max-width: 100%; min-width: 0; white-space: normal; overflow-wrap: anywhere; padding: 12px 20px; text-align: center; }
.detail-photo-gallery figure { margin: 0; min-width: 0; }
.detail-photo-gallery img { display: block; width: 100%; max-height: 540px; object-fit: contain; }
.detail-photo-gallery figcaption { margin: 12px 0; overflow-wrap: anywhere; }
.detail-preview { display: block; max-width: 100%; max-height: min(70vh, 720px); width: auto; min-width: min(100%, 22rem); height: auto; margin: 0; border-radius: var(--radius-md); object-fit: contain; background: var(--bb-card); box-shadow: var(--bb-shadow-original); }
.detail-preview-fallback { width: min(100%, 36rem); margin: 0; padding: 18px 20px; border: 1px dashed var(--bb-line-strong); border-radius: var(--radius-md); background: var(--bb-card); line-height: 1.55; text-align: center; }
.detail-original-stage .detail-link-preview { margin-top: 0; }
.detail-context { min-width: 0; display: grid; gap: 12px; align-content: start; }
.detail-context h2, .detail-memory h2, .detail-related h2, .detail-understanding h2 {
  margin: 0;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
}
.detail-user-context { margin: 0 0 12px; display: grid; gap: 8px; }
.detail-user-context p { min-width: 0; max-width: 100%; margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font-family: var(--bb-font-display); font-size: 1.625rem; font-style: italic; line-height: 1.2; }
.detail-facts { margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.detail-facts > div { min-width: 0; max-width: 100%; min-height: 38px; padding: 7px 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; border-radius: var(--radius-pill); background: var(--bb-sunk); font-size: 0.875rem; }
.detail-facts dt { color: var(--muted); }
.detail-facts dd { margin: 0; color: var(--ink); font-weight: 600; line-height: 1.4; overflow-wrap: anywhere; }
.privacy-dot { display: inline-block; width: 9px; height: 9px; margin-right: 7px; border: 1.5px solid var(--ink); border-radius: 50%; background: var(--lime); }

.detail-memory { position: relative; min-width: 0; margin-top: 32px; }
.detail-memory-heading-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; }
.detail-memory-heading-row > div { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.detail-memory-heading-row > div:first-child { flex: 1 1 16rem; }
.detail-memory-heading-row p, .detail-memory-status { margin: 4px 0 0; color: var(--muted); font-size: 0.875rem; line-height: 1.5; }
.detail-memory-heading-row .button { min-height: 40px; padding: 0 12px; font-size: 0.875rem; }
.detail-memory-status:empty { display: none; }
.detail-memory-summary { min-width: 0; margin-top: 14px; display: grid; gap: 8px; }
.memory-current { min-width: 0; padding: 16px 20px 18px; border: 1px solid var(--bb-line); border-radius: 18px; background: var(--bb-card); }
.memory-field-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 4px 24px; }
.memory-field { margin: 10px 0 0; min-width: 0; }
.memory-field strong { display: block; color: var(--muted); font-size: 0.8125rem; font-weight: 600; }
.memory-field p { margin: 3px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.55; }
.memory-current .memory-field:first-child { grid-column: 1 / -1; margin-top: 0; }
.memory-current .memory-field:first-child p { font-size: 1.125rem; font-weight: 600; line-height: 1.35; }
.memory-corrected { display: inline-block; margin-left: 8px; padding: 1px 8px; border-radius: var(--radius-pill); background: var(--bb-mark); color: var(--ink); font-size: 0.75rem; font-weight: 600; }
.memory-suggestion { min-width: 0; padding: 0 4px; }
.memory-suggestion summary { min-height: 44px; display: inline-flex; align-items: center; color: var(--ink); font-size: 0.875rem; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.memory-suggestion h3 { margin: 6px 0 0; font-size: 0.875rem; font-weight: 600; }
.memory-suggestion .memory-field-grid { margin-top: 6px; padding: 4px 16px 14px; border-radius: 14px; background: var(--bb-sunk); }
.understanding-editor {
  min-width: 0;
  margin-top: 16px;
  padding: 20px 22px 18px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  border: 1px solid var(--bb-line-strong);
  border-radius: var(--radius-md);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-float);
}
.understanding-editor[hidden] { display: none; }
.understanding-editor h3 { margin: 0; font-size: 1.125rem; font-weight: 600; }
.editor-field { min-width: 0; display: grid; align-content: start; gap: 6px; margin-top: 10px; }
.understanding-editor label { font-weight: 600; }
.understanding-editor input, .understanding-editor textarea { width: 100%; min-width: 0; padding: 12px 14px; border: 1px solid var(--bb-line-strong); border-radius: 12px; background: var(--white); color: var(--ink); font: inherit; line-height: 1.55; }
.understanding-editor textarea { min-height: 96px; resize: vertical; white-space: pre-wrap; overflow-wrap: anywhere; }
.understanding-editor p { margin: 0; color: var(--muted); font-size: 0.875rem; line-height: 1.5; }
.understanding-editor .correction-error { min-height: 1.5em; color: var(--danger); font-size: 0.9375rem; font-weight: 600; }
.understanding-editor-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }

.detail-related { min-width: 0; margin-top: 32px; }
.detail-related .detail-section-help { margin-top: 4px; }
.detail-related-list { list-style: none; margin: 12px 0 0; padding: 0; display: grid; }
.detail-related-list li { min-width: 0; padding: 12px 0; display: flex; align-items: flex-start; gap: 12px; border-top: 1px solid var(--bb-line); overflow-wrap: anywhere; white-space: pre-wrap; line-height: 1.5; }
.detail-related-list .bb-icon { width: 2.25rem; height: 2.25rem; padding: 8px; flex: none; border-radius: 10px; background: var(--bb-sunk); color: var(--bb-ink-2); }
.detail-collections { min-width: 0; margin-top: 32px; padding-top: 20px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 18px; border-top: 1px solid var(--bb-line); }
.detail-collections .button { max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
.detail-collections h2 { margin: 0; color: var(--muted); font-size: 0.875rem; font-weight: 600; }
.detail-collections .detail-section-help { margin-top: 4px; }
/* BB-P05-T024 correction: the memory's current collections, as wrapping text labels. */
.detail-collections-copy { min-width: 0; flex: 1 1 18rem; }
.detail-collection-list { margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.detail-collection-list li { min-width: 0; max-width: 100%; min-height: 32px; padding: 5px 12px; display: inline-flex; align-items: center; border-radius: var(--radius-pill); background: var(--bb-sunk); font-size: 0.875rem; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.detail-collections-state { margin: 10px 0 0; color: var(--muted); font-size: 0.875rem; }
.detail-collections-state:empty { display: none; }

.detail-understanding { min-width: 0; margin-top: 32px; }
.detail-understanding-status { margin: 4px 0 0; color: var(--muted); font-size: 0.875rem; line-height: 1.55; }
.detail-understanding-status-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.detail-understanding-status-row .button { min-height: 44px; }
.detail-link-preview {
  min-width: 0;
  width: min(100%, 42rem);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-md);
  background: var(--bb-card);
  color: inherit;
  text-decoration: none;
  box-shadow: var(--bb-shadow-original);
  transition: border-color var(--bb-duration-ui) var(--bb-ease-out), transform var(--bb-duration-ui) var(--bb-ease-out);
}
.detail-link-preview:hover { border-color: var(--bb-line-strong); transform: translateY(-1px); }
.detail-link-preview-media { position: relative; width: 100%; aspect-ratio: var(--media-aspect, 16 / 9); overflow: hidden; background: var(--bb-sunk); }
.detail-link-preview-image { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; background: transparent; }
.detail-link-preview[data-media-aspect="portrait"] { width: min(100%, 21rem); }
.detail-link-preview-copy { min-width: 0; padding: 16px 18px 17px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; overflow-wrap: anywhere; }
.detail-link-source-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; background: var(--bb-sunk); color: var(--ink); font-size: 1rem; font-weight: 700; }
.detail-link-preview-text { min-width: 0; display: grid; gap: 3px; }
.detail-link-preview-copy strong { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; font-size: 1.0625rem; line-height: 1.35; }
.detail-link-preview-copy p { margin: 0; color: var(--bb-ink-2); line-height: 1.5; }
.detail-link-preview-description { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.detail-link-preview[data-thumbnail="fallback"] .detail-link-preview-media,
.detail-link-preview[data-thumbnail="unavailable"] .detail-link-preview-media { display: none; }
.detail-link-preview-copy p:empty, .detail-link-preview-copy strong:empty { display: none; }
.detail-link-preview-text > span { color: var(--muted); font-size: 0.875rem; }
.detail-link-preview-open { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: var(--bb-sunk); color: var(--bb-ink-2); }
.detail-link-preview-open .bb-icon { width: 1.125rem; height: 1.125rem; }
.detail-understanding-content { display: grid; min-width: 0; gap: 12px; margin-top: 14px; overflow-wrap: anywhere; }
.detail-understanding-content:empty { display: none; }
.derived-block { min-width: 0; padding: 14px 16px; border: 1px solid var(--bb-line); border-radius: 16px; background: var(--bb-card); }
.derived-block h3 { margin: 0 0 6px; font-size: 0.875rem; font-weight: 600; }
.derived-block p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.6; }
.derived-note { margin-top: 8px !important; color: var(--muted); font-size: 0.8125rem; }

/* Settings keeps its deliberate export-first order in the same card language. */
.secondary-view {
  min-width: 0;
  width: min(880px, 100%);
  margin: 0 auto;
  padding: clamp(24px, 5vw, 44px);
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-xl);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-card);
}
.secondary-view .back-link { margin-bottom: 8px; }
.secondary-view h1 { margin: 4px 0 0; overflow-wrap: anywhere; font-family: var(--bb-font-display); font-size: clamp(2.5rem, 4vw, 3.25rem); font-weight: 400; line-height: 1; }
/* BB-P05-T024 self-filing Collections (Joseph's four approved screenshots). */
.collections-page, .collection-page { min-width: 0; width: min(100%, var(--bb-content-max)); margin: 0 auto; }
.collections-hero { max-width: 60rem; margin: 0 auto; padding-top: 8px; text-align: center; }
.collections-hero h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); }
.collections-hero > p { max-width: 44ch; margin: 18px auto 0; color: var(--bb-ink-2); font-size: 1.1875rem; line-height: 1.5; }
.collections-unavailable { max-width: 44rem; margin: 28px auto 0; padding: 18px 22px; border: 1px dashed var(--bb-line-strong); border-radius: var(--radius-md); text-align: center; line-height: 1.5; }
.collections-create-area { width: min(100%, 58rem); margin: 36px auto 0; }
.collections-create-wrap { position: relative; }
.collections-create {
  min-width: 0;
  min-height: 84px;
  padding: 10px 10px 10px 22px;
  display: flex;
  align-items: center;
  gap: 14px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-xl);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-card);
}
.collections-create-icon { width: 1.5rem; height: 1.5rem; color: var(--bb-ink-2); }
.collections-create input {
  min-width: 0;
  min-height: 52px;
  flex: 1 1 auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 1.5rem;
  outline: none;
}
.collections-create input::placeholder { color: var(--bb-subtle); }
.collections-create-button { min-height: 60px; padding: 0 26px; font-size: 1.0625rem; }
.collections-create-help { margin: 18px 0 0; color: var(--muted); font-size: 0.9375rem; text-align: center; }
.collections-status { text-align: center; }
.collections-status:empty { min-height: 0; margin: 0; }
.collection-receipt {
  min-width: 0;
  margin-top: 18px;
  padding: 12px 14px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-xl);
  background: var(--bb-card);
}
.collection-receipt-mascot { width: 3.5rem; height: auto; aspect-ratio: 1319 / 1193; object-fit: contain; }
.collection-receipt-copy { min-width: 0; }
.collection-receipt-copy p { margin: 0; overflow-wrap: anywhere; }
.collection-receipt-title { display: flex; align-items: center; gap: 8px; font-size: 1.0625rem; font-weight: 600; }
.collection-receipt-check { width: 1.125rem; height: 1.125rem; stroke-width: 2.25; }
.collection-receipt-detail { margin-top: 2px !important; color: var(--bb-ink-2); line-height: 1.45; }
.collection-receipt-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; }
.collection-receipt-undo { text-decoration: none; font-weight: 600; }
.collection-receipt-undo:hover { text-decoration: underline; }
.collections-shelf { margin-top: 56px; }
.collections-shelf-header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; }
.collections-shelf-title { position: relative; min-width: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; }
.collections-shelf-title h2 { margin: 0; font-size: 1.5rem; font-weight: 600; }
.collections-count, .collections-several { margin: 0; color: var(--muted); font-size: 0.9375rem; }
.collections-sort select {
  min-height: 48px;
  padding: 0 16px 0 20px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-pill);
  background: var(--bb-card);
  color: var(--ink);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}
.collections-shelf .empty-state { margin-top: 24px; }
/* BB-P05-T024 correction 2: collection-name search beside the sort menu. */
.collections-sort { min-width: 0; flex: 1 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
.collections-search-toggle { width: 48px; padding: 0; }
.collections-name-search { position: relative; min-width: 0; flex: 0 1 17rem; }
.collections-name-search-icon { position: absolute; top: 50%; left: 16px; width: 1.125rem; height: 1.125rem; transform: translateY(-50%); color: var(--bb-ink-2); pointer-events: none; }
.collections-name-search input { width: 100%; min-width: 0; min-height: 48px; padding: 0 48px 0 44px; border: 1px solid var(--bb-line-strong); border-radius: var(--radius-pill); background: var(--bb-card); color: var(--ink); font: inherit; }
.collections-name-search input::-webkit-search-cancel-button { display: none; }
.collections-name-search-close { position: absolute; top: 50%; right: 6px; width: 36px; height: 36px; display: grid; place-items: center; transform: translateY(-50%); border: 0; border-radius: 50%; background: transparent; color: var(--bb-ink-2); font-size: 1.25rem; line-height: 1; cursor: pointer; }
.collections-name-search-close:hover { background: var(--bb-sunk); color: var(--ink); }
.collections-search-status { margin: 12px 0 0; color: var(--muted); font-size: 0.9375rem; }
.collections-search-status:empty { display: none; }
.collection-grid { margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr)); gap: 24px; list-style: none; }
.collection-card { min-width: 0; }
.collection-card-link {
  min-width: 0;
  height: 100%;
  padding: 14px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-lg);
  background: var(--bb-card);
  color: inherit;
  text-decoration: none;
  transition: border-color var(--bb-duration-ui) var(--bb-ease-out);
}
.collection-card-link:hover { border-color: var(--bb-line-strong); }
.collection-card[data-fresh="true"] .collection-card-link { border-color: var(--lime); box-shadow: 0 0 0 4px var(--bb-lime-ring); }
.collection-mosaic {
  min-width: 0;
  aspect-ratio: 5 / 3;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 3px;
  overflow: hidden;
  border-radius: calc(var(--radius-lg) - 8px);
  background: var(--bb-line);
}
.collection-tile { position: relative; min-width: 0; min-height: 0; display: grid; overflow: hidden; background: var(--bb-sunk); }
.collection-tile .capture-thumb { width: 100%; height: 100%; }
.collection-tile .capture-thumb[data-kind="image"], .collection-tile .capture-thumb[data-kind="link"] { height: 100%; }
.collection-tile .capture-image-preview { width: 100%; height: 100%; object-fit: cover; }
.collection-tile-text {
  margin: 0;
  padding: 12px 14px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  background: var(--bb-card);
  color: var(--ink);
  font-family: var(--bb-font-display);
  font-size: 1.125rem;
  line-height: 1.12;
  overflow-wrap: anywhere;
}
.collection-tile-empty { display: grid; place-items: center; color: var(--bb-subtle); }
.collection-tile-empty .bb-icon { width: 1.25rem; height: 1.25rem; stroke-width: 1.4; }
.collection-card-body { min-width: 0; padding: 18px 6px 6px; display: grid; gap: 10px; }
.collection-card-name { overflow-wrap: anywhere; font-family: var(--bb-font-display); font-size: clamp(2rem, 3vw, 2.5rem); font-weight: 400; line-height: 1; }
.collection-card-meta { min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; color: var(--muted); font-size: 0.9375rem; }
.collection-new { display: inline-flex; align-items: center; gap: 6px; color: var(--ink); font-weight: 600; }
.collection-new::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 1px rgba(16, 17, 20, 0.12); }
.collection-chip {
  margin-left: auto;
  min-height: 30px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: var(--radius-pill);
  background: var(--bb-sunk);
  color: var(--ink);
  font-size: 0.8125rem;
  font-weight: 600;
  white-space: nowrap;
}
.collection-chip .bb-icon { width: 0.9375rem; height: 0.9375rem; stroke-width: 2.25; }
.collection-card-description { margin: 0; color: var(--bb-ink-2); font-size: 0.9375rem; line-height: 1.5; overflow-wrap: anywhere; }
.collection-card-progress { color: var(--muted); font-size: 0.875rem; }
.collection-topline { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.collection-back { display: inline-flex; align-items: center; gap: 10px; }
.collection-back .bb-icon { width: 1.125rem; height: 1.125rem; }
.collection-status-chips { margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; list-style: none; }
.collection-status-chips li {
  min-height: 40px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-pill);
  background: var(--bb-card);
  font-size: 0.875rem;
  font-weight: 500;
}
.collection-status-chips .bb-icon { width: 1rem; height: 1rem; stroke-width: 2; }
.collection-detail-header { margin-top: 24px; }
.collection-detail-meta { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; color: var(--muted); font-size: 0.9375rem; }
.collection-detail-meta[data-files-itself="true"]::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 1px rgba(16, 17, 20, 0.12); }
.collection-detail-header h1 { margin-top: 8px; overflow-wrap: anywhere; font-size: clamp(2.75rem, 6vw, 4.75rem); }
.collection-detail-description { max-width: 52ch; margin: 18px 0 0; color: var(--bb-ink-2); font-size: 1.125rem; line-height: 1.5; }
.collection-tools { margin-top: 20px; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 12px; }
.collection-search { position: relative; min-width: 0; flex: 0 1 26rem; }
.collection-search-icon { position: absolute; top: 50%; left: 18px; width: 1.25rem; height: 1.25rem; transform: translateY(-50%); color: var(--bb-ink-2); pointer-events: none; }
.collection-search input { width: 100%; min-height: 52px; padding: 0 18px 0 50px; border: 1px solid var(--bb-line); border-radius: var(--radius-pill); background: var(--bb-card); color: var(--ink); font: inherit; }
.collection-menu-wrap { position: relative; }
.collection-menu-button { width: 52px; min-height: 52px; padding: 0; }
.collection-menu-dots { font-size: 0.75rem; letter-spacing: 0.12em; }
.collection-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 12;
  min-width: 14rem;
  padding: 6px;
  display: grid;
  border: 1px solid var(--bb-line);
  border-radius: var(--radius-sm);
  background: var(--bb-card);
  box-shadow: var(--bb-shadow-float);
}
.collection-menu-item { min-height: 44px; padding: 0 12px; display: flex; align-items: center; gap: 10px; border: 0; border-radius: 10px; background: transparent; color: var(--ink); font: inherit; font-weight: 500; text-align: left; cursor: pointer; }
.collection-menu-item:hover, .collection-menu-item:focus-visible { background: var(--bb-sunk); }
.collection-menu-item .bb-icon { width: 1rem; height: 1rem; }
.collection-menu-danger { color: var(--danger); }
.collection-layout { margin-top: 20px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; }
.collection-members-header { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; }
.collection-members-header h2 { margin: 0; overflow-wrap: anywhere; font-size: 1.5rem; font-weight: 600; }
.collection-members-order { margin: 0; color: var(--muted); font-size: 0.9375rem; }
.collection-search-status { min-height: 1.5em; margin: 8px 0 0; color: var(--muted); font-size: 0.9375rem; }
.collection-search-status:empty { min-height: 0; }
.collection-memory-list { margin-top: 18px; columns: 3 15rem; }
.capture-reason { margin: 0; padding: 0 20px 12px; color: var(--bb-ink-2); font-size: 0.875rem; line-height: 1.4; overflow-wrap: anywhere; }
.collection-load-more { margin-top: 8px; }
.collection-side { min-width: 0; display: grid; align-content: start; gap: 20px; }
.clue-panel, .missed-panel { min-width: 0; padding: 26px; border: 1px solid var(--bb-line); border-radius: var(--radius-lg); background: var(--bb-card); }
.clue-panel-header { position: relative; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.clue-panel h2, .missed-panel h2 { margin: 0; font-size: 1.1875rem; font-weight: 600; }
.clue-panel-help, .missed-panel p { margin: 12px 0 0; color: var(--bb-ink-2); line-height: 1.55; }
.clue-list { margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; list-style: none; }
.clue-chip {
  min-width: 0;
  max-width: 100%;
  min-height: 44px;
  padding: 0 6px 0 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: var(--radius-pill);
  background: var(--bb-sunk);
}
.clue-kind { color: var(--muted); white-space: nowrap; }
.clue-text { min-width: 0; overflow-wrap: anywhere; font-weight: 600; }
.clue-remove { width: 34px; height: 34px; flex: none; display: grid; place-items: center; border: 0; border-radius: 50%; background: transparent; color: var(--bb-ink-2); font-size: 1.125rem; line-height: 1; cursor: pointer; }
.clue-remove:hover { background: var(--bb-card); color: var(--ink); }
.clue-empty { margin: 14px 0 0; color: var(--muted); }
.add-clue-button {
  width: 100%;
  min-height: 56px;
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1.5px dashed var(--bb-line-strong);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.add-clue-button:hover { border-color: var(--ink); }
.add-clue-form { margin-top: 14px; display: grid; gap: 12px; }
.add-clue-field { display: grid; gap: 6px; }
.add-clue-field label { font-weight: 600; }
.add-clue-field select, .add-clue-field input { width: 100%; min-width: 0; min-height: 48px; padding: 0 13px; border: 1px solid var(--bb-line-strong); border-radius: 12px; background: var(--white); color: var(--ink); font: inherit; }
.add-clue-help { margin: 0; color: var(--muted); font-size: 0.875rem; line-height: 1.45; }
.add-clue-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.filing-progress { min-height: 1.5em; margin: 14px 0 0; color: var(--bb-ink-2); font-size: 0.9375rem; line-height: 1.45; }
.filing-progress:empty { min-height: 0; margin: 0; }
.filing-retry { margin-top: 10px; }
.filing-alert { margin: 16px 0 0; padding: 14px 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; border: 1px solid var(--bb-line); border-radius: var(--radius-lg); background: var(--bb-card); }
.filing-alert .filing-retry { margin-top: 0; }
.filing-alert-text { flex: 1 1 16rem; min-width: 0; margin: 0; color: var(--ink); font-size: 0.9375rem; line-height: 1.45; }
.add-clue-message:empty, .dialog-message:empty { min-height: 0; margin: 0; }
.add-clue-message { margin: 8px 0 0; color: var(--bb-ink-2); }
.dialog-message { margin: 12px 0 0; color: var(--bb-ink-2); }
.auto-filing-row { margin-top: 20px; padding-top: 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-top: 1px solid var(--bb-line); }
.auto-filing-copy { min-width: 0; }
.auto-filing-label { margin: 0; font-weight: 600; }
.auto-filing-help { margin: 2px 0 0; color: var(--muted); font-size: 0.875rem; }
.filing-switch {
  position: relative;
  width: 60px;
  height: 36px;
  flex: none;
  padding: 0;
  border: 1px solid var(--bb-line-strong);
  border-radius: var(--radius-pill);
  background: var(--bb-sunk);
  cursor: pointer;
}
.filing-switch-thumb { position: absolute; top: 4px; left: 4px; width: 26px; height: 26px; border-radius: 50%; background: var(--bb-card); box-shadow: 0 1px 2px rgba(16, 17, 20, 0.25); transition: transform var(--bb-duration-ui) var(--bb-ease-out); }
.filing-switch[aria-checked="true"] { border-color: var(--lime); background: var(--lime); }
.filing-switch[aria-checked="true"] .filing-switch-thumb { transform: translateX(24px); background: var(--ink); }
.filing-switch:disabled { cursor: not-allowed; opacity: 0.6; }
.add-by-hand-button { width: 100%; margin-top: 16px; }
.rename-collection-form > p { line-height: 1.55; }
@media (min-width: 1100px) {
  .collection-layout { grid-template-columns: minmax(0, 1fr) minmax(0, 30rem); align-items: start; }
  .collection-side { position: sticky; top: calc(var(--bb-topbar-height) + 16px); }
  .collection-memory-list { columns: 3 13rem; }
  .collection-tools { margin-top: -64px; }
  .collection-detail-description { max-width: min(52ch, calc(100% - 42rem)); }
}
.collection-form { min-width: 0; margin-top: 24px; display: flex; flex-wrap: wrap; align-items: end; gap: 12px; }
.collection-name-field { min-width: min(100%, 16rem); flex: 1 1 20rem; display: grid; gap: 6px; }
.collection-name-field label { font-weight: 600; }
.collection-name-field input { width: 100%; min-width: 0; min-height: 48px; padding: 11px 13px; border: 1px solid var(--bb-line-strong); border-radius: 12px; background: var(--white); color: var(--ink); font: inherit; }
.collection-name-field p { margin: 0; color: var(--muted); font-size: 0.8125rem; }
.collection-dialog { width: min(620px, calc(100% - 28px)); max-height: min(82vh, 760px); padding: clamp(20px, 4vw, 32px); overflow: auto; border: 1px solid var(--bb-line-strong); border-radius: var(--radius-lg); background: var(--paper); color: var(--ink); box-shadow: var(--bb-shadow-float); }
.collection-dialog::backdrop { background: rgba(16, 17, 20, 0.48); }
.collection-dialog h2 { margin: 3px 0 0; overflow-wrap: anywhere; font-family: var(--bb-font-display); font-size: 2rem; font-weight: 400; line-height: 1.05; }
.collection-dialog > p { line-height: 1.55; }
.dialog-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.manage-collections-list { margin: 20px 0 0; padding: 0; display: grid; border: 0; }
.manage-collection-option { min-width: 0; min-height: 48px; padding: 10px 4px; display: flex; align-items: center; gap: 11px; border-top: 1px solid var(--bb-line); overflow-wrap: anywhere; cursor: pointer; }
.manage-collection-option input { width: 1.25rem; height: 1.25rem; flex: none; accent-color: var(--ink); }
.manage-collection-option span { min-width: 0; flex: 1; }
.dialog-actions { margin-top: 24px; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
.account-deleted-message { margin: 0 0 22px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--bb-mark); line-height: 1.55; }
.privacy-card { margin-top: 28px; padding: clamp(20px, 4vw, 32px); border: 1px solid var(--bb-line); border-radius: var(--radius-md); background: var(--paper); }
.privacy-card h2 { margin: 4px 0 0; font-family: var(--bb-font-display); font-size: 2rem; font-weight: 400; line-height: 1.05; }
.privacy-card h3 { margin: 0 0 10px; font-size: 1.0625rem; font-weight: 600; }
.privacy-section { max-width: 66ch; margin-top: 26px; padding-top: 24px; border-top: 1px solid var(--bb-line); }
.privacy-section > p { line-height: 1.62; }
.danger-zone { max-width: none; padding: 24px; border: 1px solid rgba(180, 35, 24, 0.45); border-radius: var(--radius-sm); background: var(--bb-card); }
.danger-zone label { display: block; max-width: 66ch; margin-top: 20px; font-weight: 600; line-height: 1.5; }
.delete-confirmation { width: 100%; min-height: 48px; margin-top: 9px; padding: 11px 13px; border: 1px solid var(--bb-line-strong); border-radius: 12px; background: var(--white); color: var(--ink); }
.field-help { margin: 8px 0 16px; color: var(--muted); font-size: 0.9375rem; }
.settings-section-heading { margin: 44px 0 0; font-family: var(--bb-font-display); font-size: 2rem; font-weight: 400; line-height: 1.05; }
.settings-card { margin-top: 20px; padding: clamp(20px, 4vw, 32px); border: 1px solid var(--bb-line); border-radius: var(--radius-md); background: var(--paper); }
.settings-card h2 { margin: 4px 0 0; font-size: 1.375rem; font-weight: 600; }
.settings-card h3 { margin: 26px 0 10px; font-size: 1.0625rem; font-weight: 600; }
.settings-card > p, .setup-steps { max-width: 66ch; line-height: 1.6; }
.setup-steps { padding-left: 22px; }
.setup-steps li + li { margin-top: 8px; }
.settings-card code { overflow-wrap: anywhere; }
.secret-once { margin-top: 18px; padding: 18px; border: 1.5px solid var(--ink); border-radius: var(--radius-sm); background: var(--white); }
.secret-once > strong, .secret-once > code { display: block; }
.secret-once > code { margin-top: 12px; user-select: all; }
.settings-actions { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 10px; }
.endpoint-copy { margin: 18px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.endpoint-copy code { min-width: 0; flex: 1 1 280px; }
.settings-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 10px; }
.settings-list li { padding: 14px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; border-radius: 12px; background: var(--neutral); }
.settings-list p { margin: 0; line-height: 1.5; }

.mobile-nav, .mobile-capture { display: none; }
.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;
}
noscript { display: block; padding: 16px; text-align: center; background: var(--ink); color: var(--paper); }

/* Handwritten annotation layer (Joseph's Studio decision). Decorative only: real text in the
   hand font, fixed placement and rotation, no animation, no pointer events, hidden from
   assistive technology, desktop only (>= 1200px, or wider where a note needs a gutter). */
.bb-hand-note, .ink-spark {
  display: none;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}
.bb-hand-note {
  position: absolute;
  z-index: 1;
  color: var(--bb-hand-ink);
  font-family: var(--bb-font-hand);
  font-size: 1.875rem;
  font-weight: 500;
  line-height: 0.98;
  white-space: nowrap;
}
.hand-note-text { display: block; transform: rotate(-5deg); transform-origin: 0 100%; }
.ink-arrow, .ink-spark {
  fill: none;
  stroke: var(--bb-hand-ink);
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ink-arrow { display: block; width: 3.25rem; height: 2.875rem; }
.ink-spark { position: absolute; width: 1.625rem; height: 1.625rem; }

@media (min-width: 1200px) {
  .hand-note-safety, .hand-note-find, .hand-note-detail, .hand-note-fix { display: flex; }
  .hand-note-several, .hand-note-plain-words { display: flex; }
  .collections-several { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
  .collections-shelf-title { padding-right: 19rem; }
  .ink-spark { display: block; }
  /* Reserve rem-based room so the notes never meet text, even with enlarged text. */
  .find-header { padding-inline: 12rem; }
  .detail-original { --detail-note-reserve: 7.5rem; }
  .detail-memory { padding-top: 4.75rem; }
}
/* Notes that live in a side gutter appear only once the gutter exists. */
@media (min-width: 1360px) {
  .hand-note-capture { display: flex; }
  .hand-note-name-it { display: flex; }
  .app-shell:has(#workspace-status[data-kind="synced"]) .hand-note-greeting { display: flex; }
}
@media (min-width: 1440px) {
  .hand-note-evidence, .hand-note-vague { display: flex; }
}
/* BB-P05-T024 Collections notes (Joseph's approved Collections screenshots). */
.hand-note-name-it { top: -4.75rem; left: calc(100% + 10px); flex-direction: column; font-size: 1.875rem; }
.hand-note-name-it .hand-note-text { transform: rotate(-6deg); }
.ink-arrow-name-it { margin: 4px 0 0 4px; transform: scale(-1, 1) rotate(-12deg); }
.hand-note-several { position: absolute; top: -0.75rem; right: 0; flex-direction: row; font-size: 1.75rem; }
.hand-note-several .hand-note-text { transform: rotate(-3deg); }
.ink-arrow-several { display: none; }
.hand-note-plain-words { position: static; font-size: 1.625rem; }
.hand-note-plain-words .hand-note-text { transform: rotate(-4deg); }
.ink-arrow-plain-words { display: none; }
.hand-note-greeting { top: 58%; right: calc(100% + 18px); flex-direction: row; align-items: flex-end; }
.hand-note-greeting .hand-note-text { transform: rotate(-7deg); }
.ink-arrow-greeting { margin: 0 0 18px 4px; transform: scale(-1, -1) rotate(20deg); }
.hand-note-capture { top: 12px; left: calc(100% + 30px); flex-direction: column; }
.ink-arrow-capture { margin: 6px 0 0 18px; transform: rotate(12deg); }
.ink-spark-save { top: -0.9rem; right: -1.75rem; }
.composer { container-type: inline-size; }
@container (max-width: 40rem) { .ink-spark-save { display: none; } }
.hand-note-safety { position: relative; justify-self: end; margin: 6px 24px 0 0; flex-direction: column; }
.hand-note-safety .hand-note-text { margin-left: 2.5rem; }
.ink-arrow-safety { order: -1; margin: 0 0 2px; transform: scaleY(-1) rotate(-6deg); }
.hand-note-find { top: -0.5rem; right: 0; flex-direction: column; }
.ink-arrow-find { margin: 6px 0 0 34px; transform: rotate(6deg); }
.hand-note-evidence { top: 5.5rem; left: calc(100% + 26px); flex-direction: column; font-size: 1.75rem; }
.hand-note-evidence .hand-note-text { transform: rotate(5deg); }
.ink-arrow-evidence { margin: 8px 0 0 8px; transform: rotate(28deg); }
.hand-note-vague { top: -2.5rem; right: calc(100% + 18px); flex-direction: column; align-items: flex-end; font-size: 1.75rem; }
.ink-arrow-vague { margin: 4px 8px 0 0; transform: scaleX(-1) rotate(-60deg); }
.ink-spark-mascot { top: -14px; left: -32px; width: 1.25rem; height: 1.25rem; transform: scaleX(-1); }
.hand-note-detail { top: 28px; left: 32px; flex-direction: column; font-size: 2.125rem; }
.hand-note-detail .hand-note-text { transform: rotate(-6deg); }
.ink-arrow-detail { margin: 4px 0 0 96px; transform: scaleX(-1) rotate(-8deg); }
.hand-note-fix { top: 0.25rem; right: 12rem; flex-direction: row; align-items: flex-start; font-size: 1.625rem; }
.hand-note-fix .hand-note-text { transform: rotate(4deg); }
.ink-arrow-fix { width: 2.75rem; height: 2.5rem; margin: 12px 0 0 4px; transform: scaleX(-1) rotate(-30deg); }

@keyframes bb-results-settle {
  from { opacity: 0; transform: translate3d(0, 6px, 0); }
  to { opacity: 1; transform: none; }
}

/* Full catch, 1,100 ms: form 0-180, arc 180-690, reaction 690-990, resolve 920-1,100. */
@keyframes signature-memory-slip {
  0% { opacity: 0; transform: translate3d(0, 5px, 0) scale(0.72); }
  16.364% { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
  39.5% { opacity: 1; transform: translate3d(28px, -10px, 0) scale(0.78) rotate(3deg); }
  62.727% { opacity: 0; transform: translate3d(72px, 51px, 0) scale(0.2) rotate(8deg); }
  100% { opacity: 0; transform: translate3d(72px, 51px, 0) scale(0.2) rotate(8deg); }
}
@keyframes signature-mascot-catch {
  0%, 62.726% { transform: translate3d(0, 0, 0) scale(1); }
  75% { transform: translate3d(0, 2px, 0) scaleY(0.975) rotate(-0.6deg); }
  90%, 100% { transform: translate3d(0, 0, 0) scale(1); }
}
@keyframes signature-receipt-resolve {
  0%, 83.636% { opacity: 0; }
  100% { opacity: 1; }
}

/* Later-save catch, 640 ms: form 0-105, arc 105-395, reaction 395-535, resolve 460-640. */
@keyframes compact-memory-slip {
  0% { opacity: 0; transform: translate3d(0, 3px, 0) scale(0.78); }
  16.406% { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }
  40% { opacity: 1; transform: translate3d(24px, -6px, 0) scale(0.74) rotate(2deg); }
  61.719% { opacity: 0; transform: translate3d(70px, 50px, 0) scale(0.2) rotate(5deg); }
  100% { opacity: 0; transform: translate3d(70px, 50px, 0) scale(0.2) rotate(5deg); }
}
@keyframes compact-mascot-catch {
  0%, 61.718% { transform: translate3d(0, 0, 0) scale(1); }
  73% { transform: translate3d(0, 1px, 0) scaleY(0.99); }
  83.594%, 100% { transform: translate3d(0, 0, 0) scale(1); }
}
@keyframes compact-receipt-resolve {
  0%, 71.875% { opacity: 0; }
  100% { opacity: 1; }
}
@keyframes reduced-receipt-crossfade {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Roomy desktop: each column sizes its own content; gallery height never stretches detail spacing. */
@media (min-width: 1200px) {
  .detail-view {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 540px);
    column-gap: 56px;
    grid-template-rows: auto min-content minmax(0, 1fr);
    align-items: start;
  }
  .detail-view > .back-link { grid-column: 1 / -1; }
  .detail-header { grid-column: 2; grid-row: 2; }
  .detail-original-layout { display: contents; }
  .detail-content { grid-column: 2; grid-row: 3; }
  .detail-original {
    grid-column: 1;
    grid-row: 2 / span 2;
    position: sticky;
    top: calc(var(--bb-topbar-height) + 12px);
    min-height: min(calc(100vh - var(--bb-topbar-height) - 88px), 1010px);
    margin-top: 12px;
  }
  .detail-context { margin-top: 28px; }
}

@media (max-width: 900px) {
  .capture-page { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 1199px) {
  .dashboard-lower { grid-template-columns: minmax(0, 1fr); }
  .dashboard-side { grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); }
  .find-mascot { display: none !important; }
  .find-top:has(.find-mascot:not([hidden])) h2 { min-height: 0; padding-left: 0; }
  .find-best { grid-template-columns: minmax(0, 300px) minmax(0, 1fr); }
  .find-best > .find-best-body { padding: 26px 28px; }
}

@media (max-width: 1099px) {
  .app-topbar { padding: 0 24px; }
  .workspace-status { font-size: 0; gap: 0; }
  .rail-capture { padding: 0 12px; }
  .rail-capture span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
  .nav-item { padding: 0 14px; }
}

/* Below 900px: compact top bar and a floating bottom tab bar. */
@media (max-width: 899px) {
  :root { --bb-topbar-height: 64px; }
  .app-topbar { grid-template-columns: minmax(0, 1fr) auto; padding: 0 16px; }
  .desktop-nav, .rail-capture { display: none; }
  .brand-mark { height: 30px; }
  .brand-wordmark { height: 19px; }
  .workspace-status { font-size: 0.75rem; gap: 6px; }
  .account-avatar { width: 36px; height: 36px; font-size: 0.875rem; }
  .main-panel { padding: 20px 16px 132px; }
  html { scroll-padding-bottom: 116px; }
  .future-notice:not(:empty) { position: fixed; right: 16px; bottom: 112px; left: 16px; z-index: 11; margin: 0; box-shadow: var(--bb-shadow-float); }
  .workspace-header { align-items: flex-start; gap: 6px; text-align: left; }
  .workspace-header h1 { max-width: 100%; font-size: clamp(2.25rem, 10.5vw, 2.75rem); }
  .workspace-supporting { font-size: 0.9375rem; }
  .capture-area { margin-top: 18px; justify-items: stretch; }
  #capture-form { width: 100%; }
  .capture-card { padding: 16px 16px 12px; border-radius: 26px; }
  .capture-help { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
  .composer-text textarea { min-height: 60px; font-size: 1.25rem; }
  .composer-footnote { font-size: 0.75rem; }
  .save-feedback { min-height: 64px; border-radius: 28px; }
  .dashboard-lower { margin-top: 32px; gap: 28px; }
  .section-heading-row { margin-bottom: 14px; }
  .global-find { flex: 1 1 100%; margin-left: 0; }
  .shortcut-hint { display: none; }
  .find-header, .find-header h1 { text-align: left; }
  .find-header h1 { font-size: clamp(2rem, 9vw, 2.5rem); }
  .find-header > #find-helper { margin-left: 0; font-size: 0.9375rem; }
  .find-form { margin-top: 18px; }
  .find-form textarea { min-height: 60px; padding: 16px 104px 16px 46px; border-radius: 20px; font-size: 1rem; }
  .find-field-icon { top: 18px; left: 16px; width: 1.25rem; height: 1.25rem; }
  .find-button { min-height: 44px; margin: 8px 8px 0 0; padding: 0 18px; font-size: 0.9375rem; }
  .find-privacy { text-align: left; }
  .find-status-row { justify-content: flex-start; }
  .find-top h2 { font-size: 1.875rem; }
  .find-best { grid-template-columns: minmax(0, 1fr); border-radius: var(--radius-lg); }
  .find-best-thumb { min-height: 0; height: 170px; }
  .find-best > .find-best-body { padding: 16px 16px 18px; gap: 10px; }
  .find-result-title { font-size: 1.1875rem; }
  .find-best .find-result-snippet { font-size: 0.9375rem; }
  .find-best-actions .button { flex: 1 1 auto; }
  .find-other { margin-top: 28px; }
  .find-alternate-list { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .find-alternate { flex-direction: row; align-items: center; gap: 12px; padding: 10px 0; border: 0; border-top: 1px solid var(--bb-line); border-radius: 0; background: transparent; }
  .find-alternate .capture-thumb { width: 56px; height: 56px; flex: none; border-radius: 12px; }
  .find-alternate .capture-thumb .bb-icon { width: 1.5rem; height: 1.5rem; }
  .find-alternate .find-best-body { padding: 0; gap: 2px; }
  .detail-header h1 { font-size: clamp(2rem, 9vw, 2.25rem); }
  .detail-original { min-height: 300px; padding: 20px; border-radius: 26px; }
  .detail-body { padding: 20px; }
  .detail-memory, .detail-related, .detail-understanding { margin-top: 24px; }
  .secondary-view { padding: 24px 18px; border-radius: 24px; }
  .mobile-nav {
    position: fixed;
    right: 16px;
    bottom: 22px;
    left: 16px;
    z-index: 10;
    min-height: 74px;
    padding: 6px 4px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto minmax(0, 1.2fr) minmax(0, 1fr);
    align-items: center;
    gap: 2px;
    border: 1px solid var(--bb-line);
    border-radius: 30px;
    background: var(--bb-card);
    box-shadow: var(--bb-shadow-float);
  }
  .mobile-nav-item {
    min-width: 0;
    min-height: 58px;
    padding: 6px 0 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border: 0;
    border-radius: 22px;
    background: transparent;
    color: var(--bb-subtle);
    font-size: 0.6875rem;
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.01em;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
  }
  .mobile-nav-item .bb-icon { width: 1.375rem; height: 1.375rem; }
  .mobile-nav-item > span:last-child { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
  .mobile-nav-item-active { color: var(--ink); }
  .mobile-nav-item-active .bb-icon { stroke-width: 2; }
  .mobile-nav-item-active::after { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--ink); }
  .mobile-capture {
    width: 60px;
    height: 60px;
    margin: 0 2px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 22px;
    background: var(--lime);
    color: var(--ink);
    cursor: pointer;
  }
  .mobile-capture .bb-icon { width: 1.75rem; height: 1.75rem; stroke-width: 2.25; }
  .mobile-capture:active { background: var(--bb-lime-pressed); }
}

/* Switch only the shared navigation chrome to its compact layout when its own
   font-relative inline space is insufficient. At normal 16px text this aligns with
   the mobile breakpoint; at 200% text it prevents desktop header clusters from
   colliding without hiding Bucket, Find, Capture, account, or status access. */
@container app-shell (max-width: 56em) {
  .app-topbar { height: 64px; grid-template-columns: minmax(0, 1fr) auto; padding: 0 16px; }
  .desktop-nav, .rail-capture { display: none; }
  .brand-mark { height: 30px; }
  .brand-wordmark { height: 19px; }
  .workspace-status { font-size: 0.75rem; gap: 6px; }
  .account-avatar { width: 36px; height: 36px; font-size: 0.875rem; }
  .main-panel { padding-bottom: calc(5rem + 36px); }
  .future-notice:not(:empty) { position: fixed; right: 16px; bottom: calc(5rem + 32px); left: 16px; z-index: 11; margin: 0; box-shadow: var(--bb-shadow-float); }
  .bb-hand-note, .ink-spark { display: none !important; }
  .mobile-nav {
    position: fixed;
    right: 16px;
    bottom: 22px;
    left: 16px;
    z-index: 10;
    min-height: max(74px, 4.625rem);
    padding: 6px 4px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto minmax(0, 1.2fr) minmax(0, 1fr);
    align-items: center;
    gap: 2px;
    border: 1px solid var(--bb-line);
    border-radius: 30px;
    background: var(--bb-card);
    box-shadow: var(--bb-shadow-float);
  }
  .mobile-nav-item {
    min-width: 0;
    min-height: max(58px, 3.625rem);
    padding: 6px 2px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    border: 0;
    border-radius: 22px;
    background: transparent;
    color: var(--bb-subtle);
    font-size: 0.6875rem;
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.01em;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
  }
  .mobile-nav-item .bb-icon { width: 1.375rem; height: 1.375rem; }
  .mobile-nav-label { max-width: 100%; display: grid; justify-items: center; gap: 1px; }
  .mobile-nav-label > span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
  .mobile-nav-note { font-size: 0.5rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
  .mobile-nav-item-active { color: var(--ink); }
  .mobile-nav-item-active .bb-icon { stroke-width: 2; }
  .mobile-nav-item-active::after { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--ink); }
  .mobile-capture {
    width: max(60px, 3.75rem);
    height: max(60px, 3.75rem);
    margin: 0 2px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 22px;
    background: var(--lime);
    color: var(--ink);
    cursor: pointer;
  }
  .mobile-capture .bb-icon { width: 1.75rem; height: 1.75rem; stroke-width: 2.25; }
  .mobile-capture:active { background: var(--bb-lime-pressed); }
}

@media (max-width: 639px) {
  .capture-page { grid-template-columns: minmax(0, 1fr); }
  .collection-memory-list { columns: 1; }
  .collections-hero { text-align: left; }
  .collections-hero > p { margin-left: 0; font-size: 1.0625rem; }
  .collections-create { min-height: 0; padding: 12px; flex-wrap: wrap; border-radius: var(--radius-lg); }
  .collections-create input { flex: 1 1 10rem; font-size: 1.1875rem; }
  .collections-create-button { width: 100%; min-height: 52px; }
  .collections-create-help, .collections-status { text-align: left; }
  .collection-receipt { grid-template-columns: auto minmax(0, 1fr); border-radius: var(--radius-lg); }
  .collection-receipt-actions { grid-column: 1 / -1; }
  .collections-shelf { margin-top: 40px; }
  .collections-sort { width: 100%; justify-content: flex-start; }
  .collections-name-search { flex: 1 1 100%; }
  .collection-grid { gap: 16px; }
  .collection-tools { justify-content: stretch; }
  .collection-search { flex: 1 1 12rem; }
  .clue-panel, .missed-panel { padding: 20px 16px; }
  .capture-reason { padding: 0 14px 10px; font-size: 0.75rem; }
  .capture-item { margin-bottom: 12px; border-radius: 18px; }
  .capture-thumb { height: 5.5rem; }
  .capture-thumb[data-kind="image"] { height: 9.5rem; }
  .capture-thumb[data-kind="link"] { height: 4.5rem; }
  .capture-thumb[data-preview="image"] { height: auto; }
  .capture-thumb[data-preview="image"][data-media-aspect="portrait"] { min-height: 0; }
  .capture-body { padding: 14px 14px 7px; gap: 7px; }
  .capture-text { -webkit-line-clamp: 2; font-size: 1.1875rem; }
  .capture-text, .capture-file-name { font-size: 0.875rem; }
  .capture-item .capture-text { font-size: 1.1875rem; }
  .capture-file-meta, .capture-excerpt, .capture-user-context, .capture-generated-summary { font-size: 0.75rem; }
  .capture-meta { padding: 6px 14px 14px; gap: 6px 8px; font-size: 0.75rem; }
  .composer-actions { align-items: stretch; }
  .save-button { flex: 1 1 auto; justify-content: space-between; }
  .understanding-editor { padding-inline: 16px; }
  .danger-zone { padding: 18px 14px; }
  .privacy-card, .settings-card { padding: 20px 16px; }
}

@media (max-width: 440px) {
  .main-panel { padding-inline: 14px; }
  .auth-actions { display: grid; }
  .auth-actions .button { width: 100%; }
  .find-empty-actions .button { width: 100%; }
  .button-danger { width: 100%; }
  .collection-form > .button, .collection-actions > .button { width: 100%; }
  .dialog-header { display: grid; }
  .dialog-header .button { justify-self: start; }
  .save-feedback { align-items: center; gap: 8px; padding-inline: 8px 12px; }
  .signature-receipt { width: 64px; flex-basis: 64px; }
  .receipt-mascot-stage { width: 44px; }
  .mascot-slot[data-mascot-placement="receipt"] { width: 42px; }
  .receipt-idle-note { padding-left: 78px; padding-right: 10px; font-size: 0.8125rem; text-align: left; justify-content: flex-start; }
  .selected-file { grid-template-columns: auto minmax(0, 1fr); }
  .selected-file-actions { grid-column: 1 / -1; justify-content: flex-start; }
  /* Keep the composer to one row: the file control becomes a labelled icon button. */
  /* The text stays the control's accessible name; only its glyphs collapse. Icon size is rem-based. */
  .file-picker { width: 48px; min-height: 48px; padding: 0; gap: 0; font-size: 0; }
  .composer-actions { flex-wrap: nowrap; }
}

@media (max-width: 360px) {
  .empty-state { grid-template-columns: 1fr; gap: 12px; }
  .brand-wordmark { height: 16px; }
}

/* This font-relative container boundary is reached by the 320-360px shell only when text is
   enlarged to roughly 200%. Ordinary phone and every approved desktop layout stay unchanged. */
@container app-shell (max-width: 11.25em) {
  /* The full text remains in the accessibility tree; the existing status dot is the
     narrow visual treatment so enlarged text cannot collide with brand or account. */
  .workspace-status { font-size: 0; gap: 0; }
  /* At the minimum viewport, enlarged idle guidance must size the bar instead of escaping
     an absolutely positioned desktop line. The mascot and copy remain flex items in flow. */
  .save-feedback[data-kind="idle"][data-receipt-visible="false"] {
    min-height: 64px;
    height: auto;
    padding-block: 8px;
  }
  .save-feedback[data-kind="idle"][data-receipt-visible="false"] > .receipt-icon,
  .save-feedback[data-kind="idle"][data-receipt-visible="false"] > .save-feedback-copy,
  .save-feedback[data-kind="idle"][data-receipt-visible="false"] > #save-error { display: none; }
  .save-feedback[data-kind="idle"][data-receipt-visible="false"] .receipt-idle-note {
    min-width: 0;
    position: static;
    inset: auto;
    flex: 1 1 auto;
    padding: 0;
    align-items: flex-start;
  }
  .receipt-idle-note > span { min-width: 0; overflow-wrap: anywhere; }
  /* The approved label stays complete; only this enlarged minimum-width layout may wrap it. */
  .save-button { min-width: 0; padding-left: 14px; white-space: normal; line-height: 1.05; }
  .save-label { min-width: 0; overflow-wrap: normal; }
}

@media (forced-colors: active) {
  .bb-hand-note, .ink-spark {
    display: none !important;
  }
  input, textarea, .button, .nav-item, .mobile-nav, .capture-card, .capture-item, .composer, .global-find, .save-feedback,
  .rail-capture, .find-best, .find-alternate, .safety-card, .anywhere-card, .detail-original, .memory-current, .account-popover,
  .collection-card-link, .collection-dialog, .manage-collection-option, .collections-create, .collection-receipt,
  .clue-panel, .missed-panel, .clue-chip, .collection-status-chips li, .collection-chip, .filing-switch, .collection-menu,
  .collection-search input, .collections-sort select, .add-clue-button, .detail-collection-list li,
  .collections-name-search input {
    border: 1px solid CanvasText;
    box-shadow: none;
  }
  .nav-item-active, .mobile-nav-item-active, .rail-link[aria-current="page"] { outline: 2px solid Highlight; }
  input:not(:is(:not([type]), [type="text"], [type="search"], [type="email"], [type="password"], [type="url"], [type="tel"], [type="number"])):focus-visible, button:focus-visible, a:focus-visible, summary:focus-visible, [tabindex]:focus-visible {
    outline: 3px solid Highlight;
    box-shadow: none;
  }
  /* Text fields add no BrainBucket outline here; the browser's own forced-colors focus indicator is kept. */
  input:is(:not([type]), [type="text"], [type="search"], [type="email"], [type="password"], [type="url"], [type="tel"], [type="number"]):focus-visible, textarea:focus-visible { outline: revert; }
  .find-alternate:has(.find-result-link:focus-visible) { outline: 3px solid Highlight; box-shadow: none; }
  .workspace-status::before, .capture-sync, .receipt-icon, .receipt-check, .memory-slip, .status-dot, .privacy-dot { border: 1px solid CanvasText; }
  .find-form textarea { box-shadow: none; }
  .collection-card[data-fresh="true"] .collection-card-link { outline: 2px solid Highlight; box-shadow: none; }
  .filing-switch[aria-checked="true"] { background: Highlight; }
  .filing-switch-thumb { border: 1px solid CanvasText; }
  .collection-new::before, .collection-detail-meta[data-files-itself="true"]::before { border: 1px solid CanvasText; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
  .memory-slip { display: none !important; }
  .save-feedback[data-receipt-motion="full"] .mascot-slot[data-mascot-placement="receipt"],
  .save-feedback[data-receipt-motion="compact"] .mascot-slot[data-mascot-placement="receipt"] {
    animation: none !important;
    transform: none !important;
  }
  .save-feedback[data-receipt-motion="full"] .signature-receipt,
  .save-feedback[data-receipt-motion="full"] .save-feedback-copy,
  .save-feedback[data-receipt-motion="compact"] .signature-receipt,
  .save-feedback[data-receipt-motion="compact"] .save-feedback-copy {
    animation: reduced-receipt-crossfade 120ms ease-out both !important;
  }
  .receipt-check { opacity: 1; transform: none; }
}
