:root {
  --font-serif: "CMU Serif", "Computer Modern Serif", "Latin Modern Roman", "New Computer Modern", "Times New Roman", serif;
  --ink: #000000;
  --text: #111111;
  --muted: #303030;
  --soft: #5a5a5a;
  --paper: #ffffff;
  --border: 2px solid var(--ink);
  color-scheme: light;
  font-family: var(--font-serif);
}

@font-face {
  font-family: "CMU Serif";
  src: url("fonts/cmunrm.otf") format("opentype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "CMU Serif";
  src: url("fonts/cmunbx.otf") format("opentype");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: "CMU Serif";
  src: url("fonts/cmunti.otf") format("opentype");
  font-style: italic;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "CMU Serif";
  src: url("fonts/cmunbi.otf") format("opentype");
  font-style: italic;
  font-weight: 700;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  overflow-y: auto;
  background: var(--paper);
  color: var(--ink);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.page-frame {
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 100dvh;
  overflow: clip;
  border: var(--border);
  background: var(--paper);
}

.site-header {
  display: grid;
  grid-template-columns: auto 1fr minmax(210px, 26vw);
  align-items: center;
  gap: clamp(18px, 3vw, 46px);
  min-height: 66px;
  padding: 9px 14px;
  border-bottom: var(--border);
}

.site-title,
.site-nav a {
  font-size: clamp(1.45rem, 2.4vw, 2.05rem);
  line-height: 1;
  white-space: nowrap;
}

.site-nav {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: clamp(14px, 2.6vw, 42px);
}

.site-search {
  min-width: 0;
}

.site-search input {
  width: 100%;
  min-height: 43px;
  padding: 0 14px;
  border: var(--border);
  color: var(--ink);
  font-size: clamp(1.25rem, 2vw, 1.7rem);
  outline: none;
}

.site-search input::placeholder {
  color: var(--ink);
  opacity: 1;
}

.home-page,
.simple-page {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 34px clamp(20px, 3vw, 34px) clamp(18px, 2vw, 28px);
}

.home-page h1,
.simple-page h1 {
  margin: 0 0 32px;
  font-size: clamp(3rem, 6vw, 5.2rem);
  font-weight: 400;
  line-height: 1;
}

.title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
}

.title-row h1 {
  margin-bottom: 32px;
}

.title-action {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  padding: 2px 14px;
  border: var(--border);
  background: var(--paper);
  color: var(--ink);
  font-size: clamp(1.05rem, 1.5vw, 1.28rem);
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}

.title-action:hover {
  background: #f1f1f1;
}

.filter-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 18px;
  padding: 12px;
  overflow-x: auto;
  border: var(--border);
}

.filter-panel[hidden] {
  display: none;
}

.filter-panel h2 {
  margin: 0 0 8px;
  font-size: clamp(1rem, 1.35vw, 1.18rem);
}

.filter-options {
  display: flex;
  max-height: 112px;
  flex-wrap: wrap;
  gap: 6px;
  overflow-y: auto;
  padding-right: 4px;
}

.filter-chip {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  padding: 2px 8px;
  border: 1px solid var(--ink);
  background: var(--paper);
  color: var(--muted);
  font-size: clamp(0.9rem, 1.08vw, 1rem);
  line-height: 1.05;
  cursor: pointer;
}

.filter-chip.is-active {
  background: var(--ink);
  color: var(--paper);
}

.paper-window {
  flex: 1;
  width: 100%;
  min-height: 0;
  margin: 0;
  padding: 24px 22px 18px;
  overflow: hidden;
  border: var(--border);
}

.paper-scroll {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
  gap: 14px;
  overflow-y: auto;
  padding-right: 10px;
  scrollbar-color: var(--ink) transparent;
  scrollbar-width: auto;
}

.paper-scroll::-webkit-scrollbar {
  width: 14px;
}

.paper-scroll::-webkit-scrollbar-thumb {
  background: var(--ink);
}

.paper-scroll::-webkit-scrollbar-track {
  background: transparent;
}

.paper-row {
  display: grid;
  flex: 0 0 auto;
  grid-template-columns: minmax(0, 1fr) minmax(210px, 35%);
  gap: 24px;
  min-height: 108px;
  padding: 10px 14px;
  border: var(--border);
}

.paper-main h2 {
  margin: 0 0 5px;
  color: var(--text);
  font-size: clamp(1.35rem, 2vw, 1.85rem);
  font-weight: 700;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.paper-authors,
.paper-meta p,
.paper-abstract summary,
.paper-abstract p {
  margin: 0;
  line-height: 1.16;
}

.paper-authors {
  max-width: 62ch;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.45vw, 1.28rem);
  overflow-wrap: anywhere;
}

.paper-authors a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.paper-authors a:hover {
  background: #f1f1f1;
}

.paper-abstract summary {
  color: var(--soft);
  font-size: clamp(1rem, 1.4vw, 1.2rem);
}

.paper-abstract {
  margin-top: 3px;
}

.paper-abstract summary {
  display: inline-block;
  cursor: pointer;
  list-style: none;
}

.paper-abstract summary::-webkit-details-marker {
  display: none;
}

.paper-abstract summary::after {
  content: " (expand)";
}

.paper-abstract[open] summary::after {
  content: " (close)";
}

.paper-abstract p {
  margin-top: 8px;
  max-width: 72ch;
  color: var(--soft);
  font-size: clamp(0.98rem, 1.25vw, 1.12rem);
  line-height: 1.3;
}

.paper-meta {
  display: grid;
  align-content: center;
  justify-items: start;
  min-width: 0;
  gap: 9px;
}

.paper-meta time {
  color: var(--soft);
  font-size: clamp(0.96rem, 1.18vw, 1.08rem);
}

.paper-links {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.paper-chip {
  display: inline-flex;
  max-width: 100%;
  min-height: 28px;
  align-items: center;
  padding: 2px 8px 3px;
  overflow: hidden;
  border: 1px solid var(--ink);
  color: var(--muted);
  font-size: clamp(0.94rem, 1.2vw, 1.08rem);
  line-height: 1.05;
  text-overflow: ellipsis;
}

.paper-chip:first-child {
  color: var(--muted);
  font-weight: 700;
}

.paper-chip:hover {
  background: #f1f1f1;
}

.review-chip {
  border-style: double;
  color: var(--ink);
}

.review-list {
  gap: 18px;
}

.review-row {
  display: grid;
  flex: 0 0 auto;
  gap: 8px;
}

.review-row > .paper-row {
  min-height: 0;
}

.review-details {
  padding: 10px 14px;
  border: 1px solid var(--ink);
  color: var(--muted);
  font-size: clamp(0.95rem, 1.18vw, 1.08rem);
}

.review-details p,
.review-details ul {
  margin: 0 0 6px;
}

.review-details ul {
  padding-left: 20px;
}

.review-details code {
  font-family: inherit;
  color: var(--ink);
}

.empty-row {
  display: block;
  min-height: auto;
  font-size: clamp(1.35rem, 2vw, 1.8rem);
}

.empty-panel {
  width: 100%;
  min-height: 0;
  border: var(--border);
}

.people-list {
  gap: 10px;
}

.person-row {
  display: grid;
  flex: 0 0 auto;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 10px 14px;
  border: var(--border);
  color: var(--text);
  font-size: clamp(1.2rem, 1.8vw, 1.55rem);
}

.person-row span:first-child {
  font-weight: 700;
}

.person-row span:last-child {
  color: var(--soft);
  font-size: clamp(1rem, 1.35vw, 1.18rem);
}

.person-row:hover {
  background: #f5f5f5;
}

.group-list {
  gap: 12px;
}

.group-row {
  display: grid;
  flex: 0 0 auto;
  grid-template-columns: minmax(0, 1fr) minmax(230px, 32%);
  gap: 18px;
  padding: 10px 14px;
  border: var(--border);
}

.group-main h2 {
  margin: 0 0 5px;
  color: var(--text);
  font-size: clamp(1.25rem, 1.8vw, 1.65rem);
  font-weight: 700;
  line-height: 1.08;
  overflow-wrap: anywhere;
}

.group-main h2 a {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.group-institution,
.group-detail {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.32vw, 1.18rem);
  line-height: 1.2;
}

.group-detail {
  color: var(--soft);
}

.group-meta {
  display: flex;
  flex-wrap: wrap;
  align-content: center;
  gap: 7px;
}

.group-page .paper-scroll {
  gap: 18px;
}

.group-profile,
.group-section {
  flex: 0 0 auto;
  padding: 14px;
  border: var(--border);
}

.group-profile {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 38%);
  gap: 18px;
}

.group-profile h2,
.group-section h2 {
  margin: 0 0 8px;
  color: var(--text);
  font-size: clamp(1.2rem, 1.7vw, 1.5rem);
}

.group-profile p {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.35vw, 1.18rem);
  line-height: 1.26;
}

.profile-meta {
  display: grid;
  gap: 8px;
  margin: 0;
}

.profile-meta div {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 10px;
}

.profile-meta dt {
  color: var(--text);
  font-weight: 700;
}

.profile-meta dd {
  margin: 0;
  color: var(--muted);
}

.group-section-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

@media (max-width: 860px) {
  .page-frame {
    min-height: 100dvh;
    overflow: visible;
  }

  .site-header {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .site-nav {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 10px 18px;
  }

  .site-title,
  .site-nav a {
    white-space: normal;
  }

  .paper-window {
    margin-left: 0;
    padding: 14px;
  }

  .paper-row {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .group-row {
    grid-template-columns: 1fr;
  }

  .title-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 0;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .group-profile {
    grid-template-columns: 1fr;
  }

  .paper-meta {
    align-content: start;
  }
}

@media (max-width: 520px) {
  .page-frame {
    border-width: 1px;
  }

  .site-header {
    min-height: 0;
    padding: 7px 12px 9px;
  }

  .site-title {
    font-size: 1.42rem;
  }

  .site-nav a {
    font-size: 1.22rem;
  }

  .site-search input {
    min-height: 39px;
    padding: 0 11px;
    font-size: 1.2rem;
  }

  .home-page,
  .simple-page {
    display: block;
    min-height: auto;
    padding: 28px 14px 26px;
  }

  .home-page h1,
  .simple-page h1 {
    margin-bottom: 26px;
    font-size: clamp(2.65rem, 13vw, 4rem);
  }

  .paper-window {
    flex: none;
    min-height: 0;
    padding: 14px;
    overflow: visible;
  }

  .paper-scroll {
    height: auto;
    max-height: none;
    gap: 12px;
    overflow: visible;
    padding-right: 0;
  }

  .paper-row,
  .group-row,
  .person-row,
  .group-profile,
  .group-section {
    padding: 10px 12px;
  }

  .paper-main,
  .paper-meta,
  .group-main,
  .group-meta {
    min-width: 0;
  }

  .paper-main h2 {
    font-size: 1.45rem;
  }

  .paper-authors {
    max-width: none;
    font-size: 1.02rem;
  }

  .paper-abstract summary,
  .paper-meta time,
  .paper-chip {
    font-size: 0.98rem;
  }

  .paper-chip {
    min-height: 26px;
  }

  .title-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
  }

  .title-row h1 {
    margin-bottom: 24px;
  }
}

.dev-add-button {
  margin-left: auto;
}

.admin-page {
  gap: 14px;
}

.admin-page .title-row h1 {
  margin-bottom: 0;
}

.admin-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: var(--border);
}

.admin-url-form {
  display: grid;
  flex: 1 1 420px;
  grid-template-columns: auto minmax(180px, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.admin-url-form label,
.admin-select-label {
  color: var(--muted);
  font-size: clamp(1rem, 1.2vw, 1.12rem);
}

.admin-url-form input,
.admin-toolbar select,
.admin-field input,
.admin-field select,
.admin-field textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: clamp(1rem, 1.2vw, 1.12rem);
}

.admin-url-form input,
.admin-toolbar select,
.admin-field input,
.admin-field select {
  min-height: 36px;
  padding: 3px 8px;
}

.admin-field textarea {
  min-height: 92px;
  resize: vertical;
  padding: 7px 8px;
  line-height: 1.2;
}

.admin-dashboard {
  display: grid;
  grid-template-columns: minmax(300px, 43%) minmax(0, 1fr);
  flex: 1;
  min-height: 0;
  gap: 14px;
}

.admin-list-window {
  padding: 14px;
}

.admin-paper-list {
  gap: 10px;
}

.admin-paper-row {
  flex: 0 0 auto;
  border: var(--border);
}

.admin-paper-row button {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  background: var(--paper);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.admin-paper-row.is-selected,
.admin-paper-row:hover {
  background: #f3f3f3;
}

.admin-paper-row h2 {
  margin: 0 0 5px;
  font-size: clamp(1.08rem, 1.35vw, 1.28rem);
  line-height: 1.08;
}

.admin-paper-row p {
  margin: 0 0 8px;
  color: var(--soft);
  font-size: clamp(0.92rem, 1.08vw, 1rem);
  line-height: 1.16;
}

.admin-editor {
  min-height: 0;
  overflow-y: auto;
  padding: 14px;
  border: var(--border);
}

.admin-editor-head {
  display: grid;
  gap: 8px;
  margin-bottom: 8px;
}

.admin-editor h2,
.admin-modal-panel h2 {
  margin: 0;
  font-size: clamp(1.55rem, 2.3vw, 2.1rem);
  line-height: 1.05;
}

.admin-authors,
.admin-date,
.admin-note {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: clamp(1rem, 1.22vw, 1.12rem);
  line-height: 1.2;
}

.admin-abstract {
  margin: 10px 0 14px;
}

.admin-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.admin-field {
  display: grid;
  gap: 4px;
  color: var(--muted);
}

.admin-field span {
  color: var(--ink);
  font-weight: 700;
}

.admin-group-select {
  margin-top: 10px;
}

.admin-group-select select {
  min-height: 170px;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.admin-primary-action {
  border-width: 3px;
  font-weight: 700;
}

.admin-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(255, 255, 255, 0.82);
}

.admin-modal[hidden] {
  display: none;
}

.admin-modal-panel {
  width: min(760px, 100%);
  max-height: calc(100dvh - 36px);
  overflow-y: auto;
  padding: 16px;
  border: var(--border);
  background: var(--paper);
}

.admin-modal-panel .title-row {
  align-items: center;
  margin-bottom: 14px;
}

.admin-modal-panel .admin-field {
  margin-bottom: 10px;
}

@media (max-width: 980px) {
  .admin-dashboard {
    grid-template-columns: 1fr;
  }

  .admin-list-window {
    max-height: 48dvh;
  }
}

@media (max-width: 620px) {
  .admin-toolbar,
  .admin-url-form,
  .admin-form-grid {
    grid-template-columns: 1fr;
  }

  .admin-toolbar {
    display: grid;
  }

  .admin-page .title-row {
    grid-template-columns: 1fr;
  }

  .admin-editor h2,
  .admin-modal-panel h2 {
    font-size: 1.42rem;
  }
}

.admin-toolbar,
.admin-toolbar > *,
.admin-dashboard,
.admin-list-window,
.admin-editor,
.admin-paper-row,
.admin-paper-row button,
.admin-url-form {
  min-width: 0;
  max-width: 100%;
}

.admin-paper-row h2,
.admin-paper-row p,
.admin-editor h2,
.admin-authors,
.admin-note {
  overflow-wrap: anywhere;
}

@media (max-width: 620px) {
  .admin-toolbar .title-action,
  .admin-url-form .title-action {
    width: 100%;
  }

  .admin-list-window {
    width: 100%;
  }
}

/* Admin review layout: fixed panes, independent scroll. */
.admin-body {
  height: 100dvh;
  overflow: hidden;
}

.admin-body .page-frame {
  height: 100dvh;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
}

.admin-page {
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.admin-dashboard {
  min-height: 0;
  overflow: hidden;
}

.admin-list-window {
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

.admin-list-window .paper-scroll,
.admin-paper-list {
  height: 100%;
  max-height: none;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.admin-editor {
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.admin-taxonomy-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.admin-check-section {
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--ink);
}

.admin-check-section.is-large {
  margin-top: 10px;
}

.admin-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.admin-section-head h3 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.05rem, 1.35vw, 1.22rem);
  line-height: 1.05;
}

.admin-section-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.admin-section-actions .title-action {
  min-height: 28px;
  padding: 1px 8px;
  font-size: clamp(0.88rem, 1.05vw, 0.98rem);
}

.admin-option-list {
  display: grid;
  max-height: 178px;
  gap: 5px;
  overflow-y: auto;
  padding-right: 6px;
  scrollbar-color: var(--ink) transparent;
}

.admin-check-section.is-large .admin-option-list {
  max-height: 250px;
}

.admin-option-row {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
  min-width: 0;
  padding: 3px 4px;
  color: var(--muted);
  font-size: clamp(0.96rem, 1.14vw, 1.04rem);
  line-height: 1.12;
  cursor: pointer;
}

.admin-option-row:hover {
  background: #f3f3f3;
}

.admin-option-row input {
  width: 15px;
  height: 15px;
  margin: 1px 0 0;
  accent-color: var(--ink);
}

.admin-option-row span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.admin-option-meta {
  grid-column: 2;
  color: var(--soft);
  font-size: 0.9em;
}

.admin-option-empty {
  color: var(--soft);
  font-size: clamp(0.96rem, 1.14vw, 1.04rem);
}

.admin-work-options {
  max-height: none;
}

@media (max-width: 980px) {
  .admin-body {
    height: auto;
    overflow-y: auto;
  }

  .admin-body .page-frame {
    height: auto;
    min-height: 100dvh;
    overflow: visible;
  }

  .admin-page {
    height: auto;
    overflow: visible;
  }

  .admin-dashboard {
    overflow: visible;
  }

  .admin-list-window {
    height: 46dvh;
  }

  .admin-editor {
    height: auto;
    max-height: none;
  }
}

@media (max-width: 720px) {
  .admin-taxonomy-grid {
    grid-template-columns: 1fr;
  }

  .admin-section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-section-actions {
    justify-content: flex-start;
  }
}

.admin-page {
  padding-top: 18px;
}

.admin-page .title-row h1 {
  font-size: clamp(2.1rem, 3.2vw, 3.2rem);
  line-height: 1;
}

.admin-toolbar {
  padding: 9px 10px;
}

.admin-section-search {
  width: 100%;
  min-height: 30px;
  margin: 0 0 7px;
  padding: 2px 7px;
  border: 1px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: clamp(0.92rem, 1.08vw, 1rem);
}

.admin-section-search::placeholder {
  color: var(--soft);
  opacity: 1;
}

.admin-option-row[hidden] {
  display: none;
}

/* 2026 visual system: a warmer research-atlas surface with ion-trap accents. */
:root {
  --ink: #171a1b;
  --text: #202426;
  --muted: #51585a;
  --soft: #747a7b;
  --paper: #f4f1ea;
  --surface: #fffdf8;
  --surface-cool: #edf5f4;
  --line: #c9c4b9;
  --copper: #a84d2b;
  --copper-dark: #75351f;
  --ion: #087887;
  --border: 1px solid var(--line);
}

body {
  background: var(--paper);
  color: var(--text);
}

::selection {
  background: #bfe4e6;
  color: var(--ink);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--ion);
  outline-offset: 3px;
}

.page-frame {
  min-height: 100dvh;
  overflow: visible;
  border: 0;
  background: var(--paper);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  grid-template-columns: auto minmax(260px, 420px);
  justify-content: space-between;
  min-height: 62px;
  gap: 30px;
  padding: 10px max(22px, calc((100vw - 1440px) / 2));
  border: 0;
  border-bottom: 1px solid var(--line);
  background: rgba(244, 241, 234, 0.96);
  box-shadow: 0 8px 24px rgba(23, 26, 27, 0.05);
}

.site-title {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  font-size: 1.45rem;
  font-weight: 700;
  line-height: 1;
}

.brand-mark {
  display: inline-grid;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  place-items: center;
}

.brand-mark i {
  display: block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #6deeff;
  box-shadow: 0 0 5px #57eaff, 0 0 12px rgba(67, 223, 241, 0.9), 0 0 22px rgba(67, 223, 241, 0.55);
}

.site-nav {
  display: none !important;
  min-width: 0;
  align-items: center;
  gap: 4px;
}

.site-search {
  grid-column: 2;
}

.site-nav a {
  position: relative;
  padding: 8px 10px;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1;
  white-space: nowrap;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
}

.site-nav a[aria-current="page"]::after {
  position: absolute;
  right: 10px;
  bottom: 2px;
  left: 10px;
  height: 2px;
  background: var(--copper);
  content: "";
}

.site-nav .site-tool-link {
  color: var(--soft);
  font-style: italic;
}

.site-search input {
  min-height: 38px;
  padding: 5px 12px 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--surface);
  color: var(--ink);
  font-size: 1rem;
}

.site-search input::placeholder {
  color: var(--soft);
}

.site-search input:focus {
  border-color: var(--ion);
}

.nav-toggle {
  display: none !important;
  min-height: 36px;
  padding: 4px 11px 5px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
}

.home-page {
  display: block;
  min-height: auto;
  padding: 0 24px 64px;
}

.home-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(390px, 0.9fr) minmax(0, 1.25fr);
  grid-template-rows: 440px;
  width: min(1440px, 100%);
  min-height: 0;
  margin: 24px auto 0;
  overflow: hidden;
  border-radius: 6px;
  background: #111718;
  color: #ffffff;
}

.hero-slides {
  position: relative;
  grid-column: 2;
  grid-row: 1;
  min-height: 0;
  border-left: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-slide {
  position: absolute;
  inset: 0;
  margin: 0;
}

.hero-slide {
  z-index: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  visibility: hidden;
  opacity: 0;
  transition: opacity 700ms ease, visibility 700ms ease;
}

.hero-slide.is-active {
  visibility: visible;
  opacity: 1;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: center;
  background: #050909;
}

.hero-slide figcaption {
  position: static;
  z-index: 1;
  display: flex;
  max-width: none;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding: 10px 16px 11px;
  border-radius: 0;
  background: #0d1314;
  color: #e8eeee;
  font-size: 0.82rem;
  line-height: 1.15;
}

.hero-slide figcaption span {
  color: #ffffff;
  font-weight: 700;
}

.hero-slide figcaption a {
  color: #aeeaf0;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.home-hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  grid-column: 1;
  grid-row: 1;
  width: 100%;
  flex-direction: column;
  justify-content: center;
  padding: 40px 44px;
  background: #151d20;
}

.carousel-controls {
  position: absolute;
  right: 18px;
  top: 18px;
  bottom: auto;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px;
  border-radius: 4px;
  background: rgba(12, 17, 18, 0.78);
}

.carousel-arrow,
.carousel-dots button {
  display: inline-grid;
  width: 30px;
  height: 30px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
}

.carousel-arrow:hover,
.carousel-dots button:hover,
.carousel-dots button.is-active {
  border-color: #6deeff;
  background: rgba(109, 238, 255, 0.18);
}

.carousel-dots {
  display: flex;
  gap: 6px;
}

.carousel-dots button {
  width: 8px;
  height: 8px;
  border: 0;
  background: rgba(255, 255, 255, 0.45);
}

.carousel-dots button.is-active {
  background: #6deeff;
  box-shadow: 0 0 8px rgba(109, 238, 255, 0.85);
}

.section-kicker {
  margin: 0 0 9px;
  color: var(--copper);
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.1;
  text-transform: uppercase;
}

.home-hero .section-kicker {
  color: #6fd5de;
}

.home-page .home-hero h1 {
  max-width: 560px;
  margin: 0;
  color: #ffffff;
  font-size: 3rem;
  font-weight: 400;
  line-height: 1.05;
}

.home-hero-copy {
  max-width: 530px;
  margin: 18px 0 0;
  color: #e4e8e7;
  font-size: 1.2rem;
  line-height: 1.35;
}

.home-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  margin: 28px 0 0;
}

.home-stats div {
  display: grid;
  grid-template-columns: auto auto;
  align-items: baseline;
  gap: 7px;
}

.home-stats dt {
  color: #ffffff;
  font-size: 1.45rem;
  font-weight: 700;
}

.home-stats dd {
  margin: 0;
  color: #c6cecd;
  font-size: 0.95rem;
}

.paper-feed {
  width: min(1440px, 100%);
  margin: 46px auto 0;
  scroll-margin-top: 86px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 15px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--ink);
}

.section-heading h2 {
  margin: 0;
  color: var(--ink);
  font-size: 2.65rem;
  font-weight: 400;
  line-height: 1;
}

.paper-status {
  margin: 0 0 2px;
  color: var(--soft);
  font-size: 1rem;
}

.home-page .paper-window {
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: visible;
  border: 0;
}

.home-page .paper-scroll {
  height: auto;
  gap: 0;
  overflow: visible;
  padding: 0;
}

.home-page .paper-row {
  position: relative;
  grid-template-columns: minmax(0, 1fr) minmax(250px, 32%);
  gap: 34px;
  min-height: 0;
  padding: 22px 16px 23px;
  border: 0;
  border-bottom: 1px solid var(--line);
  box-shadow: inset 3px 0 transparent;
  transition: background-color 140ms ease, box-shadow 140ms ease;
}

.home-page .paper-row:hover {
  background: var(--surface);
  box-shadow: inset 3px 0 var(--copper);
}

.paper-main h2 {
  margin-bottom: 7px;
  color: var(--ink);
  font-size: 1.48rem;
  line-height: 1.12;
}

.paper-main h2 a:hover {
  color: var(--copper-dark);
}

.paper-authors {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.28;
}

.paper-authors a {
  color: inherit;
  text-decoration-color: #a8adae;
}

.paper-authors a:hover {
  background: transparent;
  color: var(--ion);
  text-decoration-color: var(--ion);
}

.paper-abstract {
  margin-top: 7px;
}

.paper-abstract summary {
  color: var(--soft);
  font-size: 0.95rem;
}

.paper-abstract p {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.45;
}

.paper-meta {
  align-content: start;
  padding-top: 2px;
}

.paper-meta time {
  color: var(--soft);
  font-size: 0.9rem;
}

.paper-links {
  gap: 6px;
}

.paper-chip,
.filter-chip {
  min-height: 26px;
  padding: 3px 8px 4px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.9rem;
}

.paper-chip:first-child {
  border-color: #b7806a;
  color: var(--copper-dark);
}

.paper-chip:hover,
.filter-chip:hover,
.title-action:hover {
  border-color: var(--ion);
  background: var(--surface-cool);
  color: #075d68;
}

.paper-pagination {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) 110px;
  align-items: center;
  gap: 18px;
  padding-top: 20px;
  color: var(--soft);
  text-align: center;
}

.pagination-button,
.title-action {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
}

.pagination-button:disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.simple-page {
  width: min(1490px, 100%);
  margin: 0 auto;
  padding: 42px 24px 32px;
}

.simple-page h1 {
  color: var(--ink);
  font-size: 3.25rem;
}

.simple-page .paper-window,
.empty-panel,
.filter-panel,
.group-profile,
.group-section,
.admin-toolbar,
.admin-editor,
.admin-modal-panel {
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--surface);
}

.simple-page .paper-row,
.simple-page .group-row,
.simple-page .person-row,
.admin-paper-row {
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fffefb;
}

.group-main h2 a:hover,
.person-row:hover {
  color: var(--copper-dark);
}

.admin-check-section,
.admin-metadata-editor,
.admin-section-search,
.admin-field input,
.admin-field select,
.admin-field textarea,
.admin-url-form input,
.admin-toolbar select {
  border-color: var(--line);
  border-radius: 3px;
  background: #fffefb;
}

@media (max-width: 1160px) {
  .site-header {
    gap: 14px;
  }

  .site-nav a {
    padding-right: 6px;
    padding-left: 6px;
    font-size: 0.94rem;
  }
}

@media (max-width: 980px) {
  .site-header {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px 16px;
    padding: 10px 16px 12px;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .site-nav {
    grid-column: 1 / -1;
    flex-wrap: wrap;
    gap: 3px;
    padding: 10px 0 1px;
    border-top: 1px solid var(--line);
  }

  .site-shell-ready .site-nav:not(.is-open) {
    display: none;
  }

  .site-search {
    grid-column: 1 / -1;
  }

  .home-hero-content {
    width: 100%;
    padding: 32px;
  }

  .home-page .home-hero h1 {
    font-size: 2.75rem;
  }
}

@media (max-width: 700px) {
  .site-title {
    gap: 8px;
    font-size: 1.2rem;
  }

  .brand-mark {
    width: 18px;
    height: 18px;
  }

  .site-nav a {
    padding: 7px 8px;
    font-size: 1rem;
  }

  .home-page {
    padding: 0 14px 42px;
  }

  .home-hero {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: 260px auto;
    min-height: 0;
    margin-top: 14px;
  }

  .hero-slides {
    grid-column: 1;
    grid-row: 1;
    right: auto;
    bottom: auto;
    height: auto;
    border-left: 0;
  }

  .hero-slide img {
    object-position: center;
  }

  .hero-slide figcaption {
    max-width: none;
    align-items: start;
    flex-direction: column;
    gap: 2px;
    padding: 7px 10px 8px;
    font-size: 0.76rem;
  }

  .carousel-controls {
    top: 10px;
    right: 10px;
    bottom: auto;
  }

  .home-hero-content {
    grid-column: 1;
    grid-row: 2;
    width: 100%;
    min-height: 0;
    justify-content: center;
    margin-top: 0;
    padding: 28px 24px;
    background: #151d20;
  }

  .home-page .home-hero h1 {
    max-width: 430px;
    font-size: 2.65rem;
  }

  .home-hero-copy {
    max-width: 440px;
    margin-top: 12px;
    font-size: 1.05rem;
  }

  .home-stats {
    gap: 14px 22px;
    margin-top: 18px;
  }

  .home-stats dt {
    font-size: 1.22rem;
  }

  .home-stats dd {
    font-size: 0.86rem;
  }

  .paper-feed {
    margin-top: 34px;
  }

  .section-heading {
    align-items: start;
    flex-direction: column;
    gap: 10px;
  }

  .section-heading h2 {
    font-size: 2.25rem;
  }

  .home-page .paper-row {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 19px 11px 20px;
  }

  .paper-main h2 {
    font-size: 1.3rem;
  }

  .paper-meta {
    gap: 8px;
  }

  .paper-pagination {
    grid-template-columns: 88px minmax(0, 1fr) 88px;
    gap: 9px;
    font-size: 0.9rem;
  }

  .pagination-button {
    min-height: 36px;
  }

  .simple-page {
    padding: 30px 14px 24px;
  }

  .simple-page h1 {
    font-size: 2.6rem;
  }
}

@media (max-width: 420px) {
  .site-header {
    padding-right: 11px;
    padding-left: 11px;
  }

  .site-title-label {
    font-size: 1.08rem;
  }

  .brand-mark {
    width: 18px;
  }

  .nav-toggle {
    min-height: 34px;
    padding-right: 9px;
    padding-left: 9px;
    font-size: 0.92rem;
  }

  .home-page .home-hero h1 {
    font-size: 2.25rem;
  }

  .home-hero-content {
    padding: 24px 18px;
  }

  .home-stats div {
    grid-template-columns: auto;
    gap: 0;
  }

  .paper-pagination {
    grid-template-columns: 1fr 1fr;
  }

  .paper-pagination span {
    grid-column: 1 / -1;
    grid-row: 1;
  }
}

.admin-metadata-editor {
  margin: 10px 0;
  padding: 10px;
  border: 1px solid var(--ink);
}

.admin-metadata-editor summary {
  cursor: pointer;
  color: var(--ink);
  font-size: clamp(1rem, 1.18vw, 1.1rem);
  line-height: 1.1;
}

.admin-metadata-editor .admin-field {
  margin-top: 9px;
}

.admin-metadata-editor textarea {
  min-height: 92px;
}
