/* =========================================================
   EXONUMIST SITE STYLES

   Keep page-specific styles in the clearly labeled sections below.
   When changing CSS, search for the matching section heading first.
   ========================================================= */

/* =========================================================
   DESIGN TOKENS
   Shared color and interaction values used across page sections.
   ========================================================= */

:root {
  --bg: #f4f1ea;
  --panel: #fffdf8;
  --line: #d9d2c5;
  --text: #201c18;
  --muted: #6f6658;
  --accent: #6b4f2f;
  --soft: #efe7da;
  --dark: #211d18;
  --shadow-card: 0 8px 24px rgba(0, 0, 0, 0.04);

  /* Interactive hover states cue clickability while preserving the museum-style palette. */
  --interactive-border: #b8a78d;
  --interactive-outline: 1px solid rgba(120, 98, 71, 0.26);
  --interactive-shadow-soft: 0 12px 28px rgba(82, 63, 39, 0.1);
  --interactive-shadow-medium: 0 14px 30px rgba(82, 63, 39, 0.12);
  --interactive-shadow-strong: 0 12px 30px rgba(82, 63, 39, 0.16);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.45;
}

a {
  color: inherit;
}

.is-filter-hidden {
  display: none !important;
}

[hidden] {
  display: none !important;
}

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

.topbar {
  background: var(--dark);
  color: #f7f2e9;
  padding: 10px 22px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.brand {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.brand a,
.nav a {
  text-decoration: none;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  color: #ddd3c3;
  font-size: 0.94rem;
}

.nav a {
  padding: 0.28rem 0.62rem;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #e8dfd1;
  font-weight: 500;
  letter-spacing: 0.005em;
  opacity: 0.92;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    opacity 0.15s ease,
    color 0.15s ease;
}

.nav a:hover,
.nav a:focus-visible {
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.07);
  opacity: 1;
  color: #ffffff;
}

.nav a:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.34);
  outline-offset: 2px;
}

.nav a[aria-current="page"] {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  opacity: 1;
  text-decoration: none;
}

.shell {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px;
}

.hero,
.section,
.card,
.token-shell,
.facts,
.resource-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow-card);
}

.hero {
  padding: 24px 28px;
  margin-bottom: 22px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 24px;
  align-items: center;
}

h1 {
  margin: 0 0 10px;
  font-size: 3rem;
  line-height: 1.02;
}

h2 {
  margin: 0 0 10px;
  font-size: 1.5rem;
}

.section,
.token-shell {
  padding: 22px;
  margin-bottom: 22px;
}

.grid-5,
.grid-4,
.grid-3 {
  display: grid;
  gap: 16px;
}

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

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

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

.grid-narrow {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  max-width: 980px;
}

.card,
.resource-card {
  padding: 18px;
  border-radius: 16px;
}

.resource-card-with-media {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px;
  gap: 18px;
  align-items: center;
}

.resource-card-body {
  min-width: 0;
}

.resource-card-body p {
  margin-bottom: 0;
}

.resource-card-media {
  display: flex;
  justify-content: center;
  align-items: center;
}

.resource-card-logo {
  display: block;
  width: 104px;
  height: 104px;
  object-fit: contain;
}

.eyebrow {
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 6px;
  display: block;
}

.cta,
.btn {
  display: inline-block;
  text-decoration: none;
  font-weight: 600;
}

.cta {
  color: var(--accent);
  margin-top: 12px;
}

.btn {
  padding: 11px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: white;
  font-weight: 700;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.06);
}

.btn.primary {
  background: var(--accent);
  color: #fffaf4;
  border-color: var(--accent);
}

.hero-side {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.mini-card {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px;
  min-height: 118px;
}

.footer {
  color: var(--muted);
  font-size: 0.94rem;
}

.footer-inner {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 28px;
  border-top: 1px solid rgba(217, 210, 197, 0.82);
}

.footer-note {
  max-width: 46rem;
}

.footer-note p {
  margin: 0;
}

.footer-note p + p {
  margin-top: 0.2rem;
}

.footer-nav {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  gap: 0.22rem 0.62rem;
  justify-content: flex-end;
}

.footer-nav a {
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 600;
  opacity: 0.78;
  text-decoration: none;
  text-underline-offset: 0.1em;
}

.footer-nav a:hover,
.footer-nav a:focus-visible {
  opacity: 1;
  text-decoration: underline;
}

.footer-nav a:focus-visible {
  outline: 3px solid rgba(116, 88, 54, 0.28);
  outline-offset: 3px;
  border-radius: 0.25rem;
}

/* =========================================================
   BREADCRUMBS
   Used by: section, group, token detail, and standalone pages
   ========================================================= */

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.45rem;
  align-items: center;
  margin: 0 0 0.85rem;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.35;
}

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

.breadcrumb a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.hero-visual {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  align-items: center;
}

.hero-visual-card {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 12px;
  min-height: 140px;
}

.hero-visual-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  display: block;
}

/* =========================================================
   INTERACTIVE HOVER STATES
   Shared cues for linked cards so clickable surfaces respond consistently.
   ========================================================= */

.card-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.card-link .card,
.card-link .resource-card {
  height: 100%;
  transition:
    background 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}

.card-link:hover .card,
.card-link:hover .resource-card {
  transform: translateY(-3px);
  box-shadow: var(--interactive-shadow-medium);
  border-color: var(--interactive-border);
  background: rgba(255, 253, 248, 0.98);
}

.card-link:focus-visible .card,
.card-link:focus-visible .resource-card {
  outline: 3px solid rgba(116, 88, 54, 0.28);
  outline-offset: 4px;
  transform: translateY(-3px);
  box-shadow: var(--interactive-shadow-medium);
  border-color: var(--interactive-border);
  background: rgba(255, 253, 248, 0.98);
}

.utility-link {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  max-width: 100%;
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}

.utility-link-icon {
  width: 1.35rem;
  height: 1.35rem;
  flex: 0 0 auto;
  color: currentColor;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.utility-link span:last-child {
  text-decoration: underline;
  text-underline-offset: 0.08em;
}

.utility-link:hover span:last-child,
.utility-link:focus-visible span:last-child {
  text-decoration-thickness: 0.08em;
}

.utility-link:focus-visible {
  outline: 3px solid rgba(116, 88, 54, 0.28);
  outline-offset: 4px;
  border-radius: 0.35rem;
}

/* =========================================================
   TOKEN DETAIL PAGE
   Used by: individual token detail pages
   ========================================================= */

.token-header {
  margin-bottom: 1.5rem;
}

.token-header h1 {
  margin: 0 0 0.4rem;
  font-size: clamp(2.25rem, 4vw, 3.5rem);
  line-height: 0.98;
}

.token-subtitle {
  margin: 0 0 0.55rem;
  max-width: 62ch;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.35;
}

.token-meta-line {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.45;
}

.meta {
  color: var(--muted);
  margin-bottom: 0.85rem;
  font-size: 0.85rem;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 1rem;
}

.badge {
  background: rgba(255, 255, 255, 0.4);
  border: 1px solid var(--line);
  opacity: 0.85;
  border-radius: 999px;
  padding: 0.38rem 0.74rem;
  font-size: 0.78rem;
  line-height: 1.2;
}

.token-summary {
  max-width: 72ch;
  margin-bottom: 1.15rem;
}

.token-summary p {
  margin: 0;
  color: var(--text);
  font-size: 1rem;
  line-height: 1.6;
}

.token-images {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin: 0 0 22px;
}

.token-image-card {
  margin: 0;
  min-width: 0;
  padding: 1rem 1rem 1.15rem;
  border: 1px solid rgba(120, 98, 71, 0.22);
  border-radius: 16px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.78),
    rgba(247, 241, 231, 0.92)
  );
  text-align: center;
}

.token-image {
  width: 100%;
  max-width: 520px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  display: block;
  margin: 0 auto 0.9rem;
  border-radius: 12px;
  cursor: zoom-in;
  transition:
    transform 160ms ease,
    filter 160ms ease,
    box-shadow 160ms ease;
  transform-origin: center;
}

.token-image-button {
  display: block;
  width: 100%;
  max-width: 520px;
  margin: 0 auto 0.9rem;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 12px;
  background: none;
  cursor: zoom-in;
  font: inherit;
}

.token-image-button .token-image {
  max-width: none;
  margin: 0;
  cursor: zoom-in;
}

.token-image-button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.token-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  box-sizing: border-box;
  padding: 0.9rem;
  border: 1px dashed rgba(120, 98, 71, 0.35);
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.55),
    rgba(245, 238, 226, 0.8)
  );
  color: var(--muted);
  text-align: center;
}

.token-placeholder-icon {
  font-size: clamp(2rem, 6vw, 2.5rem);
  line-height: 1;
}

.token-placeholder-title {
  color: var(--text);
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.2;
}

.token-placeholder-subtitle {
  max-width: 18rem;
  font-size: 0.9rem;
  line-height: 1.35;
}

.placeholder {
  width: 100%;
  max-width: 520px;
  aspect-ratio: 1 / 1;
  margin: 0 auto 0.9rem;
  border-radius: 12px;
}

.token-face-label {
  margin-top: 0.15rem;
  text-align: center;
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text);
}

.token-face-text {
  margin: 0.45rem auto 0;
  max-width: 32ch;
  font-size: 0.98rem;
  font-weight: 600;
  color: #4f4437;
  line-height: 1.45;
  text-align: center;
  overflow-wrap: anywhere;
}

.token-caption-text {
  display: block;
  margin-top: 0.28rem;
  overflow-wrap: anywhere;
}

.token-lower-grid {
  display: grid;
  grid-template-columns: minmax(290px, 0.86fr) minmax(0, 1.14fr);
  gap: 20px;
  align-items: start;
}

.token-quickfacts,
.token-notes-section {
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
}

.token-quickfacts h2,
.token-notes-section h2 {
  margin-bottom: 0.75rem;
  font-size: 1.35rem;
  line-height: 1.2;
}

.facts {
  padding: 4px 18px;
  box-shadow: none;
  background: rgba(255, 255, 255, 0.55);
}

.quickfacts-panel {
  max-width: 100%;
  margin: 0;
  height: 100%;
  flex: 1;
}

.quickfacts-panel dl {
  margin: 0;
}

.facts-row {
  display: grid;
  grid-template-columns: minmax(9.5rem, 0.45fr) minmax(0, 1fr);
  gap: 14px;
  padding: 0.85rem 0;
  border-bottom: 1px solid #e7e0d2;
  align-items: start;
}

.facts-row:last-child {
  border-bottom: none;
}

.facts dt {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
  line-height: 1.35;
}

.facts dd {
  margin: 0;
  font-weight: 600;
  font-size: 0.98rem;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.token-detail--compact {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(300px, 0.88fr);
  gap: 0 22px;
  align-items: start;
}

.token-detail--compact > * {
  grid-column: 1 / -1;
}

.token-detail--compact .breadcrumb {
  margin-bottom: 0.55rem;
}

.token-detail--compact .token-heading {
  grid-column: 1 / -1;
  grid-row: 2;
  margin-bottom: 0.9rem;
}

.token-detail--compact h1 {
  margin-bottom: 0.35rem;
  font-size: clamp(2rem, 3.2vw, 2.45rem);
}

.token-detail--compact .token-subtitle {
  margin-bottom: 0.35rem;
}

.token-detail--compact .token-primary {
  grid-column: 1;
  grid-row: 3;
  order: 3;
  min-width: 0;
}

.token-detail--compact .token-images {
  gap: 14px;
  margin-bottom: 0.45rem;
}

.token-detail--compact .token-image-card {
  padding: 0.85rem 0.85rem 0.95rem;
  border-radius: 12px;
}

.token-detail--compact .token-image,
.token-detail--compact .placeholder {
  max-height: 260px;
  margin-bottom: 0.65rem;
  aspect-ratio: 1 / 1;
  object-fit: contain;
}

.token-detail--compact .token-image-caption {
  font-size: 0.9rem;
  line-height: 1.42;
}

.token-detail--compact .token-lower-grid {
  display: contents;
}

.token-detail--compact .token-quickfacts {
  grid-column: 2;
  grid-row: 3;
  order: 2;
  min-width: 0;
}

.token-detail--compact .quickfacts-panel {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.token-detail--compact .token-summary {
  max-width: 85ch;
  margin: 0;
}

.token-detail--compact .token-notes-section {
  grid-column: 1 / -1;
  grid-row: 4;
  order: 5;
  margin-top: 0.85rem;
}

.token-detail--compact .token-pager {
  grid-column: 1 / -1;
  grid-row: 5;
  order: 6;
  margin-top: 24px;
}

.token-detail--compact .notes-content p {
  max-width: 95ch;
}

.token-notes-section {
  padding: 20px;
}

.notes-frame {
  position: relative;
  border: 1px solid #e6dccd;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.6);
}

.notes-content {
  padding: 1.15rem 1.2rem;
  color: var(--text);
}

.notes-content p {
  margin: 0 0 1rem;
  max-width: 70ch;
  line-height: 1.78;
  white-space: pre-line;
}

.notes-content p:last-child {
  margin-bottom: 0;
}

@media (min-width: 821px) and (max-width: 1150px) {
  .token-detail--compact {
    grid-template-columns: minmax(0, 1fr) minmax(380px, 0.78fr);
    gap: 0 16px;
  }

  .token-detail--compact .token-image,
  .token-detail--compact .placeholder {
    max-height: 230px;
  }

  .token-detail--compact .token-image-card {
    padding: 0.75rem 0.75rem 0.85rem;
  }

  .token-detail--compact .facts {
    padding-inline: 14px;
  }

  .token-detail--compact .facts-row {
    grid-template-columns: minmax(6.8rem, 0.32fr) minmax(0, 1fr);
    gap: 10px;
  }

  .token-detail--compact .facts dd {
    overflow-wrap: normal;
    word-break: normal;
  }
}

@media (max-width: 820px) {
  .token-detail--compact {
    grid-template-columns: 1fr;
  }

  .token-detail--compact .token-heading,
  .token-detail--compact .token-primary,
  .token-detail--compact .token-quickfacts,
  .token-detail--compact .token-notes-section,
  .token-detail--compact .token-pager {
    grid-column: 1;
    grid-row: auto;
  }

  .token-detail--compact .token-heading {
    order: 2;
  }

  .token-detail--compact .token-primary {
    order: 3;
  }

  .token-detail--compact .token-quickfacts {
    order: 4;
  }

  .token-detail--compact .token-notes-section {
    order: 5;
  }

  .token-detail--compact .token-pager {
    order: 6;
  }
}

.section-intro {
  color: var(--muted);
  max-width: 70ch;
}

.note {
  color: var(--muted);
  font-size: 0.94rem;
}

/* =========================================================
   TOKEN LIST CARDS
   Used by: section, city, and group listing cards
   ========================================================= */

.token-card-grid {
  align-items: stretch;
}

.token-list-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 16px;
}

.token-card-id {
  display: block;
  margin-bottom: 0.25rem;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.2;
}

.token-list-card-media {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 150px;
  max-height: 170px;
  margin-bottom: 12px;
  overflow: hidden;
}

.token-list-card-media-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

.token-list-card-media-frame--round,
.token-list-card-media-frame--octagon {
  width: 150px;
  height: 150px;
  background: rgba(255, 255, 255, 0.38);
  overflow: hidden;
}

.token-list-card-media-frame--round {
  border-radius: 50%;
}

.token-list-card-media-frame--octagon {
  clip-path: polygon(
    30% 0%,
    70% 0%,
    100% 30%,
    100% 70%,
    70% 100%,
    30% 100%,
    0% 70%,
    0% 30%
  );
}

.token-list-card-image {
  width: 100%;
  max-width: 170px;
  max-height: 150px;
  object-fit: contain;
  display: block;
  transition:
    transform 180ms ease,
    filter 180ms ease;
  transform-origin: center;
}

.token-list-card-media-frame--round .token-list-card-image,
.token-list-card-media-frame--octagon .token-list-card-image {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
}

.token-list-card-placeholder {
  width: 108px;
  height: 108px;
  gap: 0.2rem;
  padding: 0.45rem;
  border-color: rgba(120, 98, 71, 0.22);
  border-radius: 12px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.38),
    rgba(245, 238, 226, 0.52)
  );
}

.token-list-card-placeholder .token-placeholder-icon {
  font-size: 1.65rem;
}

.token-list-card-placeholder .token-placeholder-title {
  font-size: 0.78rem;
}

.token-list-card-placeholder .token-placeholder-subtitle {
  font-size: 0.62rem;
  line-height: 1.2;
}

.token-list-card-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  height: 100%;
}

.token-list-card-title {
  display: block;
  font-size: 1.05rem;
  line-height: 1.3;
}

.token-list-card-desc {
  margin: 0;
  color: var(--text);
  line-height: 1.45;
}

.token-card-meta-row {
  margin-top: auto;
  padding-top: 6px;
}

.token-card-meta-row p + p {
  margin-top: 0.25rem;
}

.token-list-card-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

/* =========================================================
   TOKEN DETAIL PAGER
   Previous / Next navigation on token detail pages
   ========================================================= */

.token-pager {
  margin-top: 18px;
}

.token-pager-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: stretch;
}

/* If both Previous and Next are present, use two columns on desktop. */
.token-pager-grid:has(
  .token-pager-item:not(:empty) + .token-pager-item:not(:empty)
) {
  grid-template-columns: 1fr 1fr;
}

.token-pager-item {
  min-height: 1px;
  display: flex;
}

.token-pager-item:empty {
  display: none;
}

.token-pager-link {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 100%;
  text-decoration: none;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.55);
  transition:
    background 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}

.token-pager-link:hover,
.token-pager-link:focus-visible {
  transform: translateY(-2px);
  box-shadow: var(--interactive-shadow-soft);
  border-color: var(--interactive-border);
  background: rgba(255, 253, 248, 0.86);
}

.token-pager-link:focus-visible {
  outline: 3px solid rgba(116, 88, 54, 0.28);
  outline-offset: 4px;
}

.token-pager-media {
  flex: 0 0 72px;
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.token-pager-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.token-pager-image-frame {
  width: 72px;
  height: 72px;
  overflow: hidden;
}

.token-pager-image-frame--round {
  border-radius: 50%;
}

.token-pager-image-frame--octagon {
  clip-path: polygon(
    30% 0%,
    70% 0%,
    100% 30%,
    100% 70%,
    70% 100%,
    30% 100%,
    0% 70%,
    0% 30%
  );
}

.token-pager-image-frame .token-pager-image {
  object-fit: cover;
}

.token-pager-placeholder {
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed rgba(120, 98, 71, 0.22);
  border-radius: 10px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.38),
    rgba(245, 238, 226, 0.52)
  );
  color: var(--muted);
  font-size: 2rem;
  line-height: 1;
}

.token-pager-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  min-width: 0;
}

.token-pager-next .token-pager-link {
  flex-direction: row-reverse;
  text-align: right;
}

.token-pager-label {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1.1;
  margin-bottom: 4px;
}

.token-pager-link strong {
  font-size: 1rem;
}

.token-pager-borough {
  display: block;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.1;
  text-transform: uppercase;
}

.token-pager-content span:last-child {
  color: var(--muted);
}

/* =========================================================
   HOMEPAGE MASTHEAD
   Top hero area on the home page
   ========================================================= */

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

.hero-home-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(220px, 0.7fr);
  gap: 28px;
  align-items: center;
}

.hero-home-main {
  min-width: 0;
}

.hero-home-main .hero-branding {
  margin: 0 0 0.65rem;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  display: block;
}

.hero-logo {
  display: block;
  width: min(560px, 100%);
  height: auto;
  opacity: 1;
  mix-blend-mode: normal;
  filter: none;
}

.hero-home-main h1 {
  max-width: 17ch;
  margin: 0 0 0.8rem;
  font-size: clamp(1.95rem, 3.4vw, 2.9rem);
  line-height: 0.95;
  letter-spacing: -0.025em;
}

.hero-copy {
  max-width: 58ch;
}

.hero-copy p {
  margin: 0 0 0.65rem;
  font-size: 1rem;
  line-height: 1.56;
}

.hero-copy .note {
  font-size: 0.98rem;
  line-height: 1.52;
}

.hero-feature {
  display: flex;
  justify-content: center;
}

.hero-feature .card-link {
  cursor: pointer;
}

.hero-feature-card {
  width: 100%;
  max-width: 250px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.55);
  box-shadow: var(--shadow-card);
  text-align: center;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease;
}

.hero-feature .card-link:hover .hero-feature-card,
.hero-feature .card-link:focus-visible .hero-feature-card {
  border-color: var(--interactive-border);
  box-shadow: var(--interactive-shadow-medium);
  transform: translateY(-3px) scale(1.01);
}

.hero-feature-card img {
  width: 100%;
  max-width: 170px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  display: block;
  margin: 0 auto 0.7rem;
}

.hero-feature-text strong {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 1rem;
}

.hero-feature-text p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

/* =========================================================
   HOMEPAGE SECTION CARDS
   Collection and spotlight cards on home page
   ========================================================= */

.home-section-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.home-section-card {
  height: 100%;
  padding: 18px;
}

.home-section-card-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px;
  gap: 16px;
  align-items: start;
  height: 100%;
}

.home-section-card-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 100%;
}

.home-section-card-title {
  display: block;
  font-size: 1.08rem;
  line-height: 1.3;
  margin-bottom: 8px;
}

.home-section-card-desc {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.home-section-card-action {
  margin-top: auto;
  padding-top: 0.9rem;
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.25;
}

.home-section-card-media {
  display: flex;
  align-items: center;
  padding-top: 0.45rem;
  justify-content: center;
}

.home-section-card-image {
  width: 100%;
  max-width: 110px;
  max-height: 110px;
  object-fit: contain;
  display: block;
}

.home-section-card-media .token-list-card-media-frame--round,
.home-section-card-media .token-list-card-media-frame--octagon {
  width: 110px;
  height: 110px;
}

.home-section-card-media .token-list-card-image {
  width: 100%;
  height: 100%;
}

/* =========================================================
   ABOUT PAGE
   Used by: /about/

   This section controls:
   - Two-column about page rows
   - Right-side boxed asides (Site Focus, Also Collecting, etc.)
   - Want List token cards
   ========================================================= */

.about-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 320px);
  gap: 2rem;
  align-items: start;
}

.about-aside {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: var(--panel);
}

.about-want-list-note {
  margin-top: 0.85rem;
}

.about-want-list-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.85rem;
  margin-top: 0.45rem;
  max-width: 100%;
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}

.about-want-list-link span {
  min-width: 0;
}

.about-want-list-link:hover,
.about-want-list-link:focus-visible {
  text-decoration: underline;
}

.about-want-list-link:focus-visible {
  outline: 3px solid rgba(116, 88, 54, 0.28);
  outline-offset: 4px;
  border-radius: 0.5rem;
}

.about-want-list-icon {
  display: block;
  width: 56px;
  height: 56px;
  box-sizing: border-box;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.72);
  object-fit: cover;
  flex: 0 0 56px;
}

.about-content-use {
  background: rgba(255, 255, 255, 0.42);
  box-shadow: none;
}

/* Want List token card grid */
.wanted-token-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-top: 1rem;
}

.wanted-secondary-heading {
  margin-top: 2rem;
}

/* Individual Want List token cards */
.wanted-token-link {
  position: relative;
  display: grid;
  gap: 0.15rem;
  padding: 0.75rem 1rem 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 0.65rem;
  background: var(--panel);
  box-shadow: var(--shadow-card);
  cursor: pointer;
  text-decoration: none;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease;
}

.wanted-token-link strong {
  padding-right: 3.5rem;
  display: inline-block;
}

.wanted-token-link:hover,
.wanted-token-link:focus-visible {
  border-color: var(--interactive-border);
  box-shadow: var(--interactive-shadow-soft);
  text-decoration: none;
  transform: translateY(-3px);
}

.wanted-token-link strong,
.wanted-token-link span {
  display: block;
}

/* Top-right "Wanted" badge on Want List token cards */
.wanted-token-badge {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  padding: 0.2rem 0.45rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--soft);
  color: var(--accent);
  font-size: 0.65rem; /* slightly smaller */
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  opacity: 0.85; /* slightly lighter */
}

/* Muted material / counterstamp / type line on Want List cards */
.wanted-token-meta {
  margin-top: 0.35rem;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.3;
}

@media (max-width: 760px) {
  .about-split {
    grid-template-columns: 1fr;
  }

  .about-aside {
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 0.75rem;
    background: var(--panel);
  }

  .wanted-token-list {
    grid-template-columns: 1fr;
  }
}
/* =========================================================
   CONTACT PAGE
   Used by: /contact/
   ========================================================= */

.contact-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 500px);
  gap: 2rem;
  align-items: center;
}

.contact-hero-content {
  min-width: 0;
}

.contact-profile-card {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  max-width: 500px;
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.48);
}

.contact-profile-image-frame {
  flex: 0 0 150px;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  border: 1px solid var(--line);
  overflow: hidden;
}

.contact-profile-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.contact-profile-body {
  min-width: 0;
}

.contact-profile-body h2 {
  margin-bottom: 0.35rem;
  font-size: 1.2rem;
}

.contact-profile-name {
  display: block;
  margin-bottom: 0.35rem;
}

.contact-profile-body p {
  margin: 0 0 0.45rem;
  color: var(--muted);
  line-height: 1.5;
}

.contact-profile-link {
  color: var(--accent);
  font-size: 0.94rem;
  font-weight: 700;
}

.related-page-card-with-media {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 104px;
  gap: 14px;
  align-items: center;
}

.related-page-card-body {
  min-width: 0;
}

.related-page-card-media {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 104px;
  height: 104px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.72);
  flex: 0 0 104px;
  overflow: hidden;
}

.related-page-card-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/*
  Contact detail rows reuse the About page split layout.
  These scoped rules tighten the cards without changing the About page itself.
*/
.section:has(.contact-hero) ~ .section:has(.about-split) {
  padding-top: 18px;
  padding-bottom: 18px;
}

.section:has(.contact-hero) ~ .section .about-split {
  gap: 1.25rem;
  align-items: start;
}

.section:has(.contact-hero) ~ .section .about-split h2 {
  margin-bottom: 0.45rem;
}

/*
  Keep Contact page section paragraphs controlled and predictable.
  The second paragraph gets explicit spacing so it reads as a separate thought.
*/
.contact-section-content .prose-width {
  margin: 0;
}

.contact-section-content .prose-width + .prose-width {
  margin-top: 1rem;
}

.section:has(.contact-hero) ~ .section .about-aside {
  align-self: start;
  padding: 0.85rem 1rem;
}

.section:has(.contact-hero) ~ .section .about-aside h3 {
  margin-top: 0;
  margin-bottom: 0.45rem;
}

.section:has(.contact-hero) ~ .section .about-aside ul {
  margin: 0.35rem 0 0;
  padding-left: 1.25rem;
}

@media (max-width: 760px) {
  .contact-hero {
    grid-template-columns: 1fr;
  }

  .contact-profile-card {
    max-width: 100%;
    padding: 1.25rem;
  }

  .contact-profile-image-frame {
    flex-basis: 112px;
    width: 112px;
    height: 112px;
  }

  .related-page-card-with-media {
    grid-template-columns: minmax(0, 1fr) 104px;
  }
}

/* =========================================================
   BROWSE PAGE
   Used by: /search/ filter controls and token result cards
   ========================================================= */

.browse-controls {
  padding: 1rem;
  margin-bottom: 1rem;
}

.search-controls {
  max-width: 980px;
  padding: 1.1rem;
  background: rgba(255, 253, 248, 0.96);
}

.browse-search-group {
  margin-bottom: 1.15rem;
}

.search-control-title {
  margin: 0 0 0.55rem;
  font-size: 1.12rem;
}

.search-input-label {
  display: block;
  margin-bottom: 0.4rem;
  color: var(--text);
  font-weight: 800;
}

.search-input-shell {
  position: relative;
  display: flex;
  align-items: center;
}

.search-input-icon {
  position: absolute;
  left: 1rem;
  width: 1.18rem;
  height: 1.18rem;
  color: var(--accent);
  fill: none;
  opacity: 0.78;
  pointer-events: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.browse-search-input,
.collection-search-input {
  width: 100%;
  padding: 0.75rem;
  font-size: 1rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  background-color: var(--panel);
  font-family: inherit;
}

.search-controls .browse-search-input {
  min-height: 3.25rem;
  padding: 0.9rem 1rem 0.9rem 2.95rem;
  border-color: rgba(120, 98, 71, 0.32);
  border-radius: 0.65rem;
  background-color: #fffdf8;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  font-size: 1.08rem;
}

.browse-search-input::placeholder,
.collection-search-input::placeholder {
  color: var(--muted);
}

.browse-search-input:focus,
.collection-search-input:focus {
  outline: none;
  border-color: var(--text);
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.search-controls .browse-search-input:focus {
  border-color: var(--accent);
  box-shadow:
    0 0 0 3px rgba(116, 88, 54, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.search-input-help {
  margin: 0.55rem 0 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.collection-search-help,
.collection-result-summary,
.collection-empty-message {
  margin: 0.65rem 0 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.collection-result-summary {
  font-weight: 700;
}

.search-filter-area {
  padding-top: 0.85rem;
  border-top: 1px solid rgba(217, 210, 197, 0.82);
}

.search-filter-title {
  margin: 0 0 0.7rem;
  color: var(--muted);
  font-size: 0.88rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.search-results-header {
  margin: 1.25rem 0 0.75rem;
}

.search-results-header h2 {
  margin: 0;
  font-size: 1.35rem;
}

.browse-card-details {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.35;
}

.browse-filter-group + .browse-filter-group {
  margin-top: 1rem;
}

.browse-filter-heading {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.browse-group-action,
#browse-reset {
  border: 1px solid var(--line);
  background: transparent;
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  cursor: pointer;
  font: inherit;
}

.browse-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.browse-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid var(--line);
  background: #fffaf2;
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  cursor: pointer;
  font: inherit;
  transition: 0.15s ease;
}

.browse-chip:hover {
  transform: translateY(-1px);
}

.browse-chip.is-active {
  background: #7a542b;
  color: #fff;
  border-color: #7a542b;
}

.browse-chip-count {
  font-size: 0.85em;
  opacity: 0.85;
}

.browse-summary {
  margin-top: 1rem;
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.browse-card {
  padding: 16px;
  border-color: rgba(120, 98, 71, 0.18);
  background: linear-gradient(
    180deg,
    rgba(255, 253, 248, 0.98),
    rgba(255, 250, 242, 0.94)
  );
  transition:
    background 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease;
}

.browse-card:hover,
.browse-card:focus-within {
  transform: translateY(-3px);
  border-color: var(--interactive-border);
  box-shadow: var(--interactive-shadow-medium);
  background: linear-gradient(
    180deg,
    rgba(255, 253, 248, 1),
    rgba(255, 250, 242, 0.98)
  );
}

.browse-card:focus-within {
  outline: 3px solid rgba(116, 88, 54, 0.28);
  outline-offset: 4px;
}

.browse-card-link:focus-visible {
  outline: none;
}

.browse-card-link {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  text-decoration: none;
  color: inherit;
}

.browse-card-media {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 150px;
  max-height: 170px;
  margin-bottom: 12px;
  overflow: hidden;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.28);
}

.browse-card-media img {
  max-width: 100%;
  max-height: 150px;
  object-fit: contain;
}

@media (hover: hover) and (pointer: fine) {
  .card-link:hover .token-list-card-image,
  .card-link:focus-visible .token-list-card-image,
  .browse-card-link:hover .token-list-card-image,
  .browse-card-link:focus-visible .token-list-card-image {
    filter: brightness(1.025) contrast(1.02);
    transform: scale(1.08);
  }

  .token-image-button:hover .token-image,
  .token-image-button:focus-visible .token-image {
    filter: brightness(1.025) contrast(1.02);
    transform: scale(1.12);
  }
}

.browse-card-placeholder {
  width: 108px;
  height: 108px;
  gap: 0.2rem;
  padding: 0.45rem;
  border-color: rgba(120, 98, 71, 0.22);
  border-radius: 12px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.38),
    rgba(245, 238, 226, 0.52)
  );
}

.browse-card-placeholder .token-placeholder-icon {
  font-size: 1.65rem;
}

.browse-card-placeholder .token-placeholder-title {
  font-size: 0.78rem;
}

.browse-card-placeholder .token-placeholder-subtitle {
  font-size: 0.62rem;
  line-height: 1.2;
}

.browse-card-body {
  margin-top: auto;
  display: flex;
  flex: 1;
  flex-direction: column;
}

.browse-card-title {
  margin: 0 0 0.45rem 0;
  line-height: 1.35;
}

.browse-card-meta {
  margin: 0;
  font-size: 0.88rem;
  opacity: 0.8;
}

.browse-empty-state {
  margin-top: 1rem;
  padding: 1rem 1.1rem;
  border: 1px solid rgba(122, 84, 43, 0.42);
  border-left: 5px solid var(--accent);
  border-radius: 8px;
  background:
    linear-gradient(
      180deg,
      rgba(255, 250, 242, 0.98),
      rgba(246, 234, 214, 0.88)
    );
  box-shadow: 0 10px 24px rgba(82, 58, 32, 0.08);
  color: var(--muted);
}

.browse-empty-state strong {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--text);
}

.browse-empty-state p {
  margin: 0;
  max-width: 64ch;
  line-height: 1.5;
}

.browse-empty-state ul {
  margin: 0.35rem 0 0;
  padding-left: 1.2rem;
}

.browse-empty-state li {
  margin: 0.16rem 0;
}

.browse-badge {
  font-size: 0.75rem;
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  white-space: nowrap;
  border: 1px solid transparent;
}

.browse-badge-listed {
  background: #eef7ee;
  color: #246b2b;
  border-color: #cfe6d1;
}

.browse-badge-unlisted {
  background: #f8f1e5;
  color: #8a5a00;
  border-color: #ead7aa;
}

/* =========================================================
   RESPONSIVE RULES
   Shared tablet/mobile layout adjustments
   ========================================================= */

@media (max-width: 980px) {
  .hero-grid,
  .grid-5,
  .grid-4,
  .grid-3,
  .hero-side,
  .hero-visual,
  .token-images,
  .token-lower-grid,
  .hero-home-grid {
    grid-template-columns: 1fr;
  }

  .home-section-grid {
    grid-template-columns: 1fr;
  }

  .home-section-card-layout {
    align-items: center;
  }

  .home-section-card-media {
    align-self: center;
    align-items: center;
  }

  h1 {
    font-size: 2.25rem;
  }

  .section,
  .token-shell {
    padding: 20px;
  }

  .quickfacts-panel {
    max-width: 100%;
  }

  .token-detail--compact .token-images {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .token-image,
  .placeholder {
    max-width: 100%;
  }

  .facts-row {
    grid-template-columns: minmax(8.75rem, 0.42fr) minmax(0, 1fr);
  }

  .token-list-card-media {
    min-height: 140px;
    max-height: 160px;
  }

  .token-list-card-image {
    max-width: 155px;
    max-height: 140px;
  }

  .token-list-card-media-frame--round,
  .token-list-card-media-frame--octagon {
    width: 140px;
    height: 140px;
  }

  .hero-feature {
    justify-content: flex-start;
  }

  .notes-content {
    padding-bottom: 1.1rem;
  }
}

@media (max-width: 640px) {
  .topbar {
    padding: 8px 12px;
  }

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

  .resource-card-with-media {
    grid-template-columns: 1fr;
  }

  .resource-card-media {
    justify-content: flex-start;
  }

  .nav {
    gap: 6px;
    font-size: 0.88rem;
    line-height: 1.2;
  }

  .nav a {
    padding: 0.26rem 0.5rem;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.7rem;
  }

  .footer-nav {
    display: grid;
    grid-template-columns: repeat(3, max-content);
    width: 100%;
    gap: 0.38rem 1rem;
    justify-content: flex-start;
  }

  .search-controls {
    padding: 0.85rem;
  }

  .search-controls .browse-search-input {
    min-height: 3rem;
    padding-right: 0.85rem;
    padding-left: 2.65rem;
    font-size: 1rem;
  }

  .search-input-icon {
    left: 0.85rem;
    width: 1.05rem;
    height: 1.05rem;
  }

  .section,
  .token-shell {
    padding: 16px;
  }

  .token-shell h1 {
    margin-bottom: 0.5rem;
    font-size: clamp(2rem, 13vw, 2.55rem);
    line-height: 1;
    overflow-wrap: anywhere;
  }

  .token-subtitle {
    font-size: 1.05rem;
    line-height: 1.4;
  }

  .token-meta-line {
    font-size: 0.9rem;
  }

  .badges {
    gap: 0.42rem;
    margin-bottom: 0.9rem;
  }

  .badge {
    padding: 0.42rem 0.68rem;
  }

  .token-summary {
    margin-bottom: 1rem;
  }

  .token-images {
    gap: 14px;
    margin-bottom: 18px;
  }

  .token-image-card {
    padding: 0.8rem 0.8rem 0.9rem;
    border-radius: 14px;
  }

  .token-image,
  .placeholder {
    margin-bottom: 0.65rem;
  }

  .token-face-text,
  .token-image-caption {
    font-size: 0.95rem;
    line-height: 1.48;
  }

  .token-lower-grid {
    gap: 16px;
  }

  .token-quickfacts,
  .token-notes-section {
    padding: 14px;
  }

  .facts {
    padding: 0 14px;
    border-radius: 14px;
  }

  .facts-row {
    grid-template-columns: 1fr;
    gap: 4px;
    padding: 0.8rem 0;
  }

  .facts dt {
    font-size: 0.76rem;
    white-space: normal;
  }

  .facts dd {
    font-size: 0.98rem;
    line-height: 1.48;
  }

  .notes-content {
    padding: 1rem 1rem 1.15rem;
  }

  .notes-content p {
    max-width: none;
    line-height: 1.68;
  }

  .token-list-card {
    padding: 14px;
  }

  .token-list-card-media {
    min-height: 120px;
    max-height: 140px;
    margin-bottom: 10px;
  }

  .token-list-card-image {
    max-width: 135px;
    max-height: 120px;
  }

  .browse-card-media {
    min-height: 120px;
    max-height: 140px;
    margin-bottom: 10px;
  }

  .browse-card-media img {
    max-height: 120px;
  }

  .token-list-card-media-frame--round,
  .token-list-card-media-frame--octagon {
    width: 120px;
    height: 120px;
  }

  .token-list-card-title {
    font-size: 1rem;
  }

  .token-pager-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .token-pager-grid:has(
    .token-pager-item:not(:empty) + .token-pager-item:not(:empty)
  ) {
    grid-template-columns: 1fr;
  }

  .token-pager-link,
  .token-pager-next .token-pager-link {
    flex-direction: row;
    align-items: center;
    min-height: 5.25rem;
    text-align: left;
    gap: 10px;
    padding: 12px;
  }

  .token-pager-media {
    order: 0;
    flex-basis: auto;
    width: 58px;
    height: 58px;
  }

  .token-pager-image-frame {
    width: 58px;
    height: 58px;
  }

  .token-pager-placeholder {
    width: 58px;
    height: 58px;
    font-size: 1.65rem;
  }

  .token-pager-content {
    order: 0;
    align-items: flex-start;
    gap: 3px;
  }

  .token-pager-label {
    margin-bottom: 2px;
    font-size: 0.72rem;
  }

  .token-pager-link strong {
    font-size: 1rem;
    line-height: 1.15;
  }

  .token-pager-content span:last-child {
    display: block;
    font-size: 0.86rem;
    line-height: 1.3;
  }

  .hero-home-wide {
    padding: 16px 16px 18px;
  }

  .hero-home-main h1 {
    max-width: none;
    font-size: clamp(1.65rem, 7vw, 2.15rem);
    line-height: 0.95;
    letter-spacing: -0.02em;
    margin-bottom: 0.6rem;
  }

  .hero-logo {
    width: 100%;
  }

  .hero-copy p,
  .hero-copy .note {
    font-size: 1rem;
  }

  .hero-copy .note {
    display: none;
  }

  .hero-feature-card {
    max-width: none;
  }

}

/* =========================================================
   IMAGE MODAL
   ========================================================= */

.image-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

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

.image-modal-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
}

.image-modal-content img {
  max-width: 100%;
  max-height: 100%;
  display: block;
}

.image-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  color: white;
  font-size: 30px;
  background: none;
  border: none;
  cursor: pointer;
}
/* =========================================================
   AVAILABLE PAGE
   Used by: /available/

   Displays sale inventory from src/_data/forSale.csv.
   Items are grouped by state in collapsible sections.
   ========================================================= */

.for-sale-list {
  max-width: 700px;
}

.for-sale-terms {
  max-width: 700px;
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: rgba(239, 231, 218, 0.45);
  color: var(--muted);
}

.for-sale-terms p {
  margin: 0 0 0.75rem;
}

.available-mode-switch {
  display: inline-flex;
  flex-wrap: wrap;
  max-width: 700px;
  margin: 1rem 0 1.25rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  overflow: hidden;
}

.available-mode-button {
  padding: 0.72rem 1rem;
  border: 0;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
  font: inherit;
  font-weight: 800;
}

.available-mode-button.is-active {
  background: var(--accent);
  color: #fffaf4;
}

.available-workflow {
  max-width: 700px;
  margin: 0 0 1.25rem;
}

.available-workflow h2 {
  margin-bottom: 0.35rem;
}

.available-utility-row {
  display: flex;
  width: fit-content;
  max-width: 100%;
  flex-wrap: wrap;
  gap: 0.45rem 0.9rem;
  align-items: center;
  margin: 0.95rem 0 1.15rem;
  padding: 0.48rem 0.65rem;
  border: 1px solid rgba(122, 84, 43, 0.18);
  border-radius: 0.55rem;
  background: rgba(246, 234, 214, 0.28);
  color: var(--muted);
  font-size: 0.94rem;
}

.available-updated {
  font-weight: 700;
}

.available-print-link {
  flex: 0 0 auto;
  font-size: 0.94rem;
}

.available-print-page {
  max-width: 780px;
}

.available-print-header {
  margin-bottom: 1.35rem;
}

.available-print-updated {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-weight: 700;
}

.print-page-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 1rem;
  align-items: center;
  margin-top: 1rem;
}

.available-print-list {
  width: 100%;
  font-variant-numeric: tabular-nums;
}

.available-print-row {
  display: grid;
  grid-template-columns: minmax(6rem, 0.7fr) minmax(0, 1.5fr) auto;
  gap: 0.75rem;
  align-items: baseline;
  padding: 0.42rem 0.55rem;
  border-bottom: 1px solid var(--line);
}

.available-print-row:first-child {
  border-top: 1px solid var(--line);
}

.available-print-row:nth-child(even) {
  background: rgba(239, 231, 218, 0.28);
}

.available-print-row-header {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.available-print-id {
  font-weight: 700;
}

.available-print-place {
  min-width: 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.available-print-price {
  flex: 0 0 auto;
  white-space: nowrap;
  text-align: right;
}

.inquiry-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
}

.inquiry-count {
  margin: 0 0 0.8rem;
  font-weight: 800;
}

.inquiry-warning {
  margin: 0.35rem 0 0;
  color: #8b3a26;
  font-weight: 700;
}

.want-list {
  margin: 0;
}

.want-list-label {
  display: block;
  margin-bottom: 0.25rem;
  font-weight: 800;
}

.want-list-help {
  margin: 0 0 0.65rem;
  color: var(--muted);
  font-size: 0.94rem;
}

.want-list-example {
  margin-top: 0.35rem;
  font-size: 0.88rem;
  line-height: 1.45;
}

.want-list-input {
  display: block;
  width: 100%;
  min-height: 7rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  background: var(--panel);
  color: var(--text);
  font: inherit;
  resize: vertical;
}

.want-list-input:focus {
  outline: 2px solid rgba(107, 79, 47, 0.35);
  outline-offset: 2px;
}

.want-list-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 0.75rem;
}

.want-list-result {
  margin: 0.75rem 0 0;
  color: var(--muted);
  font-weight: 700;
}

.want-list-result:empty {
  display: none;
}

.matched-tokens-summary {
  max-width: 700px;
  margin: 0 0 0.75rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem 0.5rem 0.35rem 0.35rem;
  background: rgba(239, 231, 218, 0.35);
}

.matched-tokens-summary[hidden],
.matched-tokens-list[hidden] {
  display: none;
}

.matched-tokens-summary h2 {
  margin: 0 0 0.25rem;
  font-size: 1rem;
}

.matched-tokens-summary p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
}

.matched-tokens-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.55rem;
}

.matched-token-link {
  display: inline-flex;
  padding: 0.2rem 0.48rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
}

.matched-token-link:hover,
.matched-token-link:focus-visible {
  border-color: var(--interactive-border);
  background: var(--soft);
}

.inquiry-dialog[hidden],
.inquiry-list[hidden],
.inquiry-empty[hidden] {
  display: none;
}

.inquiry-dialog {
  position: fixed;
  z-index: 40;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.inquiry-dialog-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(49, 34, 19, 0.38);
}

.inquiry-panel {
  position: relative;
  z-index: 1;
  display: flex;
  width: min(100%, 760px);
  max-height: min(82vh, 720px);
  flex-direction: column;
  padding: 1rem;
  border: 1px solid rgba(122, 84, 43, 0.28);
  border-radius: 0.65rem;
  background:
    linear-gradient(
      180deg,
      rgba(255, 253, 248, 0.99),
      rgba(250, 244, 233, 0.98)
    );
  box-shadow: 0 24px 72px rgba(49, 34, 19, 0.28);
}

body.has-inquiry-dialog {
  overflow: hidden;
}

.inquiry-panel-header {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  justify-content: space-between;
}

.inquiry-panel h2 {
  margin: 0 0 0.25rem;
  color: var(--text);
  font-size: 1.05rem;
}

.inquiry-panel .inquiry-count {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.45rem;
  align-items: baseline;
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.inquiry-count-total::before {
  content: "\00b7";
  margin-right: 0.45rem;
}

.inquiry-dialog-close {
  min-width: 2.75rem;
  min-height: 2.4rem;
  padding: 0.35rem 0.7rem;
  border: 1px solid rgba(122, 84, 43, 0.22);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.8);
  color: var(--accent);
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 800;
}

.inquiry-dialog-close:hover,
.inquiry-dialog-close:focus-visible {
  border-color: var(--interactive-border);
  background: var(--soft);
}

.inquiry-help {
  margin: 0.3rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.4;
}

.inquiry-list {
  min-height: 0;
  margin-top: 0.85rem;
  border: 1px solid rgba(217, 210, 197, 0.82);
  border-radius: 0.45rem;
  background: rgba(255, 253, 248, 0.72);
  overflow: auto;
  overscroll-behavior: contain;
}

.inquiry-panel > .inquiry-actions {
  justify-content: flex-end;
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(217, 210, 197, 0.72);
}

.inquiry-panel > .inquiry-actions .btn {
  min-height: 2.5rem;
}

.inquiry-copy-status {
  flex: 0 0 auto;
  margin: 0.55rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.inquiry-copy-status[hidden] {
  display: none;
}

.inquiry-list-header {
  display: grid;
  grid-template-columns: minmax(5.5rem, 0.8fr) minmax(9rem, 1.4fr) minmax(4.5rem, 0.55fr) auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.42rem 0.65rem;
  border-bottom: 1px solid rgba(217, 210, 197, 0.82);
  background: rgba(246, 234, 214, 0.44);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.inquiry-list-row {
  display: grid;
  grid-template-columns: minmax(5.5rem, 0.8fr) minmax(9rem, 1.4fr) minmax(4.5rem, 0.55fr) auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.5rem 0.65rem;
  min-height: 2.55rem;
  border-bottom: 1px solid rgba(217, 210, 197, 0.62);
}

.inquiry-list-row:last-child {
  border-bottom: 0;
}

.inquiry-list-details {
  display: grid;
  grid-template-columns: minmax(5.5rem, 0.85fr) minmax(8rem, 1.35fr);
  gap: 0.75rem;
  align-items: baseline;
  min-width: 0;
}

.inquiry-list-token {
  color: var(--accent);
  font-weight: 800;
  text-decoration: none;
}

.inquiry-list-token:hover,
.inquiry-list-token:focus-visible {
  text-decoration: underline;
}

.inquiry-list-meta {
  display: contents;
}

.inquiry-list-region {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--text);
}

.inquiry-list-price {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.inquiry-list-value {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 0.12rem;
}

.inquiry-list-box {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.15;
  white-space: nowrap;
}

.inquiry-list-remove {
  min-width: 2.25rem;
  min-height: 2.25rem;
  padding: 0.35rem 0.65rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.2;
}

.inquiry-list-remove:hover,
.inquiry-list-remove:focus-visible {
  border-color: var(--interactive-border);
  background: var(--soft);
}

.inquiry-empty {
  margin-top: 0.85rem;
  padding: 0.75rem 0.8rem;
  border: 1px dashed rgba(122, 84, 43, 0.26);
  border-radius: 0.45rem;
  background: rgba(255, 253, 248, 0.58);
  color: var(--muted);
  font-size: 0.94rem;
}

.inquiry-empty p {
  margin: 0;
}

.inquiry-empty p + p {
  margin-top: 0.2rem;
}

.inquiry-clear-confirm {
  flex: 0 0 auto;
  margin-top: 0.85rem;
  padding: 0.75rem 0.8rem;
  border: 1px solid rgba(122, 84, 43, 0.3);
  border-radius: 0.45rem;
  background: rgba(246, 234, 214, 0.58);
  color: var(--text);
}

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

.inquiry-clear-confirm p {
  margin: 0;
  font-weight: 800;
}

.inquiry-clear-confirm-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.65rem;
}

.inquiry-clear-confirm .btn.danger {
  border-color: rgba(122, 84, 43, 0.5);
  background: rgba(122, 84, 43, 0.12);
  color: var(--accent);
}

.inquiry-clear-confirm .btn.danger:hover,
.inquiry-clear-confirm .btn.danger:focus-visible {
  border-color: var(--interactive-border);
  background: rgba(122, 84, 43, 0.18);
}

.inquiry-sticky {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  left: 1rem;
  z-index: 20;
  display: flex;
  justify-content: center;
  pointer-events: none;
}

.inquiry-sticky[hidden] {
  display: none;
}

.inquiry-sticky-inner {
  display: flex;
  width: min(100%, 760px);
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0.85rem;
  border: 1px solid rgba(122, 84, 43, 0.34);
  border-radius: 0.75rem;
  background:
    linear-gradient(
      180deg,
      rgba(255, 253, 248, 0.98),
      rgba(246, 234, 214, 0.96)
    );
  box-shadow: 0 16px 36px rgba(82, 58, 32, 0.18);
  pointer-events: auto;
}

.inquiry-sticky-summary {
  margin: 0;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 800;
}

.inquiry-sticky-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  justify-content: flex-end;
}

body.has-inquiry-sticky {
  padding-bottom: 5.25rem;
}

.inquiry-toggle {
  justify-self: end;
  padding: 0.38rem 0.65rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  color: var(--accent);
  cursor: pointer;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.inquiry-toggle:hover,
.inquiry-toggle:focus-visible {
  border-color: var(--interactive-border);
  background: var(--soft);
}

.inquiry-toggle.is-selected {
  border-color: var(--accent);
  background: var(--accent);
  color: #fffaf4;
}

.btn:disabled,
.btn[aria-disabled="true"],
.inquiry-toggle:disabled {
  cursor: not-allowed;
  opacity: 0.58;
  transform: none;
  box-shadow: none;
}

.for-sale-group {
  margin-bottom: 1rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: var(--panel);
  overflow: hidden;
}

.for-sale-group summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 0.35rem 0.75rem;
  align-items: baseline;
  cursor: pointer;
  padding: 0.85rem 1rem;
  font-weight: 800;
  background: rgba(239, 231, 218, 0.45);
  list-style: none;
}

.for-sale-group summary::-webkit-details-marker {
  display: none;
}

.for-sale-group summary::before {
  content: "▸";
  color: var(--accent);
  font-size: 0.9em;
  line-height: 1;
  transform: translateY(-0.03em);
}

.for-sale-group[open] summary::before {
  content: "▾";
}

.for-sale-group summary .for-sale-group-name {
  color: var(--text);
  font-weight: 800;
}

.for-sale-group summary .for-sale-group-meta {
  color: var(--muted);
  font-weight: 600;
  text-align: right;
}

.for-sale-items {
  border-top: 1px solid var(--line);
}

.for-sale-list-header {
  display: grid;
  grid-template-columns: minmax(7rem, 0.75fr) minmax(10rem, 1.25fr) auto auto;
  gap: 1.5rem;
  padding: 0.5rem 1rem 0.42rem;
  border-bottom: 1px solid rgba(217, 210, 197, 0.78);
  background: rgba(255, 250, 242, 0.72);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.for-sale-list-header span:nth-child(3) {
  text-align: right;
}

.for-sale-list-header span:nth-child(4) {
  text-align: center;
}

.for-sale-item {
  display: grid;
  grid-template-columns: minmax(7rem, 0.75fr) minmax(10rem, 1.25fr) auto auto;
  gap: 1.5rem;
  align-items: flex-start;
  padding: 0.45rem 1rem;
  border-bottom: 1px solid rgba(217, 210, 197, 0.65);
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}

.for-sale-group[hidden],
.for-sale-list[hidden],
.for-sale-item[hidden],
#for-sale-empty[hidden] {
  display: none;
}

/* Alternating row color for easier scanning */
.for-sale-item:nth-child(even) {
  background: rgba(239, 231, 218, 0.32);
}

.for-sale-item:not(.is-selected):hover,
.for-sale-item:not(.is-selected):focus-within {
  background: rgba(246, 234, 214, 0.56);
  border-bottom-color: var(--interactive-border);
  box-shadow: inset 3px 0 0 rgba(122, 84, 43, 0.16);
}

.for-sale-item.is-selected {
  border-left: 4px solid var(--accent);
  background: rgba(239, 231, 218, 0.74);
  box-shadow: inset 0 0 0 1px rgba(122, 84, 43, 0.18);
}

.for-sale-item.is-selected:hover,
.for-sale-item.is-selected:focus-within {
  background: rgba(239, 231, 218, 0.86);
}

.for-sale-item:last-child {
  border-bottom: 0;
}

.for-sale-token-info {
  display: contents;
}

.for-sale-id {
  font-weight: 700;
  font-style: normal;
  letter-spacing: 0.02em;
}

.for-sale-place {
  min-width: 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.for-sale-price {
  white-space: nowrap;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.for-sale-search {
  max-width: 700px;
  margin: 1.25rem 0 1rem;
}

.for-sale-search label {
  display: block;
  margin-bottom: 0.35rem;
  font-weight: 800;
}

.for-sale-search input {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  background: var(--panel);
  color: var(--text);
  font: inherit;
}

.for-sale-search input:focus {
  outline: 2px solid rgba(107, 79, 47, 0.35);
  outline-offset: 2px;
}

.for-sale-results-summary {
  display: flex;
  flex-direction: column;
  max-width: none;
  gap: 0.45rem;
  align-items: flex-start;
  margin-bottom: 0.85rem;
}

.for-sale-group-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.35;
}

.for-sale-group-actions-label {
  margin-right: 0.15rem;
  color: var(--muted);
  font-weight: 800;
  letter-spacing: 0.01em;
}

.for-sale-group-action {
  min-height: 1.85rem;
  padding: 0.22rem 0.62rem;
  border: 1px solid rgba(122, 84, 43, 0.24);
  border-radius: 999px;
  background: rgba(255, 250, 242, 0.72);
  color: var(--accent);
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1.2;
}

.for-sale-group-action:hover,
.for-sale-group-action:focus-visible {
  border-color: var(--interactive-border);
  background: rgba(239, 231, 218, 0.68);
  color: var(--accent-strong);
}

.for-sale-group-action:focus-visible {
  outline: 3px solid rgba(116, 88, 54, 0.28);
  outline-offset: 2px;
}

.for-sale-group-action:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.for-sale-empty {
  margin-top: 1rem;
  padding: 0.95rem 1rem;
  border: 1px solid rgba(122, 84, 43, 0.28);
  border-left: 4px solid rgba(122, 84, 43, 0.42);
  border-radius: 0.55rem;
  background: rgba(246, 234, 214, 0.46);
  color: var(--text);
}

.for-sale-empty p {
  margin: 0;
}

.for-sale-empty-title {
  font-weight: 800;
}

.for-sale-empty-query,
.for-sale-empty-help {
  margin-top: 0.35rem;
  color: var(--muted);
  line-height: 1.45;
}

@media (max-width: 640px) {
  .available-utility-row {
    width: auto;
    align-items: flex-start;
    flex-direction: column;
    gap: 0.35rem;
  }

  .available-updated {
    display: block;
  }

  .available-mode-switch {
    display: grid;
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.2rem;
    padding: 0.2rem;
    border-radius: 0.55rem;
    overflow: visible;
  }

  .available-mode-button {
    min-height: 2.5rem;
    padding: 0.55rem 0.6rem;
    border-radius: 0.4rem;
    font-size: 0.94rem;
    line-height: 1.2;
  }

  .for-sale-item {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    padding: 0.5rem 0.75rem;
  }

  .for-sale-group summary {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .for-sale-group summary .for-sale-group-meta {
    grid-column: 2;
    text-align: left;
  }

  .for-sale-list-header {
    display: none;
  }

  .for-sale-item.is-selected {
    padding-left: calc(0.75rem - 4px);
  }

  .for-sale-token-info {
    display: flex;
    min-width: 0;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 0.12rem;
    align-items: flex-start;
  }

  .for-sale-price {
    color: var(--muted);
    font-size: 0.88rem;
    text-align: left;
  }

  .for-sale-item .inquiry-toggle {
    flex: 0 0 auto;
    padding: 0.38rem 0.7rem;
    font-size: 0.9rem;
    text-align: center;
  }

  .inquiry-dialog {
    align-items: flex-end;
    padding: 0;
  }

  .inquiry-panel {
    width: 100%;
    max-height: min(86vh, 720px);
    padding: 0.85rem;
    border-radius: 0.85rem 0.85rem 0 0;
  }

  .inquiry-panel-header {
    gap: 0.75rem;
  }

  .inquiry-panel-header > div {
    min-width: 0;
  }

  .inquiry-panel h2 {
    padding-right: 0.25rem;
    font-size: 1rem;
    line-height: 1.2;
  }

  .inquiry-panel .inquiry-count {
    display: grid;
    gap: 0.08rem;
    font-size: 0.9rem;
    line-height: 1.25;
  }

  .inquiry-count-total::before {
    content: "";
    margin-right: 0;
  }

  .inquiry-help {
    margin-top: 0.35rem;
    font-size: 0.88rem;
    line-height: 1.35;
  }

  .inquiry-dialog-close {
    display: inline-grid;
    width: 2.75rem;
    min-width: 2.75rem;
    height: 2.75rem;
    min-height: 2.75rem;
    flex: 0 0 auto;
    place-items: center;
    padding: 0;
    border-radius: 50%;
    font-size: 0;
    line-height: 1;
  }

  .inquiry-dialog-close::before {
    content: "\00d7";
    color: currentColor;
    font-size: 1.55rem;
    font-weight: 700;
    line-height: 1;
    transform: translateY(-0.03em);
  }

  .inquiry-dialog-close-text {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  .inquiry-panel > .inquiry-actions {
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.55rem;
  }

  .inquiry-panel > .inquiry-actions .btn {
    text-align: center;
  }

  .inquiry-clear-confirm {
    padding: 0.65rem;
  }

  .inquiry-clear-confirm-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
  }

  .inquiry-clear-confirm-actions .btn {
    text-align: center;
  }

  .inquiry-sticky {
    right: 0.65rem;
    bottom: 0.65rem;
    left: 0.65rem;
  }

  .inquiry-sticky-inner {
    flex-direction: column;
    gap: 0.65rem;
    align-items: stretch;
    padding: 0.7rem;
  }

  .inquiry-sticky-summary {
    text-align: center;
  }

  .inquiry-sticky-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
  }

  .inquiry-sticky-actions .btn {
    padding-right: 0.75rem;
    padding-left: 0.75rem;
    text-align: center;
  }

  body.has-inquiry-sticky {
    padding-bottom: 8.25rem;
  }

  .inquiry-list-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.16rem 0.55rem;
    min-height: 0;
    padding: 0.48rem 0.55rem;
  }

  .inquiry-list-header {
    display: none;
  }

  .inquiry-list-token {
    grid-column: 1;
    grid-row: 1;
  }

  .inquiry-list-region {
    min-width: 0;
  }

  .inquiry-list-meta {
    display: flex;
    grid-column: 1;
    grid-row: 2;
    min-width: 0;
    flex-wrap: wrap;
    gap: 0.12rem 0.35rem;
    align-items: baseline;
  }

  .inquiry-list-meta .inquiry-list-price::before {
    content: "Price:";
    margin-right: 0.35rem;
    font-weight: 700;
  }

  .inquiry-list-region,
  .inquiry-list-price,
  .inquiry-list-box {
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.25;
  }

  .inquiry-list-value {
    gap: 0.04rem;
  }

  .inquiry-list-remove {
    grid-column: 2;
    grid-row: 1 / span 2;
    min-width: 2.5rem;
    min-height: 2.5rem;
    align-self: center;
  }

  .want-list-actions .btn {
    flex: 1;
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .card-link .card,
  .card-link .resource-card,
  .hero-feature-card,
  .browse-card,
  .token-pager-link,
  .browse-chip,
  .token-list-card-image,
  .token-image,
  .for-sale-item {
    transition: none;
  }

  .card-link:hover .card,
  .card-link:hover .resource-card,
  .card-link:focus-visible .card,
  .card-link:focus-visible .resource-card,
  .hero-feature .card-link:hover .hero-feature-card,
  .hero-feature .card-link:focus-visible .hero-feature-card,
  .browse-card:hover,
  .browse-card:focus-within,
  .token-pager-link:hover,
  .token-pager-link:focus-visible,
  .card-link:hover .token-list-card-image,
  .card-link:focus-visible .token-list-card-image,
  .browse-card-link:hover .token-list-card-image,
  .browse-card-link:focus-visible .token-list-card-image,
  .token-image-button:hover .token-image,
  .token-image-button:focus-visible .token-image,
  .browse-chip:hover {
    transform: none;
  }
}

@media (max-width: 520px) {
  .footer-note {
    max-width: 100%;
  }

  .footer-nav {
    display: grid;
    grid-template-columns: repeat(3, max-content);
    gap: 0.35rem 0.9rem;
    justify-content: flex-start;
    max-width: 100%;
  }

  .footer-nav a {
    font-size: 0.88rem;
    line-height: 1.2;
    opacity: 0.82;
  }
}

@media (max-width: 340px) {
  .footer-nav {
    grid-template-columns: repeat(2, max-content);
  }
}

@media print {
  :root {
    --bg: #ffffff;
    --panel: #ffffff;
    --line: #000000;
    --text: #000000;
    --muted: #000000;
    --accent: #000000;
  }

  body {
    background: #ffffff;
    color: #000000;
    font-size: 10pt;
    line-height: 1.25;
  }

  .topbar,
  .footer,
  .print-page-nav,
  .print-page-actions {
    display: none !important;
  }

  .shell {
    max-width: none;
    padding: 0;
  }

  .section,
  .available-print-page {
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: #ffffff;
    box-shadow: none;
  }

  .available-print-header {
    margin-bottom: 0.35in;
  }

  h1 {
    margin-bottom: 0.12in;
    color: #000000;
    font-size: 18pt;
    line-height: 1.1;
  }

  .section-intro,
  .available-print-updated {
    margin: 0 0 0.08in;
    color: #000000;
  }

  .available-print-list {
    column-count: 2;
    column-gap: 1rem;
    width: 100%;
    font-variant-numeric: tabular-nums;
  }

  .available-print-row {
    display: grid;
    grid-template-columns: minmax(0.62in, 0.7fr) minmax(0, 1.55fr) auto;
    gap: 0.08in;
    align-items: baseline;
    break-inside: avoid;
    page-break-inside: avoid;
    padding: 2px 0;
    border-top: 0;
    border-bottom: 1px solid #dddddd;
    background: #ffffff;
    color: #000000;
    font-size: 9pt;
    line-height: 1.15;
  }

  .available-print-row:first-child {
    border-top: 0;
  }

  .available-print-id {
    min-width: 0;
    font-weight: 700;
  }

  .available-print-row-header {
    font-size: 7.5pt;
    letter-spacing: 0;
  }

  .available-print-place {
    min-width: 0;
    color: #000000;
    overflow-wrap: anywhere;
  }

  .available-print-price {
    flex: 0 0 auto;
    white-space: nowrap;
    text-align: right;
  }
}

@media (max-width: 390px) {
  .nav {
    gap: 3px;
    font-size: 0.78rem;
  }

  .nav a {
    padding: 0.2rem 0.34rem;
  }
}
