:root {
  color-scheme: light;
  --paper: #f6f5ef;
  --card: #fffefa;
  --ink: #182a28;
  --muted: #52635d;
  --line: #d8ddd1;
  --forest: #132b2b;
  --gold: #e2d3a6;
  --serif: "Noto Serif SC", "Songti SC", "SimSun", Georgia, serif;
  --sans: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", system-ui, sans-serif;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 280px; }
h1, h2, h3, p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button, select { cursor: pointer; }
button:disabled { cursor: default; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #a86b22; outline-offset: 4px; }
section[id] { scroll-margin-top: 1.5rem; }
::selection { background: #eadbb1; color: var(--ink); }

.shell { width: min(100% - 4rem, 75rem); margin-inline: auto; }
.sr-only, .skip-link:not(:focus) {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link:focus {
  position: absolute;
  z-index: 3;
  top: .5rem;
  left: .5rem;
  padding: .8rem 1rem;
  background: var(--card);
}

.site-header { background: var(--paper); }
.header-inner {
  min-height: 4.55rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: .72rem;
  font-weight: 800;
  letter-spacing: .065em;
  white-space: nowrap;
}
.brand-mark {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  width: 2.2rem;
  height: 2.2rem;
  padding-left: .55rem;
  border-radius: 4px;
  background: var(--forest);
}
.brand-mark i { display: block; height: 2px; width: 1.08rem; background: var(--gold); }
.brand-mark i:last-child { width: .66rem; }
.site-header nav { display: flex; align-items: center; gap: clamp(.6rem, 3vw, 2.2rem); }
.site-header nav a { padding-block: .6rem; font-size: .9rem; white-space: nowrap; }
.site-header nav a:hover { text-decoration: underline; text-underline-offset: .28em; }
.site-header .header-contact {
  border: 1px solid #9da99d;
  padding-inline: 1.1rem;
  border-radius: 4px;
  font-weight: 700;
}

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: #f8f6ec;
  background: var(--forest);
}
.hero-art {
  position: absolute;
  z-index: -1;
  inset: 0 0 0 27%;
  pointer-events: none;
}
.hero-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 57% 54%;
}
.hero-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, var(--forest), #132b2bd1 14%, #132b2b36 48%, transparent 67%),
    linear-gradient(0deg, #0a1a1a55, transparent 44%);
}
.hero-inner {
  min-height: 31rem;
  padding-block: clamp(3.6rem, 6vw, 6.5rem) 3.2rem;
}
.hero h1 {
  font-family: var(--serif);
  font-size: clamp(2.8rem, 5.35vw, 5.2rem);
  line-height: 1.13;
  letter-spacing: .035em;
  font-weight: 800;
}
.hero h1 span { display: block; color: var(--gold); margin-top: .18em; }
.hero-description {
  max-width: 26rem;
  margin-top: 1.35rem;
  color: #e0e8df;
  font-size: clamp(1rem, 1.36vw, 1.14rem);
  line-height: 1.85;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.7rem; }
.button, .contact-action, .pagination button {
  min-height: 2.85rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 4px;
  padding: .65rem 1.05rem;
  font-weight: 700;
}
.button-primary { background: var(--gold); color: #20251c; }
.button-primary:hover { background: #efe3bd; }
.button-outline { border-color: #aebeb2; color: #f8f6ec; }
.button-outline:hover { background: #ffffff1c; }
.hero-count {
  width: fit-content;
  margin-top: 1.8rem;
  padding-top: .65rem;
  border-top: 1px solid #b8cbb65c;
  color: #dfe6d8;
  font-size: .9rem;
}
.hero-count strong { color: var(--gold); font-size: 1.15rem; font-variant-numeric: tabular-nums; }

.catalog { padding-block: 3.65rem 4.6rem; }
.hero-count a {
  display: inline-block;
  margin-left: .65rem;
  padding-left: .65rem;
  border-left: 1px solid #b8cbb65c;
}
.hero-count a:hover { text-decoration: underline; text-underline-offset: .2em; }
.series-switch { display: flex; gap: .45rem; margin-bottom: 1.35rem; flex-wrap: wrap; }
.series-switch button {
  min-height: 2.75rem;
  padding: .55rem 1rem;
  border: 1px solid #9db1a4;
  border-radius: 5px;
  background: var(--card);
  color: #263e36;
  font-weight: 700;
}
.series-switch button:hover { background: #e6ede2; }
.series-switch button[aria-pressed="true"] { border-color: var(--forest); background: var(--forest); color: #f9f5e9; }
#reports { scroll-margin-block: 1.25rem; }
.filters[data-series="reports"] { grid-template-columns: minmax(0, 1fr); }
.results-table[data-series="reports"] thead th:first-child { width: 68%; }
.section-heading { margin-bottom: 1.55rem; }
.section-heading h2, .contact h2 {
  font-family: var(--serif);
  font-size: clamp(2rem, 3.3vw, 2.9rem);
  letter-spacing: .035em;
  line-height: 1.2;
}
.section-heading p { margin-top: .55rem; color: var(--muted); line-height: 1.65; }
.filters {
  display: grid;
  grid-template-columns: minmax(16rem, 2fr) repeat(2, minmax(9rem, 1fr));
  gap: .85rem;
  padding: 1.15rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #edf0e8;
}
.field { min-width: 0; }
.field label { display: block; margin-bottom: .38rem; color: #364b43; font-weight: 700; font-size: .875rem; }
.field input, .field select {
  width: 100%;
  min-width: 0;
  height: 2.9rem;
  border: 1px solid #aebbb0;
  border-radius: 4px;
  background-color: var(--card);
  color: var(--ink);
}
.field input { padding: .55rem .85rem .55rem 2.5rem; }
.field input::placeholder { color: #607168; opacity: 1; }
.field select {
  appearance: none;
  padding: .55rem 2.15rem .55rem .8rem;
  background-image: linear-gradient(45deg, transparent 50%, #45574f 50%), linear-gradient(135deg, #45574f 50%, transparent 50%);
  background-size: 5px 5px;
  background-position: calc(100% - 16px) 51%, calc(100% - 11px) 51%;
  background-repeat: no-repeat;
}
.search-field { position: relative; }
.search-icon {
  position: absolute;
  z-index: 1;
  pointer-events: none;
  left: .95rem;
  top: .93rem;
  width: .8rem;
  height: .8rem;
  border: 1.6px solid #567164;
  border-radius: 50%;
}
.search-icon::after {
  content: "";
  position: absolute;
  top: .63rem;
  left: .57rem;
  width: .32rem;
  height: 1.6px;
  background: #567164;
  transform: rotate(45deg);
  transform-origin: left;
}
.results-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  min-height: 3.5rem;
  padding-inline: .1rem;
}
.results-toolbar p { color: #3e5148; font-weight: 700; font-size: .9rem; scroll-margin-top: 1.15rem; }
.text-button {
  padding: .43rem .2rem;
  border: 0;
  background: transparent;
  color: #244e45;
  text-decoration: underline;
  text-underline-offset: .2em;
  font-size: .9rem;
}
.table-frame { border: 1px solid var(--line); border-radius: 6px; overflow: clip; }
.results-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  text-align: left;
  background: var(--card);
}
.results-table thead { background: #dfe6dc; color: #2a423a; font-size: .875rem; }
.results-table thead th:first-child { width: 42%; }
.results-table thead th:nth-child(2) { width: 16%; }
.results-table thead th:nth-child(3) { width: 15%; }
.results-table thead th:nth-child(4) { width: 17%; }
.results-table thead th:last-child { width: 10%; }
.results-table th, .results-table td { padding: .82rem .95rem; overflow-wrap: anywhere; }
.results-table tbody tr + tr { border-top: 1px solid #e5e8df; }
.results-table tbody tr:nth-child(even) { background: #f9faf5; }
.results-table tbody tr:hover { background: #edf1e8; }
.results-table tbody th { font-weight: 700; line-height: 1.45; }
.results-table tbody td { color: #465952; font-size: .89rem; line-height: 1.5; }
.entry-title, .entry-id { display: block; }
.entry-title {
  padding: 0;
  border: 0;
  background: transparent;
  color: #234f43;
  font-weight: inherit;
  line-height: inherit;
  text-align: left;
  text-decoration: underline;
  text-underline-offset: .2em;
  overflow-wrap: anywhere;
  max-width: 100%;
}
.entry-title:hover { color: #0f342a; }
.entry-details {
  width: min(calc(100% - 2rem), 48rem);
  max-height: calc(100dvh - 2rem);
  padding: clamp(1rem, 4vw, 1.55rem);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--card);
  color: var(--ink);
  overflow: auto;
}
.entry-details::backdrop { background: #112b2b99; }
.detail-heading {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: .85rem;
  padding-bottom: .6rem;
  background: var(--card);
}
.detail-heading form { flex: none; }
.entry-details h2 {
  font-family: var(--serif);
  font-size: clamp(1.35rem, 4vw, 1.75rem);
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.detail-fields { margin-block: 1rem; }
.detail-fields div {
  display: grid;
  grid-template-columns: minmax(5.5rem, .65fr) minmax(0, 2fr);
  gap: .65rem;
  padding: .5rem 0;
  border-bottom: 1px solid var(--line);
}
.detail-fields dt { color: var(--muted); font-size: .88rem; }
.detail-fields dd { margin: 0; overflow-wrap: anywhere; }
.detail-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .6rem; }
.detail-close { background: var(--card); border-color: var(--line); color: var(--ink); }
.detail-close:hover { background: #edf0e8; }
.detail-status { margin-top: 1rem; color: var(--muted); font-size: .92rem; }
.detail-body { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.detail-body h3 { margin-bottom: .55rem; font-size: 1.1rem; }
.detail-text { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.85; }
.entry-id { margin-top: .25rem; color: #596a60; font-size: .78rem; font-weight: 400; }
.entry-date, .pages-column { font-variant-numeric: tabular-nums; }
.pages-column { text-align: right; }
.empty {
  padding: 2rem 1.25rem;
  border: 1px dashed #afbcad;
  border-radius: 6px;
  background: var(--card);
  color: var(--muted);
}
.pagination { display: flex; align-items: center; justify-content: center; gap: .7rem; margin-top: 1.3rem; }
.pagination button { min-width: 5.2rem; border-color: #aab7aa; color: #263e36; background: var(--card); }
.pagination button:hover:not(:disabled) { background: #e6ede2; }
.pagination button:disabled { color: #66736a; border-color: #d4dacf; background: #edeee7; }
.pagination span { min-width: 7rem; text-align: center; font-size: .93rem; font-variant-numeric: tabular-nums; }

.contact { background: var(--forest); color: #f8f6ec; }
.contact-inner { padding-block: 3.2rem; }
.contact-text p { margin-top: .6rem; color: #d1ded4; line-height: 1.7; }
.contact-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .9rem; margin-top: 1.65rem; }
.contact-method { padding: 1.2rem; background: #1d3837; border: 1px solid #50675e; border-radius: 6px; }
.contact-method h3 { color: #d7e3d9; font-size: .92rem; }
.contact-method p {
  margin-block: .42rem .85rem;
  font-size: clamp(1.05rem, 1.9vw, 1.35rem);
  letter-spacing: .015em;
  font-weight: 700;
  overflow-wrap: anywhere;
  user-select: text;
}
.contact-action { background: var(--gold); color: #20251c; font-size: .9rem; }
.contact-action:hover { background: #efe3bd; }
footer { color: #50625a; font-size: .88rem; }
.footer-inner { min-height: 4.8rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.footer-inner a:hover { text-decoration: underline; text-underline-offset: .2em; }

@media (max-width: 52rem) {
  .hero-art { inset-inline-start: 18%; }
  .hero-art::after {
    background: linear-gradient(90deg, var(--forest), #132b2baa 31%, #132b2b1f 80%);
  }
  .filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .filters .field:first-child { grid-column: 1 / -1; }
  .results-table th, .results-table td { padding-inline: .72rem; }
}

@media (max-width: 39rem) {
  .shell { width: calc(100% - 2rem); }
  .header-inner { min-height: 4rem; gap: .5rem; }
  .brand { letter-spacing: .02em; gap: .42rem; font-size: .88rem; }
  .brand-mark { width: 1.84rem; height: 1.84rem; padding-left: .42rem; }
  .brand-mark i { width: .94rem; }
  .brand-mark i:last-child { width: .60rem; }
  .site-header nav { gap: .58rem; }
  .site-header nav a { font-size: .79rem; }
  .site-header .header-contact { padding-inline: .52rem; }
  .hero-art { inset-inline-start: 0; }
  .hero-art img { object-position: 66% 50%; }
  .hero-art::after {
    background: linear-gradient(90deg, #102725ed, #132b2b97 59%, #132b2b40),
      linear-gradient(0deg, #102725c4, transparent 72%);
  }
  .hero-inner { min-height: 28rem; padding-block: 3.65rem 2.15rem; }
  .hero h1 { font-size: clamp(2.15rem, 9.2vw, 3.65rem); }
  .hero-description { max-width: 23rem; }
  .hero-actions { gap: .55rem; }
  .button { padding-inline: .8rem; font-size: .92rem; }
  .catalog { padding-block: 2.65rem 3rem; }
  .filters { padding: .85rem; gap: .65rem; }
  .table-frame { border: none; overflow: visible; }
  .results-table, .results-table tbody { display: block; background: transparent; }
  .results-table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .results-table tbody { display: grid; gap: .6rem; }
  .results-table tbody tr, .results-table tbody tr:nth-child(even) {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .4rem .65rem;
    padding: .8rem .9rem;
    border: 1px solid var(--line);
    border-radius: 5px;
    background: var(--card);
  }
  .results-table tbody th { grid-column: 1 / -1; padding: 0 0 .25rem; }
  .results-table tbody td { padding: 0; text-align: left; }
  .results-table td[data-label]::before {
    content: attr(data-label) "　";
    color: #52665d;
    font-size: .77rem;
  }
  .contact-inner { padding-block: 2.4rem; }
  .contact-grid { grid-template-columns: 1fr; margin-top: 1rem; gap: .55rem; }
  .contact-method { padding: .85rem 1rem; }
  .contact-method p { margin-bottom: .65rem; }
  .footer-inner { min-height: 4rem; gap: .55rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
