:root {
  --bg: #f6f8fb;
  --paper: #ffffff;
  --paper-2: #f0f5ff;
  --ink: #111827;
  --muted: #5b677a;
  --soft: #7b8798;
  --line: #dbe4ef;
  --line-strong: #b8c6d8;
  --blue: #2563eb;
  --cyan: #0891b2;
  --green: #16a34a;
  --pink: #e11d48;
  --yellow: #f59e0b;
  --shadow: 0 18px 38px rgba(15, 23, 42, 0.08);
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --wrap: min(1220px, calc(100vw - 32px));
}

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

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", Arial, sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

img {
  max-width: 100%;
}

.site-shell {
  padding: 20px 0 44px;
}

.site-wrap {
  width: var(--wrap);
  margin: 0 auto;
}

.registry-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.02rem;
  font-weight: 800;
}

.site-brand::before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 16px 0 0 var(--pink), 32px 0 0 var(--yellow);
}

.top-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.top-links a {
  padding: 8px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #f9fbff;
  color: #1f3b63;
  font-size: 0.9rem;
  font-weight: 700;
}

.registry-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 18px;
  align-items: start;
}

.registry-main,
.registry-rail {
  min-width: 0;
}

.registry-rail {
  position: sticky;
  top: 18px;
  display: grid;
  gap: 14px;
}

.result-head,
.panel,
.side-card,
.registry-footer {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow);
}

.result-head {
  padding: 24px;
  border-top: 5px solid var(--blue);
}

.result-head.compact {
  padding: 22px;
}

.query-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 0.92rem;
}

.query-strip span {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: var(--radius-sm);
  background: #eaf1ff;
  color: var(--blue);
  font-weight: 800;
}

.query-strip strong {
  color: var(--ink);
  font-weight: 800;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.result-head h1 {
  margin-bottom: 12px;
  font-size: clamp(1.75rem, 3.2vw, 3rem);
  line-height: 1.2;
  letter-spacing: 0;
}

.lead {
  max-width: 72ch;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 1rem;
}

.key-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.key-facts div {
  min-height: 86px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}

.key-facts span,
.summary-list dt {
  display: block;
  color: var(--soft);
  font-size: 0.82rem;
  font-weight: 700;
}

.key-facts strong {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-size: 1.03rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.panel,
.side-card,
.registry-footer {
  margin-top: 14px;
  padding: 18px;
}

.registry-rail .side-card {
  margin-top: 0;
}

.panel-title {
  display: flex;
  gap: 12px;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}

.panel-title h2,
.side-card h2 {
  margin-bottom: 0;
  font-size: 1.2rem;
}

.panel-title p {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.registry-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 0.94rem;
}

.registry-table th,
.registry-table td {
  padding: 12px;
  border: 1px solid var(--line);
  vertical-align: top;
  overflow-wrap: anywhere;
}

.registry-table th {
  width: 150px;
  background: #f4f7fb;
  color: #34445a;
  font-weight: 800;
}

.registry-table td {
  background: #fff;
  color: #1f2937;
}

.registry-table a {
  color: var(--blue);
  font-weight: 700;
}

.scope-text {
  margin-bottom: 0;
  padding: 14px 16px;
  border: 1px solid #fde68a;
  border-radius: var(--radius-md);
  background: #fffbeb;
  color: #573b00;
}

.result-list {
  display: grid;
  gap: 10px;
}

.result-item a {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #fbfdff;
}

.result-item a:hover,
.top-links a:hover,
.friend-links a:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.result-item strong {
  font-size: 1rem;
}

.result-item span {
  color: var(--muted);
  font-size: 0.92rem;
}

.side-card {
  border-top: 4px solid var(--cyan);
}

.contact-card {
  border-top-color: var(--green);
}

.side-card p {
  margin: 9px 0 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.summary-list {
  display: grid;
  gap: 10px;
  margin: 0;
}

.summary-list div {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.summary-list div:last-child {
  border-bottom: 0;
}

.summary-list dd {
  margin: 4px 0 0;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.breadcrumbs {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.9rem;
}

.breadcrumbs a {
  color: var(--blue);
  font-weight: 700;
}

.related-list ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.related-list a {
  display: block;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #f9fbff;
  color: #1f3b63;
  font-weight: 700;
}

.tag {
  display: inline-flex;
  margin: 0 6px 6px 0;
  padding: 5px 9px;
  border-radius: var(--radius-sm);
  background: #ecfeff;
  color: #0e7490;
  font-size: 0.82rem;
  font-weight: 700;
}

.prose {
  display: grid;
  gap: 12px;
  color: var(--muted);
}

.registry-footer {
  margin-top: 18px;
  color: var(--muted);
}

.registry-footer strong {
  display: block;
  margin-bottom: 10px;
  color: var(--ink);
}

.friend-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.friend-links a {
  display: inline-flex;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #fff;
  color: #334155;
  font-size: 0.9rem;
  font-weight: 700;
}

.registry-footer p {
  margin: 14px 0 0;
  font-size: 0.88rem;
}

@media (max-width: 1080px) {
  .registry-layout {
    grid-template-columns: 1fr;
  }

  .registry-rail {
    position: static;
  }
}

@media (max-width: 760px) {
  .site-shell {
    padding-top: 12px;
  }

  .site-wrap {
    width: calc(100vw - 22px);
  }

  .registry-topbar,
  .panel-title {
    align-items: flex-start;
    flex-direction: column;
  }

  .top-links {
    justify-content: flex-start;
  }

  .result-head,
  .panel,
  .side-card,
  .registry-footer {
    border-radius: 14px;
    padding: 15px;
  }

  .key-facts,
  .related-list ul {
    grid-template-columns: 1fr;
  }

  .registry-table,
  .registry-table tbody,
  .registry-table tr,
  .registry-table th,
  .registry-table td {
    display: block;
    width: 100%;
  }

  .registry-table tr {
    border: 1px solid var(--line);
    border-bottom: 0;
  }

  .registry-table tr:last-child {
    border-bottom: 1px solid var(--line);
  }

  .registry-table th,
  .registry-table td {
    border-width: 0 0 1px;
  }
}
