/* Pristop OS demo. Brand rules taken from pristop.si:
   black and white, square corners, heavy uppercase geometric headings,
   light large text, small tracked uppercase labels. Colour is used only for status. */
@font-face { font-family: "Jost"; src: url(../fonts/JostVariable.ttf) format("truetype"); font-weight: 100 900; font-style: normal; }
@font-face { font-family: "JBMono"; src: url(../fonts/JetBrainsMonoVariable.ttf) format("truetype"); font-weight: 100 800; font-style: normal; }

:root {
  --ink: #000;
  --paper: #fff;
  --wash: #f4f4f2;
  --rule: #dcdcda;
  --mute: #8a8a8a;
  --soft: #555;
  --pos: #0b7a3e;
  --neg: #c4321c;
  --warn: #a86400;
  --rail: 248px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; background: var(--paper); color: var(--ink); }
body { font-family: "Jost", sans-serif; font-size: 16px; line-height: 1.4; font-weight: 400; -webkit-font-smoothing: antialiased; overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; border-radius: 0; }
button { cursor: pointer; background: none; border: 0; }
ul, ol { list-style: none; }
svg { display: block; flex: none; }
::selection { background: var(--ink); color: var(--paper); }

/* ---------- Shell: black top bar with section menus, then breadcrumbs, then the page ---------- */
.shell { display: flex; flex-direction: column; height: 100vh; position: relative; }
.topbar { height: 60px; flex: none; background: var(--ink); color: var(--paper); display: flex; align-items: center; gap: 18px; padding: 0 24px 0 10px; position: relative; z-index: 40; }
.brand { display: flex; align-items: center; flex: none; height: 60px; }
.brand img { width: 129px; height: 43px; }
.brand span { font-weight: 300; font-size: 26px; letter-spacing: 0.02em; margin-left: -1px; }
.menu { display: flex; align-items: stretch; height: 60px; flex: 1; min-width: 0; margin-right: 12px; }
.mi { position: relative; display: flex; align-items: center; }
.mi .mt, .mi.later { display: flex; align-items: center; gap: 7px; height: 34px; padding: 0 11px; font-weight: 600; font-size: 11.5px; letter-spacing: 0.13em; text-transform: uppercase; color: #a9a9a9; white-space: nowrap; }
.mi:hover .mt, .mi.open .mt { color: var(--paper); background: #262626; }
.mi.on .mt { color: var(--paper); }
.mi.on::after { content: ""; position: absolute; left: 11px; right: 11px; bottom: 0; height: 3px; background: var(--paper); }
.mi.later { color: #5e5e5e; cursor: default; align-self: center; }
.mi.later em { font-style: normal; font-size: 9.5px; letter-spacing: 0.08em; border: 1px solid #4a4a4a; padding: 0 4px; color: #777; }
.mi .panel { display: none; position: absolute; top: 58px; left: 0; min-width: 270px; background: var(--paper); color: var(--ink); border: 1px solid var(--ink); box-shadow: 8px 8px 0 rgba(0,0,0,.10); padding: 6px; z-index: 60; }
.mi.open .panel { display: block; animation: fade .12s; }
.mi .panel a { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 9px 12px 9px 14px; font-weight: 500; font-size: 15px; white-space: nowrap; }
.mi .panel a:hover { background: var(--ink); color: var(--paper); }
.mi .panel a.on::before { content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px; background: var(--ink); }
.mi .panel a.on { font-weight: 700; }
.mi .panel a:hover.on::before { background: var(--paper); }
.mi .panel a b { font-family: "JBMono", monospace; font-weight: 500; font-size: 11px; background: var(--ink); color: var(--paper); padding: 0 5px; }
.mi .panel a:hover b { background: var(--paper); color: var(--ink); }
.tools { display: flex; align-items: center; gap: 12px; flex: none; }
.gsearch { display: flex; align-items: center; gap: 9px; width: 250px; height: 36px; padding: 0 11px; background: #1c1c1c; border: 1px solid #333; color: #9a9a9a; }
.gsearch:focus-within { border-color: var(--paper); color: var(--paper); }
.gsearch input { border: 0; outline: 0; flex: 1; min-width: 0; font-size: 14.5px; background: none; color: var(--paper); }
.gsearch input::placeholder { color: #8a8a8a; }
.gsearch kbd { font-family: "JBMono", monospace; font-size: 10.5px; border: 1px solid #444; padding: 0 4px; color: #8a8a8a; }
.iconbtn { position: relative; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border: 1px solid #333; color: var(--paper); }
.iconbtn:hover { border-color: var(--paper); }
.iconbtn b { position: absolute; top: -6px; right: -6px; min-width: 17px; height: 17px; padding: 0 4px; background: var(--paper); color: var(--ink); font-family: "JBMono", monospace; font-size: 10.5px; font-weight: 500; display: flex; align-items: center; justify-content: center; }
.langsw { display: flex; border: 1px solid #444; }
.langsw button { height: 28px; padding: 0 9px; font-weight: 600; font-size: 11px; letter-spacing: 0.1em; color: #9a9a9a; }
.langsw button.on { background: var(--paper); color: var(--ink); }
.user { display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 6px 0 4px; color: var(--paper); }
.user:hover { background: #262626; }
.user .who { background: var(--paper); color: var(--ink); }
.user .un { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.15; }
.user .un b { font-weight: 600; font-size: 14px; white-space: nowrap; }
.user .un small { font-size: 12px; color: #9a9a9a; white-space: nowrap; }
.crumbrow { height: 46px; flex: none; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 0 48px; border-bottom: 1px solid var(--ink); background: var(--paper); }
.crumbs { display: flex; align-items: center; gap: 10px; min-width: 0; white-space: nowrap; font-weight: 600; font-size: 11.5px; letter-spacing: 0.15em; text-transform: uppercase; }
.crumbs a { color: var(--mute); }
.crumbs a:hover { color: var(--ink); }
.crumbs i { font-style: normal; color: var(--rule); }
.crumbs span { overflow: hidden; text-overflow: ellipsis; }
.chip { display: inline-flex; align-items: center; gap: 9px; height: 30px; padding: 0 11px; border: 1px solid var(--ink); font-weight: 600; font-size: 11px; letter-spacing: 0.13em; text-transform: uppercase; white-space: nowrap; flex: none; }
a.chip:hover { background: var(--wash); }
.chip .mini { width: 46px; height: 4px; background: var(--rule); }
.chip .mini i { display: block; height: 4px; background: var(--ink); }
.chip b { font-family: "JBMono", monospace; font-weight: 500; letter-spacing: 0; font-size: 12.5px; }
.who { width: 36px; height: 36px; background: var(--ink); color: var(--paper); display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 12.5px; letter-spacing: 0.06em; flex: none; }
.who.sm { width: 26px; height: 26px; font-size: 10px; }
.who.line { background: var(--paper); color: var(--ink); border: 1px solid var(--ink); }
.pop { position: absolute; top: 58px; right: 24px; width: 330px; background: var(--paper); border: 1px solid var(--ink); box-shadow: 8px 8px 0 rgba(0,0,0,.08); z-index: 60; }
.pop .ph { padding: 14px 16px 12px; border-bottom: 1px solid var(--ink); }
.pop .pi { display: flex; gap: 11px; align-items: flex-start; padding: 11px 16px; border-bottom: 1px solid var(--rule); font-size: 14.5px; line-height: 1.3; }
.pop .pi:last-child { border-bottom: 0; }
.pop a.pi:hover, .pop button.pi:hover { background: var(--wash); }
.pop button.pi { width: 100%; text-align: left; }
.pop .pi small { display: block; color: var(--mute); font-size: 12.5px; margin-top: 2px; }
.pop .pg { padding: 10px 16px 12px; border-bottom: 1px solid var(--rule); }
.pop .pg:last-child { border-bottom: 0; }

.scroll { flex: 1; min-height: 0; overflow-y: auto; }
.page { padding: 36px 48px 80px; max-width: 1720px; margin: 0 auto; }

/* ---------- Sitemap (root page) ---------- */
.sitemap { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 44px 32px; }
.sitemap section h2 { font-size: 13px; font-weight: 600; letter-spacing: 0.16em; border-bottom: 1px solid var(--ink); padding-bottom: 10px; margin-bottom: 6px; display: flex; align-items: center; justify-content: space-between; }
.sitemap li { border-bottom: 1px solid var(--rule); }
.sitemap li > a, .sitemap li > span.pg { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; padding: 9px 0 8px; }
.sitemap li > a .nm { font-weight: 600; font-size: 16px; }
.sitemap li > a:hover .nm { border-bottom: 1px solid var(--ink); margin-bottom: -1px; }
.sitemap li .pt { font-family: "JBMono", monospace; font-size: 11.5px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sitemap li.off > a .nm, .sitemap li.off .nm { color: #b0b0b0; font-weight: 400; }
.sitemap li .tabsl { padding: 0 0 9px 0; display: flex; flex-wrap: wrap; gap: 5px; }
.sitemap li .tabsl a { font-size: 12.5px; color: var(--soft); border: 1px solid var(--rule); padding: 1px 7px; }
.sitemap li .tabsl a:hover { border-color: var(--ink); color: var(--ink); }
@media (max-width: 1500px) { .sitemap { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* ---------- Type ---------- */
h1 { font-weight: 800; font-size: 72px; line-height: 0.95; letter-spacing: -0.01em; text-transform: uppercase; }
h2 { font-weight: 800; font-size: 26px; line-height: 1.05; text-transform: uppercase; letter-spacing: 0; }
h3 { font-weight: 600; font-size: 19px; line-height: 1.2; }
.lede { font-weight: 300; font-size: 25px; line-height: 1.22; margin-top: 12px; max-width: 980px; }
.label { font-weight: 600; font-size: 11.5px; letter-spacing: 0.15em; text-transform: uppercase; }
.mute { color: var(--mute); }
.soft { color: var(--soft); }
.mono { font-family: "JBMono", monospace; font-size: 13px; letter-spacing: 0; }
.small { font-size: 14px; }
.xs { font-size: 12.5px; }
.big { font-weight: 300; font-size: 21px; line-height: 1.3; }
.fig { font-weight: 300; font-size: 52px; line-height: 1; letter-spacing: -0.02em; white-space: nowrap; }
.fig small { font-size: 20px; letter-spacing: 0; margin-left: 4px; }
.fig.s { font-size: 30px; }
.pos { color: var(--pos); }
.neg { color: var(--neg); }
.warn { color: var(--warn); }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.center { text-align: center; }
.clip { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link { border-bottom: 1px solid var(--ink); }
.link:hover { background: var(--ink); color: var(--paper); }
.ext { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 11.5px; letter-spacing: 0.13em; text-transform: uppercase; border-bottom: 1px solid var(--ink); padding-bottom: 1px; white-space: nowrap; }
.prose p { margin-top: 10px; max-width: 760px; }
.prose p:first-child { margin-top: 0; }
.prose ul { margin-top: 8px; }
.prose li { position: relative; padding-left: 18px; margin-top: 6px; max-width: 760px; }
.prose li::before { content: ""; position: absolute; left: 0; top: 9px; width: 7px; height: 7px; background: var(--ink); }

/* ---------- Layout helpers ---------- */
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; margin-bottom: 34px; }
.head.compact h1 { font-size: 48px; }
.head .eyebrow { margin-bottom: 10px; display: flex; align-items: center; gap: 10px; }
.head .acts { display: flex; align-items: center; gap: 10px; flex: none; flex-wrap: wrap; justify-content: flex-end; }
.head .meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; margin-top: 14px; font-size: 14.5px; color: var(--soft); }
.row { display: flex; align-items: center; gap: 12px; }
.row.top { align-items: flex-start; }
.row.between { justify-content: space-between; }
.row.wrap { flex-wrap: wrap; }
.col { display: flex; flex-direction: column; gap: 12px; }
.grow { flex: 1; min-width: 0; }
.grid { display: grid; gap: 28px; }
.grid.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid.c5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.grid.c6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.grid.c7 { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.grid.side { grid-template-columns: minmax(0, 1fr) 380px; }
.grid.side.wide { grid-template-columns: minmax(0, 1fr) 480px; }
.grid.lead { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.gap0 { gap: 0; } .gap8 { gap: 8px; } .gap16 { gap: 16px; } .gap20 { gap: 20px; } .gap40 { gap: 40px; }
.mt4 { margin-top: 4px; } .mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; } .mt24 { margin-top: 24px; } .mt32 { margin-top: 32px; } .mt40 { margin-top: 40px; } .mt56 { margin-top: 56px; }
.mb8 { margin-bottom: 8px; } .mb16 { margin-bottom: 16px; } .mb24 { margin-bottom: 24px; }
.hide { display: none !important; }

/* Section: a titled block with a black top rule */
.sect { border-top: 1px solid var(--ink); padding-top: 14px; }
.sect > .sh { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 22px; margin-bottom: 14px; }
.sect > .sh .acts { display: flex; align-items: center; gap: 14px; }
/* Box: a bordered panel */
.box { border: 1px solid var(--rule); padding: 18px 20px; background: var(--paper); }
.box.ink { border-color: var(--ink); }
.box.wash { background: var(--wash); border-color: var(--wash); }
.box.black { background: var(--ink); color: var(--paper); border-color: var(--ink); }
a.box:hover, .box.hover:hover { border-color: var(--ink); }
.cells { display: grid; border-top: 1px solid var(--ink); }
.cells > * { padding: 16px 22px 18px 0; min-width: 0; }
.cells > * + * { border-left: 1px solid var(--rule); padding-left: 22px; }
.stat .label { color: var(--mute); display: block; margin-bottom: 12px; }
.stat p { font-size: 14px; color: var(--soft); margin-top: 7px; line-height: 1.3; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 38px; padding: 0 16px; border: 1px solid var(--ink); background: var(--paper); font-weight: 600; font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; white-space: nowrap; user-select: none; }
.btn:hover { background: var(--ink); color: var(--paper); }
.btn.primary { background: var(--ink); color: var(--paper); }
.btn.primary:hover { background: #2b2b2b; }
.btn.ghost { border-color: var(--rule); }
.btn.ghost:hover { background: var(--paper); color: var(--ink); border-color: var(--ink); }
.btn.danger { border-color: var(--neg); color: var(--neg); }
.btn.danger:hover { background: var(--neg); color: var(--paper); }
.btn.sm { height: 28px; padding: 0 10px; font-size: 10.5px; gap: 6px; }
.btn.lg { height: 48px; padding: 0 24px; font-size: 12.5px; }
.btn[disabled] { opacity: .35; pointer-events: none; }
.btn.block { width: 100%; }

/* ---------- Tags and status ---------- */
.tag { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 7px; border: 1px solid var(--ink); font-weight: 600; font-size: 10.5px; letter-spacing: 0.13em; text-transform: uppercase; white-space: nowrap; vertical-align: middle; }
.tag.fill { background: var(--ink); color: var(--paper); }
.tag.ghost { border-color: var(--rule); color: var(--mute); }
.tag.pos { border-color: var(--pos); color: var(--pos); }
.tag.neg { border-color: var(--neg); color: var(--neg); }
.tag.warn { border-color: var(--warn); color: var(--warn); }
.st { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; white-space: nowrap; }
.st i { width: 8px; height: 8px; background: var(--mute); flex: none; }
.st.pos i { background: var(--pos); } .st.neg i { background: var(--neg); } .st.warn i { background: var(--warn); }
.st.run i { background: var(--ink); animation: pulse 1.1s ease-in-out infinite; }
.st.neg { color: var(--neg); } .st.warn { color: var(--warn); } .st.idle { color: var(--mute); }
@keyframes pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .25; transform: scale(.7); } }
.cite { display: inline-flex; align-items: center; justify-content: center; min-width: 19px; height: 19px; padding: 0 4px; margin-left: 4px; border: 1px solid var(--ink); font-family: "JBMono", monospace; font-size: 11px; font-weight: 500; vertical-align: 2px; cursor: pointer; }
.cite:hover { background: var(--ink); color: var(--paper); }
.srcchip { display: inline-flex; align-items: center; gap: 7px; height: 26px; padding: 0 9px; border: 1px solid var(--rule); font-size: 13px; white-space: nowrap; max-width: 100%; }
.srcchip:hover { border-color: var(--ink); }

/* ---------- Progress ---------- */
.bar { height: 6px; background: var(--rule); position: relative; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--ink); transition: width .6s linear; }
.bar.thin { height: 3px; } .bar.thick { height: 10px; }
.bar.neg i { background: var(--neg); } .bar.pos i { background: var(--pos); } .bar.warn i { background: var(--warn); }
.bar.live i::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,.55), transparent); width: 30%; animation: sweep 1.6s linear infinite; }
@keyframes sweep { from { transform: translateX(-120%); } to { transform: translateX(420%); } }
.barrow { display: grid; grid-template-columns: 170px minmax(0, 1fr) 80px; align-items: center; gap: 14px; padding: 7px 0; font-size: 14.5px; }
.barrow .v { text-align: right; font-family: "JBMono", monospace; font-size: 12.5px; }
.spin { width: 14px; height: 14px; border: 2px solid var(--rule); border-top-color: var(--ink); border-radius: 50%; animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Tables ---------- */
table { border-collapse: collapse; width: 100%; }
th { text-align: left; font-weight: 600; font-size: 11px; letter-spacing: 0.15em; text-transform: uppercase; color: var(--mute); padding: 0 14px 10px 0; border-bottom: 1px solid var(--ink); white-space: nowrap; }
td { padding: 12px 14px 12px 0; border-bottom: 1px solid var(--rule); vertical-align: middle; font-size: 15px; }
td.n, th.n { text-align: right; }
td.n { font-family: "JBMono", monospace; font-size: 13px; white-space: nowrap; }
td:last-child, th:last-child { padding-right: 0; }
td small { display: block; color: var(--mute); font-size: 12.5px; margin-top: 1px; }
td.acts { text-align: right; white-space: nowrap; }
td.acts .btn + .btn { margin-left: 6px; }
tr.click { cursor: pointer; }
tr.click:hover td { background: var(--wash); }
table.dense td { padding-top: 8px; padding-bottom: 8px; font-size: 14px; }
td.main b, td b.t { font-weight: 600; }
.tablewrap { overflow-x: auto; }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 30px; border-bottom: 1px solid var(--ink); margin-bottom: 26px; }
.tabs a { display: flex; align-items: center; gap: 8px; height: 42px; font-weight: 600; font-size: 11.5px; letter-spacing: 0.15em; text-transform: uppercase; color: var(--mute); border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs a:hover { color: var(--ink); }
.tabs a.on { color: var(--ink); border-bottom-color: var(--ink); }
.tabs a b { font-family: "JBMono", monospace; font-weight: 500; font-size: 11px; letter-spacing: 0; border: 1px solid currentColor; padding: 0 4px; }

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 7px; }
.field > .label { color: var(--soft); }
.field .hint { font-size: 13px; color: var(--mute); }
.field .err { font-size: 13px; color: var(--neg); }
.in, select.in, textarea.in { width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--rule); background: var(--paper); outline: 0; font-size: 15.5px; }
.in:focus { border-color: var(--ink); }
.in.bad { border-color: var(--neg); }
textarea.in { height: auto; min-height: 110px; padding: 10px 12px; resize: vertical; line-height: 1.4; }
select.in { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 30px; }
.in.sm { height: 34px; font-size: 14px; }
.searchbox { display: flex; align-items: center; gap: 10px; height: 42px; padding: 0 12px; border: 1px solid var(--rule); }
.searchbox:focus-within { border-color: var(--ink); }
.searchbox input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; font-size: 15px; }
.searchbox.xl { height: 64px; padding: 0 20px; border-color: var(--ink); gap: 14px; }
.searchbox.xl input { font-size: 22px; font-weight: 300; }
.check { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: 15px; user-select: none; }
.check input { appearance: none; width: 18px; height: 18px; border: 1px solid var(--ink); background: var(--paper); flex: none; cursor: pointer; }
.check input:checked { background: var(--ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='10'%3E%3Cpath d='M1 5l3.5 3.5L11 1.5' fill='none' stroke='%23fff' stroke-width='2'/%3E%3C/svg%3E") center no-repeat; }
.check input[type=radio] { border-radius: 50%; }
.check input[type=radio]:checked { background: var(--paper); box-shadow: inset 0 0 0 4px var(--ink); }
.toggle { display: inline-flex; align-items: center; gap: 11px; cursor: pointer; font-size: 15px; user-select: none; }
.toggle input { appearance: none; width: 38px; height: 20px; border: 1px solid var(--ink); background: var(--paper); position: relative; flex: none; cursor: pointer; }
.toggle input::after { content: ""; position: absolute; left: 2px; top: 2px; width: 14px; height: 14px; background: var(--ink); transition: transform .15s; }
.toggle input:checked { background: var(--ink); }
.toggle input:checked::after { background: var(--paper); transform: translateX(18px); }
.seg { display: inline-flex; border: 1px solid var(--ink); }
.seg button { height: 34px; padding: 0 14px; font-weight: 600; font-size: 11px; letter-spacing: 0.13em; text-transform: uppercase; white-space: nowrap; }
.seg button + button { border-left: 1px solid var(--ink); }
.seg button.on { background: var(--ink); color: var(--paper); }
.seg.sm button { height: 28px; padding: 0 10px; font-size: 10.5px; }
.filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.filters .in, .filters .searchbox { width: auto; height: 36px; font-size: 14px; }
.filters .searchbox { width: 280px; }
.filters .sp { flex: 1; }
.pill { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 11px; border: 1px solid var(--rule); font-size: 14px; white-space: nowrap; cursor: pointer; user-select: none; }
.pill:hover { border-color: var(--ink); }
.pill.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.pill b { font-family: "JBMono", monospace; font-weight: 500; font-size: 11.5px; opacity: .6; }
.drop { border: 1px dashed var(--ink); padding: 34px 24px; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; background: var(--wash); }
.drop.over { background: var(--ink); color: var(--paper); }

/* ---------- Key/value, lists ---------- */
.kv { display: grid; grid-template-columns: 170px minmax(0, 1fr); font-size: 15px; }
.kv > * { padding: 9px 0; border-bottom: 1px solid var(--rule); min-width: 0; }
.kv > dt { color: var(--mute); font-weight: 600; font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; padding-top: 12px; }
.list > * { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--rule); min-width: 0; }
.list > a:hover, .list > .click:hover { background: var(--wash); }
.list .t { font-weight: 600; }
.list small { display: block; color: var(--mute); font-size: 13px; }
.list.tight > * { padding: 8px 0; }

/* ---------- Banners, empty, skeleton ---------- */
.banner { display: flex; align-items: center; gap: 14px; padding: 12px 16px; border: 1px solid var(--ink); margin-bottom: 22px; font-size: 15px; }
.banner.warn { border-color: var(--warn); color: var(--warn); }
.banner.neg { border-color: var(--neg); color: var(--neg); }
.banner.pos { border-color: var(--pos); color: var(--pos); }
.banner.black { background: var(--ink); color: var(--paper); }
.banner .sp { flex: 1; }
.banner .btn { border-color: currentColor; background: none; color: inherit; }
.empty { border-top: 1px solid var(--ink); padding: 70px 0 60px; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.empty h2 { font-size: 38px; }
.empty p { font-weight: 300; font-size: 20px; max-width: 620px; color: var(--soft); }
.empty .btn { margin-top: 12px; }
.skel { background: linear-gradient(90deg, var(--wash) 25%, #e9e9e6 50%, var(--wash) 75%); background-size: 200% 100%; animation: skel 1.3s linear infinite; height: 16px; }
@keyframes skel { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* ---------- Toast, modal, drawer ---------- */
#toasts { position: fixed; right: 28px; bottom: 26px; display: flex; flex-direction: column; gap: 10px; z-index: 200; }
.toast { display: flex; align-items: center; gap: 12px; min-width: 300px; max-width: 460px; padding: 13px 16px; background: var(--ink); color: var(--paper); font-size: 15px; box-shadow: 8px 8px 0 rgba(0,0,0,.12); animation: rise .25s ease-out; }
.toast.neg { background: var(--neg); }
.toast i { width: 8px; height: 8px; background: #35c16f; flex: none; }
.toast.neg i { background: var(--paper); }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.veil { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 100; display: flex; align-items: center; justify-content: center; animation: fade .15s; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal { width: 600px; max-width: calc(100vw - 80px); max-height: calc(100vh - 80px); overflow-y: auto; background: var(--paper); border: 1px solid var(--ink); box-shadow: 12px 12px 0 rgba(0,0,0,.18); }
.modal.wide { width: 860px; }
.modal .mh { display: flex; align-items: center; justify-content: space-between; padding: 18px 24px; border-bottom: 1px solid var(--ink); }
.modal .mb { padding: 22px 24px; }
.modal .mf { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--rule); }
.drawer { position: fixed; top: 106px; right: 0; bottom: 0; width: 520px; background: var(--paper); border-left: 1px solid var(--ink); z-index: 50; overflow-y: auto; padding: 24px 28px 40px; box-shadow: -10px 0 0 rgba(0,0,0,.05); animation: slide .2s ease-out; }
@keyframes slide { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---------- Media ---------- */
.thumb { position: relative; background: var(--ink); overflow: hidden; aspect-ratio: 16 / 9; }
.thumb svg { width: 100%; height: 100%; }
.thumb .play { position: absolute; left: 10px; bottom: 10px; width: 30px; height: 30px; background: var(--paper); color: var(--ink); display: flex; align-items: center; justify-content: center; }
.thumb .dur { position: absolute; right: 8px; bottom: 8px; background: var(--ink); color: var(--paper); font-family: "JBMono", monospace; font-size: 11.5px; padding: 1px 6px; }
.thumb .kind { position: absolute; left: 8px; top: 8px; }
.thumb .kind .tag { background: var(--paper); }
.thumb.sq { aspect-ratio: 1 / 1; }
.thumb.doc { background: var(--wash); border: 1px solid var(--rule); }
.player { background: var(--ink); color: var(--paper); }
.player .screen { position: relative; aspect-ratio: 16 / 9; overflow: hidden; cursor: pointer; }
.player .screen svg { width: 100%; height: 100%; }
.player .screen .bigplay { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; background: var(--paper); color: var(--ink); display: flex; align-items: center; justify-content: center; }
.player.playing .bigplay { display: none; }
.player .screen .sub { position: absolute; left: 0; right: 0; bottom: 14px; text-align: center; font-size: 17px; text-shadow: 0 1px 6px #000; padding: 0 30px; }
.player .ctl { display: flex; align-items: center; gap: 12px; padding: 10px 14px; }
.player .ctl .track { flex: 1; height: 4px; background: #3a3a3a; cursor: pointer; }
.player .ctl .track i { display: block; height: 4px; background: var(--paper); width: 0; }
.player .ctl .mono { font-size: 12px; color: #bdbdbd; }
.wave { display: flex; align-items: center; gap: 2px; height: 44px; }
.wave i { flex: 1; background: var(--rule); min-width: 2px; }
.wave i.on { background: var(--ink); }
.meter { display: flex; gap: 3px; align-items: flex-end; height: 22px; }
.meter i { width: 5px; background: var(--rule); height: 100%; }
.meter i.on { background: var(--ink); }

/* ---------- Timeline / steps ---------- */
.steps { border-top: 1px solid var(--ink); }
.step { display: grid; grid-template-columns: 54px minmax(0, 1fr); border-bottom: 1px solid var(--rule); }
.step > .no { padding: 18px 0; font-family: "JBMono", monospace; font-weight: 500; font-size: 13px; color: var(--mute); }
.step > .bd { padding: 16px 0 18px; min-width: 0; }
.step .sh { display: flex; align-items: center; gap: 16px; cursor: pointer; }
.step .sh h3 { flex: 1; min-width: 0; }
.step .more { margin-top: 16px; }
.step.shut .more { display: none; }
.step .caret { transition: transform .15s; }
.step.shut .caret { transform: rotate(-90deg); }
.log { font-family: "JBMono", monospace; font-size: 12.5px; line-height: 1.55; }
.log .ln { display: grid; grid-template-columns: 92px 62px 150px minmax(0, 1fr); gap: 12px; padding: 5px 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.log .ln .lv { font-weight: 600; }
.log .ln.error .lv, .log .ln.error .msg { color: var(--neg); }
.log .ln.warning .lv { color: var(--warn); }
.log .ln .msg { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
pre.code { font-family: "JBMono", monospace; font-size: 12.5px; line-height: 1.55; background: var(--wash); padding: 14px 16px; overflow-x: auto; white-space: pre-wrap; word-break: break-word; }

/* ---------- Chat ---------- */
.chat { display: flex; flex-direction: column; gap: 20px; }
.msg { max-width: 780px; }
.msg.me { align-self: flex-end; background: var(--ink); color: var(--paper); padding: 12px 16px; max-width: 620px; }
.msg.ai { border-left: 3px solid var(--ink); padding: 2px 0 2px 18px; }
.msg.ai .srcs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.typing { display: inline-flex; gap: 5px; padding: 6px 0; }
.typing i { width: 7px; height: 7px; background: var(--ink); animation: pulse 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }

/* ---------- Rating ---------- */
.stars { display: inline-flex; gap: 3px; vertical-align: middle; }
.stars i { width: 14px; height: 14px; background: var(--rule); clip-path: polygon(50% 0, 62% 36%, 100% 38%, 70% 60%, 80% 100%, 50% 77%, 20% 100%, 30% 60%, 0 38%, 38% 36%); }
.stars i.on { background: var(--ink); }
.stars.lg i { width: 30px; height: 30px; cursor: pointer; }
.thumbs { display: inline-flex; border: 1px solid var(--ink); }
.thumbs button { width: 38px; height: 32px; display: flex; align-items: center; justify-content: center; }
.thumbs button + button { border-left: 1px solid var(--ink); }
.thumbs button.on { background: var(--ink); color: var(--paper); }

/* ---------- Charts ---------- */
.chart text { font-family: "JBMono", monospace; font-size: 11px; fill: var(--mute); }
.chart .axis { stroke: var(--rule); stroke-width: 1; }
.chart .ln { fill: none; stroke: var(--ink); stroke-width: 2; }
.chart .ln.b { stroke: var(--mute); stroke-dasharray: 4 4; }
.chart .dot { fill: var(--ink); }
.legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 13px; color: var(--soft); }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend i { width: 14px; height: 2px; background: var(--ink); }

/* ---------- Login ---------- */
.login { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); height: 100vh; }
.login .l { background: var(--ink); color: var(--paper); display: flex; flex-direction: column; justify-content: space-between; padding: 44px 56px 48px; }
.login .l h1 { font-size: 92px; line-height: .92; }
.login .l p { font-weight: 300; font-size: 26px; line-height: 1.25; margin-top: 22px; max-width: 560px; }
.login .r { display: flex; flex-direction: column; justify-content: center; padding: 0 84px; position: relative; }
.login .r .lang { position: absolute; top: 40px; right: 56px; }
.msbtn { display: flex; align-items: center; gap: 14px; height: 56px; padding: 0 22px; border: 1px solid var(--ink); font-weight: 600; font-size: 13px; letter-spacing: 0.13em; text-transform: uppercase; width: 100%; max-width: 420px; }
.msbtn:hover { background: var(--ink); color: var(--paper); }
.msbtn .ms { display: grid; grid-template-columns: 9px 9px; gap: 2px; }
.msbtn .ms i { width: 9px; height: 9px; }

/* ---------- Matrix ---------- */
.matrix td, .matrix th { text-align: center; padding-left: 8px; padding-right: 8px; }
.matrix td:first-child, .matrix th:first-child { text-align: left; padding-left: 0; }
.matrix .yes { display: inline-block; width: 10px; height: 10px; background: var(--ink); }
.matrix .no { display: inline-block; width: 10px; height: 1px; background: var(--rule); vertical-align: middle; }
.matrix .part { display: inline-block; width: 10px; height: 10px; border: 1px solid var(--ink); }

/* ---------- Graph ---------- */
.graph { border: 1px solid var(--rule); background: var(--paper); position: relative; }
.graph svg { width: 100%; height: 100%; }
.graph .edge { stroke: #bdbdbd; stroke-width: 1; }
.graph .edge.hi { stroke: var(--ink); stroke-width: 1.5; }
.graph .node { cursor: pointer; }
.graph .node rect, .graph .node circle { stroke: var(--ink); stroke-width: 1; fill: var(--paper); }
.graph .node.fill rect, .graph .node.fill circle { fill: var(--ink); }
.graph .node text { font-family: "Jost", sans-serif; font-size: 12.5px; fill: var(--ink); }
.graph .node.fill text.in { fill: var(--paper); }
.graph .node:hover rect, .graph .node:hover circle { stroke-width: 2.5; }
.graph .node.dim { opacity: .28; }

@media (max-width: 1780px) {
  .gsearch { width: 190px; }
}
@media (max-width: 1640px) {
  .gsearch { width: 44px; }
  .gsearch input, .gsearch kbd { display: none; }
  .mi .mt, .mi.later { padding: 0 8px; }
}
@media (max-width: 1500px) {
  .grid.side { grid-template-columns: minmax(0, 1fr) 330px; }
  .user .un { display: none; }
}
