/* ───────── SUMI · ink on washi (loaded last, wins over every older look) ─────────
   Warm washi paper with fibres, sumi ink for text and lines, one vermilion seal colour for what
   matters. Headlines in a brush-cut Mincho, body in a calm Gothic. The navigation is a hanging
   scroll on the right: one kanji seal per tool. Panels are sheets of paper with a brushed top edge;
   hovering one presses a small red seal into its corner. */

@property --seal { syntax: '<length>'; inherits: false; initial-value: 0px; }
:root {
  --rail-w: 104px; --side-w: 0px; --nav-h: 76px;
  --paper: #F1EADB; --paper-2: #E8DFCB; --paper-3: #F8F3E8; --paper-4: #FFFCF5;
  --sumi: #1B1815; --sumi-2: #3B352E; --sumi-3: #6A6156; --sumi-4: #978C7E;
  --shu: #C2381F; --shu-2: #A02C17; --shu-soft: rgba(194, 56, 31, .10);
  --moss: #4C6B3C; --ochre: #9C6E25; --ai: #2F4B64;
  --display: 'Shippori Mincho B1', 'Noto Serif CJK JP', 'Noto Serif JP', 'Hiragino Mincho ProN', Georgia, serif;
  --brush: 'Yuji Syuku', 'Noto Serif CJK JP', 'Shippori Mincho B1', serif;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --brushline: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 300 8' preserveAspectRatio='none'%3E%3Cpath d='M1 3.6C30 2.2 62 3.9 96 2.8S170 3.6 210 2.4 270 3.4 299 2.6L299 4.6C262 6.2 230 4.4 190 5.6S120 4.6 80 6 20 5.2 1 5.4Z' fill='%231B1815' fill-opacity='.82'/%3E%3C/svg%3E");
  --brushstroke: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 40' preserveAspectRatio='none'%3E%3Cpath d='M4 22C10 8 40 6 80 7S160 4 192 9C199 12 198 24 192 30 160 36 110 33 70 35S12 38 6 32C2 29 2 25 4 22Z' fill='black'/%3E%3C/svg%3E");
}
html body, html body[data-module] {
  --bg: var(--paper); --surface: var(--paper-3); --surface-2: var(--paper-2);
  --line: rgba(27, 24, 21, .16); --line-2: rgba(27, 24, 21, .09);
  --ink: var(--sumi); --mute: #5E564C; --dim: #8A8073;
  --green: var(--moss); --amber: var(--ochre); --red: var(--shu);
  --accent: var(--shu); --accent-ink: #FFF8EC; --accent-soft: var(--shu-soft);
  --sans: 'Zen Kaku Gothic New', 'Noto Sans CJK JP', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'DM Mono', ui-monospace, 'DejaVu Sans Mono', monospace;
  --serif: var(--display);
  --panel: var(--paper-3);
  --red-hi: var(--shu); --wire: var(--sumi); --hi: var(--shu); --hi-ink: #FFF8EC; --pen: var(--sumi);
  color-scheme: light;
}
html, html:has(body[data-module]) { background: var(--paper) !important; }
body {
  background-color: var(--paper) !important;
  background-image:
    radial-gradient(ellipse 70% 55% at 75% 8%, rgba(255, 252, 244, .9), transparent 70%),
    radial-gradient(ellipse 60% 50% at 10% 100%, rgba(214, 199, 170, .35), transparent 70%) !important;
  background-attachment: fixed !important;
  padding-left: 0 !important; padding-right: var(--rail-w);
  color: var(--sumi); font-family: var(--sans); font-size: 15px;
}
/* washi fibres + grain above the background, under everything else */
body::before {
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 0; opacity: .9;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.012 .09' numOctaves='3' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 .45 0 0 0 0 .38 0 0 0 0 .28 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23f)'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .25 0 0 0 0 .2 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}
#view, .toasts, .modal, .help-fab, .tour, .tour-offer { position: relative; z-index: 1; }
.help-fab, .toasts, .tour-offer { position: fixed; }
.tour { position: fixed; z-index: 90; }
.modal { position: fixed; z-index: 80; }
#backdrop { left: 0 !important; right: var(--rail-w) !important; }
::selection { background: var(--shu); color: #FFF8EC; }
:focus-visible { outline: 1.5px solid var(--shu) !important; outline-offset: 3px; }
#view:focus, #view:focus-visible, main:focus { outline: none !important; }
a { text-underline-offset: 3px; }

/* ═════════════ type ═════════════ */
#view h1, #view h2, .dialog h3 {
  font-family: var(--display) !important; font-weight: 800 !important; text-transform: none !important; letter-spacing: -.01em !important;
  color: var(--sumi) !important; background: none !important; -webkit-text-fill-color: currentColor; text-shadow: none !important; animation: none;
}
#view h1 { line-height: 1.04 !important; }
#view h1 em, #view h2 em, #view h1 .acc { font-style: normal !important; font-weight: 800 !important; color: var(--shu) !important; -webkit-text-fill-color: var(--shu); background: none !important; box-shadow: none !important; padding: 0 !important; display: inline; }
#view h3 { font-family: var(--display); font-weight: 700; letter-spacing: 0; }
.serif, .hub-line, .ag-dname, .ag-card-h b, .ag-stats b, .ag-howno, .mu-cb b, .ag-brand { font-family: var(--display) !important; font-style: normal !important; }
.label, body[data-module] .label { font-family: var(--mono) !important; letter-spacing: .14em !important; color: var(--sumi-3) !important; text-transform: uppercase; font-weight: 500; }
.mute { color: var(--mute) !important; } .dim { color: var(--dim) !important; }
a.acc, .acc { color: var(--shu) !important; }
.mono, code { font-family: var(--mono) !important; }
.up { color: var(--moss) !important; } .down { color: var(--shu) !important; } .warn { color: var(--ochre) !important; }
.koe-ul { height: 8px; } .koe-ul path { stroke: var(--shu) !important; stroke-width: 3 !important; fill: none; stroke-linecap: round; opacity: 1 !important; }

/* brush underline under every page title (sumi.js adds .su-brush after the h1) */
.su-brush { display: block; height: 12px; margin: 10px 0 2px; pointer-events: none; width: var(--w, 220px); max-width: 100%; }
.su-brush svg { width: 100%; height: 100%; display: block; overflow: visible; }
.su-brush path { fill: none; stroke: var(--shu); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 1000; stroke-dashoffset: 1000; animation: suBrush 1.1s var(--ease) .3s forwards; }
.su-brush path + path { stroke: var(--sumi); stroke-width: 1.4; opacity: .55; animation-delay: .55s; }
@keyframes suBrush { to { stroke-dashoffset: 0; } }

/* small red seal with a kanji, used inline */
.su-seal { display: inline-grid; place-items: center; width: 22px; height: 22px; background: var(--shu); color: #FFF8EC; font: 400 14px/1 var(--brush); border-radius: 2px; transform: rotate(-3deg); flex: none; }
.su-seal.lg { width: 44px; height: 44px; font-size: 28px; }

/* ═════════════ the scroll on the right: navigation ═════════════ */
.nav.rail {
  position: fixed; inset: 0 0 0 auto; left: auto; width: var(--rail-w); z-index: 45; display: flex; flex-direction: column; align-items: center;
  padding: 18px 0 14px; background: linear-gradient(90deg, rgba(232, 223, 203, .0), rgba(232, 223, 203, .65) 18%), var(--paper-3);
  border-left: 1px solid var(--line); height: 100vh; height: 100dvh; grid-template-columns: none;
}
/* the scroll's wooden rods */
.nav.rail::before, .nav.rail::after { content: ''; position: absolute; left: 8px; right: 8px; height: 6px; background: linear-gradient(#5A4632, #2A2016); border-radius: 3px; box-shadow: 0 1px 0 rgba(255, 255, 255, .4) inset; }
.nav.rail::before { top: 4px; } .nav.rail::after { bottom: 4px; }
.nav.rail .brand { display: grid; justify-items: center; gap: 2px; color: var(--sumi); margin-bottom: 8px; position: relative; }
.sumi-mark { width: 54px; height: 54px; overflow: visible; flex: none; }
.sumi-mark .sm-enso { fill: none; stroke: var(--sumi); stroke-width: 7; stroke-linecap: round; stroke-dasharray: 260; stroke-dashoffset: 0; transition: stroke-dashoffset .1s; }
.sumi-mark .sm-k { font: 400 38px/1 var(--brush); fill: var(--sumi); }
.sumi-mark .sm-seal { fill: var(--shu); transform-origin: 78px 78px; transform: rotate(-6deg); }
.brand:hover .sumi-mark .sm-enso { animation: ensoRedraw 1.1s var(--ease); }
@keyframes ensoRedraw { from { stroke-dashoffset: 260; } to { stroke-dashoffset: 0; } }
.brand-word { font: 800 15px/1 var(--display) !important; letter-spacing: .32em !important; text-transform: uppercase; padding-left: .32em; color: var(--sumi); }
.rail-body { display: contents; }
.nav.rail .modnav { position: static; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 0 0; border: 0; border-radius: 0; background: none; opacity: 1; transform: none; flex: 1; min-height: 0; }
.nav.rail .modnav a {
  position: relative; display: grid; justify-items: center; gap: 3px; width: 78px; padding: 7px 0 6px; border-radius: 4px; border: 0;
  color: var(--sumi); text-transform: none; letter-spacing: 0; font-size: 0; transition: background .25s, color .25s;
}
.nav.rail .modnav a i {
  display: grid; place-items: center; width: 40px; height: 40px; font: 400 25px/1 var(--brush); font-style: normal; color: var(--sumi);
  border: 1.5px solid transparent; border-radius: 3px; transition: color .25s, background .25s, border-color .25s, transform .35s var(--ease);
}
.nav.rail .modnav a em { font: 500 9.5px/1 var(--mono); font-style: normal; letter-spacing: .12em; text-transform: uppercase; color: var(--sumi-3); transition: color .2s; }
/* the paper slip that slides out to the left with the tool's name */
.nav.rail .modnav a > span {
  position: absolute; right: calc(100% + 14px); top: 50%; transform: translate(10px, -50%); opacity: 0; pointer-events: none; white-space: nowrap;
  display: grid; gap: 4px; padding: 10px 16px 10px 14px; background: var(--paper-4); border: 1px solid var(--line); border-right: 3px solid var(--shu);
  font: 700 17px/1.1 var(--display); color: var(--sumi); box-shadow: 0 10px 30px -18px rgba(40, 30, 20, .55);
  transition: opacity .2s, transform .3s var(--ease);
}
.nav.rail .modnav a > span small { font: 400 12px/1.2 var(--sans); color: var(--mute); }
.nav.rail .modnav a:hover > span, .nav.rail .modnav a:focus-visible > span { opacity: 1; transform: translate(0, -50%); }
.nav.rail .modnav a:hover i { border-color: var(--sumi); transform: rotate(-4deg); }
.nav.rail .modnav a[aria-current="page"], .nav.rail .modnav a:hover { background: none !important; color: var(--sumi) !important; box-shadow: none !important; }
.nav.rail .modnav a[aria-current="page"] i { background: var(--shu); color: #FFF8EC; border-color: var(--shu); transform: rotate(-3deg); }
.nav.rail .modnav a[aria-current="page"] em { color: var(--shu); }
.nav.rail .modnav a + a::before { content: ''; position: absolute; top: -2px; left: 32px; right: 32px; height: 1px; background: var(--line-2); }
.nav-ink { display: none; }
.nav.rail .menu-btn { display: none; }

/* tools: top right, on the paper strip */
.rail-tools { position: fixed; top: 16px; right: calc(var(--rail-w) + 20px); z-index: 46; display: flex; align-items: center; gap: 8px; }
.su-crumb {
  position: fixed; top: 0; left: 0; right: var(--rail-w); height: var(--nav-h); z-index: 40; display: flex; align-items: center; gap: 12px; padding: 0 var(--gut);
  background: linear-gradient(var(--paper) 62%, rgba(241, 234, 219, 0)); pointer-events: none;
  font: 500 10.5px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--sumi-3);
}
.su-crumb-k { font: 400 24px/1 var(--brush); color: var(--shu); letter-spacing: 0; }
.su-crumb-t { color: var(--sumi); font: 700 15px/1 var(--display); letter-spacing: .02em; text-transform: none; }
.su-crumb .flip { animation: crumbIn .55s var(--ease); }
@keyframes crumbIn { from { opacity: 0; transform: translateY(6px); filter: blur(3px); } }
.guide-btn { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px 0 8px; border: 1px solid var(--line) !important; border-radius: 20px; background: var(--paper-3); color: var(--sumi) !important; font: 500 13px/1 var(--sans) !important; letter-spacing: 0 !important; text-transform: none; transition: border-color .2s, background .2s; }
.guide-btn span, .help-fab span { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--sumi); color: var(--paper-3) !important; font: 500 12px/1 var(--mono); border: 0 !important; }
.guide-btn:hover { border-color: var(--sumi) !important; background: var(--paper-4); }
.rail-tools .ca-chip { height: 36px; padding: 0 12px; gap: 10px; border-radius: 20px !important; background: var(--paper-3) !important; border: 1px solid var(--line) !important; }
.rail-tools .x-link { display: inline-flex; width: 36px; height: 36px; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 50%; background: var(--paper-3); color: var(--sumi); }
.rail-tools .x-link:hover { border-color: var(--sumi); }
.rail-tools .net { height: 36px; padding: 0 12px; border: 1px solid var(--line); border-radius: 20px; background: var(--paper-3); color: var(--sumi-3); }
.wbtn { position: relative; isolation: isolate; overflow: hidden; height: 36px; padding: 0 18px; border-radius: 20px !important; border: 1.5px solid var(--sumi) !important; background: var(--sumi) !important; color: var(--paper-3) !important; font: 700 13px/1 var(--sans) !important; letter-spacing: .06em !important; text-transform: uppercase; transition: color .25s, border-color .25s; }
.wbtn::before { content: ''; position: absolute; inset: -2px -10px; z-index: -1; background: var(--shu); -webkit-mask: var(--brushstroke) center / 100% 100% no-repeat; mask: var(--brushstroke) center / 100% 100% no-repeat; transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); }
.wbtn:hover { border-color: var(--shu) !important; }
.wbtn:hover::before { transform: scaleX(1); }
.wbtn.on { background: var(--paper-3) !important; color: var(--sumi) !important; border-color: var(--line) !important; font: 500 12px/1 var(--mono) !important; letter-spacing: 0 !important; text-transform: none; }
.wbtn.on::before { display: none; }
.dot { background: var(--sumi-4); } .up .dot, .dot.up, .net.ok .dot { background: var(--moss); }

@media (max-height: 760px) and (min-width: 1001px) {
  .nav.rail .modnav a { padding: 4px 0; } .nav.rail .modnav a i { width: 34px; height: 34px; font-size: 22px; } .nav.rail .modnav a em { display: none; }
  .sumi-mark { width: 44px; height: 44px; }
}
@media (max-width: 1240px) and (min-width: 1001px) { .rail-tools .net-label, .rail-tools .guide-btn em { display: none; } .rail-tools .guide-btn { padding: 0 8px; } .rail-tools .ca-chip .ca-long { display: none; } }

/* phones and small tablets: a top bar, the scroll opens as a full sheet */
@media (max-width: 1000px) {
  :root { --rail-w: 0px; --nav-h: 62px; }
  body { padding-right: 0; }
  .nav.rail { inset: 0 0 auto 0; left: 0; width: 100%; height: 62px; flex-direction: row; align-items: center; justify-content: space-between; padding: 0 var(--gut); border-left: 0; border-bottom: 1px solid var(--line); background: var(--paper-3); }
  .nav.rail::before { display: none; } .nav.rail::after { left: 0; right: 0; bottom: -1px; height: 3px; border-radius: 0; }
  .nav.rail .brand { display: flex; align-items: center; gap: 10px; margin: 0; }
  .sumi-mark { width: 40px; height: 40px; }
  .brand-word { font-size: 17px !important; }
  .nav.rail .menu-btn { display: inline-grid; place-items: center; width: 42px; height: 42px; border: 1.5px solid var(--sumi); border-radius: 50%; gap: 5px; align-content: center; }
  .nav.rail .menu-btn span { display: block; width: 16px; height: 1.5px; background: var(--sumi); transition: transform .3s var(--ease); }
  .nav.rail .menu-btn[aria-expanded="true"] span:first-child { transform: translateY(3.2px) rotate(45deg); } .nav.rail .menu-btn[aria-expanded="true"] span:last-child { transform: translateY(-3.2px) rotate(-45deg); }
  .rail-body { display: flex; flex-direction: column; position: fixed; top: 62px; left: 0; right: 0; bottom: 0; padding: 14px var(--gut) 24px; overflow-y: auto; background: var(--paper); transform: translateY(-10px); opacity: 0; pointer-events: none; transition: opacity .25s, transform .35s var(--ease); }
  .rail-body.open { transform: none; opacity: 1; pointer-events: auto; }
  .rail-body:not(.open) * { pointer-events: none !important; }
  .nav.rail .modnav { flex: none; align-items: stretch; gap: 0; padding: 0; }
  .nav.rail .modnav a { width: auto; display: flex; align-items: center; gap: 14px; padding: 12px 4px; border-radius: 0; border-bottom: 1px solid var(--line-2); }
  .nav.rail .modnav a + a::before { display: none; }
  .nav.rail .modnav a em { display: none; }
  .nav.rail .modnav a > span { position: static; opacity: 1; transform: none; padding: 0; background: none; border: 0; box-shadow: none; font-size: 19px; pointer-events: auto; }
  .rail-tools { position: static; flex-wrap: wrap; margin-top: 18px; gap: 10px; }
  .rail-tools .wbtn { flex: 1 1 100%; height: 46px; order: -1; }
  .su-crumb { right: 0; top: 62px; height: 40px; background: linear-gradient(var(--paper) 50%, rgba(241, 234, 219, 0)); display: none; }
}

/* ═════════════ one set of controls for every module ═════════════ */
#view *:not(.dot):not(.d):not(.hub-dot):not(.ot-hint-dot):not(.vc-net):not(.mu-chamber):not(.hub-pv-art):not(.ag-sketch):not(.au-la):not(.tl-screen):not(.su-round), .dialog, .dialog *, .toast, .state, .input, .select, .textarea, .chip, .seg, .ca-chip, .ca-big { border-radius: 3px !important; }
#view *, .dialog, .toast { text-shadow: none !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
#view *:not(.su-shadow) { box-shadow: none !important; }
html body .btn {
  position: relative; isolation: isolate; overflow: hidden;
  height: 44px; padding: 0 20px; border: 1.5px solid var(--sumi) !important; border-radius: 3px !important; background: transparent !important; color: var(--sumi) !important;
  font: 700 14px/1 var(--sans) !important; letter-spacing: .04em !important; text-transform: none !important; animation: none !important; transition: color .3s, border-color .3s, transform .15s !important;
}
html body .btn::before { content: ''; position: absolute; inset: -4px -14px; z-index: -1; background: var(--sumi); -webkit-mask: var(--brushstroke) center / 100% 100% no-repeat; mask: var(--brushstroke) center / 100% 100% no-repeat; transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); }
html body .btn:hover { color: var(--paper-4) !important; background: transparent !important; }
html body .btn:hover::before { transform: scaleX(1); }
html body .btn:active { transform: translateY(1px); }
html body .btn.primary { background: var(--shu) !important; border-color: var(--shu) !important; color: #FFF8EC !important; }
html body .btn.primary:hover { border-color: var(--sumi) !important; }
html body .btn.sm { height: 34px; padding: 0 13px; font-size: 13px !important; }
html body .btn:disabled { opacity: .4; } html body .btn:disabled::before { display: none; }
html body .btn .arrow { display: inline-block; transition: transform .25s var(--ease); }
html body .btn:hover .arrow { transform: translate(2px, -2px); }
html body .input, html body .select, html body .textarea {
  background: var(--paper-4) !important; border: 1px solid var(--line) !important; border-bottom: 1.5px solid var(--sumi) !important; color: var(--sumi) !important;
  font-family: var(--sans); caret-color: var(--shu); border-radius: 3px 3px 0 0 !important;
}
html body .input.mono, html body .textarea.mono { font-family: var(--mono) !important; }
html body .input::placeholder, html body .textarea::placeholder { color: rgba(27, 24, 21, .4); }
html body .input:focus, html body .select:focus, html body .textarea:focus { border-color: var(--line) !important; border-bottom-color: var(--shu) !important; background: #FFFFFF !important; outline: none !important; box-shadow: 0 2px 0 0 var(--shu) !important; }
html body .chip { border: 1px solid var(--line) !important; color: var(--sumi-2) !important; background: var(--paper-3) !important; font-family: var(--mono) !important; border-radius: 20px !important; }
html body .chip.on, html body .chip:hover { color: var(--shu) !important; border-color: var(--shu) !important; background: var(--shu-soft) !important; }
html body .seg { border: 1px solid var(--line) !important; background: var(--paper-3) !important; padding: 3px; border-radius: 22px !important; }
html body .seg button { font-family: var(--sans) !important; font-weight: 500; color: var(--sumi-2) !important; border-radius: 18px !important; text-transform: none; letter-spacing: 0; }
html body .seg button.on { background: var(--sumi) !important; color: var(--paper-4) !important; }
html body .state { background: var(--paper-3) !important; border: 1px dashed rgba(27, 24, 21, .28) !important; color: var(--sumi-2); }
html body .dialog { background: var(--paper-3) !important; border: 1px solid var(--line) !important; color: var(--sumi); box-shadow: 0 30px 80px -30px rgba(40, 30, 20, .6) !important; }
html body .dialog::before { content: ''; display: block; height: 7px; background: var(--brushline) 0 0 / 100% 100% no-repeat; margin: -22px -22px 6px; }
html body .toast { background: var(--paper-4) !important; border: 1px solid var(--line) !important; border-left: 4px solid var(--shu) !important; color: var(--sumi) !important; box-shadow: 0 14px 40px -20px rgba(40, 30, 20, .55) !important; }
html body .modal { background: rgba(40, 32, 24, .42) !important; }
html body .tbl th { font-family: var(--mono); color: var(--sumi-3) !important; border-bottom: 1.5px solid var(--sumi) !important; text-transform: uppercase; letter-spacing: .1em; font-size: 11px; background: transparent !important; }
html body .tbl td { border-bottom: 1px solid var(--line-2) !important; color: var(--sumi); }
html body .tbl tbody tr[data-href]:hover td, html body .tbl tbody tr:hover td { background: var(--shu-soft) !important; }
html body .skel { background: linear-gradient(90deg, var(--paper-2) 0, #F3ECDD 40%, var(--paper-2) 80%) !important; background-size: 300% 100% !important; }
.ca-chip { border: 1px solid var(--line) !important; background: var(--paper-3) !important; color: var(--sumi) !important; }
.ca-chip .ca-k, .ca-chip .ca-c { color: var(--shu) !important; }
.ca-big { border: 1px solid var(--line) !important; background: var(--paper-3) !important; color: var(--sumi) !important; }
.ca-big .label { color: var(--shu) !important; }
.ca-big .ca-act { background: var(--sumi) !important; color: var(--paper-4) !important; font-family: var(--sans); font-weight: 700; }
.x-link:hover { color: var(--shu) !important; }
.logo-ph { background: var(--paper-2) !important; color: var(--sumi) !important; font-family: var(--display); }
.foot { border-top: 0 !important; position: relative; color: var(--sumi-3); }
.foot::before { content: ''; position: absolute; left: var(--gut); right: var(--gut); top: 0; height: 6px; background: var(--brushline) 0 0 / 100% 100% no-repeat; opacity: .5; }
.empty { color: var(--mute); }

/* every panel in every module: a sheet of paper with a brushed top edge and a seal on hover */
.mu-card, .mu-sec, .mu-dimg, .mu-par, .mu-chip, .mu-ch-label,
.au-art, .au-lotart, .au-bidbox, .au-asset, .au-mine, .au-flow,
.ot-sec, .ot-mkt, .otw-step, .ot-tokbox, .ot-pill,
.ag-tape, .ag-card, .panel, .ag-dhead, .ag-kpis, .ag-preview, .ag-tip,
.lc-col, .lc-sec, .lc-verdict,
.vc-sec, .vc-verdict, .vc-graph,
.hub-faq details, .adm-card, .adm-wallet, .tl-panel,
.tl-coin, .tl-rules > div, .tl-cmd, .tl-kpis {
  background:
    linear-gradient(var(--shu), var(--shu)) right 12px top 14px / var(--seal) var(--seal) no-repeat,
    var(--brushline) 0 0 / 100% 6px no-repeat,
    var(--paper-3) !important;
  border: 1px solid var(--line-2) !important; border-top: 0 !important; color: var(--sumi);
  transition: --seal .3s var(--ease), border-color .25s, transform .35s var(--ease), background-color .25s !important;
}
.mu-card:hover, .ag-card:hover, .tl-coin:hover, .tl-rules > div:hover, .au-lot:hover .au-art, .lc-sec:hover, .vc-sec:hover, .ot-sec:hover, .hub-faq details:hover {
  --seal: 9px; border-color: var(--line) !important; transform: translateY(-2px);
}
.mu-img, .au-art, .au-lotart, .tl-coin .logo-wrap { background-color: var(--paper-2) !important; }
.vc-sec::before { display: none !important; }
.vc-tbl tr.top td { background: var(--shu-soft) !important; }
.vc-bar { background: var(--paper-2) !important; } .vc-bar i { background: var(--shu) !important; }
.lc-meter i.on { background: currentColor !important; }
.ag::before { display: none !important; }
.ag, .vc, .lc, .mu, .ot, .au { background: none !important; color: var(--sumi); }
.ag-bar, .au-tabs { background: rgba(248, 243, 232, .94) !important; border-bottom: 1px solid var(--line) !important; }
.au-tabs a.on, .au-tabs .on { border-color: var(--shu) !important; color: var(--shu) !important; background: var(--shu-soft) !important; }
.ag-lede { color: var(--mute) !important; } .ag-lede b { box-shadow: none !important; color: var(--sumi); }
.ot-copy h1, .ot-page h1, .lc-hero h1, .lc-verdict h1, .vc-hero h1, .vc-verdict h1, .mu-copy h1, .au-hero h1, .ag-h1, .hub-title, .mu-ch h1, .mu-dinfo h1 { font-family: var(--display) !important; }

/* screens that hold a painting: a mounted sheet of paper, no frame lines */
.wire-c { display: block; width: 100%; height: 100%; }
.vc-net, .mu-chamber, .hub-pv-art, .ag-sketch, .au-la, .tl-screen {
  background: radial-gradient(ellipse at 50% 40%, var(--paper-4), var(--paper-3) 70%) !important;
  border: 1px solid var(--line) !important; border-radius: 2px !important; overflow: hidden;
  box-shadow: 0 18px 40px -30px rgba(40, 30, 20, .5) !important;
}
.tl-screen, .ag-sketch, .mu-chamber, .vc-net { position: relative; }
#backdrop[data-mod]::after { display: none !important; }
.vc-net { image-rendering: auto !important; height: 420px; }
.ag-sketch { padding: 0 !important; height: 280px; }
.au-la { height: 380px; }
.hub-pv-art::after { display: none; }
.hub-canvas, .mu-canvas, .ot-canvas { background: none !important; }
.hub-hero::before, .mu-hero::before, .ot-hero::before, .ot-hero::after { display: none !important; }

/* ═════════════ help button + tour ═════════════ */
.help-fab { position: fixed; right: calc(var(--rail-w) + 18px); bottom: 18px; z-index: 50; display: flex; align-items: center; gap: 0; height: 44px; padding: 0 12px; background: var(--paper-4) !important; border: 1px solid var(--line) !important; border-radius: 22px; color: var(--sumi) !important; font: 700 13px/1 var(--sans) !important; letter-spacing: .02em; overflow: hidden; transition: border-color .2s, gap .3s var(--ease); box-shadow: 0 10px 28px -18px rgba(40, 30, 20, .55); }
.help-fab em { font-style: normal; max-width: 0; opacity: 0; white-space: nowrap; transition: max-width .35s var(--ease), opacity .25s; }
.help-fab:hover, .help-fab:focus-visible { border-color: var(--sumi) !important; gap: 10px; }
.help-fab:hover em, .help-fab:focus-visible em { max-width: 220px; opacity: 1; }
.toasts { bottom: 74px !important; right: calc(var(--rail-w) + 18px) !important; }
.tour-spot { position: fixed; box-shadow: 0 0 0 200vmax rgba(40, 32, 24, .48) !important; border: 2px solid var(--shu) !important; border-radius: 4px; transition: top .35s var(--ease), left .35s var(--ease), width .35s var(--ease), height .35s var(--ease); pointer-events: none; }
.tour-spot::before, .tour-spot::after { display: none; }
.tour-card { position: fixed; display: grid; gap: 10px; padding: 20px 18px 18px; background: var(--brushline) 0 0 / 100% 7px no-repeat, var(--paper-4) !important; border: 1px solid var(--line) !important; border-top: 0 !important; color: var(--sumi); transition: top .35s var(--ease), left .35s var(--ease); box-shadow: 0 24px 60px -30px rgba(40, 30, 20, .6); }
.tour-card.in { animation: tourIn .35s var(--ease); } @keyframes tourIn { from { opacity: 0; transform: translateY(8px); } }
.tour-top { display: flex; justify-content: space-between; align-items: center; }
.tour-x { width: 28px; height: 28px; color: var(--mute); }
.tour-t { font: 800 21px/1.15 var(--display); }
.tour-p { margin: 0; color: var(--mute); font-size: 13.5px; line-height: 1.6; }
.tour-dots { display: flex; gap: 5px; } .tour-dots i { width: 18px; height: 3px; background: var(--line); border-radius: 2px; } .tour-dots i.done { background: var(--sumi-4); } .tour-dots i.on { background: var(--shu); }
.tour-act { display: flex; justify-content: flex-end; gap: 8px; }
.tour-offer { position: fixed; right: calc(var(--rail-w) + 18px); bottom: 74px; z-index: 55; width: min(320px, calc(100vw - 36px)); display: grid; gap: 8px; padding: 18px 16px 16px; background: var(--brushline) 0 0 / 100% 7px no-repeat, var(--paper-4) !important; border: 1px solid var(--line) !important; border-top: 0 !important; color: var(--sumi); animation: tourIn .4s var(--ease); box-shadow: 0 20px 50px -28px rgba(40, 30, 20, .6); }
.tour-offer b { font: 800 19px/1.15 var(--display); }
.tour-offer p { margin: 0; color: var(--mute); font-size: 13px; }
.tour-offer div { display: flex; gap: 8px; margin-top: 4px; }

/* ═════════════ motion: ink soaking in ═════════════ */
.su-pre { opacity: 0; filter: blur(8px); transform: scale(.985); }
.su-in { animation: suIn 1s var(--ease) both; }
@keyframes suIn { from { opacity: 0; filter: blur(8px); transform: scale(.985); } 60% { opacity: 1; } to { opacity: 1; filter: blur(0); transform: none; } }
.entering #view section, .entering #view .tl-steps, .entering #view header, .entering #view .foot { animation: suIn .9s var(--ease) both !important; }
.entering #view section:nth-of-type(2) { animation-delay: .08s !important; } .entering #view section:nth-of-type(n+3) { animation-delay: .16s !important; }
.entering #view h1 { animation: inkWrite 1s var(--ease) both .05s !important; }
@keyframes inkWrite { from { opacity: 0; filter: blur(10px); letter-spacing: .04em; } 50% { opacity: .8; } to { opacity: 1; filter: blur(0); } }

/* the cursor: an ink trail and drops on click (sumi.js draws on this canvas) */
#inkfx { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 44; }
#fx { z-index: 95; }

@media (prefers-reduced-motion: reduce) {
  .entering #view * { animation: none !important; }
  .su-brush path { animation: none; stroke-dashoffset: 0; }
  .su-pre { opacity: 1; filter: none; transform: none; } .su-in { animation: none; }
  .brand:hover .sumi-mark .sm-enso { animation: none; }
  #inkfx { display: none; }
}
