:root {
  --bg: #090a0a;
  --bg-soft: #0e100f;
  --panel: #141614;
  --panel-raised: #1a1d1a;
  --paper: #f4ecdf;
  --text: #ddd4c6;
  --muted: #98958e;
  --line: rgba(222, 207, 181, 0.16);
  --line-strong: rgba(222, 207, 181, 0.3);
  --gold: #d2a95f;
  --gold-light: #f0d597;
  --gold-dark: #8e672b;
  --mint: #78b99f;
  --coral: #d78668;
  --blue: #7d9fc4;
  --violet: #9e8ab7;
  --danger: #d17b6f;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.44);
  --shell: min(1280px, calc(100vw - 64px));
  font-family: "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  letter-spacing: 0;
}

body::before {
  position: fixed;
  z-index: -1;
  inset: 0;
  content: "";
  opacity: 0.26;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 72px 72px;
  pointer-events: none;
}

button,
input,
select {
  font: inherit;
}

button,
select {
  cursor: pointer;
}

button,
input,
select,
a {
  -webkit-tap-highlight-color: transparent;
}

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

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

img {
  display: block;
  max-width: 100%;
}

.site-header {
  position: sticky;
  z-index: 30;
  top: 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  min-height: 72px;
  padding: 10px max(32px, calc((100vw - 1280px) / 2));
  border-bottom: 1px solid var(--line);
  background: rgba(9, 10, 10, 0.92);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-width: 0;
  gap: 11px;
}

.brand img {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  object-fit: cover;
}

.brand-copy {
  display: grid;
  min-width: 0;
  line-height: 1.3;
}

.brand-copy strong {
  overflow: hidden;
  color: var(--paper);
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand-copy small {
  color: var(--muted);
  font-size: 11px;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
}

.top-nav a {
  color: var(--muted);
  transition: color 160ms ease;
}

.top-nav a:hover {
  color: var(--paper);
}

.saved-entry {
  display: inline-flex;
  justify-self: end;
  align-items: center;
  min-height: 40px;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: var(--text);
  background: var(--panel);
}

.saved-entry > span:first-child {
  color: var(--gold-light);
  font-size: 20px;
  line-height: 1;
}

.saved-entry strong {
  display: inline-grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 50%;
  color: #171207;
  background: var(--gold);
  font-size: 11px;
}

.saved-entry.active {
  border-color: var(--gold);
  color: var(--paper);
  background: #211a0f;
}

.intro-band {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.65fr);
  grid-template-areas:
    "copy stats"
    "search search";
  gap: 36px 64px;
  width: var(--shell);
  min-height: 390px;
  align-content: center;
  margin: 0 auto;
  padding: 64px 0 48px;
  border-bottom: 1px solid var(--line);
}

.intro-copy {
  grid-area: copy;
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.4;
  text-transform: uppercase;
}

.intro-copy h1,
.section-heading h2,
.library-heading h2 {
  margin: 0;
  color: var(--paper);
  letter-spacing: 0;
}

.intro-copy h1 {
  max-width: 760px;
  font-size: 70px;
  line-height: 1.04;
}

.intro-lead {
  margin: 22px 0 7px;
  color: var(--gold-light);
  font-size: 23px;
  font-weight: 700;
}

.intro-text {
  max-width: 650px;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.intro-stats {
  display: grid;
  grid-area: stats;
  grid-template-columns: repeat(3, 1fr);
  align-self: end;
  margin: 0 0 8px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.intro-stats div {
  padding: 22px 14px;
  border-left: 1px solid var(--line);
}

.intro-stats div:first-child {
  border-left: 0;
}

.intro-stats dt {
  color: var(--paper);
  font-size: 30px;
  font-weight: 800;
  line-height: 1;
}

.intro-stats dd {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}

.search-box {
  display: grid;
  grid-area: search;
  grid-template-columns: 118px minmax(0, 1fr) auto;
  align-items: center;
  min-height: 78px;
  padding: 12px 18px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--panel);
}

.search-box > label {
  color: var(--paper);
  font-size: 13px;
  font-weight: 700;
}

.search-control {
  position: relative;
  min-width: 0;
}

.search-control input {
  width: 100%;
  height: 48px;
  padding: 0 48px 0 16px;
  border: 0;
  border-left: 1px solid var(--line);
  border-radius: 0;
  color: var(--paper);
  outline: 0;
  background: transparent;
  font-size: 16px;
}

.search-control input::placeholder {
  color: #77766f;
}

.clear-search {
  position: absolute;
  top: 50%;
  right: 10px;
  display: grid;
  width: 32px;
  height: 32px;
  padding: 0;
  transform: translateY(-50%);
  place-items: center;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: 22px;
}

.clear-search[hidden] {
  display: none;
}

.search-box > span {
  padding-left: 24px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.route-band,
.library {
  width: var(--shell);
  margin: 0 auto;
}

.route-band {
  padding: 60px 0 66px;
  border-bottom: 1px solid var(--line);
}

.section-heading,
.library-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.section-heading h2,
.library-heading h2 {
  font-size: 30px;
  line-height: 1.2;
}

.section-heading > p,
.result-summary {
  max-width: 460px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  text-align: right;
}

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

.route-grid,
.domain-tabs {
  scrollbar-width: none;
}

.route-grid::-webkit-scrollbar,
.domain-tabs::-webkit-scrollbar {
  display: none;
}

.route-card {
  position: relative;
  display: grid;
  min-height: 186px;
  align-content: space-between;
  gap: 20px;
  padding: 20px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  text-align: left;
  background: var(--panel);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.route-card:hover {
  transform: translateY(-3px);
  border-color: var(--route-color, var(--gold));
  background: var(--panel-raised);
}

.route-card::after {
  position: absolute;
  right: -24px;
  bottom: -31px;
  width: 92px;
  height: 92px;
  border: 1px solid var(--route-color, var(--gold));
  border-radius: 50%;
  content: "";
  opacity: 0.35;
}

.route-index {
  color: var(--route-color, var(--gold));
  font-size: 11px;
  font-weight: 800;
}

.route-card strong {
  display: block;
  margin-bottom: 8px;
  color: var(--paper);
  font-size: 17px;
}

.route-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.route-tools {
  display: flex;
  gap: 6px;
}

.route-tools span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--text);
  background: var(--bg-soft);
  font-size: 10px;
  font-weight: 800;
}

.library {
  padding: 62px 0 84px;
}

.result-summary strong {
  color: var(--paper);
}

.filter-workbench {
  position: sticky;
  z-index: 20;
  top: 84px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px 26px;
  margin-bottom: 28px;
  padding: 15px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: rgba(20, 22, 20, 0.94);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(18px);
}

.filter-row {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 10px;
}

.filter-label {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.segmented,
.domain-tabs {
  display: flex;
  min-width: 0;
  gap: 4px;
}

.segmented {
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--bg-soft);
}

.segmented button,
.domain-tabs button {
  min-height: 32px;
  padding: 0 11px;
  border: 0;
  border-radius: 4px;
  color: var(--muted);
  white-space: nowrap;
  background: transparent;
  font-size: 12px;
}

.segmented button:hover,
.domain-tabs button:hover {
  color: var(--paper);
}

.segmented button.active {
  color: #171207;
  background: var(--gold);
  font-weight: 800;
}

.domain-tabs button.active {
  color: var(--paper);
  background: #292820;
}

.select-row {
  justify-content: flex-end;
}

.select-row label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 11px;
}

.select-row select {
  height: 34px;
  padding: 0 28px 0 9px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--text);
  background: var(--bg-soft);
  font-size: 12px;
}

.reset-button {
  height: 34px;
  padding: 0 10px;
  border: 0;
  color: var(--gold-light);
  background: transparent;
  font-size: 12px;
}

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

.tool-card {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 258px;
  grid-template-rows: auto 1fr auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.tool-card:hover {
  transform: translateY(-3px);
  border-color: var(--domain-color, var(--gold));
  background: var(--panel-raised);
}

.card-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  padding: 17px 17px 0;
}

.tool-mark,
.detail-mark {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--domain-color, var(--gold)) 65%, transparent);
  border-radius: 7px;
  color: var(--domain-color, var(--gold));
  background: color-mix(in srgb, var(--domain-color, var(--gold)) 11%, var(--bg));
  font-weight: 900;
}

.tool-mark {
  width: 42px;
  height: 42px;
  font-size: 13px;
}

.save-button {
  display: grid;
  width: 34px;
  height: 34px;
  padding: 0;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--muted);
  background: var(--bg-soft);
  font-size: 19px;
  line-height: 1;
}

.save-button:hover,
.save-button.active {
  border-color: var(--gold-dark);
  color: var(--gold-light);
}

.card-open {
  display: block;
  width: 100%;
  min-width: 0;
  padding: 15px 17px 10px;
  border: 0;
  color: inherit;
  text-align: left;
  background: transparent;
}

.card-open h3 {
  max-width: 100%;
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--paper);
  font-size: 18px;
  line-height: 1.32;
}

.card-open p {
  display: -webkit-box;
  min-height: 44px;
  margin: 9px 0 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 17px;
  padding: 12px 0 15px;
  border-top: 1px solid var(--line);
}

.card-tags {
  display: flex;
  min-width: 0;
  gap: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: var(--bg-soft);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tag.domain {
  border-color: color-mix(in srgb, var(--domain-color, var(--gold)) 45%, transparent);
  color: var(--domain-color, var(--gold));
}

.card-arrow {
  flex: 0 0 auto;
  color: var(--gold-light);
  font-size: 15px;
}

.empty-state {
  min-height: 320px;
  padding: 70px 24px;
  border: 1px dashed var(--line-strong);
  text-align: center;
}

.empty-state strong {
  color: var(--paper);
  font-size: 20px;
}

.empty-state p {
  margin: 8px 0 20px;
  color: var(--muted);
}

.empty-state button,
.detail-primary,
.detail-secondary {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
}

.empty-state button,
.detail-primary {
  border: 1px solid var(--gold);
  color: #171207;
  background: var(--gold);
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  min-height: 140px;
  padding: 32px max(32px, calc((100vw - 1280px) / 2));
  border-top: 1px solid var(--line);
  background: var(--bg-soft);
  font-size: 12px;
}

.site-footer > div {
  display: grid;
}

.site-footer strong {
  color: var(--paper);
  font-size: 14px;
}

.site-footer span,
.site-footer p {
  color: var(--muted);
}

.site-footer a {
  justify-self: end;
  color: var(--gold-light);
}

.detail-dialog {
  width: min(700px, 100vw);
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0 0 0 auto;
  padding: 0;
  overflow: visible;
  border: 0;
  color: var(--text);
  background: var(--bg-soft);
  box-shadow: var(--shadow);
}

.detail-dialog[open] {
  animation: drawer-in 220ms ease-out both;
}

.detail-dialog::backdrop {
  background: rgba(0, 0, 0, 0.68);
  backdrop-filter: blur(4px);
}

.dialog-shell {
  position: relative;
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.dialog-close {
  position: sticky;
  z-index: 4;
  top: 16px;
  display: grid;
  width: 40px;
  height: 40px;
  margin: 16px 18px 0 auto;
  padding: 0;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: var(--paper);
  background: rgba(20, 22, 20, 0.94);
  font-size: 24px;
  line-height: 1;
  backdrop-filter: blur(10px);
}

.detail-content {
  padding: 8px 42px 64px;
}

.detail-head {
  padding: 22px 0 28px;
  border-bottom: 1px solid var(--line);
}

.detail-identity {
  display: flex;
  align-items: center;
  gap: 17px;
}

.detail-mark {
  width: 64px;
  height: 64px;
  font-size: 17px;
}

.detail-identity h2 {
  max-width: 480px;
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--paper);
  font-size: 42px;
  line-height: 1.12;
}

.detail-kicker {
  margin: 0 0 5px;
  color: var(--domain-color, var(--gold));
  font-size: 11px;
  font-weight: 800;
}

.detail-tagline {
  margin: 20px 0 0;
  color: var(--gold-light);
  font-size: 17px;
  font-weight: 600;
}

.detail-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 22px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.detail-meta div {
  min-width: 0;
  padding: 14px 12px;
  border-left: 1px solid var(--line);
}

.detail-meta div:first-child {
  border-left: 0;
}

.detail-meta span,
.detail-meta strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-meta span {
  color: var(--muted);
  font-size: 10px;
}

.detail-meta strong {
  margin-top: 5px;
  color: var(--paper);
  font-size: 12px;
}

.detail-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.detail-secondary {
  border: 1px solid var(--line-strong);
  color: var(--text);
  background: var(--panel);
}

.detail-secondary.active {
  border-color: var(--gold-dark);
  color: var(--gold-light);
}

.detail-section {
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}

.detail-section h3 {
  margin: 0 0 16px;
  color: var(--paper);
  font-size: 18px;
}

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

.detail-list li {
  position: relative;
  min-height: 58px;
  padding: 11px 12px 11px 28px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text);
  background: var(--panel);
  font-size: 13px;
}

.detail-list li::before {
  position: absolute;
  top: 18px;
  left: 13px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  content: "";
  background: var(--domain-color, var(--gold));
}

.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.pros-cons h4 {
  margin: 0 0 10px;
  font-size: 13px;
}

.pros-cons > div:first-child h4 {
  color: var(--mint);
}

.pros-cons > div:last-child h4 {
  color: var(--coral);
}

.pros-cons ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
}

.pros-cons li + li {
  margin-top: 7px;
}

.audience-copy {
  margin: 0;
  color: var(--text);
  font-size: 14px;
}

.not-for {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.related-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.related-button {
  display: flex;
  min-width: 0;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text);
  text-align: left;
  background: var(--panel);
}

.related-button strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.related-button span {
  flex: 0 0 auto;
  color: var(--gold-light);
}

.toast {
  position: fixed;
  z-index: 60;
  right: 24px;
  bottom: 24px;
  max-width: min(340px, calc(100vw - 48px));
  padding: 12px 16px;
  transform: translateY(20px);
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: var(--paper);
  background: #20221f;
  box-shadow: var(--shadow);
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

@keyframes drawer-in {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

@media (max-width: 1160px) {
  :root {
    --shell: min(calc(100% - 48px), 1080px);
  }

  .intro-copy h1 {
    font-size: 58px;
  }

  .detail-identity h2 {
    font-size: 36px;
  }

  .intro-band {
    grid-template-columns: 1fr 300px;
  }

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

  .domain-row {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .select-row {
    justify-content: flex-end;
  }

  .tool-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  :root {
    --shell: calc(100% - 36px);
  }

  .site-header {
    grid-template-columns: 1fr auto;
    padding-right: 18px;
    padding-left: 18px;
  }

  .top-nav {
    display: none;
  }

  .intro-band {
    grid-template-columns: 1fr;
    grid-template-areas: "copy" "stats" "search";
    gap: 28px;
    min-height: 0;
    padding-top: 54px;
  }

  .intro-stats {
    align-self: auto;
    margin: 0;
  }

  .search-box {
    grid-template-columns: 96px 1fr;
  }

  .search-box > span {
    display: none;
  }

  .route-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .filter-workbench {
    position: relative;
    top: auto;
    grid-template-columns: 1fr;
  }

  .domain-row {
    grid-column: auto;
    grid-row: auto;
  }

  .select-row {
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .domain-tabs {
    overflow-x: auto;
    padding-bottom: 3px;
  }

  .tool-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .site-footer {
    grid-template-columns: 1fr auto;
  }

  .site-footer p {
    display: none;
  }
}

@media (max-width: 560px) {
  :root {
    --shell: calc(100% - 28px);
  }

  html {
    scroll-padding-top: 76px;
  }

  .site-header {
    min-height: 64px;
  }

  .brand img {
    width: 40px;
    height: 40px;
  }

  .brand-copy small,
  .saved-entry > span:nth-child(2) {
    display: none;
  }

  .saved-entry {
    min-width: 72px;
    justify-content: center;
  }

  .intro-band {
    padding: 42px 0 34px;
  }

  .intro-copy h1 {
    font-size: 40px;
  }

  .intro-lead {
    font-size: 18px;
  }

  .intro-stats div {
    padding: 17px 8px;
  }

  .intro-stats dt {
    font-size: 24px;
  }

  .intro-stats dd {
    font-size: 10px;
  }

  .search-box {
    grid-template-columns: 1fr;
    gap: 3px;
    min-height: 82px;
    padding: 8px 12px;
  }

  .search-box > label {
    padding-left: 12px;
    font-size: 10px;
  }

  .search-control input {
    height: 42px;
    border-left: 0;
    font-size: 14px;
  }

  .route-band,
  .library {
    padding-top: 46px;
  }

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

  .section-heading > p,
  .result-summary {
    text-align: left;
  }

  .route-grid {
    display: flex;
    margin-right: -14px;
    padding-right: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
  }

  .route-card {
    width: min(78vw, 280px);
    min-width: min(78vw, 280px);
    min-height: 168px;
    scroll-snap-align: start;
  }

  .filter-workbench {
    gap: 15px;
    margin-right: -4px;
    margin-left: -4px;
    padding: 14px 12px;
  }

  .filter-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
  }

  .segmented,
  .domain-tabs {
    width: 100%;
  }

  .segmented button {
    flex: 1;
    padding: 0 5px;
  }

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

  .select-row label {
    display: grid;
  }

  .select-row select {
    width: 100%;
  }

  .reset-button {
    grid-column: 1 / -1;
    justify-self: start;
    padding: 0;
  }

  .tool-grid {
    grid-template-columns: 1fr;
  }

  .tool-card {
    min-height: 232px;
  }

  .site-footer {
    grid-template-columns: 1fr;
    gap: 16px;
    min-height: 170px;
    padding: 30px 20px;
  }

  .site-footer a {
    justify-self: start;
  }

  .detail-dialog {
    width: 100vw;
  }

  .detail-content {
    padding: 0 18px 54px;
  }

  .detail-head {
    padding-top: 6px;
  }

  .detail-identity {
    align-items: flex-start;
  }

  .detail-mark {
    width: 52px;
    height: 52px;
  }

  .detail-identity h2 {
    font-size: 27px;
  }

  .detail-meta {
    grid-template-columns: repeat(2, 1fr);
  }

  .detail-meta div:nth-child(3) {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .detail-meta div:nth-child(4) {
    border-top: 1px solid var(--line);
  }

  .detail-list,
  .pros-cons,
  .related-list {
    grid-template-columns: 1fr;
  }

  .detail-actions > * {
    flex: 1;
  }

  .toast {
    right: 14px;
    bottom: 14px;
    max-width: calc(100vw - 28px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.auth-pending > :not(.member-auth-gate) {
  visibility: hidden;
}

.member-auth-gate {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: grid;
  align-content: center;
  justify-items: center;
  padding: 28px;
  color: var(--text);
  text-align: center;
  background: var(--bg);
}

.member-auth-gate img {
  width: 58px;
  height: 58px;
  margin-bottom: 22px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
}

.member-auth-gate p {
  margin: 0 0 8px;
  color: var(--gold);
  font-size: 11px;
  font-weight: 800;
}

.member-auth-gate h1 {
  margin: 0;
  color: var(--paper);
  font-size: 28px;
}

.member-auth-gate span {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
}

.member-auth-gate a {
  margin-top: 22px;
  padding-bottom: 2px;
  border-bottom: 1px solid var(--gold-dark);
  color: var(--gold-light);
  font-size: 13px;
}

.auth-ready .member-auth-gate {
  display: none;
}
