/* The collection page: your train, your boxes, and every part there is. */

.col { display: block; padding-top: 28px; padding-bottom: 72px; }
.col h1 { margin: 0; font-size: 44px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.05; }
.col h2 { margin: 0; font-size: 26px; font-weight: 800; letter-spacing: -0.02em; }
.col h3 { margin: 30px 0 0; font-size: 16px; font-weight: 800; }
.col-lead { margin: 8px 0 0; max-width: 640px; font-size: 15px; line-height: 1.55; color: var(--muted); }
.col-note { margin: 10px 0 0; min-height: 20px; font-size: 14px; line-height: 1.45; color: var(--muted); }
.col-note.warn { color: #fde68a; }

/* Sections sit on solid cards, so the map behind the page never fights the parts. */
.col-hero, .col-wardrobe, .col-odds, .col-gate {
  padding: 32px;
  border-radius: 28px;
  background: var(--card);
  border: 1px solid var(--line);
}
.col-wardrobe, .col-odds { margin-top: 20px; }
.col-gate { max-width: 560px; margin: 40px auto 0; }
.col-gate p { margin: 14px 0 0; font-size: 16px; line-height: 1.55; color: var(--muted); }

/* ---- your train ---- */
.col-hero { display: flex; flex-wrap: wrap; align-items: center; gap: 28px 48px; }
.col-stage { position: relative; flex: none; width: 340px; max-width: 100%; margin: 0 auto; text-align: center; }
.col-stage .look { display: block; margin: 0 auto; max-width: 100%; }
.col-stage .look-car { cursor: grab; }
.col-stage .look-car:active { cursor: grabbing; }
.col-glow { position: absolute; inset: -8% -8% 4%; border-radius: 50%; background: radial-gradient(closest-side, var(--accent), transparent); opacity: 0.2; pointer-events: none; }
.col-hint { position: relative; margin: 12px 0 0; font-size: 13px; color: var(--muted); }
.col-side { flex: 1 1 380px; min-width: 0; }
.col-sub { margin: 10px 0 0; font-size: 16px; line-height: 1.5; color: var(--soft); }
.col-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.col-actions .button { width: auto; min-width: 190px; margin-top: 0; padding: 0 26px; }

.col-boxes {
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px 18px;
  margin-top: 26px; padding: 18px 20px;
  border-radius: 20px;
  background: var(--field); border: 1px solid var(--field-line);
}
/* A small parcel, drawn with two boxes and a ribbon. */
.col-box-art { position: relative; width: 54px; height: 50px; flex: none; }
.col-box-art::before { content: ''; position: absolute; left: 4px; right: 4px; bottom: 0; height: 32px; border-radius: 7px; background: linear-gradient(180deg, #7c3aed, #5b21b6); }
.col-box-art::after { content: ''; position: absolute; left: 0; right: 0; top: 6px; height: 16px; border-radius: 6px; background: #a78bfa; }
.col-box-art span { position: absolute; left: 22px; top: 6px; bottom: 0; width: 10px; background: #fde68a; z-index: 1; border-radius: 2px; }
.col-box-text { flex: 1 1 180px; min-width: 0; }
.col-box-count { font-size: 17px; color: var(--soft); }
.col-box-count strong { font-size: 26px; font-weight: 800; color: var(--text); }
.col-box-text .col-note { margin-top: 2px; min-height: 0; }
.col-boxes .button { width: auto; min-width: 170px; margin-top: 0; padding: 0 26px; }

/* Which box to open next, when the person holds boxes of more than one set. */
.col-box-sets { flex: 1 1 100%; display: flex; flex-wrap: wrap; gap: 8px; }
.col-box-sets[hidden] { display: none; }
.col-box-sets .col-tab { height: 34px; padding: 0 14px; background: #101015; font-size: 13px; }
.col-box-sets .col-tab[aria-pressed='true'] { background: rgba(167, 139, 250, 0.18); }

/* ---- parts ---- */
.col-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.col-tab {
  height: 40px; padding: 0 16px;
  border: 0; border-radius: 20px;
  background: var(--field); color: var(--muted);
  font: inherit; font-size: 14px; font-weight: 800;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}
.col-tab:hover { color: var(--text); }
.col-tab[aria-pressed='true'] { background: rgba(167, 139, 250, 0.18); color: var(--accent); }
.col-tab small { margin-left: 6px; font-size: 12px; font-weight: 700; opacity: 0.8; }

.col-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 12px; margin-top: 20px; }
.col-tile {
  position: relative;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 14px 8px 12px;
  border: 2px solid transparent; border-radius: 20px;
  background: var(--field); color: var(--text);
  font: inherit; text-align: center;
  cursor: pointer;
  transition: transform 140ms ease, border-color 140ms ease, background 140ms ease;
}
.col-tile:hover { transform: translateY(-2px); background: #20202a; }
.col-tile[aria-pressed='true'] { border-color: var(--accent); background: #1d1a2c; }
/* The name takes whatever room is left in the tile. Tiles in a row are the same height, so the
   lines under the name (rarity, price) sit at the same level on every one of them, whether a
   name runs to one line or two. A name that runs to two is split evenly. */
.col-tile-name { flex: 1 0 auto; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 800; line-height: 1.2; text-wrap: balance; }
.col-tile-tier { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; color: var(--tier, var(--muted)); }
.col-tile-count {
  position: absolute; top: 8px; right: 8px;
  min-width: 22px; height: 22px; padding: 0 6px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 11px;
  background: var(--accent); color: var(--accent-ink);
  font-size: 11px; font-weight: 800;
}
/* A part of a limited set, which the site calls a "Private set" (only so many ever made, numbered, sold in the shop): it wears
   its own label, white on black with a fine white edge, apart from the six rarity colors.
   A fine line all the way round the tile, never a strip down one side. */
.limited-label {
  display: inline-block; padding: 3px 9px;
  border: 1px solid rgba(255, 255, 255, 0.85); border-radius: 999px;
  background: #050505; color: #ffffff;
  font-size: 10px; font-weight: 800; letter-spacing: 0.09em; line-height: 1.3; text-transform: uppercase; white-space: nowrap;
}
/* On a tile the label sits over the top edge of the picture, so the picture and the words stay level with the tiles beside it. */
.limited-label.on-tile { position: absolute; top: 5px; left: 50%; z-index: 1; transform: translateX(-50%); padding: 1px 7px; font-size: 9px; }
.col-tile.of-limited-set { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28); }
.col-tile.of-limited-set .col-tile-lock { top: 7px; left: 7px; }
.col-tile-limited { color: #ffffff; letter-spacing: 0; text-transform: none; font-size: 10.5px; }
.col-tile.locked .col-tile-limited { color: var(--muted); }

/* A part the person does not own yet: there to be wanted, and to try on. */
.col-tile.locked .look { filter: saturate(0.55) brightness(0.8); }
.col-tile.locked .col-tile-name { color: var(--muted); }
.col-tile-lock {
  position: absolute; top: 9px; left: 9px;
  width: 20px; height: 20px;
  border-radius: 10px; background: #0b0b0f;
}
.col-tile-lock::before { content: ''; position: absolute; left: 5px; top: 9px; width: 10px; height: 7px; border-radius: 2px; background: var(--muted); }
.col-tile-lock::after { content: ''; position: absolute; left: 7px; top: 4px; width: 6px; height: 7px; border: 2px solid var(--muted); border-bottom: 0; border-radius: 4px 4px 0 0; box-sizing: border-box; }
.col-none { width: 76px; height: 76px; display: flex; align-items: center; justify-content: center; border-radius: 50%; border: 2px dashed var(--field-line); color: var(--muted); font-size: 13px; font-weight: 700; }

/* ---- what is in a box ---- */
.col-set-blurb { margin: 16px 0 0; font-size: 16px; line-height: 1.5; color: var(--soft); }
.col-set-blurb b { font-weight: 800; color: var(--text); }
.col-odds .col-tabs { margin-top: 18px; }
.col-tiers { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-top: 20px; }
/* Rarity is told by the color of its name, and nothing else. No colored strip
   down one side of a card, here or anywhere: the founder ruled it out. */
.col-tier { padding: 16px 18px; border-radius: 18px; background: var(--field); }
.col-tier-name { font-size: 12px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; color: var(--tier); }
.col-tier-chance { margin-top: 4px; font-size: 26px; font-weight: 800; }
.col-tier-parts { margin-top: 2px; font-size: 13px; color: var(--muted); }
.col-earn { margin: 12px 0 0; padding: 0 0 0 20px; color: var(--soft); font-size: 15px; line-height: 1.7; }
.col-earn strong { color: var(--text); }

/* ---- opening a box ---- */
.col-overlay { position: fixed; inset: 0; z-index: 20; display: flex; align-items: center; justify-content: center; padding: 20px; background: rgba(4, 4, 7, 0.93); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.col-open { width: 100%; max-width: 860px; }
.col-reel-window { position: relative; height: 196px; overflow: hidden; border-radius: 24px; background: var(--card); border: 1px solid var(--line); }
.col-reel-window::before, .col-reel-window::after { content: ''; position: absolute; top: 0; bottom: 0; width: 120px; z-index: 2; pointer-events: none; }
.col-reel-window::before { left: 0; background: linear-gradient(90deg, var(--card), transparent); }
.col-reel-window::after { right: 0; background: linear-gradient(270deg, var(--card), transparent); }
.col-reel { position: absolute; left: 0; top: 22px; display: flex; gap: 12px; will-change: transform; }
.col-reel.rolling { transition: transform 5600ms cubic-bezier(0.1, 0.72, 0.08, 1); }
.col-card { width: 132px; height: 152px; flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; border-radius: 18px; background: var(--field); }
/* On the strip, the part's name carries the color of its rarity. */
.col-card .col-card-name { color: var(--tier); }
.col-card-name { max-width: 116px; font-size: 12px; font-weight: 800; text-align: center; line-height: 1.2; }
.col-reel-mark { position: absolute; left: 50%; top: 0; bottom: 0; width: 3px; margin-left: -1.5px; z-index: 3; background: var(--accent); box-shadow: 0 0 14px var(--accent); }

.col-reveal { margin-top: 26px; display: flex; flex-direction: column; align-items: center; text-align: center; animation: col-rise 420ms cubic-bezier(0.22, 1, 0.36, 1); }
@keyframes col-rise { from { transform: translateY(18px); opacity: 0; } to { transform: none; opacity: 1; } }
.col-reveal-art { position: relative; }
.col-reveal-art::before { content: ''; position: absolute; inset: -22%; border-radius: 50%; background: radial-gradient(closest-side, var(--tier), transparent); opacity: 0.4; }
.col-reveal-art .look { position: relative; }
.col-reveal-tier { margin-top: 18px; font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--tier); }
.col-reveal-name { margin-top: 4px; font-size: 34px; font-weight: 800; letter-spacing: -0.02em; }
.col-reveal-copy { margin-top: 4px; font-size: 14px; color: var(--muted); }
.col-reveal-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 22px; }
.col-reveal-actions .button { width: auto; min-width: 150px; margin-top: 0; padding: 0 24px; }

@media (max-width: 700px) {
  .col h1 { font-size: 34px; }
  .col-hero, .col-wardrobe, .col-odds, .col-gate { padding: 22px 18px; border-radius: 22px; }
  .col-stage { width: 280px; }
  .col-actions .button, .col-boxes .button { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .col-reel.rolling { transition: none; }
  .col-reveal { animation: none; }
  .col-tile { transition: none; }
}
