:root {
  color-scheme: light;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: #18191c;
  background: #edeef2;
  --ink: #18191c;
  --muted: #606570;
  --line: #dfe2e8;
  --canvas: #f6f7fa;
  --panel: #fff;
  --focus: #3b63ad;
  -webkit-font-smoothing: antialiased;
}

* { box-sizing: border-box; }
body { margin: 0; }
button, input { font: inherit; }
button, a { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
button { border: 0; padding: 0; color: inherit; background: transparent; cursor: pointer; }
button:disabled { cursor: default; opacity: .6; }
a { color: inherit; }
button, input, a { outline-offset: 4px; }
:focus-visible { outline: 2px solid var(--focus); }
[hidden] { display: none !important; }
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  padding: 0;
  border: 0;
  clip-path: inset(50%);
  white-space: nowrap;
}
.icon {
  display: block;
  flex: none;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.workspace {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--canvas);
}
.workspace::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 0 auto;
  height: 280px;
  border-radius: inherit;
  pointer-events: none;
  background-image:
    radial-gradient(ellipse 34% 165px at 53% calc(var(--glow-bleed, 0px) - 43px), rgb(72 118 183 / .82), transparent 100%),
    radial-gradient(ellipse 47% 216px at 51% calc(var(--glow-bleed, 0px) - 80px), #a6c8ed, transparent 94%),
    radial-gradient(ellipse 65% 148px at 51% calc(var(--glow-bleed, 0px) - 20px), rgb(211 228 239 / .8), transparent 94%);
}
@media screen {
  :root:has(body[data-view="reader"]) {
    overflow: hidden;
    background-color: var(--canvas);
  }
  body[data-view="reader"] {
    position: fixed;
    inset: 0;
    overflow-y: auto;
    overscroll-behavior-y: contain;
  }
}
[data-view="reader"] .workspace::before {
  --glow-bleed: 320px;
  top: calc(0px - var(--glow-bleed));
  height: calc(280px + var(--glow-bleed));
  background-color: var(--canvas);
  /* Composite the full ellipse, including the part revealed by rubber-banding. */
  transform: translateZ(0);
}
.mast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 20px clamp(20px, 2.2vw, 40px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  font-size: 18px;
  font-weight: 660;
  letter-spacing: -.04em;
  border-radius: 12px;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 40px;
  border-radius: 13px;
  background: rgb(255 255 255 / .94);
  box-shadow: 0 1px 3px rgb(25 40 60 / .055);
}
.brand-mark img { display: block; }
#searchForm {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 42px;
  flex: 1 1 220px;
  width: 100%;
  min-width: 0;
  padding: 0 12px 0 14px;
  background: rgb(255 255 255 / .93);
  border: 1px solid #dce0e8;
  border-radius: 100px;
  box-shadow: 0 1px 3px rgb(25 40 60 / .04);
}
#searchForm:focus-within { outline: 2px solid var(--focus); outline-offset: 2px; }
#searchForm > .icon { width: 17px; height: 17px; color: #444a54; }
#query {
  width: 100%;
  min-width: 0;
  height: 100%;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 14px;
}
#query::placeholder { color: var(--muted); opacity: 1; }
#query::-webkit-search-cancel-button { display: none; }
#shortcut {
  display: grid;
  place-items: center;
  width: 19px;
  height: 22px;
  flex: none;
  border: 1px solid #e6e8ec;
  border-radius: 5px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1;
}
#clear { display: grid; place-items: center; flex: none; width: 24px; height: 26px; border-radius: 6px; }
#clear .icon { width: 15px; height: 15px; }

.board { width: min(1120px, calc(100% - 100px)); margin-inline: auto; padding: 36px 0 54px; }

.board-heading h1, .admin-headings {
  font-size: clamp(34px, 3.45vw, 48px);
  font-weight: 590;
  line-height: 1.12;
  letter-spacing: -.055em;
}


.board-heading h1 { margin: 0; }
.board-heading { margin-bottom: 21px; }
.guest-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  text-align: center;
  gap: clamp(16px, 2vw, 24px);
  padding-block: clamp(10px, 2vw, 32px) clamp(36px, 5vw, 72px);
}
.guest-hero h1 {
  margin: 0;
  font-size: clamp(38px, 4.5vw, 66px);
  font-weight: 590;
  line-height: 1.06;
  letter-spacing: -.055em;
  text-wrap: balance;
}
.hero-words { display: grid; color: #44618a; }
.hero-words > span { grid-area: 1 / 1; }
.hero-words > span:not(:first-child) { opacity: 0; }
.hero-intro { width: min(100%, 60ch); }
.hero-lead { text-wrap: balance; margin: 0; color: var(--ink); font-size: clamp(16px, 1.4vw, 19px); line-height: 1.5; }
.hero-lead strong { font-weight: 620; white-space: nowrap; }
.hero-free { margin: 10px 0 0; font-size: 15px; color: var(--muted); text-wrap: pretty; }
.hero-purchase { margin-top: 20px; }
.hero-actions {
  position: relative; display: flex; align-items: stretch; width: fit-content; max-width: 100%; margin-inline: auto;
  border-radius: 999px; background: #fff;
}
.offer-prices { display: inline-flex; align-items: center; gap: 8px; padding: 4px 7px 4px 12px; white-space: nowrap; }
.offer-prices strong { font-size: 22px; line-height: 1.1; font-weight: 650; letter-spacing: -.045em; }
.offer-promotion {
  display: inline-flex; align-items: center; gap: 7px;
  color: #5a4024; font-variant-numeric: tabular-nums; line-height: 1.3;
}
.offer-promotion s { font-size: 14px; text-decoration-thickness: 1.5px; }
.offer-discount {
  padding: 5px 9px; border-radius: 999px;
  background: #ffd16f; color: #392818; font-size: 14px; font-weight: 680;
}
.hero-terms { max-width: 64ch; margin: 12px auto 0; color: var(--muted); font-size: 10px; line-height: 1.45; text-wrap: balance; }
#readerHeading { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.reader-upgrade { color: #354e73; font-size: 14px; text-decoration: underline; text-underline-offset: .24em; }
.hero-actions .hero-buy { display: inline-block; min-width: 0; min-height: 44px; padding: 10px 18px; border-radius: inherit; line-height: 1.35; text-wrap: balance; }
.hero-buy::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.hero-actions:has(.hero-buy:focus-visible) { outline: 2px solid var(--focus); outline-offset: 2px; }
.hero-actions .hero-buy:focus-visible { outline: none; }
@media (prefers-reduced-motion: no-preference) {
  .hero-words > span { animation: hero-word 12s linear infinite; }
  .hero-words > :first-child { animation-delay: -.2s; }
  .hero-words > :nth-child(2) { animation-delay: 2.8s; }
  .hero-words > :nth-child(3) { animation-delay: 5.8s; }
  .hero-words > :nth-child(4) { animation-delay: 8.8s; }
  @keyframes hero-word {
    0% { opacity: 0; transform: translateY(.08em); }
    1.5%, 24% { opacity: 1; transform: translateY(0); }
    25.5%, 100% { opacity: 0; transform: translateY(-.08em); }
  }
}
@media (max-width: 450px) {
  .guest-hero h1 { font-size: clamp(32px, 9.5vw, 38px); }
  .offer-prices { gap: 5px; padding-inline: 8px 5px; }
  .offer-prices strong { font-size: 18px; }
  .offer-promotion { gap: 4px; }
  .offer-promotion s, .offer-discount { font-size: 12px; }
  .offer-discount { padding: 4px 6px; }
  .hero-actions .hero-buy { padding: 7px 12px; }
}
.account-tools { display: flex; align-items: center; gap: 16px; }
.account-button {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 38px; padding-inline: 16px; font-size: 14px; font-weight: 550; border-radius: 30px; text-decoration: none;
}
.account-button { color: #fff; background: var(--ink); }
[data-view="reader"] #searchForm { font-size: 14px; }
[data-view="reader"] #query { font-size: inherit; }
[data-view="reader"] :is(#searchForm > .icon, .account-button .icon, .cover-filter .icon, .external .icon) {
  width: 1lh;
  height: 1lh;
}

.section-bar { display: flex; justify-content: space-between; align-items: center; column-gap: 16px; border-bottom: 1px solid var(--line); }
.sections { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(16px, 2vw, 28px); }
.sections button {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; font-size: 14px;
  font-weight: 550; white-space: nowrap; color: var(--muted); letter-spacing: -.015em;
}
.sections button[aria-pressed="true"] { color: var(--ink); }
.sections button[aria-pressed="true"]::after {
  content: ""; position: absolute; inset: auto 0 -1px; height: 2px; border-radius: 2px; background: currentColor;
}
.total { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.catalog-toolbar { display: flex; align-items: center; gap: 8px; margin: 18px 0 22px; }
.tools, .reader-filters, .topic-filters { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.tools { flex-wrap: nowrap; }
body[data-view="reader"] .catalog-toolbar { margin-bottom: 10px; }
.reader-filters { margin-bottom: 24px; }
.reader-filters .cover-filter { margin-left: auto; }
.filter-trigger, .topic-chip {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 37px;
  padding: 6px 12px; border: 1px solid #dce0e8; border-radius: 20px; background: rgb(255 255 255 / .72);
  font-size: 13px; font-weight: 510; line-height: 1.25; white-space: nowrap;
}
.filter-trigger .icon { width: 16px; height: 16px; }
.filter-trigger .chevron { width: 12px; height: 12px; }
.filter-trigger.is-filtered, .filter-trigger[aria-pressed="true"], .topic-chip[aria-pressed="true"] { color: #fff; background: #353e50; border-color: #353e50; }
.topic-chip, .reader-filters .cover-filter { min-height: 30px; padding: 4px 11px; font-size: 12px; }
.topic-chip { border-color: #dde2ec; background: transparent; }
.card-topic { font-size: 12px; color: var(--muted); }





.option-panel {
  position: fixed;
  inset: auto;
  z-index: 3;
  min-inline-size: 0;
  width: min(246px, calc(100vw - 24px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  margin: 0;
  padding: 6px;
  border: 1px solid #e3e5ea;
  border-radius: 15px;
  color: var(--ink);
  background: var(--panel);
  box-shadow: 0 10px 40px rgb(24 34 55 / .13), 0 2px 4px rgb(24 34 55 / .04);
}
.status-option {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 35px;
  padding: 6px 9px;
  font-size: 14px;
  border-radius: 8px;
  cursor: pointer;
}
.status-option input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.status-option:has(input:focus-visible) { outline: 2px solid var(--focus); outline-offset: -2px; }
.status-option .icon { width: 15px; height: 15px; visibility: hidden; }
.status-option input:checked + .icon { visibility: visible; }
.status-option:has(input:checked) { background: #f1f3f7; }
.option-count { margin-left: auto; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }

.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.resource {
  --cover-padding: 8%;
  position: relative;
  display: grid;
  grid-template-rows: subgrid;
  grid-template-columns: minmax(0, 1fr);
  grid-row: span 3;
  row-gap: 0;
  min-width: 0;
  padding: 16px;
  background: var(--panel);
  border: 1px solid rgb(31 38 57 / .035);
  border-radius: 21px;
  box-shadow: 0 1px 3px rgb(19 33 54 / .025);
}
.resource.reader-resource {
  grid-row: auto;
  grid-template-rows: 1fr auto;
  padding: 0;
}
.reader-card-content {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 6px;
  padding: var(--cover-padding) 18px 0;
  text-align: center;
}
.reader-card-content .description:empty { display: none; }
.reader-card-content .card-open { margin-inline: auto; text-align: center; }
.reader-card-content .card-topic {
  display: table;
  margin: 0 auto 12px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #eef1f6;
  line-height: 1.35;
}
particle-title { position: relative; display: inline-block; max-width: 100%; }
particle-title canvas {
  position: absolute;
  inset: -8px -12px;
  width: calc(100% + 24px);
  height: calc(100% + 16px);
  pointer-events: none;
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  particle-title.has-particles > span { opacity: 0; }
}

.resource.is-locked { overflow: clip; }
.locked-preview {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  margin-bottom: 5px;
}
.locked-preview > * { grid-area: 1 / 1; }
.locked-preview .card-cover:not(.is-missing) { filter: blur(2px); }
.locked-preview .is-missing .icon { visibility: hidden; }
.locked-preview .is-missing span { margin-top: 22px; }
.locked-preview:has(.is-missing) .card-open { margin-top: 0; }
.locked-preview .card-open {
  z-index: 1;
  align-self: center;
  justify-self: center;
  margin-top: var(--cover-padding);
}
.is-locked .card-open .locked {
  display: grid;
  width: 44px;
  height: 44px;
  background: var(--panel);
  box-shadow: 0 2px 10px rgb(26 29 43 / .14);
}
.resource.is-locked:has(.card-open:focus-visible) { outline: 2px solid var(--focus); outline-offset: 2px; }
.card-heading { min-width: 0; }
.card-heading h2 { margin: 0; font-size: 20px; font-weight: 630; line-height: 1.18; letter-spacing: -.035em; }
.card-open { display: block; max-width: 100%; text-align: left; font: inherit; letter-spacing: inherit; color: inherit; }
.card-open span {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow-wrap: anywhere;
}
.card-open::after { content: ""; position: absolute; z-index: 1; inset: 0; border-radius: 21px; }
.card-open:focus-visible { outline: none; }
.card-open:focus-visible::after { outline: 2px solid var(--focus); outline-offset: 2px; }
.host { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; line-height: 1.4; color: var(--muted); }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  width: max-content;
  max-width: 100%;
  line-height: 1.3;
  font-size: 11.5px;
  font-weight: 520;
  color: #60646c;
  white-space: nowrap;
  --dot: #969ba5;
}
.badge::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--dot); flex: none; }
.badge[data-status="accepted"] { color: #38674d; --dot: #588567; }
.badge[data-status="deferred"], .badge[data-status="draft"] { color: #7e5a2e; --dot: #ad8451; }
.badge[data-status="rejected"], .badge[data-status="conflict"] { color: #934f53; --dot: #ad6f71; }
.badge[data-status="trusted"] { color: #496258; --dot: #719785; }
.resource-list { position: relative; }
#preloadZone {
  position: absolute;
  inset: auto 0 0;
  height: min(150vh, 100%);
  pointer-events: none;
  overflow-anchor: none;
}
.page-status { text-align: center; font-size: 13px; color: var(--muted); }
.page-status:not(:empty) { padding-top: 16px; }
.import-note { font-size: 14px; margin-top: 14px; }

.cover {
  --cover-background: #e9edf7;
  --cover-shadow: 0 4px 12px rgb(26 29 43 / .14);
  overflow: hidden;
  border-radius: 12px;
  background: var(--cover-background);
}
.cover[data-tone="1"] { --cover-background: #e8edf4; }
.cover[data-tone="2"] { --cover-background: #e4eced; }
.cover[data-tone="3"] { --cover-background: #eee8f2; }
.cover[data-tone="4"] { --cover-background: #edeae1; }
.cover[data-tone="5"] { --cover-background: #e7e8f4; }
.card-cover {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  aspect-ratio: 1.93;
  padding: clamp(13px, 1.35vw, 20px) var(--cover-padding) 0;
}
.reader-resource .card-cover {
  background: transparent;
  border-radius: 0;
  border-bottom-left-radius: inherit;
  border-bottom-right-radius: inherit;
}
.reader-resource .card-cover:not(.is-missing) { padding: var(--cover-padding) var(--cover-padding) 0; }
.cover > img { display: block; width: 100%; height: auto; border-radius: 3px; box-shadow: var(--cover-shadow); }
.card-cover > img { flex: none; }
.cover.is-missing {
  position: relative;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 14px;
  color: #616775;
  background: #eef0f5;
  text-align: center;
}
.cover.is-missing::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .45;
  background-image: radial-gradient(circle, #c3cad8 .8px, transparent 1px);
  background-size: 10px 10px;
  mask-image: linear-gradient(120deg, black, transparent 60%, black);
}
.cover.is-missing > * { position: relative; }
.reader-resource .card-cover.is-missing { background: transparent; }
.reader-resource .card-cover.is-missing::before { content: none; }
.cover.is-missing .icon { width: 27px; height: 27px; }
.cover.is-missing span { font-size: 12px; }
.description {
  align-self: center;
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: #4c5059;
  font-size: 13px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow-wrap: anywhere;
}
.open-glyph {
  flex: none;
  display: grid;
  place-items: center;
  width: 33px;
  height: 33px;
  border-radius: 50%;
  color: #fff;
  background: var(--ink);
}
.open-glyph .icon { width: 16px; height: 16px; stroke-width: 1.8; }
.locked-preview .open-glyph .icon { width: 24px; height: 24px; }
.empty, .status-msg:not(:empty) { text-align: center; border-radius: 18px; background: var(--panel); padding: 44px 18px; }
.empty { grid-column: 1 / -1; }
.empty h2 { margin: 0; font-size: 24px; letter-spacing: -.04em; line-height: 1.2; }
.empty p, .status-msg p { margin: 8px 0 17px; color: var(--muted); font-size: 14px; }
.action { display: inline-flex; align-items: center; justify-content: center; padding: 9px 16px; border-radius: 20px; font-weight: 540; font-size: 13px; background: #eff1f5; }

dialog {
  position: fixed;
  inset: 12px 12px 12px auto;
  width: min(544px, calc(100% - 24px));
  height: calc(100% - 24px);
  height: calc(100dvh - 24px);
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgb(25 33 54 / .08);
  border-radius: 22px;
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 15px 65px rgb(25 33 54 / .16);
}
dialog[open] { display: flex; flex-direction: column; }
dialog::backdrop { background: rgb(33 37 48 / .29); }
body:has(dialog[open]) { overflow: hidden; }
.dialog-bar, .edit-controls, .dialog-scroll, .save-msg { padding-inline: 24px; }
.dialog-bar { display: flex; flex: none; align-items: center; justify-content: space-between; gap: 8px; min-height: 64px; border-bottom: 1px solid var(--line); }
#detailNo { font-weight: 580; font-size: 14px; }
.review-nav { display: flex; gap: 3px; margin-left: auto; }
.review-nav button { display: inline-flex; align-items: center; gap: 3px; padding: 8px 7px; min-height: 36px; border-radius: 8px; font-size: 13px; }
.review-nav .icon { width: 15px; height: 15px; }
.review-nav button:disabled { opacity: .35; }
.review-nav button:enabled:hover { background: #f0f2f5; }
.icon-btn { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: #f0f2f5; }
.icon-btn .icon { width: 17px; height: 17px; }
.dialog-scroll { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding-block: 25px 28px; }
.detail-top { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.detail-top .host { max-width: 100%; }
#cardTitle { margin: 10px 0 9px; font-size: clamp(28px, 3.2vw, 39px); font-weight: 590; letter-spacing: -.05em; line-height: 1.08; overflow-wrap: anywhere; }
.detail-summary { margin: 0 0 16px; color: #4c5059; font-size: 15px; }
.external { display: inline-flex; gap: 8px; align-items: center; padding: 9px 15px; border-radius: 40px; color: #fff; background: var(--ink); text-decoration: none; font-weight: 530; font-size: 13px; }
.external .icon { width: 14px; height: 14px; }
.full-cover { display: block; border-radius: 14px; cursor: zoom-in; }
.detail-cover {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 5 / 4;
  padding: 0 8%;
  margin-top: 22px;
  border-radius: 14px;
}
.part { padding-top: 16px; margin-top: 20px; border-top: 1px solid var(--line); }
.part h3 { margin: 0 0 6px; font-size: 15px; font-weight: 620; letter-spacing: -.02em; }
.part p, .part li { margin: 0; font-size: 14px; overflow-wrap: anywhere; line-height: 1.55; }
.part ul { margin: 0; padding-left: 19px; }
.part li + li { margin-top: 4px; }
.muted { color: var(--muted); }
.tags { display: flex; flex-wrap: wrap; gap: 5px; }
.tag { padding: 3px 9px; background: #f0f2f6; border-radius: 12px; color: #545b66; font-size: 12px; }
.edit-controls { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; flex: none; padding-block: 13px 16px; border-top: 1px solid var(--line); background: #fafbfd; }
.edit-controls:empty { display: none; }
.edit-controls strong { flex: 1 0 100%; font-size: 13px; font-weight: 600; }
.edit-controls p { flex-basis: 100%; margin: 0; color: var(--muted); font-size: 13px; }
.decision { flex: 1 1 auto; padding: 8px; background: white; border: 1px solid var(--line); border-radius: 10px; font-size: 13px; }
.decision[data-value="accepted"] { color: white; background: var(--ink); border-color: var(--ink); }
.decision[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--ink); }
.save-msg { background: #fafbfd; font-size: 13px; }
.save-msg:not(:empty) { padding-bottom: 12px; }

.open-glyph.locked { color: #485368; background: #eef1f6; }
.account-dialog {
  inset: 0; width: min(414px, calc(100% - 32px)); height: fit-content; max-height: calc(100dvh - 32px);
  margin: auto; padding: 30px; overflow-y: auto; border-radius: 23px;
}
.account-dialog[open] { display: block; }
.modal-close { position: absolute; top: 14px; right: 14px; }
.modal-symbol { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: #eaf0f8; color: #3a4c65; margin-bottom: 17px; }
.modal-symbol .icon { width: 22px; height: 22px; }
#accountTitle { margin: 0 0 10px; font-size: 29px; line-height: 1.13; letter-spacing: -.045em; font-weight: 610; outline: none; }
.modal-lead, .account-email { margin: 0; color: #4b515c; font-size: 15px; overflow-wrap: anywhere; }
.release-details { margin: 18px 0 0; font-size: 14px; }
.release-details dt { margin-top: 12px; color: var(--ink); font-weight: 600; }
.release-details dd { margin: 3px 0 0; color: #4b515c; }
.modal-note { margin: 17px 0 20px; padding: 11px 13px; border-radius: 10px; color: #475469; background: #f1f4f8; font-size: 13px; }
.account-primary, .account-secondary { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 43px; padding: 9px 15px; border-radius: 12px; font-size: 14px; font-weight: 550; }
.account-primary { color: #fff; background: var(--ink); }
.account-secondary { margin-top: 4px; color: #495466; }
.auth-form { display: grid; gap: 14px; margin-top: 21px; }
.account-field { display: grid; gap: 5px; font-size: 13px; font-weight: 550; }
.account-field input { width: 100%; min-height: 42px; padding: 8px 12px; border: 1px solid #cdd2dc; border-radius: 10px; background: white; color: var(--ink); font-size: 16px; }
.account-field input::placeholder { font-weight: 400; }
.account-field ui-password-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  border: 1px solid #cdd2dc;
  border-radius: 10px;
  background: white;
}
.account-field ui-password-input input { min-width: 0; border: 0; }
ui-password-input-toggle button { min-height: 40px; padding: 0 12px; border-radius: 9px; color: #495466; }
ui-password-input-toggle .hide-password,
ui-password-input-toggle button[aria-pressed="true"] .show-password { display: none; }
ui-password-input-toggle button[aria-pressed="true"] .hide-password { display: inline; }
.account-error { margin: 0; color: #973b44; font-size: 13px; }
.account-error:empty { display: none; }

@media (hover: hover) and (pointer: fine) {
  .sections button:hover { color: var(--ink); }
  .filter-trigger:not(.is-filtered):not([aria-pressed="true"]):hover, .topic-chip:not([aria-pressed="true"]):hover,
  .icon-btn:hover, #clear:hover, .status-option:hover, .account-secondary:hover,
  .decision:not([data-value="accepted"]):hover { background: #e9ecf1; }
  .resource:hover { border-color: #d9dde6; box-shadow: 0 4px 14px rgb(34 45 66 / .055); }
  .external:hover, .account-button:hover, .account-primary:hover, .decision[data-value="accepted"]:hover { background: #363d4b; }
  .resource:hover .open-glyph.locked { background: #e0e6f0; }
  .action:hover { background: #e0e5ed; }
}
@media (max-width: 1000px) {
  .board { width: calc(100% - 64px); padding-top: 28px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .catalog-toolbar { flex-wrap: wrap; }
  #searchForm { flex-basis: 100%; }
  .catalog-toolbar:has(.tools:not([hidden])) { row-gap: 10px; }
}
@media (max-width: 650px) {
  .workspace::before { height: 165px; background-size: 150% 100%; background-position: center top; }
  .mast { padding: 16px; gap: 12px; }
  .brand { gap: 7px; font-size: 16px; }
  .brand-mark { width: 34px; height: 34px; border-radius: 10px; }
  .brand-mark img { width: 25px; height: 25px; }
  .account-tools { gap: 4px; }
  .account-button { padding-inline: 11px; font-size: 13px; }
  .board { width: calc(100% - 32px); padding-block: 23px 28px; }


  .board-heading { margin-bottom: 12px; }
  body[data-view="editor"] .section-bar { flex-wrap: wrap; row-gap: 3px; }
  .sections { gap: 17px; }
  .sections button { min-height: 42px; font-size: 13px; }
  .section-bar:has(.sections:not([hidden])) .total { margin-left: auto; }
  .total { font-size: 12px; }
  .catalog-toolbar { margin-block: 14px 18px; gap: 6px; }
  #query { font-size: 16px; }
  [data-view="reader"] #searchForm { font-size: 16px; }
  #shortcut { display: none; }
  .tools, .reader-filters, .topic-filters { gap: 6px; }
  .tools { flex-wrap: wrap; min-width: 0; max-width: 100%; }
  .filter-trigger { gap: 5px; padding-inline: 9px; font-size: 12px; }
  .reader-filters { margin-bottom: 18px; }
  .reader-filters .cover-filter { margin-left: 0; }
  .topic-filters { display: contents; }
  .status-option { min-height: 42px; }
  .grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .resource { padding: 15px; border-radius: 20px; }
  .reader-card-content { padding-inline: 17px; }
  .card-open::after { border-radius: 20px; }
  .card-cover { padding-top: 16px; }
  #detail { inset: 0; width: 100%; height: 100dvh; border: 0; border-radius: 0; }
  .dialog-bar, .edit-controls, .dialog-scroll, .save-msg { padding-inline: 18px; }
  .edit-controls { padding-bottom: max(16px, env(safe-area-inset-bottom)); }
  .account-dialog { padding: 25px; }
}
@media (max-width: 485px) {
  body[data-view="editor"] .section-bar:has(.sections:not([hidden])) { position: relative; margin-bottom: 32px; }
  body[data-view="editor"] .section-bar:has(.sections:not([hidden])) .total { position: absolute; right: 0; top: calc(100% + 5px); }
}
@media (max-width: 365px) {
  .mast { padding-inline: 12px; }

  .board { width: calc(100% - 24px); }
  .sections { gap: 8px; }
  .sections button { font-size: 12px; }
  .section-bar { column-gap: 4px; }
  .card-heading h2 { font-size: 19px; }
  }


.public-sections { position: relative; flex-wrap: nowrap; overflow-x: auto; gap: 18px; min-width: 0; }
.public-sections button { scroll-margin-top: 18px; }
.public-sections button:focus-visible { outline-offset: -2px; }
.public-sections button[aria-pressed="true"]::after { content: none; }
.public-sections::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: var(--line-width, 0);
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transform: translateX(var(--line-left, 0px));
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .public-sections.slide-line::after {
    transition: transform 200ms ease-out, width 200ms ease-out;
  }
}
.section-choices { border: 0; padding: 0; margin: 0; min-inline-size: 0; }
.section-choices legend { padding: 0; margin-bottom: 6px; color: var(--muted); font-size: 12px; }
.section-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.section-chip { position: relative; cursor: pointer; }
.section-chip input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: inherit; }
.section-chip input:checked + .topic-chip { background: #353e50; color: #fff; border-color: #353e50; }
.section-chip input:focus-visible + .topic-chip { outline: 2px solid var(--focus); outline-offset: 2px; }
@media (hover: hover) {
  .section-chip:hover input:enabled:not(:checked) + .topic-chip { background: #eaedf2; }
}
.classification-filter { margin-bottom: 16px; }
.classification { flex-basis: 100%; display: grid; gap: 8px; font-size: 13px; }

.admin-headings { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px clamp(18px, 2.3vw, 34px); }
.admin-headings h1 { font: inherit; letter-spacing: inherit; }
.admin-headings a { display: inline-block; color: #68717e; text-decoration: none; }
.admin-headings a:hover, .admin-headings a:focus-visible, .admin-headings a[aria-current] { color: var(--ink); }
.preview-toolbar, .preview-roles { display: flex; align-items: center; flex-wrap: wrap; }
.preview-toolbar { justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.preview-roles { gap: 2px; border: 1px solid var(--line); padding: 3px; border-radius: 12px; background: #eef0f4; }
.preview-roles button { padding: 7px 12px; font-size: 13px; border-radius: 9px; }
.preview-roles button[aria-pressed="true"] { background: white; box-shadow: 0 1px 3px #18213822; }
#openPreview { font-size: 13px; color: var(--muted); text-underline-offset: 3px; }
#readerPreview { display: block; width: 100%; height: 80dvh; min-height: 380px; border: 1px solid var(--line); border-radius: 16px; background: var(--canvas); }
@media (max-width: 700px) {
  .admin-headings { font-size: clamp(25px, 6vw, 34px); }
}
.edit-card-button { margin-inline-start: 8px; }
#contentEditor, #commentEditor { inset: 0; margin: auto; height: fit-content; width: min(500px, calc(100% - 24px)); padding: 0; }
.content-form { padding: 24px; display: grid; gap: 14px; overflow-y: auto; max-height: 86dvh; }
.content-form h2 { margin: 0 0 5px; font-size: 22px; letter-spacing: -.03em; }
.content-form label { display: grid; gap: 6px; font-size: 13px; font-weight: 550; }
.content-form :is(input,textarea) { min-width: 0; width: 100%; padding: 9px 11px; border: 1px solid var(--line); border-radius: 9px; font-family: inherit; font-size: 15px; font-weight: 400; line-height: 1.4; }
.content-form textarea { resize: vertical; }
.content-form small { margin-top: -10px; color: var(--muted); }
.form-actions { display: flex; gap: 8px; justify-content: flex-end; align-items: center; }
.form-actions .account-primary { width: auto; padding-inline: 18px; }
#contentError { color: #984842; margin: 0; }
#contentError:empty { display: none; }
.queue-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 24px; }
.queue-stats a, .stats-table { background: var(--panel); border-radius: 16px; }
.queue-stats a { display: grid; gap: 10px; padding: 18px; color: var(--muted); font-size: 14px; text-decoration: none; }
.queue-stats strong { color: var(--ink); font-size: 29px; letter-spacing: -.04em; }
.stats-table { border-spacing: 0; width: 100%; font-size: 14px; font-variant-numeric: tabular-nums; }
.stats-table caption { font-size: 19px; font-weight: 600; text-align: left; padding-bottom: 12px; }
.stats-table :is(td,th) { padding: 12px 16px; border-bottom: 1px solid var(--line); text-align: right; }
.stats-table th:first-child { text-align: left; }
.stats-table thead { color: var(--muted); font-size: 12px; }
.stats-table tfoot { font-weight: 650; }
.stats-table tfoot :is(td,th) { border: 0; }
@media(max-width: 640px) {
  [data-view="editor"] .mast { flex-wrap: wrap; height: auto; gap: 10px; }
  .queue-stats { grid-template-columns: repeat(2, 1fr); }
  .stats-table :is(td,th) { padding: 10px 6px; }
  #editorFilters { flex-wrap: wrap; }
}

@media(max-width: 700px) {
  [data-view="editor"] .catalog-toolbar { flex-wrap: wrap; }
  [data-view="editor"] #searchForm { flex: 1 0 100%; }
}

@media(max-width: 365px) {
  .stats-table { font-size: 12px; }
  .stats-table thead { font-size: 11px; }
  .stats-table :is(td,th) { padding-inline: 4px; }
}

.reader-more { display: block; margin: 20px auto 0; }

.comment-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.comment-head h3 { margin: 0; }
.card-comment .comment-text { margin-top: 8px; white-space: pre-wrap; }
.card-comment h4 { margin: 12px 0 0; font-size: 13px; }
.comment-queue { display: inline-block; margin-top: 8px; font-size: 12px; color: var(--muted); }
