/* Mamori guides, /guides/, privacy, terms, support and 404: dark mode (draft 15 Nov 2026).
   Loaded only with media="(prefers-color-scheme: dark)"; rules also wrapped in the same query.
   Same palette as the homepage dark mode and /help/. */
@media (prefers-color-scheme: dark) {
html:root {
  color-scheme: dark;
  --paper: #1c1916;
  --paper-2: #2c2723;
  --paper-3: #26221e;
  --ink: #f1ebe3;
  --ink-2: #ddd4c9;
  --ink-3: #b9afa4;
  --shu: #e0533a;
  --shu-deep: #f08a73;
  --shu-soft: #6b3326;
  --line: rgba(241, 235, 227, .12);
  --line-strong: rgba(241, 235, 227, .28);
  --focus: #f1ebe3;
  --on-ink: #1c1916;
  --mk-out: #fbf6ec;
  --mk-in: #1c1714;
  --mk-tor: #fbf6ec;
  --dawn: #2a211d;
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .8 0 0 0 0 .72 0 0 0 0 .62 0 0 0 .045 0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)'/%3E%3C/svg%3E");
  --fibre: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='600'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.004 .06' numOctaves='2' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 .8 0 0 0 0 .72 0 0 0 0 .62 0 0 0 .018 0'/%3E%3C/filter%3E%3Crect width='600' height='600' filter='url(%23f)'/%3E%3C/svg%3E");
}
/* the same grain and washi fibres as light mode, drawn light-on-dark and faint (brown fibres read as wood streaks on dark) */
html:root body { background-color: var(--paper); background-image: var(--grain), var(--fibre); }
html:root .brand { background: url(/assets/dark-v1/lockup-dark.svg) left center / contain no-repeat; }
html:root .brand .lockup { opacity: 0; }

/* the hanko seal on the short-answer box is art: light-mode vermilion with paper-white kana */
html:root .g-wrap .tldr::after { background: #c3371f; color: #f6efe2; }
html:root .seal, html:root .stamp, html:root .trust-seal { --shu: #c3371f; --on-ink: #f6efe2; }

/* the emphasised CTA box and the /guides/ banner were sumi-on-paper; on dark they become the night plum of the homepage bands */
html:root .g-wrap .mcta.e, html:root .gx-banner { background: #2b1d25; border-color: rgba(241, 235, 227, .14); color: #f1ebe3; }
html:root .g-wrap .mcta.e p, html:root .gidx .gx-banner p { color: #ddd4c9; }
html:root .g-wrap .mcta.e b, html:root .gidx .gx-banner b { color: #f1ebe3; }
html:root .g-wrap .mcta.e .mb a, html:root .gx-banner .btn { background: #f1ebe3; border-color: #f1ebe3; color: #1c1916; }
html:root .g-wrap .mcta.e .mb a:hover, html:root .gx-banner .btn:hover { background: #f08a73; border-color: #f08a73; color: #1c1916; }
html:root .g-wrap .mcta.e :focus-visible { outline-color: #f1ebe3; }
/* the charm's pink glow in the side rail: softer on dark */
html:root .rail-glow { opacity: .45; }
}
