:root {
  --bg: #f4f2ea;
  --ink: #1a1d29;
  --panel: #fffdf8;
  --line: #d7d1bf;
  --accent: #0d9488;
  --accent-2: #f97316;
  --muted: #5f6371;
  --good: #137a41;
  --bad: #9f1239;
  --shadow: 0 12px 42px rgba(15, 23, 42, 0.1);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at 10% 10%, #fffaf0, #f4f2ea 45%),
    radial-gradient(circle at 90% 90%, #e6f7f5, transparent 35%),
    var(--bg);
  color: var(--ink);
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  overflow-x: hidden;
}

.bg-orb {
  position: fixed;
  width: 480px;
  height: 480px;
  border-radius: 999px;
  pointer-events: none;
  filter: blur(60px);
  opacity: 0.3;
  z-index: -1;
}

.orb-a {
  top: -220px;
  left: -120px;
  background: #34d399;
}

.orb-b {
  right: -180px;
  bottom: -260px;
  background: #f59e0b;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.4rem;
  backdrop-filter: blur(14px);
  background: rgba(255, 253, 248, 0.72);
  border-bottom: 1px solid rgba(215, 209, 191, 0.75);
}

.brand {
  font-size: 1.1rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--ink);
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.brand i {
  color: var(--accent);
  font-size: 1.3rem;
}

nav {
  display: flex;
  gap: 0.5rem;
  flex: 1;
  justify-content: center;
}

nav a {
  text-decoration: none;
  color: var(--ink);
  font-size: 0.9rem;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: 160ms ease;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

nav a i {
  font-size: 1rem;
}

nav a:hover {
  border-color: var(--line);
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.5);
}

.nav-dropdown, .user-menu { position: relative; align-self: center; }
.nav-dropdown > summary, .user-menu > summary { list-style: none; }
.nav-dropdown > summary::-webkit-details-marker, .user-menu > summary::-webkit-details-marker { display: none; }
.nav-dropdown > summary { display: flex; align-items: center; gap: .45rem; padding: .55rem .9rem; border: 1px solid transparent; border-radius: 999px; cursor: pointer; font-size: .9rem; transition: 160ms ease; }
.nav-dropdown > summary:hover, .nav-dropdown[open] > summary { border-color: var(--line); background: rgba(255,255,255,.72); }
.nav-dropdown-chevron, .user-menu-chevron { margin-left: .05rem; font-size: .58rem !important; transition: transform .16s ease; }
.nav-dropdown[open] .nav-dropdown-chevron, .user-menu[open] .user-menu-chevron { transform: rotate(180deg); }
.nav-dropdown-panel, .user-menu-panel { position: absolute; z-index: 50; top: calc(100% + .5rem); display: grid; min-width: 290px; padding: .45rem; border: 1px solid var(--line); border-radius: 14px; background: rgba(255,253,248,.98); box-shadow: 0 18px 45px rgba(15,23,42,.18); backdrop-filter: blur(16px); }
.nav-dropdown-panel { left: 50%; transform: translateX(-50%); }
.nav-dropdown-panel a, .user-menu-panel a { display: grid; grid-template-columns: 34px minmax(0,1fr); gap: .6rem; align-items: center; padding: .58rem .65rem; border: 0; border-radius: 10px; color: var(--ink); text-decoration: none; }
.nav-dropdown-panel a:hover, .user-menu-panel a:hover { transform: none; border: 0; background: #eef8f6; }
.nav-dropdown-panel a > i, .user-menu-panel a > i { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: #e3f3f0; color: var(--accent); }
.nav-dropdown-panel a > span, .user-menu-panel a > span { display: grid; gap: .05rem; }
.nav-dropdown-panel a strong, .user-menu-panel a strong { font-size: .78rem; }
.nav-dropdown-panel a small, .user-menu-panel a small { color: var(--muted); font-size: .61rem; font-weight: 500; }
.nav-dropdown-label { padding: .35rem .65rem .25rem; color: var(--muted); font-size: .57rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }

.user-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.85rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #0f766e);
  color: white;
  font-size: 0.88rem;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(13, 148, 136, 0.25);
  border: 0;
  cursor: pointer;
}

.user-badge i {
  font-size: 1.1rem;
}

.user-menu-panel { right: 0; min-width: 255px; }
.user-menu-panel header { display: grid; gap: .05rem; margin: 0 .35rem .3rem; padding: .45rem .3rem .6rem; border-bottom: 1px solid var(--line); }
.user-menu-panel header span { color: var(--muted); font-size: .57rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.user-menu-panel header strong { font-size: .85rem; }
.user-menu-panel form { margin: .35rem .35rem 0; padding-top: .35rem; border-top: 1px solid var(--line); }
.user-menu-panel form button { display: flex; align-items: center; gap: .55rem; width: 100%; padding: .58rem .65rem; border: 0; border-radius: 9px; background: transparent; color: #b42318; font: 700 .75rem "Space Grotesk",sans-serif; cursor: pointer; }
.user-menu-panel form button:hover { background: #fff1f2; }

.page {
  width: min(1120px, 95vw);
  margin: 1.5rem auto 2rem;
  display: grid;
  gap: 1rem;
}

.page:has(.auctions-page) {
  width: min(1600px, 98vw);
}

.page:has(.movements-page) {
  width: min(1450px, 97vw);
}

.direct-offers-page { display: grid; gap: .75rem; }
.direct-offer-head { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(240px,.7fr) minmax(300px,1fr); align-items: end; gap: 1rem; padding: .85rem 1rem; }
.direct-offer-head h1 { margin: .1rem 0 0; }
.direct-player-search { position: relative; display: grid; gap: .25rem; }
.direct-player-search > span, .direct-offer-terms label > span:first-child { color: var(--muted); font-size: .72rem; font-weight: 700; }
.direct-player-search input { width: 100%; }
.direct-player-search > div { position: absolute; z-index: 30; top: calc(100% + .25rem); right: 0; left: 0; max-height: min(430px, 65vh); overflow-y: auto; padding: .35rem; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: var(--shadow); }
.direct-player-search > div button { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; align-items: center; gap: .65rem; width: 100%; padding: .45rem .55rem; border: 0; border-radius: 7px; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.direct-player-search > div button:hover { background: #eef8f6; }
.direct-player-search > div button > .fa-chevron-right { color: var(--muted); font-size: .7rem; }
.direct-player-result-photo { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; background: #eef2f1; }
.direct-player-result-copy { display: grid; gap: .1rem; min-width: 0; }
.direct-player-result-copy strong, .direct-player-result-copy small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.direct-player-result-copy small { display: flex; align-items: center; gap: .3rem; color: var(--muted); font-size: .72rem; }
.direct-player-result-team { width: 18px; height: 18px; object-fit: contain; }
.direct-offer-controls { display: grid; grid-template-columns: minmax(180px,.65fr) auto minmax(380px,1fr); align-items: end; gap: .75rem 1rem; padding: .7rem 1rem; }
.direct-offer-controls h2 { margin: .1rem 0 0; font-size: 1.05rem; }
.direct-rarity-filter { display: flex; flex-wrap: wrap; gap: .3rem; }
.direct-rarity-filter input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.direct-rarity-filter span { display: block; padding: .45rem .6rem; border: 1px solid var(--line); border-radius: 6px; background: #fff; color: var(--muted); font-size: .72rem; font-weight: 700; cursor: pointer; }
.direct-rarity-filter input:checked + span { border-color: var(--accent); background: #e8f7f4; color: var(--accent); }
.direct-offer-terms { display: grid; grid-template-columns: minmax(110px,1fr) minmax(110px,1fr) auto; align-items: end; gap: .45rem; }
.direct-offer-terms label { display: grid; gap: .25rem; }
.money-input { display: grid; grid-template-columns: 1fr auto; align-items: center; }
.money-input input { grid-column: 1 / -1; grid-row: 1; padding-right: 1.8rem; }
.money-input b { grid-column: 2; grid-row: 1; margin-right: .65rem; }
.direct-selection-summary { grid-column: 1 / -1; display: flex; align-items: center; gap: 1rem; padding-top: .45rem; border-top: 1px solid var(--line); font-size: .78rem; }
.direct-selection-summary span { color: var(--muted); }
.direct-payment-choice { margin-left: auto; }
.direct-payment-choice > span { color: var(--muted); }
.direct-offer-results { min-height: 250px; padding: .75rem 1rem; }
.direct-offer-empty { display: grid; min-height: 210px; place-items: center; align-content: center; gap: .6rem; color: var(--muted); }
.direct-offer-empty i { font-size: 1.6rem; color: var(--accent); }
.direct-offer-empty h2 { margin: 0; font-size: 1rem; }
.direct-offer-error { padding: .7rem; border: 1px solid #fecaca; border-radius: 8px; background: #fef2f2; color: var(--bad); }
.direct-offer-table-wrap { overflow-x: auto; }
.direct-offer-table { width: 100%; min-width: 760px; border-collapse: collapse; }
.direct-offer-table th, .direct-offer-table td { padding: .55rem; border-bottom: 1px solid var(--line); font-size: .8rem; text-align: left; }
.direct-card { display: flex; align-items: center; gap: .5rem; }
.direct-card img, .direct-card > span { width: 34px; height: 46px; object-fit: cover; border-radius: 4px; }
.direct-card div { display: grid; gap: .1rem; }
.direct-card small { color: var(--muted); }
.direct-sale-price { display: grid; gap: .1rem; }
.direct-sale-price small { color: var(--muted); font-size: .68rem; white-space: nowrap; }
.direct-rarity { display: inline-block; padding: .22rem .4rem; border-radius: 5px; background: #eee; font-size: .7rem; font-weight: 700; }
.direct-rarity.rarity-limited { background: #fff7d6; color: #8a6700; }
.direct-rarity.rarity-rare { background: #fee2e2; color: #b91c1c; }
.direct-rarity.rarity-super_rare { background: #dbeafe; color: #1d4ed8; }
.direct-rarity.rarity-unique { background: #111827; color: #fff; }
.direct-offer-status span { display: inline-flex; align-items: center; gap: .3rem; white-space: nowrap; }
.direct-offer-status .is-running { color: var(--accent); }
.direct-offer-status .is-success { color: var(--good); }
.direct-offer-status .is-error { color: var(--bad); }
.direct-offer-review-card h2 { margin: .1rem 0 .35rem; }
.direct-offer-review-card > p:not(.kicker) { margin-top: 0; color: var(--muted); }
.direct-offer-review-list { display: grid; gap: .45rem; margin: 1rem 0; }
.direct-offer-review-item { display: grid; grid-template-columns: minmax(130px,.65fr) minmax(180px,1fr); align-items: center; gap: .75rem; padding: .7rem; border: 1px solid var(--line); border-radius: 8px; }
.direct-offer-review-item > span:first-child { display: grid; gap: .15rem; }
.direct-offer-review-item small { color: var(--muted); }
.direct-offer-review-state { display: flex; align-items: center; gap: .4rem; font-size: .78rem; font-weight: 700; }
.direct-offer-review-item.is-compatible .direct-offer-review-state { color: var(--good); }
.direct-offer-review-item.is-blocked .direct-offer-review-state { color: var(--bad); }

@media (max-width: 600px) {
  .direct-offer-review-item { grid-template-columns: 1fr; gap: .4rem; }
  .direct-offer-review-state { align-items: flex-start; }
}

@media (max-width: 1500px) and (min-width: 781px) {
  .site-header nav { gap: .2rem; }
  .site-header nav > a { justify-content: center; width: 40px; padding: .55rem; }
  .site-header nav > a > span,
  .nav-dropdown > summary > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .nav-dropdown > summary { justify-content: center; width: 46px; padding: .55rem; }
  .nav-dropdown > summary .nav-dropdown-chevron { margin-left: -.2rem; }
}

.panel {
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.92), rgba(255, 250, 240, 0.96));
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
  padding: 1.1rem 1.2rem;
}

body.sales-export-pending .sales-edit-panel {
  display: none;
}

.hero h1 {
  margin: 0.2rem 0 0.5rem;
  font-size: clamp(1.45rem, 2.8vw, 2.25rem);
}

.hero-text {
  max-width: 70ch;
  color: var(--muted);
}

.kicker {
  margin: 0;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.card-grid {
  display: grid;
  gap: 0.9rem;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.module-card {
  display: grid;
  gap: 0.9rem;
  transition: all 240ms ease;
  position: relative;
  overflow: hidden;
}

.module-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  opacity: 0;
  transition: opacity 240ms ease;
}

.module-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 48px rgba(15, 23, 42, 0.15);
}

.module-card:hover::before {
  opacity: 1;
}

.module-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.7rem;
}

.module-head h2 {
  margin: 0;
  font-size: 1.12rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.module-head h2 i {
  color: var(--accent);
  font-size: 1.3rem;
}

.badge {
  font-size: 0.76rem;
  padding: 0.35rem 0.5rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: var(--muted);
}

.form-panel {
  display: grid;
  gap: 1rem;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 0.9rem;
}

.field-grid.single-column {
  grid-template-columns: 1fr;
}

label {
  display: grid;
  gap: 0.42rem;
  font-size: 0.9rem;
}

label span {
  color: var(--muted);
  font-size: 0.86rem;
}

.span-2 {
  grid-column: span 2;
}

input,
select,
textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0.62rem 0.7rem;
  font: inherit;
  color: var(--ink);
}

textarea {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.86rem;
}

.toggle-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.7rem;
}

.toggle {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  border: 1px dashed var(--line);
  border-radius: 12px;
  padding: 0.55rem 0.65rem;
}

.toggle input {
  width: 1rem;
  height: 1rem;
}

.toggle span {
  margin: 0;
  color: var(--ink);
}

.align-end {
  align-content: end;
}

.rarity-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.rarity-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.45rem 0.68rem;
  background: #fff;
  cursor: pointer;
  transition: 160ms ease;
}

.rarity-chip input {
  width: 0.95rem;
  height: 0.95rem;
}

.rarity-chip span {
  color: var(--ink);
  font-size: 0.84rem;
}

.rarity-limited {
  background: #fef9c3;
  border-color: #facc15;
}

.rarity-rare {
  background: #fee2e2;
  border-color: #ef4444;
}

.rarity-super {
  background: #dbeafe;
  border-color: #2563eb;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ink);
  border-radius: 999px;
  text-decoration: none;
  padding: 0.6rem 1rem;
  color: var(--ink);
  background: #fff;
  font-size: 0.88rem;
  font-weight: 600;
  transition: 170ms ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-secondary {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-accent {
  background: linear-gradient(90deg, var(--accent), #0f766e);
  border-color: transparent;
  color: #fff;
}

.btn-disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.flash-list {
  display: grid;
  gap: 0.45rem;
}

.flash {
  border-radius: 12px;
  padding: 0.56rem 0.72rem;
  border: 1px solid var(--line);
  background: #fff;
}

.flash-success {
  border-color: #bbf7d0;
  color: var(--good);
}

.flash-error {
  border-color: #fecdd3;
  color: var(--bad);
}

.errors {
  color: var(--bad);
  font-size: 0.9rem;
}

.log-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 0.8rem;
}

.table-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 0.7rem;
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 940px;
}

.data-table th,
.data-table td {
  border-bottom: 1px solid #ebe6d8;
  padding: 0.5rem 0.55rem;
  text-align: left;
  font-size: 0.82rem;
  vertical-align: top;
}

.data-table th {
  position: sticky;
  top: 0;
  background: #f8f5eb;
  z-index: 1;
  font-weight: 700;
}

.price-head-actions {
  display: grid;
  gap: 0.3rem;
}

.btn-compact {
  padding: 0.35rem 0.6rem;
  font-size: 0.75rem;
  line-height: 1.1;
}

.compact-table .data-table {
  min-width: 720px;
}

.data-table td pre {
  max-height: 140px;
}

.inline-bid-form {
  width: 116px;
  min-width: 116px;
}

.refresh-hint {
  align-self: center;
  color: var(--muted);
}

.market-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding-top: 1.1rem;
  padding-bottom: 1.1rem;
}

.market-toolbar-main,
.market-tags,
.market-refresh-form {
  display: flex;
  align-items: center;
}

.market-toolbar-main { gap: 1.5rem; }
.market-toolbar h2 { margin: 0; }
.market-toolbar-eyebrow { margin: 0 0 .18rem; color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; }
.market-tags { gap: .45rem; }
.market-tags span { display: inline-flex; align-items: center; gap: .35rem; padding: .42rem .68rem; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: .78rem; font-weight: 600; }
.market-tags .fa-gem { color: #dc2626; }
.market-refresh-form { justify-content: flex-end; gap: .75rem; flex-wrap: wrap; }
.market-refresh-actions { display: flex; align-items: center; gap: .45rem; }
.market-sync-status { display: grid; gap: .2rem; color: var(--muted); }
.market-sync-status small { display: flex; align-items: center; gap: .35rem; white-space: nowrap; }
.market-sync-status i { width: .9rem; color: var(--accent); text-align: center; }
.market-sync-status strong { color: var(--ink); font-weight: 600; }
.market-refresh-progress { flex: 1 0 100%; min-width: 280px; padding: .55rem .7rem; border: 1px solid #99f6e4; border-radius: 10px; background: #f0fdfa; }
.market-refresh-progress > div:first-child { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: .35rem; color: var(--muted); font-size: .75rem; }
.market-refresh-progress strong { color: var(--accent); font-family: 'IBM Plex Mono', monospace; white-space: nowrap; }
.market-refresh-track { height: 7px; overflow: hidden; border-radius: 999px; background: #dbe8e5; }
.market-refresh-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #14b8a6, #0f766e); transition: width .25s ease; }
.market-refresh-progress.is-indeterminate .market-refresh-track span { animation: market-progress-pulse 1.2s ease-in-out infinite alternate; }
.market-refresh-progress.is-error { border-color: #fecaca; background: #fef2f2; }
.market-refresh-progress.is-error strong, .market-refresh-progress.is-error #market-refresh-label { color: #b91c1c; }
@keyframes market-progress-pulse { from { width: 4%; } to { width: 45%; } }
.account-balance-strip { display: flex; align-items: stretch; gap: .65rem; margin-bottom: 1rem; }
.balance-heading, .balance-item, .balance-unavailable { display: flex; align-items: center; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); padding: .65rem .9rem; }
.balance-heading { gap: .5rem; color: var(--muted); font-weight: 700; }
.balance-heading i { color: var(--accent); }
.balance-item { min-width: 125px; flex-direction: column; align-items: flex-start; gap: .12rem; }
.balance-item small { color: var(--muted); font-size: .68rem; font-weight: 700; letter-spacing: .08em; }
.balance-item strong { font-family: 'IBM Plex Mono', monospace; }
.balance-unavailable { color: var(--muted); }

.auctions-command {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto;
  grid-template-areas:
    "kicker actions"
    "title actions"
    "meta status"
    "balance balance";
  align-items: center;
  gap: .25rem 1rem;
  padding: .75rem 1rem;
}
.auctions-command .kicker { grid-area: kicker; margin: 0; }
.auctions-command h1 { grid-area: title; margin: 0; font-size: 1.45rem; }
.auctions-command .hero-text { grid-area: meta; margin: 0; font-size: .78rem; }
.auctions-command .market-toolbar-main { grid-area: actions; }
.auctions-command .market-refresh-form { grid-area: status; justify-content: flex-start; }
.auctions-command .market-sync-status { display: flex; gap: .7rem; flex-wrap: wrap; }
.auctions-command .market-refresh-progress { margin-top: .25rem; }
.auctions-balance {
  grid-area: balance;
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-top: .35rem;
  padding-top: .5rem;
  border-top: 1px solid var(--line);
  font-size: .78rem;
}
.auctions-balance > span { color: var(--muted); font-weight: 700; }
.auctions-balance > span i { color: var(--accent); margin-right: .25rem; }
.auctions-balance strong { font-family: 'IBM Plex Mono', monospace; }
.auctions-balance strong small { color: var(--muted); font-family: inherit; font-weight: 500; }

.auctions-results { padding: .85rem 1rem; }
.auctions-results .table-head { margin-bottom: .55rem; }
.auction-filter-shell {
  position: relative;
  display: flex;
  align-items: end;
  gap: .55rem;
  margin-bottom: .7rem;
  padding: .55rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8faf9;
}
.saved-filter-picker { display: grid; flex: 0 1 180px; gap: .25rem; min-width: 135px; }
.saved-filter-picker > span,
.save-filter-form label > span { color: var(--muted); font-size: .7rem; }
.saved-filter-picker select { box-sizing: border-box; width: 100%; height: 38px; }
.auction-filter-shell .auction-filters {
  display: flex;
  flex: 1 1 auto;
  gap: .45rem;
  margin: 0;
}
.auction-filter-shell .auction-filters > * { flex: 1 1 120px; min-width: 105px; }
.auction-filter-shell .auction-filters .filter-actions { flex: 0 0 auto; min-width: auto; }
.auction-filter-shell .filter-multiselect summary,
.auction-filter-shell .favorite-filter-control,
.auction-filter-shell .auction-filters > label > select,
.auction-filter-shell .filter-actions .btn { height: 38px; }
.save-filter-menu { position: relative; flex: 0 0 auto; }
.save-filter-menu > summary {
  display: flex;
  align-items: center;
  gap: .35rem;
  height: 38px;
  padding: 0 .65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--accent);
  cursor: pointer;
  font-size: .78rem;
  font-weight: 700;
  list-style: none;
  white-space: nowrap;
}
.save-filter-menu > summary::-webkit-details-marker { display: none; }
.save-filter-menu > form,
.saved-filter-management {
  position: absolute;
  z-index: 40;
  top: calc(100% + .4rem);
  right: 0;
  width: 230px;
  padding: .6rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(15,23,42,.16);
}
.save-filter-menu > form { display: grid; gap: .45rem; }
.save-filter-menu > form label { display: grid; gap: .25rem; }
.save-filter-menu > form input { box-sizing: border-box; width: 100%; height: 38px; }
.saved-filter-management { top: calc(100% + 108px); }
.saved-filter-management form { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .25rem; }
.saved-filter-management button { border: 0; background: transparent; color: #dc2626; cursor: pointer; font-size: 1.1rem; }

.auctions-table { table-layout: fixed; }
.auctions-table th:nth-child(1) { width: 36%; }
.auctions-table th:nth-child(2) { width: 25%; }
.auctions-table th:nth-child(3) { width: 22%; }
.auctions-table th:nth-child(4) { width: 17%; }
.auction-player-copy { display: grid; min-width: 0; gap: .2rem; }
.auction-player-copy strong { overflow: hidden; text-overflow: ellipsis; }
.auction-player-copy small { display: flex; align-items: center; gap: .4rem; }
.auction-player-copy small b { color: var(--muted); font: 700 .68rem 'IBM Plex Mono', monospace; }
.auction-player-copy .team-badge { width: 20px; height: 20px; }

.auction-filters {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(155px, 1fr));
  gap: 0.65rem;
  align-items: end;
  margin-bottom: 0.9rem;
}
.saved-filter-bar { display: flex; align-items: end; flex-wrap: wrap; gap: .65rem; margin-bottom: .9rem; padding: .7rem; border-radius: 12px; background: #f8faf9; border: 1px solid var(--line); }
.saved-filter-bar > label, .save-filter-form label { display: grid; gap: .25rem; }
.saved-filter-bar label > span { color: var(--muted); font-size: .75rem; }
.saved-filter-bar select, .saved-filter-bar input { height: 38px; box-sizing: border-box; }
.save-filter-form { display: flex; align-items: end; gap: .45rem; }
.manage-saved-filters { position: relative; align-self: center; }
.manage-saved-filters summary { color: var(--accent); cursor: pointer; font-weight: 700; }
.manage-saved-filters > div { position: absolute; z-index: 20; right: 0; top: calc(100% + .4rem); min-width: 220px; padding: .5rem; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: 0 12px 28px rgba(15,23,42,.15); }
.manage-saved-filters form { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .35rem; }
.manage-saved-filters button { border: 0; background: transparent; color: #dc2626; font-size: 1.2rem; cursor: pointer; }
.filter-multiselect { min-width: 0; }
.filter-multiselect details { position: relative; }
.filter-field > span { display: block; margin-bottom: .25rem; color: var(--muted); font-size: .75rem; }
.filter-multiselect summary { display: flex; align-items: center; justify-content: space-between; height: 42px; box-sizing: border-box; padding: 0 .75rem; border: 1px solid var(--line); border-radius: 10px; background: #fff; cursor: pointer; list-style: none; white-space: nowrap; overflow: hidden; }
.filter-multiselect summary::after { content: '\f078'; margin-left: .5rem; color: var(--muted); font-family: 'Font Awesome 6 Free'; font-weight: 900; }
.filter-multiselect summary::-webkit-details-marker { display: none; }
.filter-options { position: absolute; z-index: 30; top: calc(100% + .35rem); left: 0; width: min(300px, calc(100vw - 3rem)); max-height: 330px; overflow-x: hidden; overflow-y: auto; padding: .45rem; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: 0 12px 28px rgba(15,23,42,.16); }
.filter-options label { display: grid; grid-template-columns: 18px minmax(0, 1fr); align-items: center; gap: .5rem; padding: .45rem; cursor: pointer; }
.filter-options label span { min-width: 0; overflow-wrap: anywhere; line-height: 1.25; }
.filter-options input { width: 17px; height: 17px; margin: 0; }
.filter-options label:hover { background: #eef8f6; }
.filter-options .btn { width: 100%; margin-top: .35rem; }

.favorite-filter-control {
  display: flex;
  align-items: center;
  height: 42px;
  gap: .4rem;
  white-space: nowrap;
}

.auction-filters > label > input:not([type="checkbox"]),
.auction-filters > label > select,
.filter-actions .btn {
  box-sizing: border-box;
  height: 42px;
}

.favorite-filter-control input { width: 1rem; height: 1rem; margin: 0; }
.favorite-filter-control small { color: var(--muted); }

.filter-actions {
  display: flex;
  gap: 0.35rem;
}

.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}

.pagination-icon {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  color: var(--accent);
  text-decoration: none;
  transition: background 140ms ease, color 140ms ease, transform 140ms ease;
}

.pagination-icon:hover { background: var(--accent); color: #fff; transform: translateY(-1px); }
.pagination-icon.is-disabled { border-color: var(--line); color: #c5c1b6; }

.sortable-heading,
.sort-buttons,
.page-jump {
  display: inline-flex;
  align-items: center;
}

.sortable-heading {
  gap: 0.45rem;
}

.sort-buttons {
  gap: 0.15rem;
}

.sort-button {
  color: var(--muted);
  padding: 0.15rem;
  line-height: 1;
}

.sort-button:hover,
.sort-button.is-active {
  color: var(--accent);
}

.page-jump {
  gap: 0.4rem;
}

.page-jump input[type="number"] {
  width: 4.5rem;
  padding: 0.4rem 0.5rem;
  -moz-appearance: textfield;
  appearance: textfield;
}

.page-jump input[type="number"]::-webkit-inner-spin-button,
.page-jump input[type="number"]::-webkit-outer-spin-button { margin: 0; -webkit-appearance: none; }

.auction-main-row {
  cursor: pointer;
  transition: background 140ms ease;
}

.auction-identity {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
}

.favorite-toggle {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: #b8b5aa;
  padding: .25rem;
  cursor: pointer;
  font-size: .92rem;
  line-height: 1;
  transition: color 140ms ease, transform 140ms ease;
}

.favorite-toggle:hover { color: #d4a514; transform: scale(1.12); }
.favorite-toggle.is-favorite { color: #eab308; }
.favorite-toggle:disabled { opacity: .5; cursor: wait; }
.empty-auctions { padding: 2rem !important; text-align: center !important; color: var(--muted); }

.player-thumb,
.team-badge {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  object-fit: contain;
}

.player-thumb {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #eef2f1;
}

.team-badge {
  width: 25px;
  height: 25px;
}

.image-fallback {
  color: var(--muted);
  background: #eef2f1;
  font-size: 0.75rem;
}

.team-badge.image-fallback {
  border-radius: 7px;
}

.auction-main-row:hover {
  background: #f0fdfa;
}

.auction-main-row.is-winning {
  background: #ecfdf5;
  box-shadow: inset 4px 0 0 var(--good);
}

.auction-main-row.is-outbid {
  background: #fff7ed;
  box-shadow: inset 4px 0 0 #f97316;
}

.winning-badge {
  display: block;
  width: max-content;
  margin-top: 0.25rem;
  padding: 0.18rem 0.4rem;
  border-radius: 999px;
  background: var(--good);
  color: white;
  font-size: 0.68rem;
  font-weight: 700;
}

.max-bid-badge {
  display: block;
  width: max-content;
  margin-top: 0.25rem;
  padding: 0.18rem 0.4rem;
  border: 1px solid #16a34a;
  border-radius: 999px;
  color: #15803d;
  background: #f0fdf4;
  font-size: 0.68rem;
  font-weight: 700;
}

.outbid-badge {
  display: block;
  width: max-content;
  margin-top: 0.25rem;
  padding: 0.18rem 0.4rem;
  border-radius: 999px;
  background: #f97316;
  color: white;
  font-size: 0.68rem;
  font-weight: 700;
}

@media (max-width: 980px) {
  .auction-filters { grid-template-columns: repeat(2, minmax(150px, 1fr)); }
  .market-toolbar { align-items: flex-start; flex-direction: column; }
  .market-refresh-form { justify-content: flex-start; }
  .auction-filter-shell { align-items: stretch; flex-wrap: wrap; }
  .auction-filter-shell .auction-filters { order: 3; flex-basis: 100%; }
}

@media (max-width: 620px) {
  .market-toolbar-main, .market-refresh-form { align-items: flex-start; flex-direction: column; gap: .65rem; }
  .market-tags { flex-wrap: wrap; }
  .market-refresh-actions { width: 100%; flex-direction: column; align-items: stretch; }
  .market-refresh-progress { min-width: 0; width: 100%; box-sizing: border-box; }
  .market-refresh-progress > div:first-child { align-items: flex-start; flex-direction: column; gap: .2rem; }
  .page:has(.auctions-page) { width: min(100% - 1rem, 1600px); margin-top: .65rem; gap: .65rem; }
  .page:has(.auctions-page) > * { min-width: 0; }
  .auctions-command {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "kicker" "title" "meta" "actions" "status" "balance";
    gap: .35rem;
    padding: .65rem .7rem;
  }
  .auctions-command > * { min-width: 0; }
  .auctions-command h1 { font-size: 1.15rem; }
  .auctions-command .market-toolbar-main,
  .auctions-command .market-refresh-actions { width: 100%; }
  .auctions-command .market-refresh-actions { flex-direction: row; }
  .auctions-command .market-refresh-actions .btn { flex: 1 1 0; padding-inline: .45rem; font-size: .72rem; }
  .auctions-command .market-refresh-form { width: 100%; }
  .auctions-command .market-sync-status { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; gap: .2rem .5rem; }
  .auctions-command .market-sync-status small { display: grid; min-width: 0; gap: .05rem; white-space: normal; }
  .auctions-command .market-sync-status small:last-child { grid-column: 1 / -1; }
  .auctions-balance { gap: .45rem; overflow-x: auto; white-space: nowrap; }
  .auctions-balance > span { font-size: 0; }
  .auctions-balance > span i { font-size: .8rem; }
  .auctions-balance strong { font-size: .7rem; }
  .auctions-results { padding: .6rem; }
  .auctions-results .table-head h2 { font-size: 1rem; }
  .auction-filter-shell { gap: .4rem; padding: .45rem; }
  .saved-filter-picker { flex: 1 1 150px; }
  .save-filter-menu > summary span,
  .auction-filter-shell .filter-actions span { display: none; }
  .auction-filter-shell .auction-filters { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); width: 100%; min-width: 0; gap: .4rem; }
  .auction-filter-shell .auction-filters > * { min-width: 0; }
  .auction-filter-shell .filter-actions { position: absolute; right: 1.1rem; }
  .auction-filter-shell .filter-multiselect details { position: static; }
  .auction-filter-shell .filter-options { left: .45rem; right: .45rem; width: auto; }
  .auctions-results .table-wrap { overflow: visible; }
  .auctions-table, .auctions-table tbody { display: block; width: 100%; min-width: 0; }
  .auctions-table thead { display: none; }
  .auctions-table .auction-main-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: .2rem .5rem;
    margin-bottom: .45rem;
    padding: .55rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
  }
  .auctions-table .auction-main-row > td { display: block; padding: 0; border: 0; }
  .auctions-table .auction-main-row > td:nth-child(1) { grid-column: 1; grid-row: 1; min-width: 0; }
  .auctions-table .auction-main-row > td:nth-child(2) { grid-column: 1; grid-row: 2; padding-left: 42px; font-size: .82rem; }
  .auctions-table .auction-main-row > td:nth-child(3) { grid-column: 2; grid-row: 1; text-align: right; font-size: .68rem !important; white-space: nowrap; }
  .auctions-table .auction-main-row > td:nth-child(4) { grid-column: 2; grid-row: 2; }
  .auctions-table .history-row:not([hidden]) { display: block; margin: -.3rem 0 .45rem; }
  .auctions-table .history-row td { display: block; padding: .5rem; }
  .auctions-table .player-thumb { width: 36px; height: 36px; }
  .auctions-table .auction-identity { width: 100%; gap: .4rem; }
  .auctions-table .favorite-toggle { margin-left: auto; }
  .auctions-table .winning-badge,
  .auctions-table .outbid-badge,
  .auctions-table .max-bid-badge { display: inline-block; margin: .2rem .15rem 0 0; }
  .auctions-table .inline-bid-amount input { width: 58px; height: 34px; }
  .auctions-table .single-bid-review { width: 34px; height: 34px; }
}

.inline-bid-amount {
  display: flex;
  gap: 0.35rem;
}

.inline-bid-amount input {
  box-sizing: border-box;
  width: 82px;
  min-width: 0;
  padding: 0.4rem;
  -webkit-appearance: none;
  appearance: none;
}

.single-bid-review {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 1px solid var(--accent);
  border-radius: 50%;
  background: #fff;
  color: var(--accent);
  cursor: pointer;
}

.single-bid-review:hover { background: var(--accent); color: #fff; }

.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.7rem;
  white-space: nowrap;
}

.inline-check input {
  flex: 0 0 auto;
  width: 1rem;
  height: 1rem;
  margin: 0;
}

.batch-bid-bar,
.bid-modal-actions {
  display: flex;
  align-items: center;
}

.batch-bid-bar {
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 1rem;
}

.bid-modal[hidden] { display: none; }
.bid-modal { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 1rem; }
.bid-modal-backdrop { position: absolute; inset: 0; background: rgba(15, 23, 42, .65); }
.bid-modal-card { position: relative; box-sizing: border-box; width: min(620px, 100%); max-width: 100%; max-height: 85vh; overflow-x: hidden; overflow-y: auto; background: var(--panel); border-radius: 16px; padding: 1.4rem; box-shadow: 0 24px 60px rgba(0,0,0,.3); }
.bid-modal-close { position: absolute; top: .6rem; right: .8rem; border: 0; background: transparent; font-size: 1.8rem; cursor: pointer; }
.bid-review-list { display: grid; gap: .5rem; margin: 1rem 0; }
.review-credit-all { display: inline-flex; width: fit-content; max-width: 100%; box-sizing: border-box; align-items: center; gap: .5rem; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: 10px; background: #f8faf9; font-weight: 700; cursor: pointer; }
.review-credit-all input, .bid-payment-choice input { flex: 0 0 auto; width: 1rem; height: 1rem; margin: 0; padding: 0; }
.review-credit-all span { color: var(--ink); white-space: normal; }
.bid-payment-summary { display: grid; gap: .65rem; margin: .85rem 0; }
.bid-payment-choice { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; font-weight: 700; }
.bid-payment-choice > span { margin-right: .25rem; }
.bid-payment-choice label { display: inline-flex; width: auto; align-items: center; gap: .45rem; padding: .48rem .7rem; border: 1px solid var(--line); border-radius: 999px; background: #fff; cursor: pointer; white-space: nowrap; }
.bid-payment-choice label span { color: inherit; }
.bid-payment-choice label:has(input:checked) { border-color: var(--accent); color: var(--accent); background: #eef8f6; }
.payment-currency-help { color: var(--muted); }
.modal-balances { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.modal-balances > span { display: grid; gap: .08rem; padding: .55rem .65rem; border-radius: 10px; background: #f8faf9; border: 1px solid var(--line); }
.modal-balances small { color: var(--muted); font-size: .68rem; font-weight: 700; }
.modal-balances strong { font-family: 'IBM Plex Mono', monospace; font-size: .84rem; }
.bid-review-item { display: grid; grid-template-columns: auto 1fr auto auto auto; align-items: center; gap: .8rem; padding: .7rem; border: 1px solid var(--line); border-radius: 10px; }
.bid-review-item small { color: var(--muted); }
.bid-review-details { display: grid; min-width: 0; gap: .18rem; }
.bid-review-details strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bid-review-price { display: grid; gap: .12rem; text-align: right; white-space: nowrap; }
.bid-review-payment-amount { color: var(--accent) !important; font-family: 'IBM Plex Mono', monospace; font-weight: 700; }
.bid-review-comparison { font-size: .72rem; font-weight: 700; }
.bid-review-comparison.is-loading { font-weight: 500; }
.bid-review-comparison.is-above { color: #dc2626; }
.bid-review-comparison.is-below { color: #15803d; }
.bid-review-comparison.is-equal { color: var(--muted); }
.bid-review-visuals { position: relative; display: block; width: 46px; height: 40px; }
.bid-review-player, .bid-review-team { display: grid; place-items: center; overflow: hidden; background: #eef2f1; color: var(--muted); }
.bid-review-player { width: 38px; height: 38px; border-radius: 50%; }
.bid-review-team { position: absolute; right: 0; bottom: -1px; width: 21px; height: 21px; border: 2px solid var(--panel); border-radius: 6px; }
.bid-review-player img, .bid-review-team img { width: 100%; height: 100%; object-fit: contain; }
.bid-review-price { color: var(--accent); font-weight: 700; font-family: 'IBM Plex Mono', monospace; }
.review-credit { display: inline-flex; grid-template-columns: none; align-items: center; gap: .4rem; white-space: nowrap; }
.review-credit input { width: 1rem; height: 1rem; margin: 0; }
.review-credit span { color: var(--muted); font-size: .75rem; }
.review-remove { display: grid; place-items: center; width: 36px; height: 36px; padding: 0; border: 1px solid #fecaca; border-radius: 50%; background: #fff; color: #dc2626; cursor: pointer; }
.review-remove:hover { background: #fef2f2; border-color: #dc2626; }
.bid-modal-actions { justify-content: flex-end; gap: .6rem; }
.modal-open { overflow: hidden; }
.bid-modal.is-submitting .bid-modal-card { cursor: wait; }
.bid-submit-progress { display: grid; grid-template-columns: auto 1fr; column-gap: .65rem; align-items: center; margin-top: 1rem; padding: .8rem; border-radius: 10px; background: #eef8f6; color: var(--ink); }
.bid-submit-progress[hidden] { display: none; }
.bid-submit-progress small { grid-column: 2; color: var(--muted); }
.bid-job-notifications { position: fixed; right: 1rem; bottom: 1rem; z-index: 1100; display: grid; gap: .65rem; width: min(430px, calc(100vw - 2rem)); pointer-events: none; }
.bid-job-notice { display: grid; grid-template-columns: auto 1fr auto; gap: .7rem; align-items: start; padding: .9rem 1rem; border: 1px solid var(--line); border-left: 5px solid var(--accent); border-radius: 12px; background: #fff; box-shadow: 0 12px 35px rgba(15, 23, 42, .18); pointer-events: auto; }
.bid-job-notice.is-success { border-left-color: #16a34a; }
.bid-job-notice.is-error { border-left-color: #dc2626; }
.bid-job-notice.is-warning { border-left-color: #d97706; }
.bid-job-notice.is-pending > i { color: var(--accent); }
.bid-job-notice.is-success > i { color: #16a34a; }
.bid-job-notice.is-error > i { color: #dc2626; }
.bid-job-notice.is-warning > i { color: #d97706; }
.bid-job-notice div { display: grid; gap: .2rem; min-width: 0; }
.bid-job-notice span { color: var(--muted); font-size: .84rem; }
.bid-job-notice ul { margin: .35rem 0 0; padding-left: 1.1rem; font-size: .84rem; }
.bid-job-notice button { border: 0; background: transparent; color: var(--muted); font-size: 1.25rem; line-height: 1; cursor: pointer; }
.bid-spinner { grid-row: 1 / 3; width: 22px; height: 22px; border: 3px solid #b7ddd7; border-top-color: var(--accent); border-radius: 50%; animation: bid-spin .75s linear infinite; }
@keyframes bid-spin { to { transform: rotate(360deg); } }

@media (max-width: 700px) {
  .batch-bid-bar { align-items: stretch; flex-direction: column; }
  .bid-review-item { grid-template-columns: auto 1fr auto auto; }
  .bid-review-item small { grid-column: 2 / -1; }
  .bid-review-item .review-credit { grid-column: 2 / 4; }
  .bid-review-item .review-remove { grid-column: 4; grid-row: 1; }
  .bid-modal-actions { align-items: stretch; flex-direction: column-reverse; }
}

.history-row td {
  background: #f8faf8;
  padding: 0.8rem;
}

.history-sales {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.5rem;
}

.history-sale {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 0.15rem 0.45rem;
  padding: 0.55rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: white;
}

.history-sale i {
  grid-row: span 3;
  color: var(--accent);
}

.history-sale span,
.history-sale small {
  color: var(--muted);
  font-size: 0.72rem;
}

.history-instant i { color: var(--accent-2); }
.history-trade i { color: #6366f1; }
.history-public i { color: #d97706; }
.history-direct i { color: #2563eb; }

.auction-warning {
  margin: 1rem 0 0;
  padding: 0.7rem;
  color: var(--bad);
  background: #fff1f2;
  border-radius: 10px;
  font-size: 0.82rem;
}

.in-season-row {
  background: #ecfdf5;
}

.confirm-card {
  display: grid;
  gap: 0.9rem;
  border: 1px dashed var(--line);
  border-radius: 18px;
  background: linear-gradient(135deg, #fffef9, #f6fbfa);
  padding: 1rem;
}

.confirm-card-head {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  align-items: flex-start;
}

.confirm-card-kicker {
  margin: 0 0 0.15rem;
  color: var(--accent);
  font-size: 0.75rem;
  font-family: "IBM Plex Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.confirm-card h3 {
  margin-top: 0;
  margin-bottom: 0;
  font-size: 1.3rem;
}

.confirm-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: flex-end;
}

.confirm-chip {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0.35rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
}

.confirm-chip-good {
  border-color: #86efac;
  color: var(--good);
  background: #f0fdf4;
}

.confirm-stat-grid,
.confirm-price-grid,
.confirm-rays-row {
  display: grid;
  gap: 0.7rem;
}

.confirm-stat-grid {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.confirm-stat,
.confirm-price-box,
.confirm-rays-card {
  display: grid;
  gap: 0.18rem;
  padding: 0.75rem 0.8rem;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid #ece5d5;
}

.confirm-stat span,
.confirm-price-box span,
.confirm-rays-card span {
  color: var(--muted);
  font-size: 0.78rem;
}

.confirm-stat strong,
.confirm-price-box strong,
.confirm-rays-card strong {
  font-size: 1rem;
}

.confirm-rays-row {
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.confirm-rays-card-accent {
  background: linear-gradient(135deg, #ecfeff, #f0fdfa);
  border-color: #99f6e4;
}

.confirm-price-grid {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.confirm-price-box-sale {
  background: linear-gradient(135deg, #0f766e, #115e59);
  border-color: transparent;
}

.confirm-price-box-sale span,
.confirm-price-box-sale strong {
  color: #fff;
}

.processing-indicator {
  display: none;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.75rem 0.9rem;
  background: #ffffff;
}

.processing-indicator.is-visible {
  display: flex;
}

.processing-indicator p {
  margin: 0.2rem 0 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.processing-dot {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.4);
  animation: pulse 1.3s infinite;
}

@keyframes pulse {
  0% {
    transform: scale(0.9);
    box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.45);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 12px rgba(13, 148, 136, 0);
  }
  100% {
    transform: scale(0.9);
    box-shadow: 0 0 0 0 rgba(13, 148, 136, 0);
  }
}

pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 300px;
  overflow: auto;
  padding: 0.7rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fcfcfb;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.8rem;
}

.reveal {
  opacity: 0;
  transform: translateY(8px);
  animation: rise 420ms ease forwards;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 780px) {
  .account-balance-strip { display: grid; grid-template-columns: repeat(3, 1fr); }
  .balance-heading, .balance-unavailable { grid-column: 1 / -1; }
  .balance-item { min-width: 0; padding: .6rem; }
  .bid-modal { padding: .65rem; }
  .bid-modal-card { padding: 1.15rem; }
  .bid-payment-choice { align-items: stretch; }
  .bid-payment-choice > span { flex-basis: 100%; }
  .modal-balances { grid-template-columns: 1fr; }
  .field-grid {
    grid-template-columns: 1fr;
  }

  .span-2 {
    grid-column: auto;
  }

  .site-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: .45rem;
    padding: .55rem .7rem;
  }

  nav {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    width: 100%;
    gap: .15rem;
  }

  .nav-dropdown { width: 100%; }
  .nav-dropdown > summary { justify-content: center; min-height: 34px; padding: .4rem 0; border-radius: 8px; }
  .nav-dropdown > summary span, .nav-dropdown > summary .nav-dropdown-chevron { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .nav-dropdown-panel { position: fixed; top: 100px; right: .7rem; left: .7rem; min-width: 0; transform: none; }

  nav a {
    justify-content: center;
    min-width: 0;
    min-height: 34px;
    padding: .4rem 0;
    border-radius: 8px;
  }

  nav a span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  .user-badge {
    align-self: center;
    padding: .4rem .55rem;
  }

  .user-badge > span { display: none; }
  .user-menu-panel { position: fixed; top: 55px; right: .7rem; left: .7rem; min-width: 0; }

  .direct-offer-head { grid-template-columns: 1fr; padding: .7rem; }
  .direct-offer-head h1 { font-size: 1.25rem; }
  .direct-offer-controls { grid-template-columns: 1fr; padding: .7rem; }
  .direct-offer-terms { grid-template-columns: 1fr 1fr; }
  .direct-offer-terms .btn { grid-column: 1 / -1; }
  .direct-selection-summary { grid-column: 1; flex-wrap: wrap; gap: .45rem 1rem; }
  .direct-offer-results { padding: .55rem; }
  .direct-offer-table, .direct-offer-table tbody { display: block; min-width: 0; }
  .direct-offer-table thead { display: none; }
  .direct-offer-table tr { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: .25rem .5rem; margin-bottom: .45rem; padding: .55rem; border: 1px solid var(--line); border-radius: 8px; }
  .direct-offer-table td { padding: 0; border: 0; }
  .direct-offer-table td:nth-child(1) { grid-column: 1; grid-row: 1 / 3; }
  .direct-offer-table td:nth-child(2) { grid-column: 2; grid-row: 1 / 3; }
  .direct-offer-table td:nth-child(3) { grid-column: 3; grid-row: 1; }
  .direct-offer-table td:nth-child(4) { grid-column: 3; grid-row: 2; text-align: right; }
  .direct-offer-table td:nth-child(5) { grid-column: 2; grid-row: 3; overflow: hidden; text-overflow: ellipsis; }
  .direct-offer-table td:nth-child(6) { grid-column: 3; grid-row: 3; text-align: right; }

  .table-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .confirm-card-head {
    flex-direction: column;
  }

  .confirm-chip-row {
    justify-content: flex-start;
  }
}

/* Ventas: inventario y publicación directa */
.page:has(.sales-page) { width: min(1600px, 98vw); }
.sales-page { display: grid; gap: 1rem; }
.sales-market-head, .sales-toolbar, .sales-toolbar-actions, .sales-rarity-tabs,
.sales-player, .sales-team, .sales-price-control, .sales-pagination,
.sales-basket, .sales-review-player, .sales-review-input { display: flex; align-items: center; }
.sales-market-head { justify-content: space-between; gap: 1rem; }
.sales-market-head h1 { margin: .2rem 0; }
.sales-market-head p:last-child { margin: .3rem 0 0; color: var(--muted); }
.sales-sync-box { min-width: 220px; display: grid; gap: .15rem; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: 14px; background: rgba(255,255,255,.72); }
.sales-sync-box span, .sales-sync-box small { color: var(--muted); font-size: .78rem; }
.sales-toolbar { justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.sales-rarity-tabs { gap: .55rem; flex-wrap: wrap; }
.sales-rarity { text-decoration: none; color: var(--ink); border: 1px solid var(--line); border-radius: 999px; padding: .58rem .85rem; font-weight: 700; opacity: .65; background: #fff; }
.sales-rarity.is-active { opacity: 1; box-shadow: 0 4px 14px rgba(15,23,42,.12); transform: translateY(-1px); }
.sales-rarity.rarity-limited i { color: #d7a900; }
.sales-rarity.rarity-rare i { color: #dc2626; }
.sales-rarity.rarity-super i { color: #2563eb; }
.sales-results { min-width: 0; }
.sales-help { color: var(--muted); font-size: .82rem; max-width: 58ch; margin: 0; }
.sales-filters { display: grid; grid-template-columns: repeat(auto-fit,minmax(145px,1fr)); gap: .65rem; align-items: end; margin: .9rem 0; }
.sales-filters input, .sales-filters select, .sales-multi-filter summary,
.sales-review-item input { width: 100%; min-height: 44px; border: 1px solid var(--line); border-radius: 12px; padding: .62rem .72rem; background: #fff; color: var(--ink); font: inherit; }
.sales-multi-filter { position: relative; }
.sales-multi-filter summary { display: flex; justify-content: space-between; align-items: center; gap: .45rem; list-style: none; cursor: pointer; }
.sales-multi-filter summary::-webkit-details-marker { display: none; }
.sales-multi-filter summary b { color: var(--accent); font-size: .8rem; }
.sales-multi-menu { position: absolute; z-index: 30; top: calc(100% + 5px); left: 0; width: max(100%, 270px); max-height: 320px; overflow-y: auto; overflow-x: hidden; padding: .45rem; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); box-shadow: var(--shadow); }
.sales-multi-menu label { grid-template-columns: 22px minmax(0,1fr); align-items: center; gap: .55rem; padding: .45rem; border-radius: 8px; }
.sales-multi-menu label:hover { background: #f0fdfa; }
.sales-multi-menu input { width: 18px; min-height: 18px; margin: 0; }
.sales-multi-menu span { color: var(--ink); white-space: normal; overflow-wrap: anywhere; }
.sales-filter-price { position: relative; }
.sales-filter-price > span { position: absolute; z-index: 1; left: .7rem; top: 50%; translate: 0 -50%; color: var(--muted); }
.sales-filter-price input { padding-left: 1.8rem; }
.sales-check-filter { display: flex; align-items: center; gap: .5rem; min-height: 44px; padding: 0 .45rem; }
.sales-check-filter input { width: 18px; min-height: 18px; }
.sales-check-filter span { color: var(--ink); }
.sales-clear { min-height: 44px; justify-content: center; }
.sales-table-wrap { max-height: none; overflow: auto; }
.sales-table { min-width: 1400px; }
.sales-table th, .sales-table td { vertical-align: middle; }
.sales-card-row { cursor: pointer; }
.sales-card-row:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.sales-table td small { display: block; color: var(--muted); font-size: .72rem; margin-top: .15rem; }
.sales-table tr.is-blocked { opacity: .68; background: #f5f4f0; }
.sales-player { gap: .6rem; min-width: 190px; }
.sales-player img, .sales-avatar { width: 43px; height: 43px; border-radius: 50%; object-fit: cover; background: #ecfdf5; flex: 0 0 auto; }
.sales-avatar { display: grid; place-items: center; color: var(--muted); }
.sales-history-cue { margin-left: .25rem; color: var(--accent); font-size: .72rem; }
.sales-ray-icon { color: #eab308; font-size: .82rem; }
.sales-history-row .history-content { padding: .15rem 0; }
.sales-team { gap: .45rem; min-width: 135px; }
.sales-team img { width: 27px; height: 27px; object-fit: contain; flex: 0 0 auto; }
.sales-pill { width: max-content; border-radius: 999px; color: var(--good) !important; background: #dcfce7; padding: .15rem .38rem; }
.sales-price-cell { min-width: 185px; }
.sales-price-control { gap: .35rem; }
.sales-price-control > span { color: var(--muted); }
.sales-price-control input { width: 92px; height: 40px; border: 1px solid var(--line); border-radius: 11px; padding: .5rem; font: inherit; }
.sale-one { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--accent); color: var(--accent); background: #fff; cursor: pointer; }
.sale-one:hover { color: #fff; background: var(--accent); }
.sales-blocked { display: inline-flex; gap: .35rem; align-items: center; color: var(--bad); font-size: .78rem; font-weight: 700; }
.sales-empty { text-align: center; padding: 2rem !important; color: var(--muted); }
.sales-pagination { justify-content: center; gap: .45rem; margin-top: 1rem; flex-wrap: wrap; }
.sales-pagination button, .sales-pagination input { min-width: 42px; height: 42px; border: 1px solid var(--accent); border-radius: 999px; color: var(--accent); background: #fff; font: inherit; font-weight: 700; text-align: center; }
.sales-pagination button { cursor: pointer; }
.sales-pagination button:disabled { opacity: .35; cursor: default; }
.sales-pagination input { width: 68px; border-radius: 12px; color: var(--ink); }
.sales-basket { position: sticky; z-index: 20; bottom: 1rem; justify-content: flex-end; gap: 1rem; width: max-content; max-width: 100%; margin-left: auto; padding: .65rem .75rem .65rem 1rem; border: 1px solid var(--line); border-radius: 999px; background: rgba(255,253,248,.95); box-shadow: var(--shadow); backdrop-filter: blur(12px); }
.sales-empty-state { text-align: center; padding: 3rem; }
.sales-empty-state > i { font-size: 2.3rem; color: var(--accent); }
.sales-empty-state p { color: var(--muted); }
.sales-modal[hidden], .sales-basket[hidden] { display: none; }
.sales-modal { position: fixed; z-index: 100; inset: 0; display: grid; place-items: center; padding: 1rem; }
.sales-modal-backdrop { position: absolute; inset: 0; background: rgba(15,23,42,.62); backdrop-filter: blur(4px); }
.sales-modal-card { position: relative; z-index: 1; width: min(850px, 96vw); max-height: 90vh; overflow: auto; padding: 1.4rem; border-radius: 22px; background: var(--panel); box-shadow: 0 26px 80px rgba(15,23,42,.35); }
.sales-modal-card h2 { margin: 0; font-size: 1.7rem; }
.sales-modal-card > p { color: var(--muted); }
.sales-modal-close { position: absolute; right: 1rem; top: .75rem; border: 0; background: transparent; font-size: 2rem; cursor: pointer; }
.sales-review-list { display: grid; gap: .65rem; }
.sales-review-item { display: grid; grid-template-columns: minmax(210px,1fr) 155px 175px 85px auto; gap: .75rem; align-items: end; border: 1px solid var(--line); border-radius: 15px; padding: .75rem; }
.sales-review-item label > span small { color: var(--muted); font-weight: 400; }
.sales-review-player { gap: .5rem; min-width: 0; }
.sales-review-player img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.sales-review-player img.team { width: 27px; height: 27px; object-fit: contain; margin-left: -16px; margin-top: 18px; background: #fff; padding: 2px; }
.sales-review-player strong { overflow-wrap: anywhere; }
.sales-review-input { position: relative; }
.sales-review-input > span { position: absolute; left: .7rem; z-index: 1; color: var(--muted); }
.sales-review-input input { padding-left: 1.8rem; }
.sales-modal-actions { justify-content: flex-end; margin-top: 1rem; }
.sales-toasts { position: fixed; z-index: 130; right: 1rem; bottom: 1rem; display: grid; gap: .6rem; width: min(430px, calc(100vw - 2rem)); }
.sales-toast { display: grid; grid-template-columns: 25px minmax(0,1fr) 22px; gap: .65rem; align-items: start; padding: .9rem; border: 1px solid var(--line); border-left: 5px solid var(--accent); border-radius: 14px; background: #fff; box-shadow: var(--shadow); }
.sales-toast.is-error { border-left-color: #ef4444; }
.sales-toast.is-success { border-left-color: #22c55e; }
.sales-toast strong { display: block; }
.sales-toast p { margin: .15rem 0 0; color: var(--muted); font-size: .8rem; overflow-wrap: anywhere; }
.sales-toast button { border: 0; background: transparent; cursor: pointer; font-size: 1.2rem; }
.sales-refresh-progress { flex: 1 0 100%; display: grid; gap: .35rem; }
.sales-refresh-progress[hidden] { display: none; }
.sales-refresh-progress > div:first-child { display: flex; justify-content: space-between; gap: .7rem; color: var(--muted); font-size: .8rem; }
.sales-refresh-progress strong { color: var(--accent); }
.sales-progress-track { height: 8px; overflow: hidden; border-radius: 999px; background: #e4e1d7; }
.sales-progress-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--accent), #2dd4bf); transition: width .3s ease; }
.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; }
body.modal-open { overflow: hidden; }
.global-sales-progress { position: fixed; z-index: 125; left: 1rem; bottom: 1rem; width: min(430px, calc(100vw - 2rem)); display: grid; grid-template-columns: 28px minmax(0,1fr); gap: .7rem; align-items: start; padding: .85rem 1rem; border: 1px solid var(--line); border-left: 5px solid var(--accent); border-radius: 15px; background: rgba(255,253,248,.97); box-shadow: var(--shadow); backdrop-filter: blur(12px); }
.global-sales-progress[hidden] { display: none; }
.global-sales-progress > i { color: var(--accent); margin-top: .2rem; }
.global-sales-progress strong, .global-sales-progress span { display: block; }
.global-sales-progress span { margin-top: .12rem; color: var(--muted); font-size: .78rem; overflow-wrap: anywhere; }
.global-sales-progress-track { height: 6px; margin-top: .5rem; overflow: hidden; border-radius: 999px; background: #e4e1d7; }
.global-sales-progress-track span { height: 100%; margin: 0; border-radius: inherit; background: linear-gradient(90deg,var(--accent),#2dd4bf); transition: width .3s ease; }
.global-sales-progress.is-complete { border-left-color: #22c55e; }
.global-sales-progress.is-error { border-left-color: #ef4444; }

/* Historial económico */
.movements-page { display: grid; gap: 1rem; }
.movement-command-bar { display: grid; gap: .65rem; padding: .8rem 1rem; }
.movement-command-main { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.movement-heading-compact { min-width: 0; }
.movement-heading-compact h1 { margin: 0; font-size: clamp(1.25rem,2vw,1.65rem); }
.movement-heading-compact p { margin: .12rem 0 0; color: var(--muted); font-size: .78rem; }
.movement-command-actions { display: flex; align-items: center; justify-content: flex-end; gap: .75rem; }
.manager-swap { display: flex; align-items: center; gap: .35rem; padding: .25rem; border: 1px solid var(--line); border-radius: 999px; background: #f7f5ef; }
.manager-swap span { padding: .36rem .55rem; border-radius: 999px; color: var(--muted); font-size: .76rem; font-weight: 700; }
.manager-swap span.is-active { background: #fff; color: var(--ink); box-shadow: 0 2px 8px rgba(15,23,42,.08); }
.manager-swap a { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 50%; background: var(--accent); color: #fff; }
.movement-command-bar .movement-sync { display: flex; min-width: 0; align-items: center; justify-content: flex-end; gap: .45rem; }
.movement-command-bar .movement-sync .btn { min-height: 36px; margin: 0; padding: .45rem .7rem; }
.movement-command-bar .movement-sync > span { max-width: 220px; text-align: right; }
.movement-command-bar .movement-sync > small:empty { display: none; }
.public-movement-note { color: var(--muted); font-size: .7rem; }
.history-coverage-warning { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: .8rem; padding: .75rem 1rem; border-color: #f0c66d; background: #fffbeb; }
.history-coverage-warning > i { color: #d97706; font-size: 1.15rem; }
.history-coverage-warning strong { display: block; }
.history-coverage-warning p { margin: .12rem 0 0; color: var(--muted); font-size: .76rem; }
.history-coverage-warning .btn { white-space: nowrap; }
.movements-hero { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.movements-hero h1 { margin: .2rem 0 .45rem; font-size: clamp(1.55rem,3vw,2.35rem); }
.movements-hero p:last-child { margin-bottom: 0; color: var(--muted); }
.movement-sync { display: grid; min-width: 230px; justify-items: end; gap: .18rem; }
.movement-sync > span, .movement-sync > small { color: var(--muted); font-size: .78rem; }
.movement-sync .btn { margin-top: .45rem; }
.movement-tabs { display: flex; flex: none; justify-content: flex-start; gap: .4rem; overflow-x: auto; padding-top: .55rem; border-top: 1px solid var(--line); }
.movement-tabs a { flex: 0 0 auto; padding: .42rem .65rem; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--ink); font-size: .76rem; font-weight: 700; }
.movement-tabs a b { color: var(--muted); font-family: "IBM Plex Mono",monospace; }
.movement-tabs a.is-active { color: #fff; border-color: var(--accent); background: var(--accent); }
.movement-tabs a.is-active b { color: #fff; }
.cycle-consideration { display: grid; gap: .22rem; margin-top: .3rem; padding-top: .3rem; border-top: 1px solid var(--line); }
.cycle-consideration > small { color: var(--muted); font-size: .62rem; font-weight: 750; letter-spacing: .04em; text-transform: uppercase; }
.cycle-consideration > div { display: flex; flex-wrap: wrap; gap: .22rem; }
.cycle-consideration em { display: inline-flex; align-items: center; gap: .2rem; padding: .16rem .32rem; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: .65rem; font-style: normal; }
.movement-craft-row { background: linear-gradient(90deg, rgba(245,158,11,.045), rgba(20,184,166,.035)); }
.movement-craft-detail { min-width: 480px; }
.craft-journey { display: grid; grid-template-columns: minmax(170px,.85fr) auto minmax(230px,1fr) minmax(125px,.65fr); align-items: center; gap: .65rem; }
.craft-journey > section, .craft-journey > aside { display: grid; gap: .12rem; min-height: 72px; padding: .6rem .7rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.craft-journey > section > span, .craft-journey > aside > span { color: var(--muted); font-size: .69rem; font-weight: 750; letter-spacing: .04em; text-transform: uppercase; }
.craft-journey > section > strong, .craft-journey > aside > strong { font-size: .93rem; }
.craft-journey > section > small, .craft-journey > aside > small { color: var(--muted); font-size: .72rem; }
.craft-journey > i { color: #d97706; }
.craft-journey .craft-origin { border-color: #fcd34d; background: #fffbeb; }
.craft-journey .craft-status.is-held { border-color: #99d8cf; background: #f0fdfa; }
.craft-journey .craft-status.is-sold { border-color: #bfdbfe; background: #eff6ff; }
.craft-journey .craft-status.is-unknown { border-color: #d1d5db; background: #f9fafb; }
.craft-journey aside { border-color: #99d8cf; background: #f0fdfa; }
.craft-essence-breakdown { display: flex; flex-wrap: wrap; gap: .22rem; margin: .18rem 0; }
.craft-essence-breakdown em { display: inline-flex; align-items: center; gap: .22rem; padding: .16rem .32rem; border: 1px solid #f7d77d; border-radius: 999px; background: #fff; color: #6b4e10; font-size: .65rem; font-style: normal; line-height: 1.1; }
.craft-essence-breakdown img { width: 14px; height: 14px; object-fit: contain; }
.craft-floor { margin-top: auto; }
.craft-floor b { color: var(--ink); }
.craft-journey aside div { display: flex; flex-wrap: wrap; gap: .25rem; margin-top: .2rem; }
.craft-journey aside em { display: inline-flex; align-items: center; gap: .25rem; padding: .14rem .3rem; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: .68rem; font-style: normal; }

@media (max-width: 780px) {
  .craft-journey { grid-template-columns: 1fr; }
  .craft-journey > i { justify-self: center; transform: rotate(90deg); }
}
.reward-manager-switch { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: .85rem; padding-bottom: .85rem; }
.reward-manager-switch > div { display: grid; gap: .12rem; }
.reward-manager-switch > div span, .reward-manager-switch label > span { color: var(--muted); font-size: .72rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.reward-manager-switch > div strong { font-size: 1.05rem; }
.reward-manager-switch label { display: flex; align-items: center; gap: .65rem; }
.reward-manager-switch select { min-width: 180px; min-height: 42px; padding: .55rem 2.2rem .55rem .75rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); font: inherit; }
.movement-summary-title { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0 .2rem; }
.movement-summary-title > div { display: grid; gap: .08rem; }
.movement-summary-title p { margin: 0; }
.movement-summary-title strong { font-size: .95rem; }
.movement-summary-title > span { color: var(--muted); font-size: .78rem; }
.trading-global-summary { width: min(100%, 560px); padding-top: .9rem; padding-bottom: .9rem; transition: width .2s ease; }
.trading-global-summary[open] { width: min(100%, 920px); }
.trading-global-summary > summary { display: grid; gap: .28rem; list-style: none; cursor: pointer; }
.trading-global-summary > summary::-webkit-details-marker { display: none; }
.trading-global-summary > span, .trading-global-summary > summary > span { color: var(--muted); font-size: .78rem; font-weight: 750; letter-spacing: .04em; text-transform: uppercase; }
.trading-global-summary > span i, .trading-global-summary > summary > span i { color: var(--accent); }
.trading-global-summary > div:not(.trading-pending-panel), .trading-global-summary > summary > div { display: flex; align-items: center; flex-wrap: wrap; gap: .55rem; }
.trading-global-summary > div:not(.trading-pending-panel) strong, .trading-global-summary > summary > div strong { font: 750 1.5rem "IBM Plex Mono",monospace; }
.trading-global-summary > div:not(.trading-pending-panel) b, .trading-global-summary > summary > div b { color: var(--muted); font-size: 1.1rem; }
.trading-global-summary > small, .trading-global-summary > summary > small { color: var(--muted); }
.trading-summary-chevron { margin-left: auto; color: var(--accent); font-size: .85rem; transition: transform .18s ease; }
.trading-global-summary[open] .trading-summary-chevron { transform: rotate(180deg); }
.trading-pending-panel { display: grid; gap: .7rem; margin-top: .85rem; padding-top: .8rem; border-top: 1px solid var(--line); }
.trading-pending-panel > header { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.trading-pending-panel > header > div { display: grid; gap: .08rem; }
.trading-pending-panel > header > div:last-child { justify-items: end; text-align: right; }
.trading-pending-panel header span { color: var(--muted); font-size: .7rem; font-weight: 750; letter-spacing: .04em; text-transform: uppercase; }
.trading-pending-panel header strong { color: var(--accent); font: 750 1.12rem "IBM Plex Mono",monospace; }
.trading-pending-panel header small { color: var(--muted); font-size: .72rem; }
.trading-pending-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .45rem; }
.trading-pending-list article { display: grid; grid-template-columns: 38px minmax(0,1fr) auto; align-items: center; gap: .55rem; min-width: 0; padding: .48rem .55rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.trading-pending-list article > img, .trading-pending-list article > .movement-avatar { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; }
.trading-pending-list article > div { display: grid; min-width: 0; gap: .06rem; }
.trading-pending-list article > div strong, .trading-pending-list article > div small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trading-pending-list article > div small { color: var(--muted); font-size: .69rem; }
.trading-card-floor { display: grid; justify-items: end; color: var(--accent); font: 750 .88rem "IBM Plex Mono",monospace; white-space: nowrap; }
.trading-card-floor small { color: var(--muted); font: 500 .6rem Inter,sans-serif; }
.trading-card-floor.is-missing { color: var(--muted); font-family: Inter,sans-serif; font-size: .72rem; }
@media (max-width: 680px) {
  .trading-pending-panel > header { align-items: start; }
  .trading-pending-list { grid-template-columns: 1fr; }
}
.movement-kpis { display: grid; grid-template-columns: 1.2fr 1.2fr .75fr 1fr 1fr; gap: .55rem; }
.movement-kpis article { display: grid; gap: .12rem; padding: .65rem .75rem; border-radius: 15px; }
.movement-kpis span, .movement-kpis small { color: var(--muted); }
.movement-kpis strong { font: 700 1.15rem "IBM Plex Mono",monospace; }
.movement-kpis article > span i { width: 1.1rem; color: var(--accent); }
.spend-split-kpi > div { display: flex; flex-wrap: wrap; gap: .45rem; }
.spend-split-kpi > div strong { display: grid; gap: .08rem; min-width: 105px; padding: .32rem .5rem; border-radius: 9px; background: #f7f5ef; font-size: 1rem; }
.spend-split-kpi > div strong:first-child { color: #b91c1c; }
.spend-split-kpi > div strong:last-child { color: #475569; }
.spend-split-kpi > div small { font: 700 .61rem Inter,sans-serif; letter-spacing: .04em; text-transform: uppercase; }
.sale-split-kpi > div { display: flex; flex-wrap: wrap; gap: .45rem; }
.sale-split-kpi > div strong { display: grid; gap: .08rem; min-width: 105px; padding: .32rem .5rem; border-radius: 9px; background: #f0fdf4; color: var(--good); font-size: 1rem; }
.movement-list-head { min-height: 0; margin-bottom: .55rem; }
.movement-list-head h2 { margin: 0; font-size: 1.25rem; }
.sale-split-kpi > div strong:last-child { color: #166534; }
.sale-split-kpi > div small { font: 700 .61rem Inter,sans-serif; letter-spacing: .04em; text-transform: uppercase; }
.essence-kpi-values { display: flex; flex-wrap: wrap; gap: .4rem; margin: .08rem 0; }
.essence-kpi-values strong { display: inline-flex; align-items: center; gap: .3rem; padding: .3rem .55rem; border-radius: 10px; font-size: 1rem; }
.essence-kpi-values .rarity-limited { color: #854d0e; background: #fef3c7; }
.essence-kpi-values .rarity-rare { color: #991b1b; background: #fee2e2; }
.essence-kpi-values .rarity-super_rare { color: #1e40af; background: #dbeafe; }
.reward-cards-total { color: #5b21b6; }
.is-out { color: #b91c1c !important; }
.is-in { color: var(--good) !important; }
.movement-results { min-width: 0; }
.movement-help { color: var(--muted); font-size: .82rem; }
.movement-filters { display: grid; grid-template-columns: repeat(auto-fit,minmax(135px,1fr)); gap: .65rem; align-items: end; margin: 1rem 0; }
.movement-filters label { min-width: 0; }
.movement-filters input, .movement-filters select { width: 100%; min-height: 44px; padding: .6rem .7rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); font: inherit; }
.movement-clear { min-height: 44px; justify-content: center; }
.movement-table-wrap { overflow: auto; }
.movement-table { min-width: 980px; }
.movement-table td { vertical-align: middle; }
.movement-table td > small, .movement-date small, .movement-kind + small { display: block; margin-top: .2rem; color: var(--muted); }
.movement-date strong { white-space: nowrap; }
.movement-cards { display: grid; gap: .45rem; min-width: 265px; }
.movement-card { display: flex; align-items: center; gap: .65rem; }
.movement-card > img, .movement-avatar { width: 44px; height: 44px; flex: 0 0 auto; border-radius: 50%; object-fit: cover; background: #ecfdf5; }
.movement-avatar { display: grid; place-items: center; color: var(--muted); }
.card-rarity-dot { display: inline-block; width: .62rem; height: .62rem; margin-right: .38rem; border-radius: 50%; vertical-align: .03rem; background: #94a3b8; box-shadow: 0 0 0 2px #fff, 0 0 0 3px rgba(15,23,42,.1); }
.card-rarity-dot.rarity-limited { background: #eab308; }
.card-rarity-dot.rarity-rare { background: #dc2626; }
.card-rarity-dot.rarity-super_rare { background: #2563eb; }
.card-rarity-dot.rarity-unique { background: #111827; }
.season-mark { display: inline-flex; align-items: center; width: max-content; margin-left: .28rem; padding: .1rem .3rem; border-radius: 999px; font-size: .56rem; font-weight: 800; letter-spacing: .035em; line-height: 1.25; text-transform: uppercase; vertical-align: .12rem; }
.season-mark.is-inseason { color: #065f46; background: #d1fae5; box-shadow: inset 0 0 0 1px #6ee7b7; }
.season-mark.is-classic { color: #475569; background: #f1f5f9; box-shadow: inset 0 0 0 1px #cbd5e1; }
.movement-card small { display: flex; align-items: center; gap: .25rem; margin-top: .12rem; color: var(--muted); }
.movement-side { display: grid; gap: .35rem; padding: .45rem .55rem; border-left: 3px solid var(--good); border-radius: 8px; background: #f0fdf4; }
.movement-side.is-sent { border-left-color: #dc2626; background: #fff1f2; }
.movement-side > b { color: var(--muted); font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; }
.movement-team { width: 18px; height: 18px; object-fit: contain; }
.movement-kind { display: inline-flex; align-items: center; gap: .4rem; width: max-content; padding: .32rem .55rem; border-radius: 999px; font-weight: 700; font-size: .8rem; }
.kind-purchase { color: #9f1239; background: #ffe4e6; }
.kind-sale { color: #166534; background: #dcfce7; }
.kind-reward { color: #854d0e; background: #fef9c3; }
.kind-trade { color: #5b21b6; background: #ede9fe; }
.reward-object { display: flex; align-items: center; gap: .7rem; }
.reward-object-icon { display: grid; place-items: center; width: 44px; height: 44px; flex: 0 0 auto; border-radius: 14px; font-size: 1.05rem; }
.reward-object small { display: block; margin-top: .12rem; color: var(--muted); }
.reward-money .reward-object-icon, .reward-kind.reward-money { color: #166534; background: #dcfce7; }
.reward-card .reward-object-icon, .reward-kind.reward-card, .reward-card-value { color: #5b21b6; background: #ede9fe; }
.reward-object.rarity-limited .reward-object-icon, .reward-kind.rarity-limited, .reward-value.rarity-limited { color: #854d0e; background: #fef3c7; }
.reward-object.rarity-rare .reward-object-icon, .reward-kind.rarity-rare, .reward-value.rarity-rare { color: #991b1b; background: #fee2e2; }
.reward-object.rarity-super_rare .reward-object-icon, .reward-kind.rarity-super_rare, .reward-value.rarity-super_rare { color: #1e40af; background: #dbeafe; }
.reward-value { display: inline-flex; align-items: center; gap: .35rem; width: max-content; padding: .32rem .5rem; border-radius: 9px; }
.reward-card-value { padding: .32rem .5rem; border-radius: 9px; }
.movement-amount { min-width: 210px; }
.movement-amount > span { display: inline-grid; gap: .08rem; margin-right: .9rem; }
.movement-amount small { color: var(--muted); }
.movement-amount strong { font-family: "IBM Plex Mono",monospace; }
.movement-amount em { display: block; margin-top: .25rem; color: var(--muted); font-size: .72rem; font-style: normal; }
.movement-pagination { display: flex; flex: none; justify-content: center; align-items: center; gap: .5rem; margin-top: 1rem; }
.movement-pagination a { display: grid; place-items: center; width: 42px; height: 42px; padding: 0; border: 1px solid var(--accent); border-radius: 50%; color: var(--accent); background: #fff; }
.cycle-badges { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .35rem; }
.cycle-match { display: block; width: max-content; max-width: 100%; margin-top: .3rem; padding: .18rem .35rem; border-radius: 999px; font-size: .68rem; font-style: normal; }
.cycle-match.is-exact { color: #166534; background: #dcfce7; }
.cycle-match.is-different { color: #9a3412; background: #ffedd5; }
.cycle-match.is-later { color: #5b21b6; background: #ede9fe; }
.movement-grouped-row { background: #fbfdfb; }
.movement-grouped-row > td { padding-top: .65rem; padding-bottom: .65rem; }
.movement-grouped-row .cycle-badges { justify-content: flex-start; }
.movement-grouped-detail { min-width: 570px; }
.movement-inline-cycle { display: grid; grid-template-columns: minmax(155px,1fr) auto minmax(175px,1fr) minmax(105px,.65fr); align-items: center; gap: .55rem; }
.movement-inline-cycle section, .movement-inline-cycle aside { display: grid; gap: .08rem; padding: .45rem .55rem; border-radius: 9px; background: #f7f5ef; }
.movement-inline-cycle section > span, .movement-inline-cycle aside > span { color: var(--muted); font-size: .64rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.movement-inline-cycle section > small { color: var(--muted); font-size: .7rem; }
.movement-inline-cycle section > strong, .movement-inline-cycle aside > strong { font: 700 .95rem "IBM Plex Mono",monospace; }
.movement-inline-cycle > i { color: var(--accent); }
.movement-inline-cycle aside { border: 1px solid #99d8cf; background: #f0fdfa; }
.movement-inline-cycle aside > strong { font-size: 1.08rem; }
.movement-balance-value { display: flex; align-items: center; flex-wrap: wrap; gap: .28rem; }
.movement-balance-value > strong { font: 700 1.08rem "IBM Plex Mono",monospace; }
.movement-balance-value > b { color: var(--good); font-size: 1rem; }
.movement-balance-value > div { display: flex; flex-wrap: wrap; gap: .22rem; }
.movement-balance-value em { display: inline-flex; align-items: center; padding: .16rem .3rem; border-radius: 999px; background: #fff; color: var(--ink); font-size: .61rem; font-style: normal; box-shadow: inset 0 0 0 1px #bcded7; }
.movement-balance-value .card-rarity-dot { width: .42rem; height: .42rem; margin-right: .24rem; box-shadow: none; }
.movement-chain { display: grid; grid-template-columns: minmax(185px,1fr) minmax(185px,1fr) minmax(115px,.55fr); gap: .45rem; margin-top: .45rem; padding: .45rem; border: 1px solid #d9e6e2; border-radius: 10px; background: #f8fffd; }
.movement-chain section, .movement-chain aside { min-width: 0; }
.movement-chain section > span, .movement-chain aside > span { display: block; margin-bottom: .25rem; color: var(--muted); font-size: .62rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.movement-chain section > div { display: flex; flex-wrap: wrap; gap: .28rem; }
.movement-chain em { display: inline-flex; align-items: center; max-width: 100%; padding: .2rem .38rem; border-radius: 999px; background: #fff; color: var(--ink); font-size: .68rem; font-style: normal; box-shadow: inset 0 0 0 1px var(--line); }
.movement-chain em b { margin-left: .25rem; color: var(--good); font-family: "IBM Plex Mono",monospace; }
.movement-chain .card-rarity-dot { width: .5rem; height: .5rem; margin-right: .28rem; box-shadow: none; }
.movement-chain .season-mark, .movement-balance-value .season-mark { margin-left: .25rem; padding: .06rem .23rem; font-size: .48rem; }
.movement-chain aside { display: grid; align-content: center; padding-left: .45rem; border-left: 1px solid #d9e6e2; }
.movement-chain aside strong { font: 700 .92rem "IBM Plex Mono",monospace; }
.movement-chain aside small { color: var(--muted); font-size: .65rem; }
.movement-inline-notes { display: flex; flex-wrap: wrap; gap: .25rem .8rem; margin-top: .35rem; color: #9a3412; }
.movement-inline-notes small { font-size: .68rem; }
.analytics-hero { background: linear-gradient(120deg,#fff 0%,#f0fdfa 65%,#ecfeff 100%); }
.analytics-updated { display: grid; justify-items: end; gap: .18rem; }
.analytics-updated span { color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; }
.analytics-updated .btn { margin-top: .45rem; }
.analytics-controls { display: grid; gap: .9rem; }
.analytics-presets { display: flex; flex-wrap: wrap; gap: .45rem; }
.analytics-presets a { padding: .45rem .7rem; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); background: #fff; font-size: .78rem; font-weight: 700; }
.analytics-presets a.is-active { border-color: var(--accent); color: #fff; background: var(--accent); }
.analytics-filters { display: grid; grid-template-columns: repeat(5,minmax(130px,1fr)); gap: .65rem; align-items: end; }
.analytics-filters label { min-width: 0; }
.analytics-filters label > span { display: block; margin-bottom: .28rem; color: var(--muted); font-size: .7rem; font-weight: 700; }
.analytics-filters input, .analytics-filters select { width: 100%; min-height: 42px; padding: .55rem .65rem; border: 1px solid var(--line); border-radius: 11px; background: #fff; color: var(--ink); font: inherit; }
.analytics-filters .btn { min-height: 42px; justify-content: center; }
.analytics-kpis { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .8rem; }
.analytics-kpis article { display: grid; gap: .2rem; min-width: 0; }
.analytics-kpis article > span, .analytics-kpis article > small { color: var(--muted); }
.analytics-kpis article > span i { width: 1.15rem; color: var(--accent); }
.analytics-kpis article > strong { font: 700 1.55rem "IBM Plex Mono",monospace; }
.analytics-kpis .analytics-balance { border-color: #99d8cf; background: linear-gradient(135deg,#fff,#f0fdfa); }
.analytics-grid { display: grid; grid-template-columns: minmax(0,.85fr) minmax(0,1.15fr); gap: .8rem; }
.analytics-grid > article { min-width: 0; }
.analytics-type-list { display: grid; gap: .65rem; margin-top: .8rem; }
.analytics-type-row { padding: .7rem; border: 1px solid var(--line); border-left: 5px solid #64748b; border-radius: 13px; background: #fcfbf8; }
.analytics-type-row.type-inseason { border-left-color: var(--accent); background: #f0fdfa; }
.analytics-type-row header { display: flex; align-items: center; justify-content: space-between; gap: .8rem; }
.analytics-type-row header > div { display: grid; gap: .08rem; }
.analytics-type-row header span { font-weight: 800; }
.analytics-type-row header small { color: var(--muted); font-size: .65rem; }
.analytics-type-row header > strong { font: 700 1.12rem "IBM Plex Mono",monospace; }
.analytics-equation { display: grid; grid-template-columns: minmax(105px,1fr) auto minmax(105px,1fr) auto minmax(105px,1fr); align-items: center; gap: .35rem; margin-top: .65rem; }
.analytics-equation > div { display: grid; gap: .08rem; min-height: 58px; align-content: center; padding: .42rem .5rem; border-radius: 9px; background: rgba(255,255,255,.82); }
.analytics-equation > div.is-result { border: 1px solid #99d8cf; background: #fff; }
.analytics-equation small { color: var(--muted); font-size: .59rem; font-weight: 700; text-transform: uppercase; }
.analytics-equation strong { font: 700 .82rem "IBM Plex Mono",monospace; }
.analytics-equation > b { color: var(--muted); }
.analytics-secondary-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: .45rem; margin-top: .45rem; }
.analytics-secondary-metrics > div { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: .1rem .5rem; padding: .48rem .55rem; border-top: 1px solid rgba(215,209,191,.75); }
.analytics-secondary-metrics span { color: var(--muted); font-size: .67rem; font-weight: 700; }
.analytics-secondary-metrics span i { width: .85rem; color: var(--accent); }
.analytics-secondary-metrics strong { font: 700 .84rem "IBM Plex Mono",monospace; }
.analytics-secondary-metrics small { grid-column: 1 / -1; color: var(--muted); font-size: .59rem; }
.analytics-legend { display: flex; gap: .7rem; color: var(--muted); font-size: .7rem; }
.analytics-legend span { display: inline-flex; align-items: center; gap: .3rem; }
.analytics-legend i { width: .65rem; height: .65rem; border-radius: 3px; }
.analytics-legend .is-purchase, .analytics-flow-row span.is-purchase { background: #ef4444; }
.analytics-legend .is-sale, .analytics-flow-row span.is-sale { background: #10b981; }
.analytics-flow-list { display: grid; gap: .5rem; margin-top: .8rem; max-height: 430px; overflow: auto; padding-right: .2rem; }
.analytics-flow-row { display: grid; grid-template-columns: 75px minmax(150px,1fr) 88px; gap: .5rem; align-items: center; }
.analytics-flow-row > strong { color: var(--muted); font-size: .68rem; }
.analytics-net-track { position: relative; height: 13px; border-radius: 999px; background: #f1f0eb; }
.analytics-net-track > i { position: absolute; z-index: 2; top: -3px; bottom: -3px; left: 50%; width: 1px; background: #94a3b8; }
.analytics-net-track > span { position: absolute; top: 1px; bottom: 1px; border-radius: 999px; }
.analytics-net-track > span.is-purchase { right: 50%; }
.analytics-net-track > span.is-sale { left: 50%; }
.analytics-flow-row > em { font: 700 .67rem "IBM Plex Mono",monospace; font-style: normal; text-align: right; white-space: nowrap; }
.analytics-flow-row > small { grid-column: 2 / 4; margin-top: -.28rem; color: var(--muted); font-size: .58rem; text-align: right; }

@media (max-width: 1180px) {
  .sales-filters { grid-template-columns: repeat(4,minmax(150px,1fr)); }
  .movement-filters { grid-template-columns: repeat(4,minmax(145px,1fr)); }
  .movement-kpis { grid-template-columns: 1fr 1fr; }
  .analytics-filters { grid-template-columns: repeat(3,minmax(140px,1fr)); }
  .analytics-kpis { grid-template-columns: 1fr 1fr; }
  .analytics-grid { grid-template-columns: 1fr; }
}
@media (max-width: 780px) {
  .sales-market-head, .sales-toolbar { align-items: stretch; flex-direction: column; }
  .sales-sync-box { min-width: 0; }
  .sales-toolbar-actions { justify-content: flex-end; }
  .sales-filters { grid-template-columns: 1fr 1fr; }
  .sales-review-item { grid-template-columns: 1fr 1fr; }
  .sales-review-player { grid-column: 1 / -1; }
  .sales-modal-card { padding: 1.1rem; }
  .movements-hero { align-items: stretch; flex-direction: column; }
  .movement-command-main { align-items: stretch; flex-direction: column; }
  .movement-command-actions { justify-content: space-between; }
  .movement-command-bar .movement-sync { justify-content: flex-end; }
  .history-coverage-warning { grid-template-columns: auto 1fr; }
  .history-coverage-warning .btn { grid-column: 1 / -1; justify-self: stretch; }
  .analytics-updated { justify-items: start; }
  .movement-sync { justify-items: start; }
  .reward-manager-switch { align-items: stretch; flex-direction: column; }
  .reward-manager-switch label { align-items: stretch; flex-direction: column; gap: .25rem; }
  .reward-manager-switch select { width: 100%; }
  .movement-filters { grid-template-columns: 1fr 1fr; }
  .movement-summary-title { align-items: start; flex-direction: column; }
  .movement-chain { grid-template-columns: 1fr; }
  .movement-chain aside { padding: .35rem 0 0; border-top: 1px solid #d9e6e2; border-left: 0; }
  .table-head { align-items: stretch; flex-direction: column; }
  .analytics-filters { grid-template-columns: 1fr 1fr; }
  .analytics-equation { grid-template-columns: 1fr auto 1fr; }
  .analytics-equation > b:nth-of-type(2), .analytics-equation > .is-result { display: none; }
  .analytics-flow-row { grid-template-columns: 65px minmax(90px,1fr) 75px; }
}
@media (max-width: 520px) {
  .sales-filters, .sales-review-item { grid-template-columns: 1fr; }
  .sales-review-player { grid-column: auto; }
  .sales-basket { width: 100%; justify-content: space-between; border-radius: 18px; }
  .movement-filters, .movement-kpis, .analytics-filters, .analytics-kpis { grid-template-columns: 1fr; }
  .movement-command-actions { align-items: stretch; flex-direction: column; }
  .movement-command-bar .movement-sync { align-items: flex-start; justify-content: flex-start; flex-wrap: wrap; }
  .movement-command-bar .movement-sync > span { max-width: none; text-align: left; }
  .analytics-secondary-metrics { grid-template-columns: 1fr; }
}

/* Retirada de publicaciones */
.delist-page { display: grid; gap: 1rem; }
.delist-head { display: flex; justify-content: space-between; align-items: center; gap: 2rem; }
.delist-head h1 { margin: .15rem 0 .4rem; font-size: clamp(1.8rem,3vw,2.7rem); }
.delist-head p { margin: 0; color: var(--muted); }
.delist-sync { display: grid; min-width: 300px; gap: .28rem; padding: .8rem 1rem; border: 1px solid var(--line); border-radius: 14px; background: rgba(255,255,255,.5); }
.delist-sync span, .delist-sync small { color: var(--muted); font-size: .65rem; }
.delist-sync strong { font: 700 .9rem "IBM Plex Mono",monospace; }
.delist-sync .btn { justify-self: start; margin-top: .3rem; min-height: 36px; padding: .42rem .72rem; font-size: .65rem; }
.delist-filter-panel form { display: grid; grid-template-columns: 1.2fr .8fr auto; align-items: end; gap: 1.1rem; }
.delist-filter-panel fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.delist-filter-panel legend { margin-bottom: .45rem; color: var(--muted); font-weight: 700; font-size: .68rem; }
.delist-choice-row { display: flex; flex-wrap: wrap; gap: .45rem; }
.delist-choice input { position: absolute; opacity: 0; pointer-events: none; }
.delist-choice span { display: flex; align-items: center; gap: .42rem; min-height: 44px; padding: .58rem .8rem; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.56); color: var(--muted); font-weight: 700; cursor: pointer; transition: .18s ease; }
.delist-choice input:checked + span { border-color: var(--accent); background: rgba(13,148,136,.1); color: var(--ink); box-shadow: inset 0 0 0 1px var(--accent); }
.delist-choice.rarity-limited input:checked + span i { color: #eab308; }.delist-choice.rarity-rare input:checked + span i { color: #ef4444; }.delist-choice.rarity-super input:checked + span i { color: #2563eb; }
.delist-warning { margin: .8rem 0 0; color: #9a5d16; font-size: .68rem; }
.delist-results-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: .8rem; }
.delist-results-head h2 { margin: .1rem 0 0; }
.delist-toggle-all { display: flex; align-items: center; gap: .45rem; font-weight: 700; cursor: pointer; }
.delist-toggle-all input, .delist-select { width: 18px; height: 18px; accent-color: var(--accent); }
.delist-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .55rem; }
.delist-card { position: relative; display: grid; grid-template-columns: auto 48px minmax(0,1fr) auto; align-items: center; gap: .7rem; padding: .7rem; border: 1px solid var(--line); border-radius: 14px; background: rgba(255,255,255,.58); cursor: pointer; transition: .18s ease; }
.delist-card:has(.delist-select:checked) { border-color: rgba(13,148,136,.48); background: rgba(236,253,250,.66); }
.delist-card > .delist-select { position: absolute; opacity: 0; }
.delist-check { display: grid; place-items: center; width: 24px; height: 24px; border: 1px solid #b8b7af; border-radius: 7px; color: transparent; }
.delist-select:checked + .delist-check { border-color: var(--accent); background: var(--accent); color: white; }
.delist-player-picture { display: grid; place-items: center; width: 48px; height: 48px; overflow: hidden; border-radius: 50%; background: #ecf4f2; color: var(--muted); }
.delist-player-picture img { width: 100%; height: 100%; object-fit: cover; }
.delist-card-copy { display: grid; min-width: 0; gap: .12rem; }
.delist-card-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.delist-card-copy small { display: flex; align-items: center; gap: .25rem; color: var(--muted); font-size: .62rem; }
.delist-card-copy small img { width: 17px; height: 17px; object-fit: contain; }
.delist-card-copy em { color: var(--muted); font-style: normal; font-size: .57rem; }
.delist-rarity { display: inline-block; width: 7px; height: 7px; margin-right: .3rem; border-radius: 50%; }.delist-rarity.is-limited { background: #eab308; }.delist-rarity.is-rare { background: #ef4444; }.delist-rarity.is-super_rare { background: #2563eb; }
.delist-price { display: grid; justify-items: end; }.delist-price strong { color: var(--accent); font: 700 .84rem "IBM Plex Mono",monospace; }
.delist-actionbar { position: sticky; z-index: 5; bottom: 1rem; display: flex; justify-content: flex-end; align-items: center; gap: 1rem; width: fit-content; margin: 1rem 0 0 auto; padding: .55rem .65rem .55rem 1rem; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); box-shadow: 0 12px 35px rgba(15,23,42,.16); }
.btn-danger { border-color: #dc2626; background: #dc2626; color: white; }.btn-danger:hover { background: #b91c1c; }.btn-danger:disabled { opacity: .45; cursor: not-allowed; }
.delist-empty { display: grid; justify-items: center; gap: .35rem; padding: 3.5rem 1rem; text-align: center; }.delist-empty > i { color: var(--accent); font-size: 2rem; }.delist-empty h3, .delist-empty p { margin: 0; }.delist-empty p { color: var(--muted); }
.delist-modal-card { width: min(680px,96vw); }.delist-review-list { max-height: 48vh; overflow: auto; }
.delist-review-item { display: grid; grid-template-columns: 40px 1fr auto; align-items: center; gap: .65rem; padding: .55rem .65rem; border: 1px solid var(--line); border-radius: 12px; }
.delist-review-item > span { display: block; width: 40px; height: 40px; overflow: hidden; border-radius: 50%; }.delist-review-item img { width: 100%; height: 100%; object-fit: cover; }.delist-review-item button { width: 32px; height: 32px; border: 0; border-radius: 50%; background: #fee2e2; color: #b91c1c; cursor: pointer; }
@media (max-width: 850px) { .delist-head { align-items: stretch; flex-direction: column; }.delist-sync { min-width: 0; }.delist-filter-panel form { grid-template-columns: 1fr; }.delist-grid { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .delist-card { grid-template-columns: auto 42px minmax(0,1fr); }.delist-player-picture { width: 42px; height: 42px; }.delist-price { grid-column: 3; justify-items: start; }.delist-actionbar { left: .5rem; right: .5rem; width: auto; justify-content: space-between; }.delist-actionbar span { font-size: .62rem; } }

/* Oportunidades */
.opportunities-page { display: grid; gap: 1rem; min-width: 0; }
.opportunities-page > *, .opportunity-results { min-width: 0; }
.opportunity-hero { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.opportunity-hero h1 { margin: .15rem 0 .35rem; }
.opportunity-hero h1 i { color: var(--accent); }
.opportunity-hero p:last-child { margin: 0; color: var(--muted); }
.opportunity-refresh { display: grid; justify-items: end; gap: .25rem; min-width: 220px; }
.opportunity-refresh > span { color: var(--muted); font-size: .7rem; }
.opportunity-refresh > strong { font: 700 .78rem "IBM Plex Mono",monospace; }
.opportunity-team-refresh { display: grid; gap: .7rem; padding: 1rem 1.15rem; }
.opportunity-team-refresh-head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; }
.opportunity-team-refresh-head h2, .opportunity-team-refresh-head p { margin: 0; }
.opportunity-team-refresh-head h2 { font-size: 1.1rem; }
.opportunity-team-refresh-head p:not(.kicker) { margin-top: .2rem; color: var(--muted); font-size: .68rem; }
.opportunity-team-refresh-actions { display: flex; align-items: center; gap: .75rem; flex: 0 0 auto; }
.opportunity-all-teams { display: inline-flex; align-items: center; justify-content: center; gap: .35rem; min-height: 38px; padding: .45rem .8rem; border: 1px solid #c9c6bc; border-radius: 999px; background: #f3f2ed; color: var(--muted); font-family: inherit; font-size: .68rem; font-weight: 800; cursor: pointer; transition: color .15s, border-color .15s, background .15s, box-shadow .15s; }
.opportunity-all-teams:hover { border-color: #5da9a1; color: #0f766e; }
.opportunity-all-teams.is-active { border-color: #0f766e; background: #115e59; color: #fff; box-shadow: 0 5px 14px rgba(15,118,110,.18); }
.opportunity-team-grid { display: grid; grid-template-columns: repeat(10,58px); gap: .48rem; }
.opportunity-team-choice { position: relative; display: grid; place-items: center; width: 58px; height: 58px; padding: .42rem; border: 1px solid #d8d5cd; border-radius: 13px; background: #efeee9; cursor: pointer; opacity: .42; filter: grayscale(.72); transition: opacity .15s, filter .15s, transform .15s, background .15s, box-shadow .15s; }
.opportunity-team-choice:hover { opacity: .72; transform: translateY(-1px); }
.opportunity-team-choice input { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }
.opportunity-team-choice img { width: 39px; height: 39px; object-fit: contain; }
.opportunity-team-choice.is-depor img { width: 42px; height: 42px; border-radius: 50%; }
.opportunity-team-choice > i { position: absolute; top: 3px; right: 3px; color: #a7f3d0; font-size: .62rem; }
.opportunity-team-choice:has(input:checked) { border-color: #0f766e; background: #115e59; box-shadow: 0 5px 14px rgba(15,118,110,.2); opacity: 1; filter: none; }
.opportunity-team-choice:focus-within { outline: 3px solid rgba(20,184,166,.25); outline-offset: 2px; }
.opportunity-team-fallback { display: grid; place-items: center; width: 39px; height: 39px; border-radius: 50%; background: rgba(255,255,255,.82); color: #115e59; font-size: .72rem; font-weight: 800; text-transform: uppercase; }
.opportunity-team-loading { margin: 0; color: var(--muted); font-size: .7rem; }
.opportunity-kpis { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .65rem; }
.opportunity-kpis article { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: .08rem .7rem; align-items: center; min-width: 0; padding: .58rem .78rem; }
.opportunity-kpis article > span { color: var(--muted); font-size: .64rem; font-weight: 700; }
.opportunity-kpis article > span i { width: 1rem; color: var(--accent); }
.opportunity-kpis article > strong { grid-column: 2; grid-row: 1 / 3; font: 700 1.08rem "IBM Plex Mono",monospace; }
.opportunity-kpis article > small { color: var(--muted); font-size: .56rem; line-height: 1.25; }
.opportunity-kpi-highlight { border-color: #8ed9cf; background: linear-gradient(135deg,#fff,#ecfdf8); }
.opportunity-progress { display: grid; gap: .55rem; }
.opportunity-progress[hidden] { display: none !important; }
.opportunity-progress > div:first-child { display: grid; grid-template-columns: auto auto minmax(0,1fr); align-items: center; gap: .5rem; min-width: 0; }
.opportunity-progress > div:first-child i { color: var(--accent); }
.opportunity-progress > div:first-child span { min-width: 0; color: var(--muted); font-size: .72rem; text-align: right; overflow-wrap: anywhere; }
.opportunity-progress.is-error > div:first-child span { text-align: left; }
.opportunity-progress.is-error > div:first-child i { color: #dc2626; }
.opportunity-progress-track { height: 8px; overflow: hidden; border-radius: 99px; background: #eceae3; }
.opportunity-progress-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg,var(--accent),#22c55e); transition: width .25s; }
.opportunity-controls { padding: .8rem 1rem; }
.opportunity-filters { display: grid; grid-template-columns: minmax(250px,1.25fr) repeat(2,minmax(155px,1fr)) auto; gap: .55rem; align-items: stretch; }
.opportunity-rarity-switch { display: grid; grid-template-columns: 1fr 1fr; gap: .35rem; min-width: 0; margin: 0; padding: .3rem .4rem .4rem; border: 1px solid var(--line); border-radius: 11px; }
.opportunity-rarity-switch legend { padding: 0 .22rem; color: var(--muted); font-size: .58rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.opportunity-rarity-switch label { position: relative; cursor: pointer; }
.opportunity-rarity-switch input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.opportunity-rarity-switch span { display: flex; align-items: center; justify-content: center; gap: .35rem; min-height: 34px; padding: .3rem .55rem; border: 1px solid transparent; border-radius: 8px; color: var(--muted); font-size: .7rem; font-weight: 800; transition: background .15s,border-color .15s,color .15s; }
.opportunity-rarity-switch .is-limited input:checked + span { border-color: #d9a900; background: #fff4b8; color: #805900; }
.opportunity-rarity-switch .is-rare input:checked + span { border-color: #e94355; background: #ffe0e4; color: #9f1428; }
.opportunity-rarity-switch label:focus-within span { outline: 2px solid rgba(20,184,166,.25); outline-offset: 1px; }
.opportunity-filter-field { display: grid; gap: .18rem; padding: .38rem .5rem .45rem; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.7); }
.opportunity-filter-field > span { color: var(--muted); font-size: .6rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.opportunity-filter-field > span i { width: .9rem; color: var(--accent); }
.opportunity-filter-field select { width: 100%; min-height: 28px; padding: 0 1.25rem 0 0; border: 0; outline: 0; background-color: transparent; color: var(--ink); font-size: .72rem; font-weight: 700; }
.opportunity-check { position: relative; display: flex; min-height: 58px; border: 1px solid #8ed9cf; border-radius: 11px; background: #effaf8; cursor: pointer; }
.opportunity-check input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.opportunity-check > span { display: grid; grid-template-columns: auto 1fr; align-content: center; column-gap: .45rem; width: 100%; padding: .42rem .65rem; color: #0f766e; }
.opportunity-check > span i { grid-row: 1 / 3; align-self: center; font-size: .9rem; }
.opportunity-check > span b { font-size: .68rem; }
.opportunity-check > span small { color: var(--muted); font-size: .54rem; }
.opportunity-check:has(input:checked) { border-color: #0f766e; background: #115e59; }
.opportunity-check:has(input:checked) > span, .opportunity-check:has(input:checked) > span small { color: #fff; }
.opportunity-clear { min-height: 38px; padding: .38rem .75rem; }
.opportunity-results .table-head > p { color: var(--muted); font-size: .68rem; }
.opportunity-table-wrap { width: 100%; max-width: 100%; overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; }
.opportunity-table { width: 100%; min-width: 1050px; border-collapse: collapse; }
.opportunity-table th { padding: .65rem .75rem; background: #f7f4ec; text-align: left; font-size: .68rem; }
.opportunity-table th small { margin-left: .2rem; color: var(--muted); font-size: .52rem; font-weight: 600; }
.opportunity-table th.rarity-limited { box-shadow: inset 0 3px #eab308; }
.opportunity-table th.rarity-rare { box-shadow: inset 0 3px #ef4444; }
.opportunity-table th.is-focus { background: #f1eee5; }
.opportunity-table td { padding: .72rem .75rem; border-top: 1px solid var(--line); vertical-align: middle; }
.opportunity-table td.opportunity-focus-cell { background: rgba(15,118,110,.025); }
.opportunity-main-row { cursor: pointer; transition: background .15s; }
.opportunity-main-row:hover { background: #f8fffd; }
.opportunity-player { display: flex; align-items: center; gap: .65rem; min-width: 215px; }
.opportunity-player > img { width: 46px; height: 46px; border-radius: 50%; object-fit: contain; background: #eafbf7; }
.opportunity-player > div { display: grid; gap: .18rem; }
.opportunity-player strong { font-size: .82rem; }
.opportunity-player span { display: flex; align-items: center; gap: .3rem; color: var(--muted); font-size: .65rem; }
.opportunity-player span img { width: 18px; height: 18px; object-fit: contain; }
.opportunity-price { display: grid; gap: .08rem; min-width: 145px; }
.opportunity-price small { color: var(--muted); font-size: .58rem; text-transform: uppercase; }
.opportunity-price strong { font: 700 1.02rem "IBM Plex Mono",monospace; }
.opportunity-price span { font-size: .64rem; }
.opportunity-price em { color: var(--muted); font-size: .58rem; font-style: normal; }
.instant-purchase-filters { display: grid; grid-template-columns: minmax(180px,1.2fr) repeat(4,minmax(130px,1fr)) minmax(165px,auto) auto; gap: .55rem; align-items: stretch; }
.instant-purchase-filters input[type="search"] { width: 100%; min-height: 28px; padding: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font: 700 .72rem "Space Grotesk",sans-serif; }
.instant-purchase-table { min-width: 1180px; }
.instant-current-price strong { color: #b91c1c; }
.instant-valuation { display: grid; gap: .06rem; min-width: 132px; padding: .45rem .55rem; border-radius: 8px; background: #f4f2ec; }
.instant-valuation small { font-size: .57rem; }
.instant-valuation strong { font: 700 1.08rem "IBM Plex Mono",monospace; }
.instant-valuation span { font-size: .56rem; }
.instant-valuation.is-favorable { background: #dcfce7; color: #166534; }
.instant-valuation.is-unfavorable { background: #fee2e2; color: #991b1b; }
.muted-dash { color: var(--muted); }
.opportunity-signal { display: grid; gap: .05rem; min-width: 120px; padding: .45rem .55rem; border-radius: 10px; }
.opportunity-signal small { font-size: .59rem; font-weight: 800; text-transform: uppercase; }
.opportunity-signal strong { font: 700 1.12rem "IBM Plex Mono",monospace; }
.opportunity-signal span { font-size: .56rem; text-transform: capitalize; }
.signal-limited { color: #8a6000; background: #fff6c7; }
.signal-rare { color: #a1162a; background: #ffe2e5; }
.opportunity-no-signal { display: grid; gap: .1rem; color: var(--muted); font-size: .62rem; }
.opportunity-actions { display: flex; gap: .35rem; }
.opportunity-actions button, .opportunity-actions a { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--accent); border-radius: 50%; background: #fff; color: var(--accent); cursor: pointer; }
.opportunity-evidence-row td { padding: 0; background: #f8fbfa; }
.opportunity-evidence { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; padding: .8rem; }
.opportunity-evidence section { min-width: 0; padding: .7rem; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.opportunity-evidence h3 { margin: 0 0 .25rem; font-size: .76rem; }
.opportunity-evidence p { margin: 0 0 .5rem; color: var(--muted); font-size: .61rem; }
.limited-dot { color: #eab308; }.rare-dot { color: #ef4444; }
.opportunity-sales { display: flex; flex-wrap: wrap; gap: .35rem; }
.opportunity-sales > span { display: grid; grid-template-columns: auto auto; gap: .05rem .25rem; align-items: center; padding: .32rem .4rem; border: 1px solid var(--line); border-radius: 8px; background: #fbfaf7; }
.opportunity-sales i { color: var(--accent); font-size: .6rem; }
.opportunity-sales strong { font: 700 .65rem "IBM Plex Mono",monospace; }
.opportunity-sales small { grid-column: 1 / -1; color: var(--muted); font-size: .52rem; }
.opportunity-sales em { color: var(--muted); font-size: .62rem; }
.opportunity-method-note { margin: 0; padding: 0 .8rem .8rem; color: #756d5f; font-size: .59rem; }
.opportunity-pagination { display: flex; justify-content: center; align-items: center; gap: .6rem; margin-top: .8rem; }
.opportunity-pagination a { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--accent); border-radius: 50%; color: var(--accent); }
.opportunity-pagination span { font-size: .7rem; }
.opportunity-empty { display: grid; justify-items: center; gap: .5rem; padding: 3rem; text-align: center; }
.opportunity-empty > i { color: var(--accent); font-size: 2rem; }
.opportunity-empty h2, .opportunity-empty p { margin: 0; }
.opportunity-empty p { color: var(--muted); }

@media (max-width: 1180px) {
  .opportunity-kpis { grid-template-columns: repeat(3,1fr); }
  .opportunity-filters, .instant-purchase-filters { grid-template-columns: repeat(3,minmax(140px,1fr)); }
}
@media (max-width: 780px) {
  .opportunity-hero { align-items: stretch; flex-direction: column; }
  .opportunity-refresh { justify-items: start; }
  .opportunity-team-refresh-head, .opportunity-team-refresh-actions { align-items: stretch; flex-direction: column; }
  .opportunity-team-grid { grid-template-columns: repeat(5,58px); }
  .opportunity-filters, .instant-purchase-filters { grid-template-columns: 1fr 1fr; }
  .opportunity-evidence { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .opportunity-kpis, .opportunity-filters, .instant-purchase-filters { grid-template-columns: 1fr; }
  .opportunity-team-choice { width: 52px; height: 52px; }
  .opportunity-team-grid { grid-template-columns: repeat(4,52px); }
  .opportunity-team-choice img, .opportunity-team-fallback { width: 35px; height: 35px; }
  .opportunity-team-choice.is-depor img { width: 38px; height: 38px; }
}
