/* TOPCHESS guild shop — design-system tokens only, hard shadows, no gradients. */
.guild-shop-page { background: var(--tc-bg); color: var(--tc-ink); font-family: 'Nunito', system-ui, sans-serif; }
.shop-main {
  width: min(100% - 2rem, 55rem);
  margin-inline: auto;
  padding-block: clamp(1.25rem, 4vw, 3rem) 2.5rem;
}
.shop-back {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--tc-blue-text);
  font-weight: 700;
  text-decoration: none;
}
.shop-main h1 { margin: .25rem 0 0; font-size: clamp(1.55rem, 5vw, 2.25rem); line-height: 1.15; }
.shop-lead { margin: .5rem 0 1rem; color: var(--tc-ink-soft); max-width: 43rem; }
.shop-notice {
  max-width: 43rem;
  margin: 0 0 1rem;
  padding: .7rem .9rem;
  background: var(--tc-surface-2);
  border: 2px solid var(--tc-ink);
  border-radius: var(--tc-radius);
  font-weight: 700;
}
.shop-notice[hidden], .shop-balance[hidden], .shop-catalog[hidden], .shop-product[hidden] { display: none; }
.shop-balance { margin: 0 0 1rem; font-weight: 800; color: var(--tc-green-text); }
.shop-catalog { display: grid; gap: 1rem; }

.shop-product {
  display: grid;
  grid-template-columns: minmax(11rem, 1fr) 1.4fr;
  max-width: 43rem;
  overflow: hidden;
  background: var(--tc-surface);
  border: 2px solid var(--tc-ink);
  border-radius: 16px;
  box-shadow: 0 4px 0 var(--tc-ink);
}
.product-art {
  display: grid;
  place-items: center;
  min-height: 11rem;
  background: var(--tc-surface-2);
  border-inline-end: 2px solid var(--tc-ink);
}
.product-art img { width: clamp(7rem, 20vw, 10rem); height: auto; }
[data-style="frame"] .product-art img {
  border: 5px double var(--tc-gold-text);
  border-radius: 50%;
  background: var(--tc-surface);
}
[data-style="board"] .product-art img {
  padding: .5rem;
  background: var(--tc-gold);
  border: 2px solid var(--tc-ink);
  border-radius: 8px;
}
.product-details { align-self: center; padding: clamp(1rem, 4vw, 1.5rem); }
.product-details h2, .checkout h2 { margin: 0; font-size: 1.3rem; line-height: 1.2; }
.product-details p { margin: .45rem 0 1.1rem; color: var(--tc-ink-soft); }
.product-footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .65rem 1rem;
  justify-content: space-between;
}
.product-price { color: var(--tc-ink-soft); font-size: .9rem; font-weight: 700; }
.product-price strong { display: block; font-size: 1.45rem; color: var(--tc-ink); }

.shop-button {
  min-height: 48px;
  padding: .5rem 1rem;
  color: var(--tc-ink);
  background: var(--tc-gold);
  border: 2px solid var(--tc-ink);
  border-radius: 10px;
  box-shadow: 0 3px 0 var(--tc-ink);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  touch-action: manipulation;
  text-align: center;
  text-decoration: none;
}
.shop-button:hover:not(:disabled) { transform: translateY(1px); box-shadow: 0 2px 0 var(--tc-ink); }
.shop-button:disabled { background: var(--tc-surface-2); box-shadow: none; cursor: default; color: var(--tc-ink-soft); }
.shop-secondary { background: var(--tc-surface); }
.guild-shop-page :focus-visible { outline: 3px solid var(--tc-blue-text); outline-offset: 3px; }

.checkout {
  position: fixed;
  box-sizing: border-box;
  width: min(29rem, 100% - 2rem);
  max-height: calc(100dvh - 2rem);
  overflow: auto;
  padding: 1rem 1.25rem 1.5rem;
  background: var(--tc-surface);
  color: var(--tc-ink);
  border: 2px solid var(--tc-ink);
  border-radius: 16px;
  box-shadow: 0 4px 0 var(--tc-ink);
}
.checkout::backdrop { background: rgb(27 36 48 / 58%); }
.checkout-header { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.checkout-close {
  min-width: 44px;
  min-height: 44px;
  background: var(--tc-surface);
  color: var(--tc-ink);
  border: 2px solid var(--tc-ink);
  border-radius: 10px;
  font: inherit;
  font-size: 1.4rem;
  cursor: pointer;
}
.checkout-summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .4rem .65rem;
  margin-block: .8rem;
  padding: .6rem .75rem;
  background: var(--tc-surface-2);
  border-radius: 10px;
}
.checkout-summary img { width: 44px; height: 44px; object-fit: contain; }
.checkout-price { margin-inline-start: auto; color: var(--tc-ink-soft); font-weight: 800; }
.checkout-quote { margin: 0; font-weight: 800; }
.checkout-quote[hidden] { display: none; }
.checkout-copy { margin: .75rem 0 1rem; }
.checkout-actions { display: grid; gap: .75rem; }
.checkout-actions [hidden] { display: none; }
.checkout-wallets { display: grid; gap: .6rem; }
.checkout-wallets img { width: 24px; height: 24px; vertical-align: middle; margin-inline-end: .5rem; }

.shop-collection { margin-top: 2rem; max-width: 43rem; }
.shop-collection h2 { margin-block: 0 .4rem; }
.shop-collection p { color: var(--tc-ink-soft); margin-block: 0 .75rem; }
.collection-items { display: flex; flex-wrap: wrap; gap: .6rem; }
.collection-item {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .5rem .75rem;
  border: 2px solid var(--tc-ink);
  border-radius: 12px;
  background: var(--tc-surface);
  font-weight: 700;
}
.collection-item img { width: 36px; height: 36px; object-fit: contain; }

@media (max-width: 36rem) {
  .shop-product { grid-template-columns: minmax(0, 1fr); }
  .product-art { min-height: 9rem; border-inline-end: 0; border-bottom: 2px solid var(--tc-ink); }
  .product-footer { display: grid; justify-content: stretch; }
  .checkout {
    inset: auto 0 0;
    margin: 0;
    width: 100%;
    max-width: none;
    max-height: calc(100dvh - 1rem);
    border-radius: 16px 16px 0 0;
    padding-right: max(1rem, env(safe-area-inset-right));
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-bottom: calc(1.25rem + env(safe-area-inset-bottom));
  }
}
