/* Art index: same sky and denim as the mint page, but a working surface, so quiet and dense. */
.index-page { background: var(--sky-low); }
.index-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .6rem 1rem;
  background: var(--panel); border-bottom: 3px solid var(--frame); position: sticky; top: 0; z-index: 2; }
.home { display: flex; align-items: center; gap: .7rem; font: 900 1.5rem/1 var(--sign-font); color: var(--ink); text-decoration: none; }
.home img { width: 3.6rem; height: 2.4rem; object-fit: cover; border-radius: 4px; }
.who { font-size: .95rem; color: var(--muted); display: flex; gap: .6rem; align-items: center; }
.who button { border: 1px solid rgba(16, 42, 58, .25); background: #fff; border-radius: 999px; padding: .3rem .8rem; font: 600 .9rem var(--ui-font); cursor: pointer; }
.index-main { max-width: 82rem; margin: 0 auto; padding: 1.25rem 1rem 4rem; }

.gate { max-width: 30rem; margin: 3rem auto; text-align: center; }
.gate h1 { margin-bottom: .5rem; }

.tools { display: flex; flex-wrap: wrap; gap: .6rem 1rem; align-items: end; margin-bottom: 1rem; }
.tools label { display: grid; gap: .2rem; font-size: .85rem; font-weight: 600; color: var(--muted); }
.tools select, .tools input { font: 500 1rem var(--ui-font); padding: .4rem .5rem; border: 1px solid rgba(16, 42, 58, .3); border-radius: 6px; background: #fff; color: var(--ink); min-height: 2.5rem; }
.shown { margin-left: auto; font-weight: 600; }

.grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: .6rem; }
.grid button { display: block; width: 100%; padding: 0; border: 0; background: #fff; border-radius: 6px; overflow: hidden; cursor: pointer; text-align: left; color: var(--ink); }
.grid img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; background: #dfe9ee; }
.grid .cap { display: flex; justify-content: space-between; padding: .3rem .45rem; font-size: .82rem; font-weight: 600; }
.grid .cap span:last-child { color: var(--muted); font-weight: 500; }

.item { border: 0; padding: 0; border-radius: 12px; max-width: min(60rem, 96vw); width: 100%; background: var(--panel); color: var(--ink); }
.item::backdrop { background: rgba(16, 42, 58, .6); }
.item-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(16rem, 22rem); }
.item-body img { width: 100%; height: auto; display: block; aspect-ratio: 1; }
.item-info { padding: 1.1rem 1.2rem; display: flex; flex-direction: column; }
.item-info h2 { font: 900 2rem/1 var(--sign-font); margin: 0 0 .3rem; }
.rank { margin: 0 0 .8rem; color: var(--muted); }
.traits { border-collapse: collapse; width: 100%; font-size: .93rem; }
.traits th { text-align: left; font-weight: 600; color: var(--muted); padding: .2rem .3rem; border-bottom: 1px solid rgba(16, 42, 58, .2); }
.traits td { padding: .32rem .3rem; border-bottom: 1px solid rgba(16, 42, 58, .08); vertical-align: top; }
.traits td:last-child { text-align: right; white-space: nowrap; }
.traits tr.rare td:nth-child(2) { color: var(--frame); font-weight: 700; }
.item-nav { margin-top: auto; padding-top: 1rem; display: flex; gap: .5rem; }
.item-nav button { flex: 1; padding: .55rem; border: 1px solid rgba(16, 42, 58, .25); background: #fff; border-radius: 8px; font: 600 .95rem var(--ui-font); cursor: pointer; }

@media (max-width: 44rem) {
  .item-body { grid-template-columns: 1fr; }
  .shown { margin-left: 0; width: 100%; }
}

.trait-head { margin: 0 0 1rem; }
.trait-head h1 { font: 900 2.2rem/1 var(--sign-font); margin: 0 0 .25rem; }
.trait-head p { margin: 0 0 .3rem; color: var(--muted); }
.traits td a { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
.traits td a:hover { text-decoration-thickness: 2px; }
