/* PreLiX — tokens från design.md. Ljust läge standard, mörkt via data-theme. */

:root {
  --paper:        #F4F6F4;
  --surface:      #FFFFFF;
  --surface-sunk: #EAEEEC;
  --ink:          #1A2422;
  --ink-2:        #4A5754;
  --ink-3:        #6B7773;
  --rule:         #D5DCD8;
  --interactive:  #0F4C3A;
  --signal:       #C2E812;
  --alert:        #B3261E;

  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px; --s8: 64px;

  --sans: "Public Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;

  --measure: 72ch;
  --radius: 3px;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --paper:        #101614;
  --surface:      #17201D;
  --surface-sunk: #0B100F;
  --ink:          #E8EDE9;
  --ink-2:        #A9B4B0;
  --ink-3:        #8A9692;
  --rule:         #2A3531;
  --interactive:  #5FBF9B;
  --signal:       #C2E812;
  --alert:        #E5675E;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 15px/1.5 var(--sans);
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--interactive); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible,
summary:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--interactive);
  outline-offset: 2px;
}

h1, h2, h3 { font-weight: 600; line-height: 1.25; margin: 0; letter-spacing: -0.005em; }
h1 { font-size: 26px; }
h2 { font-size: 18px; }
h3 { font-size: 15px; }
p { margin: 0 0 var(--s3); }

button, input, select, textarea { font: inherit; color: inherit; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ------------------------------------------------------------ ramen */

.skip { position: absolute; left: -999px; top: 0; background: var(--surface); padding: var(--s2) var(--s3); z-index: 20; }
.skip:focus { left: var(--s3); }

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--rule);
  position: sticky; top: 0; z-index: 10;
}
.site-header .inner {
  max-width: 1240px; margin: 0 auto;
  display: flex; align-items: center; gap: var(--s5);
  padding: var(--s3) var(--s5);
}
.brand { display: flex; align-items: center; color: var(--ink); flex: none; }
.brand svg { height: 22px; width: auto; display: block; }
.brand { gap: 10px; }
.brand-name {
  font-size: 11px; line-height: 1.15; color: var(--ink-3); font-weight: 500;
  border-left: 1px solid var(--rule); padding-left: 10px;
}
.brand:hover { text-decoration: none; }

.site-nav { display: flex; gap: var(--s4); flex: none; }
.site-nav a { color: var(--ink-2); font-weight: 500; font-size: 14px; padding: var(--s1) 0; border-bottom: 2px solid transparent; }
.site-nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--ink); }
.site-nav a:hover { color: var(--ink); text-decoration: none; }

.search { flex: 1; min-width: 0; display: flex; }
.search input {
  width: 100%; max-width: 420px; margin-left: auto;
  background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 7px var(--s3);
}
.search input::placeholder { color: var(--ink-3); }

.icon-btn {
  flex: none; background: none; border: 1px solid var(--rule); border-radius: var(--radius);
  width: 34px; height: 34px; display: grid; place-items: center; cursor: pointer; color: var(--ink-2);
}
.icon-btn:hover { color: var(--ink); border-color: var(--ink-3); }
.icon-btn svg { width: 16px; height: 16px; }

main { max-width: 1240px; margin: 0 auto; padding: var(--s6) var(--s5) var(--s8); min-height: 70vh; }

.site-footer { border-top: 1px solid var(--rule); color: var(--ink-3); font-size: 13px; }
.site-footer .inner { max-width: 1240px; margin: 0 auto; padding: var(--s5); display: flex; flex-wrap: wrap; gap: var(--s2) var(--s5); }
.site-footer a { color: var(--ink-2); }

.test-banner {
  background: var(--surface-sunk); color: var(--ink-2); font-size: 13px; text-align: center;
  padding: 6px var(--s4); border-bottom: 1px solid var(--rule);
}

/* ------------------------------------------------------------ gemensamt */

.page-head { margin-bottom: var(--s5); max-width: var(--measure); }
.page-head .kicker { color: var(--ink-3); font-size: 13px; margin-bottom: var(--s1); }
.page-head .kicker a { color: var(--ink-3); }
.page-head p.lede { color: var(--ink-2); margin-top: var(--s2); }

.muted { color: var(--ink-3); }
.num { font-variant-numeric: tabular-nums; }

.btn {
  display: inline-flex; align-items: center; gap: var(--s2);
  border: 1px solid var(--rule); background: var(--surface); border-radius: var(--radius);
  padding: 6px var(--s3); cursor: pointer; font-size: 14px; color: var(--ink);
}
.btn:hover { border-color: var(--ink-3); text-decoration: none; }
.btn.primary { background: var(--interactive); border-color: var(--interactive); color: var(--surface); }
:root[data-theme="dark"] .btn.primary { color: #0B100F; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--rule); border-radius: 999px; padding: 1px 10px;
  font-size: 13px; color: var(--ink-2); background: var(--surface); line-height: 22px;
}
a.chip:hover { border-color: var(--ink-3); color: var(--ink); text-decoration: none; }
.chip.active { border-color: var(--ink); color: var(--ink); font-weight: 600; }
.chip.active::before { content: ""; width: 7px; height: 7px; background: var(--signal); outline: 1px solid var(--ink); }
.chip .x { color: var(--ink-3); font-weight: 400; }

.badge {
  display: inline-block; font-size: 12px; line-height: 20px; padding: 0 7px;
  background: var(--surface-sunk); color: var(--ink-2); border-radius: var(--radius);
}
.badge.retracted { background: none; color: var(--alert); border: 1px solid var(--alert); font-weight: 600; }
.oa { font-size: 12px; color: var(--ink-2); display: inline-flex; align-items: center; gap: 4px; }
.oa::before { content: ""; width: 8px; height: 8px; border: 1.5px solid currentColor; border-radius: 50%; }

.empty { border: 1px dashed var(--rule); padding: var(--s5); color: var(--ink-2); max-width: var(--measure); }
.error { border-left: 3px solid var(--alert); padding: var(--s3) var(--s4); background: var(--surface); }

.loading { color: var(--ink-3); padding: var(--s5) 0; }

/* ------------------------------------------------------------ startsida */

.home-hero { display: flex; justify-content: space-between; align-items: end; gap: var(--s5); flex-wrap: wrap; margin-bottom: var(--s5); }
.home-hero h1 { font-size: 30px; }
.home-hero p { color: var(--ink-2); margin: var(--s1) 0 0; }
.home-hero .stats { color: var(--ink-2); font-size: 14px; }
.home-hero .stats b { color: var(--ink); font-weight: 600; }

.map-group { margin-bottom: var(--s6); }
.map-group > h2 { font-size: 14px; color: var(--ink-3); font-weight: 500; margin-bottom: var(--s3); }
.map {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  border-top: 1px solid var(--rule); border-left: 1px solid var(--rule);
}
.tile {
  display: block; background: var(--surface); color: var(--ink);
  border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule);
  padding: var(--s4); min-height: 118px; position: relative;
}
.tile:hover { background: var(--paper); text-decoration: none; }
.tile .t-head { display: flex; justify-content: space-between; gap: var(--s3); align-items: baseline; }
.tile .t-label { font-weight: 600; }
.tile .t-count { color: var(--ink-2); font-size: 14px; }
.tile .t-subs { color: var(--ink-3); font-size: 13px; margin-top: var(--s2); line-height: 1.45; }
.tile .t-bar { position: absolute; left: var(--s4); right: var(--s4); bottom: var(--s3); height: 3px; background: var(--surface-sunk); }
.tile .t-bar span { display: block; height: 100%; background: var(--ink-3); }

.entries { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s4); margin: var(--s6) 0; }
.entry { border-top: 2px solid var(--ink); padding-top: var(--s3); color: var(--ink); }
.entry:hover { text-decoration: none; }
.entry:hover h2 { text-decoration: underline; text-underline-offset: 3px; }
.entry p { color: var(--ink-2); margin: var(--s1) 0 0; font-size: 14px; }

/* ------------------------------------------------------------ flöde */

.feed-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: var(--s6); align-items: start; }

.facets { position: sticky; top: 76px; max-height: calc(100vh - 92px); overflow: auto; padding-right: var(--s2); font-size: 14px; }
.facet { border-top: 1px solid var(--rule); padding: var(--s3) 0; }
.facet > summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; }
.facet > summary::-webkit-details-marker { display: none; }
.facet > summary::after { content: "+"; color: var(--ink-3); font-weight: 400; }
.facet[open] > summary::after { content: "−"; }
.facet ul { list-style: none; margin: var(--s2) 0 0; padding: 0; }
.facet li a {
  display: flex; justify-content: space-between; gap: var(--s2);
  padding: 3px 6px 3px 12px; color: var(--ink-2); border-radius: var(--radius); position: relative;
}
.facet li a:hover { background: var(--surface-sunk); color: var(--ink); text-decoration: none; }
.facet li a .n { color: var(--ink-3); }
.facet li a.on { color: var(--ink); font-weight: 600; }
.facet li a.on::before { content: ""; position: absolute; left: 0; top: 7px; bottom: 7px; width: 3px; background: var(--signal); outline: 1px solid var(--ink); }
.facet li a.zero { opacity: .45; }
.facet li.sub a { padding-left: 24px; }
.facet li.sub a.on::before { left: 12px; }
.facet .group-label { font-size: 12px; color: var(--ink-3); margin: var(--s3) 0 2px; }
.facet .more { background: none; border: none; color: var(--interactive); cursor: pointer; padding: 4px 0 0; font-size: 13px; }
.facet .years { display: flex; gap: var(--s2); align-items: center; margin-top: var(--s2); }
.facet .years select { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius); padding: 3px 6px; }
.facet label.check { display: flex; gap: var(--s2); align-items: center; margin-top: var(--s2); cursor: pointer; }

.feed-head { display: flex; justify-content: space-between; align-items: center; gap: var(--s3); flex-wrap: wrap; padding-bottom: var(--s3); }
.feed-head .count { color: var(--ink-2); }
.feed-head .count b { color: var(--ink); }
.feed-head .tools { display: flex; gap: var(--s2); align-items: center; }
.feed-head select { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius); padding: 5px 8px; font-size: 14px; }
.active-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: var(--s3); }
.filters-toggle { display: none; }

.register { border-top: 1px solid var(--rule); }
.day { display: grid; grid-template-columns: 96px minmax(0, 1fr); }
.day + .day { border-top: 1px solid var(--rule); }
.day-label { font-size: 13px; color: var(--ink-3); padding-top: var(--s4); line-height: 1.3; }
.day-label b { display: block; color: var(--ink); font-weight: 600; font-size: 15px; }
.rows { min-width: 0; }
.row { padding: var(--s4) 0; position: relative; }
.row + .row { border-top: 1px solid var(--rule); }
.row .title { font-family: var(--serif); font-size: 18px; line-height: 1.3; font-weight: 500; color: var(--ink); display: block; max-width: var(--measure); }
.row .title:hover { color: var(--interactive); }
.row .new { position: absolute; left: -16px; top: 26px; width: 7px; height: 7px; background: var(--signal); outline: 1px solid var(--ink); }
.row .meta { color: var(--ink-2); font-size: 13px; margin-top: 4px; }
.row .meta a { color: var(--ink-2); }
.row .marks { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: var(--s2); }
.row .marks .chip { font-size: 12px; line-height: 20px; padding: 0 8px; }
.row .retract-line { margin-bottom: 6px; }

.more-wrap { padding: var(--s5) 0; text-align: center; }

/* ------------------------------------------------------------ artikel */

.article { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: var(--s7); align-items: start; }
.article h1 { font-family: var(--serif); font-weight: 500; font-size: 30px; line-height: 1.2; max-width: var(--measure); }
.article .byline a.author { color: var(--ink-2); }
.article .byline a.author:hover { color: var(--interactive); }
.article .byline { color: var(--ink-2); margin-top: var(--s3); max-width: var(--measure); }
.article .source { color: var(--ink-2); margin-top: var(--s2); font-size: 14px; }
.article .marks { display: flex; flex-wrap: wrap; gap: 6px; margin-top: var(--s4); }
.links { display: flex; flex-wrap: wrap; gap: var(--s2); margin-top: var(--s4); }
.abstract { font-family: var(--serif); font-size: 18px; line-height: 1.6; max-width: 68ch; margin-top: var(--s6); }
.abstract p { margin-bottom: var(--s4); }
.abstract .lab { font-family: var(--sans); font-size: 13px; font-weight: 600; color: var(--ink-2); display: block; margin-bottom: 2px; }
.retract-note { border: 1px solid var(--alert); color: var(--alert); padding: var(--s3) var(--s4); margin-bottom: var(--s4); font-weight: 600; max-width: var(--measure); }

.side { position: sticky; top: 76px; font-size: 14px; }
.side section { border-top: 1px solid var(--rule); padding: var(--s4) 0; }
.side h2 { font-size: 13px; color: var(--ink-3); font-weight: 500; margin-bottom: var(--s2); }
.side .chips { display: flex; flex-wrap: wrap; gap: 6px; }
.side dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 4px var(--s3); }
.side dt { color: var(--ink-3); }
.side dd { margin: 0; }
.fineprint { font-size: 12px; color: var(--ink-3); margin-top: var(--s2); }

/* rapport */
.report { border: 1px solid var(--rule); background: var(--surface); padding: var(--s4); margin-top: var(--s3); }
.report fieldset { border: none; padding: 0; margin: 0 0 var(--s3); }
.report legend { font-weight: 600; margin-bottom: var(--s2); padding: 0; }
.report label.opt { display: flex; gap: var(--s2); align-items: flex-start; padding: 3px 0; cursor: pointer; }
.report input[type="text"], .report textarea, .report select {
  width: 100%; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 6px 8px;
}
.report textarea { min-height: 70px; resize: vertical; }
.report .field { margin-bottom: var(--s3); }
.report .field label { display: block; font-size: 13px; color: var(--ink-2); margin-bottom: 3px; }
.report .done { color: var(--ink); }

/* citering */
.cite-box { margin-top: var(--s4); border: 1px solid var(--rule); background: var(--surface); max-width: var(--measure); }
.cite-box > summary { cursor: pointer; padding: var(--s2) var(--s3); font-weight: 600; font-size: 14px; }
.cite-box[open] > summary { border-bottom: 1px solid var(--rule); }
.cite-tabs { display: flex; gap: var(--s4); padding: var(--s3) var(--s3) 0; }
.cite-tabs button { background: none; border: none; padding: 2px 0; cursor: pointer; color: var(--ink-2); font-size: 14px; border-bottom: 2px solid transparent; }
.cite-tabs button[aria-selected="true"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.cite-text { padding: var(--s3); margin: 0; font-size: 14px; line-height: 1.6; padding-left: calc(var(--s3) + 2em); text-indent: -2em; overflow-wrap: anywhere; }
.cite-actions { display: flex; flex-wrap: wrap; gap: var(--s2); align-items: center; padding: 0 var(--s3) var(--s3); }
.cite-actions .fineprint { margin: 0; }

/* ändringslogg */
.changes { list-style: none; padding: 0; margin: 0; border-left: 1px solid var(--rule); }
.changes > li { position: relative; padding: 0 0 var(--s6) var(--s5); }
.changes > li::before { content: ""; position: absolute; left: -4px; top: 6px; width: 7px; height: 7px; background: var(--ink); }
.changes > li:first-child::before { background: var(--signal); outline: 1px solid var(--ink); }
.changes h2 { margin: var(--s1) 0 var(--s2) !important; font-size: 17px; }
.change-meta { display: flex; gap: var(--s2); align-items: center; color: var(--ink-3); font-size: 13px; }

/* grundare och kontakt */
.contact-links { display: flex; flex-wrap: wrap; gap: var(--s2); }
.founder {
  display: grid; grid-template-columns: 72px 1fr; gap: var(--s4); align-items: start;
  margin-top: var(--s7); padding: var(--s5); background: var(--surface);
  border: 1px solid var(--rule); border-top: 3px solid var(--ink); max-width: 560px; position: relative;
}
.founder::after { content: ""; position: absolute; top: -3px; right: var(--s5); width: 10px; height: 10px; background: var(--signal); transform: translateY(-14px); }
.founder-mark img { width: 100%; height: 100%; object-fit: cover; display: block; filter: grayscale(0.15); }
.founder-mark {
  width: 72px; height: 72px; overflow: hidden; display: grid; place-items: center; border: 1px solid var(--rule);
  font-weight: 600; font-size: 18px; letter-spacing: .02em; color: var(--ink); background: var(--paper);
}
.founder-kicker { font-size: 12px; color: var(--ink-3); }
.founder-name { font-weight: 600; font-size: 17px; margin-top: 2px; }
.founder-role { color: var(--ink-2); font-size: 14px; margin-top: 2px; }
.founder-links { display: flex; gap: var(--s4); margin-top: var(--s3); font-size: 14px; }

/* ------------------------------------------------------------ start here */

.steps { display: flex; gap: var(--s2); color: var(--ink-3); font-size: 13px; margin-bottom: var(--s4); flex-wrap: wrap; }
.steps span.on { color: var(--ink); font-weight: 600; }
.pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0; border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.pick a { display: flex; justify-content: space-between; gap: var(--s3); padding: var(--s3) var(--s4); background: var(--surface); border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); color: var(--ink); }
.pick a:hover { background: var(--paper); text-decoration: none; }
.pick a .n { color: var(--ink-3); }
.ev-group { margin-top: var(--s6); }
.ev-group > h2 { display: flex; justify-content: space-between; align-items: baseline; border-bottom: 2px solid var(--ink); padding-bottom: var(--s2); }
.ev-group > h2 .n { color: var(--ink-3); font-weight: 400; font-size: 14px; }
.ev-group .note { color: var(--ink-2); font-size: 14px; margin: var(--s2) 0 0; max-width: var(--measure); }

/* ------------------------------------------------------------ tabeller och prosa */

.prose { max-width: var(--measure); }
.prose h2 { margin: var(--s6) 0 var(--s2); }
.prose ul { padding-left: 20px; }
.prose li { margin-bottom: 4px; }
table.plain { border-collapse: collapse; width: 100%; font-size: 14px; }
table.plain th, table.plain td { text-align: left; padding: var(--s2) var(--s3) var(--s2) 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
table.plain th { font-weight: 600; color: var(--ink-2); font-size: 13px; }
table.plain td.n { text-align: right; color: var(--ink-2); }

.jlist { columns: 2; column-gap: var(--s6); }
.jlist a { display: flex; justify-content: space-between; gap: var(--s3); padding: 5px 0; border-bottom: 1px solid var(--rule); break-inside: avoid; color: var(--ink); }
.jlist a .n { color: var(--ink-3); }

/* ------------------------------------------------------------ admin */
.admin-login { max-width: 420px; }
.admin-login form { display: grid; gap: var(--s2); margin-top: var(--s4); }
.admin-login input, .admin-search input, .ed-form select, .ed-form input[type="search"], .ed-form input[list], .ed-report input {
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius); padding: 6px 8px; width: 100%;
}
.admin-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: var(--s3); }
.admin-tabs { display: flex; flex-wrap: wrap; gap: var(--s4); border-bottom: 1px solid var(--rule); }
.admin-tabs button { background: none; border: none; padding: var(--s2) 0; cursor: pointer; color: var(--ink-2); border-bottom: 2px solid transparent; margin-bottom: -1px; font-size: 14px; }
.admin-tabs button[aria-selected="true"] { color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.admin-tabs .n { color: var(--ink-3); font-weight: 400; }
.admin-desc { color: var(--ink-2); font-size: 14px; margin: var(--s3) 0; }
.admin-search[hidden] { display: none; }
.admin-search { display: flex; gap: var(--s2); max-width: 560px; margin-bottom: var(--s3); }
.admin-body { display: grid; grid-template-columns: minmax(260px, 380px) minmax(0, 1fr); gap: var(--s5); align-items: start; }
.admin-list { position: sticky; top: 76px; max-height: calc(100vh - 110px); overflow: auto; border-top: 1px solid var(--rule); }
.admin-list ol { list-style: none; margin: 0; padding: 0; }
.admin-list button { display: block; width: 100%; text-align: left; background: none; border: none; border-bottom: 1px solid var(--rule); padding: var(--s2) var(--s2); cursor: pointer; color: var(--ink); }
.admin-list button:hover { background: var(--surface-sunk); }
.admin-list button.on { background: var(--surface); box-shadow: inset 3px 0 0 var(--ink); }
.admin-list button.done .t { color: var(--ink-3); }
.admin-list .t { display: block; font-size: 14px; line-height: 1.35; }
.admin-list .m { display: flex; gap: var(--s2); font-size: 12px; margin-top: 3px; flex-wrap: wrap; }
.admin-list .rep { color: var(--alert); font-weight: 600; }
.st { font-size: 12px; padding: 0 6px; border-radius: var(--radius); background: var(--surface-sunk); color: var(--ink-2); }
.st-published { background: var(--interactive); color: var(--surface); }
:root[data-theme="dark"] .st-published { color: #0B100F; }
.admin-editor { background: var(--surface); border: 1px solid var(--rule); padding: var(--s5); }
.ed-head { display: flex; gap: var(--s3); align-items: center; font-size: 13px; }
.ed-title { font-family: var(--serif); font-weight: 500; font-size: 22px; margin: var(--s2) 0 var(--s1); }
.ed-links { font-size: 14px; }
.ed-decide { display: flex; gap: var(--s2); align-items: center; margin: var(--s3) 0; flex-wrap: wrap; }
.ed-decide kbd, .admin kbd { font: 11px var(--sans); border: 1px solid currentColor; border-radius: 3px; padding: 0 4px; opacity: .7; }
.lock { font-size: 12px; color: var(--ink-3); }
.ed-luna, .ed-abstract, .ed-log { border-top: 1px solid var(--rule); padding: var(--s2) 0; font-size: 14px; }
.ed-luna summary, .ed-abstract summary, .ed-log summary { cursor: pointer; font-weight: 600; }
.ed-luna p, .ed-abstract p { margin: var(--s2) 0 0; color: var(--ink-2); }
.ed-reports { border-top: 1px solid var(--rule); padding-top: var(--s3); }
.ed-reports h3 { margin-bottom: var(--s2); }
.ed-report { border-left: 3px solid var(--alert); padding: var(--s2) var(--s3); margin-bottom: var(--s2); background: var(--paper); font-size: 14px; }
.ed-report-actions { display: flex; gap: var(--s2); margin-top: var(--s2); }
.ed-form { border-top: 1px solid var(--rule); padding-top: var(--s3); display: grid; gap: var(--s3); font-size: 14px; }
.ed-form label { display: grid; gap: 4px; color: var(--ink-2); }
.ed-form label.check { display: flex; gap: 6px; color: var(--ink); align-items: baseline; }
.ed-form fieldset { border: none; padding: 0; margin: 0; }
.ed-form legend { color: var(--ink-2); padding: 0; margin-bottom: 4px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s3); }
.sub-grid { max-height: 260px; overflow: auto; border: 1px solid var(--rule); padding: var(--s2) var(--s3); margin-top: var(--s2); columns: 2; column-gap: var(--s4); }
.sub-group { break-inside: avoid; margin-bottom: var(--s2); }
.sub-group .group-label { font-size: 12px; color: var(--ink-3); margin-top: 4px; }
.ed-tags .chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: var(--s2); }
.ed-tags .chip button { background: none; border: none; cursor: pointer; color: var(--ink-3); padding: 0 0 0 2px; font-size: 14px; }
.ed-save { display: flex; gap: var(--s3); align-items: center; }
.ed-log ul { margin: var(--s2) 0 0; padding-left: 18px; color: var(--ink-2); font-size: 12px; overflow-wrap: anywhere; }

/* ------------------------------------------------------------ mobil */

.facets .sheet-close { display: none; justify-content: space-between; align-items: center; margin-bottom: var(--s3); }
input[type="radio"], input[type="checkbox"] { accent-color: var(--interactive); }

.sheet-backdrop { display: none; }

@media (max-width: 900px) {
  .site-header .inner { flex-wrap: wrap; gap: var(--s3); padding: var(--s3) var(--s4); }
  .search { order: 5; flex-basis: 100%; }
  .search input { max-width: none; }
  .site-nav { gap: var(--s3); margin-left: auto; }
  main { padding: var(--s5) var(--s4) var(--s7); }

  .feed-layout { grid-template-columns: 1fr; }
  .filters-toggle { display: inline-flex; }
  .facets {
    position: fixed; left: 0; right: 0; bottom: 0; top: auto; z-index: 30;
    max-height: 80vh; background: var(--surface); padding: var(--s4) var(--s4) var(--s6);
    border-top: 1px solid var(--rule); box-shadow: 0 -8px 24px rgba(0,0,0,.18);
    transform: translateY(100%); transition: transform .2s ease; visibility: hidden;
  }
  .facets.open { transform: none; visibility: visible; }
  .sheet-backdrop.open { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.35); z-index: 25; }
  .facets .sheet-close { display: flex; position: sticky; top: calc(-1 * var(--s4)); background: var(--surface); padding: var(--s2) 0; z-index: 1; }

  .day { grid-template-columns: 1fr; }
  .day-label { padding-top: var(--s3); }
  .day-label b { display: inline; font-size: 13px; margin-right: 4px; }
  .row .new { position: static; display: inline-block; margin: 0 8px 2px 0; vertical-align: middle; }

  .article { grid-template-columns: 1fr; gap: var(--s5); }
  .side { position: static; }
  .entries { grid-template-columns: repeat(2, 1fr); }
  .jlist { columns: 1; }
  .admin-body { grid-template-columns: 1fr; }
  .admin-list { position: static; max-height: 40vh; }
  .sub-grid { columns: 1; }
  .row2 { grid-template-columns: 1fr; }
  .facet li a { padding-top: 7px; padding-bottom: 7px; }
}

@media (max-width: 520px) {
  .entries { grid-template-columns: 1fr; }
  .brand-name { display: none; }
  .site-nav a.hide-sm { display: none; }
  .row .title { font-size: 17px; }
  .article h1 { font-size: 25px; }
  .abstract { font-size: 17px; }
}

@media print {
  .site-header, .site-footer, .facets, .feed-head .tools, .side .report-wrap { display: none; }
}

.week-nav { display: flex; gap: var(--s4); justify-content: space-between; margin: var(--s6) 0 var(--s4);
  border-top: 1px solid var(--rule); padding-top: var(--s3); font-family: var(--sans); font-size: 14px; }
