:root {
  --page: #eef2f7;
  --panel: #ffffff;
  --panel-strong: #161719;
  --ink: #17191f;
  --muted: #667085;
  --line: #d9dee7;
  --line-strong: #b7c0cf;
  --green: #16865a;
  --green-soft: #dff6ec;
  --blue: #2357d8;
  --blue-soft: #e7edff;
  --red: #c83f46;
  --amber: #a86c08;
  --amber-soft: #fff2d8;
  --shadow: 0 18px 42px rgba(22, 23, 25, 0.08);
  --shadow-strong: 0 28px 70px rgba(22, 23, 25, 0.14);
  --radius: 8px;
  --app-ui-font: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  /* MEMORY LINE: System Health Check START */
  --mobile-page-height: 100dvh;
  --app-safe-bottom: max(18px, env(safe-area-inset-bottom));
  --app-bottom-nav-clearance: calc(104px + env(safe-area-inset-bottom));
  --scanner-layout-height: 100dvh;
  /* MEMORY LINE: System Health Check END */
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: var(--mobile-page-height);
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background:
    linear-gradient(180deg, rgba(35, 87, 216, 0.12), transparent 310px),
    radial-gradient(circle at top right, rgba(22, 134, 90, 0.14), transparent 320px),
    var(--page);
  color: var(--ink);
}

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

/* MEMORY LINE: Performance Cleanup START */
.catalog-result-card,
.sold-item,
.scanner-job,
.vendor-inventory-card {
  content-visibility: auto;
  contain-intrinsic-size: 1px 260px;
}
/* MEMORY LINE: Performance Cleanup END */

/* MEMORY LINE: UI Cleanup START */
.catalog-result-copy strong,
.portfolio-card-copy h3,
.sold-title-row h4,
.vendor-card-title-row h2 {
  overflow-wrap: anywhere;
}
/* MEMORY LINE: UI Cleanup END */

/* MEMORY LINE: Scanner Search Fix START */
body.catalog-search-active {
  min-height: var(--scanner-layout-height);
  background:
    linear-gradient(180deg, rgba(2, 7, 14, 0.96), rgba(2, 4, 10, 1) 320px),
    #02040a;
  color: #f8fffd;
}

body.catalog-search-active .collector-app,
body.catalog-search-active .bottom-nav {
  display: none;
}

.catalog-search-page[hidden] {
  display: none;
}

.catalog-search-page {
  min-height: var(--scanner-layout-height);
  padding: max(72px, calc(env(safe-area-inset-top) + 42px)) 16px max(28px, env(safe-area-inset-bottom));
  background:
    linear-gradient(180deg, rgba(126, 211, 202, 0.12), transparent 190px),
    #02040a;
}

.catalog-search-head {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  width: min(1200px, 100%);
  margin: 0 auto 18px;
}

.catalog-exit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 66px;
  height: 42px;
  padding: 0 16px;
  color: #ecfffb;
  font: inherit;
  font-size: 0.94rem;
  font-weight: 840;
  letter-spacing: 0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
}

.catalog-search-head h1 {
  margin: 1px 0 2px;
  font-size: 2.18rem;
  line-height: 1;
  letter-spacing: 0;
}

.catalog-search-head span {
  display: block;
  overflow: hidden;
  color: rgba(214, 226, 255, 0.78);
  font-size: 0.86rem;
  font-weight: 760;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.catalog-search-form {
  width: min(1200px, 100%);
  margin: 0 auto 16px;
}

.catalog-search-field {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 48px;
  padding: 0 15px;
  color: #dbe7ff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(126, 211, 202, 0.34);
  border-radius: 8px;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.22);
}

.catalog-search-field:focus-within {
  border-color: rgba(126, 211, 202, 0.78);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.22), 0 0 0 3px rgba(126, 211, 202, 0.14);
}

.catalog-search-submit {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  color: inherit;
  background: transparent;
  border: 0;
}

.catalog-search-field svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.55;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.catalog-search-field input {
  width: 100%;
  min-width: 0;
  height: 46px;
  padding: 0;
  color: #f8fffd;
  background: transparent;
  border: 0;
  outline: 0;
  font-size: 1rem;
  font-weight: 850;
  letter-spacing: 0;
}

.catalog-search-field input::placeholder {
  color: rgba(219, 231, 255, 0.62);
}

.catalog-state {
  width: min(1200px, 100%);
  margin: 0 auto 14px;
  padding: 12px 14px;
  color: #dbe7ff;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  font-size: 0.86rem;
  font-weight: 750;
}

.catalog-results {
  display: grid;
  gap: 14px;
  width: min(1200px, 100%);
  margin: 0 auto;
}

/* MEMORY LINE: Catalog Layout Upgrade START */
.catalog-result-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 2px 0 4px;
}

.catalog-result-tabs button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
  min-height: 44px;
  padding: 0 14px;
  color: rgba(219, 231, 255, 0.82);
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  touch-action: manipulation;
  cursor: pointer;
}

.catalog-result-tabs button span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.catalog-result-tabs button.is-active {
  color: #06110f;
  background: linear-gradient(135deg, #9ee7b1, #7ed3ca);
  border-color: transparent;
  box-shadow: 0 14px 28px rgba(126, 211, 202, 0.18);
}

.catalog-result-tabs button strong {
  display: grid;
  place-items: center;
  min-width: 24px;
  height: 24px;
  padding: 0 7px;
  color: inherit;
  background: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  font-size: 0.72rem;
}

.catalog-result-tab-panels {
  min-width: 0;
}

.catalog-result-section {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.catalog-result-section[hidden] {
  display: none;
}

.catalog-result-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px;
}

.catalog-result-section-head h2 {
  margin: 0;
  color: rgba(219, 231, 255, 0.82);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.catalog-result-section-head span {
  min-width: 26px;
  padding: 4px 8px;
  color: #06110f;
  background: #8fe0a7;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 950;
  text-align: center;
}

.catalog-result-card-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  align-items: stretch;
}

.catalog-empty-panel {
  display: grid;
  gap: 5px;
  min-height: 150px;
  padding: 22px;
  color: rgba(219, 231, 255, 0.72);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  align-content: center;
}

.catalog-empty-panel strong {
  color: #f8fffd;
  font-size: 0.98rem;
}

.catalog-empty-panel span {
  max-width: 34rem;
  font-size: 0.84rem;
  line-height: 1.4;
}
/* MEMORY LINE: Catalog Layout Upgrade END */

/* MEMORY LINE: CATALOG RESULT CARD UI START */
.catalog-result-card {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 11px;
  min-width: 0;
  min-height: 100%;
  padding: 11px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.095), rgba(255, 255, 255, 0.058));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.22);
}

.catalog-result-media {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
}

.catalog-result-media img {
  position: absolute;
  inset: 8px;
  display: block;
  width: calc(100% - 16px);
  height: calc(100% - 16px);
  padding: 0;
  object-fit: contain;
}

.catalog-result-image-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
}

.catalog-result-image-fallback {
  color: rgba(219, 231, 255, 0.72);
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-align: center;
  text-transform: uppercase;
}

.catalog-result-copy {
  display: grid;
  grid-template-rows: auto auto auto auto 1fr;
  gap: 6px;
  min-width: 0;
  align-content: start;
}

.catalog-result-label-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.catalog-result-kind {
  color: #a5bfff;
  font-size: 0.58rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.catalog-result-best-badge,
.catalog-result-confidence-badge {
  min-height: 19px;
  padding: 3px 7px;
  border-radius: 999px;
  font-size: 0.58rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.catalog-result-best-badge {
  color: #06110f;
  background: #8fe0a7;
}

.catalog-result-confidence-badge {
  color: rgba(219, 231, 255, 0.88);
  background: rgba(165, 191, 255, 0.14);
}

.catalog-result-copy strong {
  color: #fff;
  display: -webkit-box;
  overflow: hidden;
  min-height: 2.3em;
  font-size: 0.98rem;
  line-height: 1.15;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.catalog-result-copy small {
  display: -webkit-box;
  overflow: hidden;
  color: rgba(236, 255, 251, 0.72);
  font-size: 0.76rem;
  line-height: 1.25;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.catalog-result-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.catalog-result-meta span {
  min-height: 21px;
  padding: 4px 7px;
  color: #dbe7ff;
  background: rgba(126, 211, 202, 0.12);
  border: 1px solid rgba(126, 211, 202, 0.16);
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 850;
}

.catalog-result-footer {
  display: grid;
  gap: 8px;
  align-self: end;
  margin-top: 4px;
}

.catalog-result-condition-control {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.catalog-result-condition-control span {
  color: rgba(219, 231, 255, 0.76);
  font-size: 0.58rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.catalog-result-condition-select {
  width: 100%;
  min-height: 34px;
  min-width: 0;
  padding: 0 30px 0 10px;
  color: #f8fffd;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(126, 211, 202, 0.22);
  border-radius: 8px;
  font-size: 0.76rem;
  font-weight: 850;
}

.catalog-result-price {
  color: #8fe0a7;
  font-size: 1.12rem;
  font-weight: 950;
  letter-spacing: 0;
}

.catalog-result-actions {
  display: grid;
  gap: 7px;
}

.catalog-grade-price-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  width: 100%;
  padding: 0 12px;
  color: #241104;
  background: linear-gradient(135deg, #ffe08a, #ffb84d 52%, #ff7f50);
  border: 1px solid rgba(255, 233, 176, 0.72);
  border-radius: 8px;
  font-size: 0.74rem;
  font-weight: 950;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  box-shadow: 0 16px 34px rgba(255, 184, 77, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.36);
  cursor: pointer;
}

.catalog-add-collection-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  width: 100%;
  padding: 0 12px;
  color: #06110f;
  background: #8fe0a7;
  border: 0;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.catalog-add-collection-btn.is-added,
.catalog-add-collection-btn:disabled {
  color: rgba(255, 255, 255, 0.88);
  background: rgba(255, 255, 255, 0.14);
}

.catalog-save-sheet {
  --catalog-save-sheet-backdrop-opacity: 0;
  --catalog-save-sheet-close-y: calc(100% + max(24px, env(safe-area-inset-bottom)));
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  align-items: end;
  padding: 0 10px max(10px, env(safe-area-inset-bottom));
  pointer-events: auto;
  overscroll-behavior: contain;
}

.catalog-save-sheet::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: rgba(2, 4, 10, 0.5);
  backdrop-filter: blur(18px) saturate(82%) brightness(0.76);
  -webkit-backdrop-filter: blur(18px) saturate(82%) brightness(0.76);
  content: "";
  opacity: var(--catalog-save-sheet-backdrop-opacity);
  transition: opacity 220ms ease;
}

.catalog-save-sheet[hidden] {
  display: none;
}

.catalog-save-sheet.is-open {
  --catalog-save-sheet-backdrop-opacity: 1;
}

.catalog-save-sheet.is-closing {
  --catalog-save-sheet-backdrop-opacity: 0;
  pointer-events: none;
}

.catalog-save-sheet.is-dragging::before {
  transition: none;
}

.catalog-save-sheet-panel {
  position: relative;
  z-index: 1;
  width: min(620px, 100%);
  max-height: min(78dvh, 620px);
  margin: 0 auto;
  overflow-x: hidden;
  overflow-y: auto;
  color: #f8fafc;
  background: rgba(18, 22, 29, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 26px 26px 18px 18px;
  box-shadow: 0 -24px 58px rgba(0, 0, 0, 0.44);
  scroll-behavior: smooth;
  touch-action: pan-y;
  transform: translate3d(0, var(--catalog-save-sheet-close-y), 0);
  transition:
    transform 240ms cubic-bezier(0.2, 0.88, 0.22, 1),
    max-height 220ms ease,
    height 220ms ease;
  will-change: transform;
  -webkit-overflow-scrolling: touch;
}

.catalog-save-sheet.is-open .catalog-save-sheet-panel {
  transform: translate3d(0, 0, 0);
}

.catalog-save-sheet.is-dragging .catalog-save-sheet-panel {
  transition: none;
}

.catalog-save-sheet-panel.is-expanded {
  height: min(90dvh, 760px);
  max-height: min(90dvh, 760px);
}

.catalog-save-sheet-handle {
  display: block;
  width: 52px;
  height: 5px;
  margin: 10px auto 4px;
  padding: 0;
  background: rgba(148, 163, 184, 0.62);
  border: 0;
  border-radius: 999px;
  touch-action: none;
}

.catalog-save-sheet-panel.is-expanded .catalog-save-sheet-handle {
  width: 66px;
  background: rgba(126, 211, 202, 0.76);
}

.catalog-save-sheet-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 10px 16px 12px;
  touch-action: none;
}

.catalog-save-sheet-head span {
  display: block;
  color: #a8bdff;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.catalog-save-sheet-head h3 {
  max-width: 100%;
  overflow: hidden;
  margin: 3px 0 0;
  color: #fff;
  font-size: 1.02rem;
  font-weight: 860;
  line-height: 1.08;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.catalog-save-sheet-head small {
  display: block;
  margin-top: 4px;
  color: #a5adba;
  font-size: 0.78rem;
  font-weight: 750;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.catalog-save-sheet-head button {
  min-height: 36px;
  padding: 0 13px;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  font-weight: 950;
}

.catalog-save-form {
  display: grid;
  grid-template-columns: minmax(118px, 0.36fr) minmax(0, 0.64fr);
  gap: 12px;
  padding: 0 16px max(18px, env(safe-area-inset-bottom));
}

.catalog-save-preview {
  display: grid;
  place-items: center;
  align-self: start;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #05070b;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
}

.catalog-save-preview img {
  width: 100%;
  height: 100%;
  padding: 8px;
  object-fit: contain;
}

.catalog-save-preview img[hidden] {
  display: none;
}

.catalog-save-fields {
  display: grid;
  gap: 9px;
  min-width: 0;
}

.catalog-save-form label {
  display: grid;
  gap: 5px;
  color: #a5adba;
  font-size: 0.72rem;
  font-weight: 850;
}

.catalog-save-form input,
.catalog-save-form select {
  width: 100%;
  min-height: 40px;
  padding: 0 11px;
  color: #f8fafc;
  background: #05070b;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 780;
}

.catalog-save-form input::placeholder {
  color: #7c8493;
}

.catalog-save-field-row {
  display: grid;
  grid-template-columns: minmax(70px, 0.34fr) minmax(0, 0.66fr);
  gap: 8px;
}

.catalog-save-submit-btn {
  min-height: 44px;
  color: #06251b;
  background: #8bd7ce;
  border: 1px solid #8bd7ce;
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 950;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.catalog-save-submit-btn:disabled {
  opacity: 0.68;
}

.catalog-save-sheet-panel.cost-basis-sheet-panel {
  width: min(560px, calc(100% - 14px));
  max-height: min(88dvh, 760px);
  overflow: hidden auto;
  background:
    linear-gradient(135deg, rgba(24, 32, 45, 0.99), rgba(7, 10, 17, 0.99) 58%, rgba(4, 7, 12, 0.99)),
    repeating-linear-gradient(90deg, rgba(236, 255, 251, 0.025) 0 1px, transparent 1px 18px);
  border-color: rgba(236, 255, 251, 0.14);
  border-radius: 24px 24px 14px 14px;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  box-shadow: 0 -28px 76px rgba(0, 0, 0, 0.56), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.catalog-save-sheet-head.cost-basis-sheet-head {
  position: sticky;
  top: 0;
  z-index: 2;
  align-items: center;
  padding: 8px 18px 12px;
  background: linear-gradient(180deg, rgba(18, 25, 36, 0.98), rgba(18, 25, 36, 0.9) 78%, rgba(18, 25, 36, 0));
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.cost-basis-title-block {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.cost-basis-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 10px;
  align-items: center;
}

.cost-basis-sheet-head .cost-basis-kicker span {
  color: #9ce0d7;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
}

.cost-basis-sheet-head .cost-basis-kicker small {
  display: inline;
  max-width: none;
  margin: 0;
  color: #93a3b8;
  font-size: 0.66rem;
  font-weight: 780;
  line-height: 1.18;
}

.cost-basis-sheet-head h3 {
  margin: 0;
  font-size: clamp(1rem, 4.3vw, 1.24rem);
  letter-spacing: 0;
}

.cost-basis-sheet-head .cost-basis-close-button {
  min-height: 34px;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.075);
  border-color: rgba(148, 163, 184, 0.22);
  border-radius: 8px;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
}

.cost-basis-form {
  display: grid;
  gap: 8px;
  padding: 0 18px max(18px, env(safe-area-inset-bottom));
}

.cost-basis-ticket-hero {
  --cost-basis-accent: #9ce0d7;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
  padding: 14px;
  background:
    linear-gradient(135deg, rgba(156, 224, 215, 0.13), rgba(126, 164, 255, 0.08) 54%, rgba(255, 255, 255, 0.035)),
    rgba(5, 8, 14, 0.34);
  border: 1px solid rgba(156, 224, 215, 0.2);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.cost-basis-ticket-copy {
  min-width: 0;
}

.cost-basis-ticket-copy span,
.cost-basis-copy-head div > span,
.cost-basis-sale-preview > span {
  display: block;
  color: #9ce0d7;
  font-size: 0.64rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.cost-basis-ticket-copy strong {
  display: block;
  margin-top: 5px;
  color: #f8fafc;
  font-size: 1.06rem;
  font-weight: 920;
  line-height: 1.05;
}

.cost-basis-ticket-copy small,
.cost-basis-copy-head div > small,
.cost-basis-copy-label span {
  display: block;
  margin-top: 3px;
  color: #8f9bad;
  font-size: 0.67rem;
  font-weight: 760;
  line-height: 1.25;
}

.cost-basis-section {
  --cost-basis-accent: #9ce0d7;
  --cost-basis-accent-soft: rgba(156, 224, 215, 0.12);
  display: grid;
  gap: 9px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(148, 163, 184, 0.13);
  border-radius: 8px;
}

.cost-basis-paid-card {
  --cost-basis-accent: #b9d8ff;
  --cost-basis-accent-soft: rgba(185, 216, 255, 0.1);
  border-color: rgba(185, 216, 255, 0.16);
}

.cost-basis-sold-card {
  --cost-basis-accent: #95f0af;
  --cost-basis-accent-soft: rgba(149, 240, 175, 0.12);
  border-color: rgba(149, 240, 175, 0.18);
}

.cost-basis-quantity-field,
.cost-basis-money-field,
.cost-basis-sold-grid label {
  display: grid;
  gap: 5px;
  color: #a5adba;
  font-size: 0.68rem;
  font-weight: 850;
}

.cost-basis-quantity-field {
  min-width: 118px;
}

.cost-basis-quantity-field span,
.cost-basis-sold-grid label > span {
  color: #dbe7ff;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cost-basis-quantity-field input,
.cost-basis-copy-row input,
.cost-basis-sold-grid input {
  width: 100%;
  min-height: 40px;
  padding: 0 10px;
  color: #f8fafc;
  background: rgba(2, 4, 9, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 8px;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 900;
}

.cost-basis-quantity-field input {
  text-align: center;
}

.cost-basis-quantity-field input:focus,
.cost-basis-copy-row input:focus,
.cost-basis-sold-grid input:focus {
  outline: 2px solid color-mix(in srgb, var(--cost-basis-accent) 50%, transparent);
  outline-offset: 1px;
  border-color: color-mix(in srgb, var(--cost-basis-accent) 48%, rgba(148, 163, 184, 0.2));
}

.cost-basis-sold-grid {
  display: grid;
  grid-template-columns: minmax(86px, 0.38fr) minmax(0, 0.62fr);
  gap: 8px;
}

.cost-basis-copy-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.cost-basis-copy-head div {
  min-width: 0;
}

.cost-basis-summary-pill {
  max-width: min(240px, 50vw);
  min-width: min(198px, 48vw);
  padding: 7px 9px;
  color: var(--cost-basis-accent);
  background: var(--cost-basis-accent-soft);
  border: 1px solid color-mix(in srgb, var(--cost-basis-accent) 28%, transparent);
  border-radius: 8px;
  font-size: 0.66rem;
  font-weight: 900;
  line-height: 1.2;
  text-align: right;
}

.cost-basis-summary-pill.is-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
  padding: 5px;
  text-align: left;
}

.cost-basis-summary-pill.is-split span {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 5px 6px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(185, 216, 255, 0.12);
  border-radius: 6px;
}

.cost-basis-summary-pill.is-split small {
  overflow: hidden;
  color: #8f9bad;
  font-size: 0.48rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  line-height: 1.1;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.cost-basis-summary-pill.is-split strong {
  overflow: hidden;
  color: #eef5ff;
  font-size: 0.7rem;
  font-weight: 950;
  line-height: 1.08;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cost-basis-paid-card .cost-basis-summary-pill {
  color: #dbe7ff;
  background: rgba(8, 13, 22, 0.64);
  border-color: rgba(185, 216, 255, 0.22);
}

.cost-basis-basis-ledger {
  display: grid;
  gap: 6px;
  max-height: min(30dvh, 260px);
  overflow-y: auto;
  padding-right: 2px;
  -webkit-overflow-scrolling: touch;
}

.cost-basis-copy-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(108px, 0.38fr);
  gap: 8px;
  align-items: center;
  padding: 8px 9px;
  background: rgba(5, 7, 11, 0.38);
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 8px;
}

.cost-basis-copy-row strong {
  display: block;
  overflow: hidden;
  color: #f8fafc;
  font-size: 0.8rem;
  font-weight: 900;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cost-basis-copy-label {
  min-width: 0;
}

.cost-basis-copy-label span {
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cost-basis-input-shell {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  min-height: 40px;
  overflow: hidden;
  background: rgba(2, 4, 9, 0.78);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 8px;
}

.cost-basis-input-shell small {
  padding-left: 10px;
  color: var(--cost-basis-accent);
  font-size: 0.78rem;
  font-weight: 950;
}

.cost-basis-input-shell input {
  min-height: 38px;
  padding-left: 5px;
  background: transparent;
  border: 0;
  border-radius: 0;
}

.cost-basis-input-shell:focus-within {
  outline: 2px solid color-mix(in srgb, var(--cost-basis-accent) 50%, transparent);
  outline-offset: 1px;
  border-color: color-mix(in srgb, var(--cost-basis-accent) 48%, rgba(148, 163, 184, 0.2));
}

.cost-basis-sale-preview {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  align-items: stretch;
  min-height: 42px;
  padding: 9px 10px;
  background:
    linear-gradient(90deg, rgba(149, 240, 175, 0.14), rgba(126, 164, 255, 0.08)),
    rgba(5, 7, 11, 0.34);
  border: 1px solid rgba(149, 240, 175, 0.18);
  border-left: 3px solid #95f0af;
  border-radius: 8px;
}

.cost-basis-sale-preview-body {
  display: block;
  min-width: 0;
  color: #dffefa;
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1.22;
  text-align: left;
  overflow-wrap: anywhere;
}

.cost-basis-sale-preview-body.is-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.cost-basis-sale-preview-stat {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 7px 8px;
  background: rgba(2, 4, 9, 0.34);
  border: 1px solid rgba(149, 240, 175, 0.14);
  border-radius: 7px;
}

.cost-basis-sale-preview-stat small {
  overflow: hidden;
  color: #9aa6b7;
  font-size: 0.52rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  line-height: 1.1;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.cost-basis-sale-preview-stat strong {
  overflow: hidden;
  color: #f2fffb;
  font-size: 0.74rem;
  font-weight: 950;
  line-height: 1.08;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cost-basis-sale-preview-stat strong.is-gain {
  color: #b8f7c5;
}

.cost-basis-sale-preview-stat strong.is-loss {
  color: #ffc2cc;
}

.cost-basis-actions {
  position: sticky;
  bottom: 0;
  display: grid;
  grid-template-columns: 1fr;
  padding-top: 6px;
  background: linear-gradient(180deg, rgba(7, 10, 17, 0), rgba(7, 10, 17, 0.96) 42%);
}

.cost-basis-actions .catalog-save-submit-btn {
  min-height: 52px;
  color: #06251b;
  background: linear-gradient(180deg, #a6e3da, #87d2c9);
  border-color: rgba(166, 227, 218, 0.88);
  border-radius: 10px;
  box-shadow: 0 16px 34px rgba(126, 211, 202, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.collection-item-cost-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025)),
    rgba(13, 18, 27, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
}

.collection-item-sold-card {
  background: rgba(143, 224, 167, 0.08);
  border-color: rgba(143, 224, 167, 0.18);
}

.collection-item-sold-card .collection-item-cost-head span,
.collection-item-sold-card .collection-item-cost-row strong {
  color: #8fe0a7;
}

.collection-item-cost-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.collection-item-cost-head span {
  color: #a9e7df;
  font-size: 0.76rem;
  font-weight: 760;
  letter-spacing: 0;
  text-transform: none;
}

.collection-item-cost-head strong {
  display: block;
  margin-top: 4px;
  color: #fff;
  font-size: 1.12rem;
  font-weight: 820;
  letter-spacing: 0;
  line-height: 1.1;
}

.collection-item-cost-head small {
  display: block;
  margin-top: 4px;
  color: #a5adba;
  font-size: 0.82rem;
  font-weight: 650;
  line-height: 1.32;
}

.collection-item-cost-head button {
  min-height: 38px;
  padding: 0 14px;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 780;
}

.collection-item-cost-list {
  display: grid;
  gap: 7px;
}

.collection-item-cost-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px 13px;
  background: rgba(5, 7, 11, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
}

.collection-item-cost-row span {
  color: #a5adba;
  font-size: 0.84rem;
  font-weight: 720;
  letter-spacing: 0;
}

.collection-item-cost-row strong {
  color: #f8fafc;
  font-size: 0.96rem;
  font-weight: 820;
  letter-spacing: 0;
}

.collection-item-cost-more {
  color: #8d96a5;
  font-size: 0.74rem;
  font-weight: 780;
}

/* MEMORY LINE: Catalog Graded Price Action START */
.catalog-graded-price-form {
  align-items: start;
}

.catalog-graded-company-choices {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
}

.catalog-graded-company-choices button {
  min-height: 38px;
  color: #dffefa;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0;
}

.catalog-graded-company-choices button.is-active {
  color: #06110f;
  background: #8bd7ce;
  border-color: #8bd7ce;
}

.catalog-graded-price-result {
  display: grid;
  gap: 4px;
  min-height: 62px;
  padding: 11px;
  color: rgba(236, 255, 251, 0.76);
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
}

.catalog-graded-price-result strong {
  color: #8fe0a7;
  font-size: 1.28rem;
  font-weight: 950;
  letter-spacing: 0;
}

.catalog-graded-price-result span,
.catalog-graded-price-result small {
  color: rgba(236, 255, 251, 0.72);
  font-size: 0.74rem;
  font-weight: 800;
  line-height: 1.3;
}

.catalog-graded-price-result[data-state="error"] strong,
.catalog-graded-price-result[data-state="unavailable"] strong {
  color: rgba(236, 255, 251, 0.9);
}

.catalog-graded-save-btn {
  background: rgba(143, 224, 167, 0.16);
  border-color: rgba(143, 224, 167, 0.32);
  color: #dffefa;
}
/* MEMORY LINE: Catalog Graded Price Action END */

@media (max-width: 560px) {
  .catalog-save-form {
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 10px;
    padding-inline: 12px;
  }

  .catalog-save-field-row {
    grid-template-columns: minmax(58px, 0.34fr) minmax(0, 0.66fr);
    gap: 7px;
  }

  .catalog-save-form input,
  .catalog-save-form select,
  .cost-basis-quantity-field input,
  .cost-basis-copy-row input,
  .cost-basis-sold-grid input {
    min-height: 38px;
    padding-inline: 9px;
    font-size: 0.72rem;
  }

  .cost-basis-form {
    padding-inline: 12px;
  }

  .cost-basis-sheet-head {
    padding-inline: 12px;
  }

  .cost-basis-ticket-hero {
    grid-template-columns: minmax(0, 1fr) minmax(98px, 116px);
    gap: 10px;
    padding: 12px;
  }

  .cost-basis-copy-row {
    grid-template-columns: minmax(0, 1fr) minmax(106px, 0.44fr);
  }

  .cost-basis-sold-grid {
    grid-template-columns: minmax(78px, 0.38fr) minmax(0, 0.62fr);
  }

  .cost-basis-summary-pill {
    text-align: right;
  }

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

@media (max-width: 380px) {
  .catalog-save-form {
    grid-template-columns: 1fr;
  }

  .cost-basis-copy-head {
    grid-template-columns: 1fr;
  }

  .cost-basis-ticket-hero,
  .cost-basis-copy-row,
  .cost-basis-sale-preview {
    grid-template-columns: 1fr;
  }

  .cost-basis-summary-pill {
    max-width: 100%;
    text-align: left;
  }

  .cost-basis-sale-preview-body {
    text-align: left;
  }

  .catalog-save-preview {
    width: min(142px, 48vw);
    justify-self: center;
  }
}

.catalog-result-tabs-skeleton span,
.catalog-result-card-skeleton .catalog-result-media,
.catalog-result-card-skeleton .catalog-result-copy > span,
.catalog-result-card-skeleton strong,
.catalog-result-card-skeleton small,
.catalog-result-card-skeleton .catalog-result-meta span,
.catalog-result-card-skeleton .catalog-result-price,
.catalog-result-card-skeleton .catalog-add-collection-btn {
  color: transparent;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.08), rgba(126, 211, 202, 0.15), rgba(255, 255, 255, 0.08));
  background-size: 220% 100%;
  border-color: transparent;
  animation: catalogSkeleton 1.1s ease-in-out infinite;
}

.catalog-result-tabs-skeleton span {
  min-height: 44px;
  border-radius: 8px;
}

.catalog-result-card-skeleton .catalog-result-copy > span,
.catalog-result-card-skeleton strong,
.catalog-result-card-skeleton small,
.catalog-result-card-skeleton .catalog-result-price {
  min-height: 16px;
  border-radius: 6px;
}

@keyframes catalogSkeleton {
  0% {
    background-position: 100% 0;
  }

  100% {
    background-position: -100% 0;
  }
}

@media (max-width: 520px) {
  .catalog-search-head h1 {
    font-size: 1.95rem;
  }
}

@media (min-width: 360px) {
  .catalog-result-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 720px) {
  .catalog-result-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 900px) {
  .catalog-result-card-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
/* MEMORY LINE: CATALOG RESULT CARD UI END */
/* MEMORY LINE: Scanner Search Fix END */

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

button,
input,
select,
textarea {
  font: inherit;
}

button,
select {
  cursor: pointer;
}

button:disabled {
  cursor: progress;
  opacity: 0.72;
}

button,
input,
select,
textarea {
  border-radius: var(--radius);
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto minmax(260px, 620px) auto;
  gap: 14px 18px;
  align-items: center;
  padding: 14px 24px;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  color: #fff;
  background: linear-gradient(145deg, #111318, #2357d8);
  border-radius: 8px;
  font-weight: 900;
}

.brand strong,
.brand small {
  display: block;
}

.brand small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.76rem;
}

.quick-search {
  display: grid;
  grid-template-columns: 1fr auto;
  border: 1px solid var(--line-strong);
  background: var(--panel);
  border-radius: var(--radius);
  overflow: hidden;
}

.quick-search input {
  min-width: 0;
  border: 0;
  padding: 12px 14px;
  outline: 0;
}

.quick-search button,
.header-actions button,
.primary-action,
.secondary-action,
.ghost-action,
.market-links a,
.card-actions a,
.card-actions button,
.comp-actions a,
.comp-actions button {
  min-height: 40px;
  padding: 0 13px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-weight: 750;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}

.quick-search button,
.primary-action {
  color: #fff;
  background: var(--blue);
  border-color: var(--blue);
}

.quick-search button:hover,
.primary-action:hover,
.market-links a:hover,
.card-actions a:hover,
.card-actions button:hover,
.comp-actions a:hover,
.comp-actions button:hover,
.header-actions button:hover,
.secondary-action:hover,
.ghost-action:hover {
  transform: translateY(-1px);
}

.header-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.app-tabs {
  grid-column: 1 / -1;
  display: flex;
  gap: 8px;
  overflow-x: auto;
}

.app-tabs a {
  min-height: 34px;
  display: inline-grid;
  place-items: center;
  padding: 0 13px;
  color: #173b8f;
  background: var(--blue-soft);
  border: 1px solid #bed0ff;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 850;
  white-space: nowrap;
}

.header-actions button,
.ghost-action {
  color: var(--ink);
  background: var(--panel);
  border-color: var(--line);
}

.app-shell {
  display: grid;
  grid-template-columns: minmax(320px, 430px) minmax(0, 1fr) minmax(280px, 340px);
  gap: 18px;
  width: min(1540px, calc(100% - 40px));
  margin: 20px auto;
  align-items: start;
}

.home-shell {
  width: min(1180px, calc(100% - 40px));
  margin: 20px auto;
  display: grid;
  gap: 18px;
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(300px, 440px) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}

.market-home-panel,
.vault-strip,
.details-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.market-home-panel,
.vault-strip {
  padding: 18px;
}

.market-home-panel {
  display: grid;
  gap: 14px;
  align-content: start;
}

.details-panel {
  overflow: hidden;
}

.details-panel summary {
  padding: 16px 18px;
  cursor: pointer;
  color: var(--ink);
  font-weight: 900;
  list-style-position: inside;
}

.details-grid {
  display: grid;
  grid-template-columns: minmax(300px, 1fr) minmax(300px, 1fr);
  gap: 18px;
  padding: 0 18px 18px;
}

.left-rail {
  display: grid;
  gap: 18px;
}

.lookup-panel,
.scanner-panel,
.dashboard,
.comps-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.lookup-panel,
.comps-panel {
  position: sticky;
  top: 86px;
  padding: 18px;
}

.scanner-panel {
  padding: 18px;
  background: #111318;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow-strong);
  min-width: 0;
}

.dashboard {
  min-width: 0;
  padding: 18px;
}

.section-heading {
  margin-bottom: 16px;
}

.panel-heading-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.status-pill {
  padding: 6px 10px;
  color: #bbf7d0;
  background: rgba(22, 134, 90, 0.18);
  border: 1px solid rgba(187, 247, 208, 0.22);
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 900;
}

.kicker {
  margin: 0 0 5px;
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2 {
  margin-bottom: 0;
  line-height: 1.1;
}

.scanner-panel .kicker {
  color: #8fb4ff;
}

.scanner-panel label,
.scanner-panel .scanner-status {
  color: #cbd5e1;
}

.scanner-panel input {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
}

.scanner-panel input::placeholder {
  color: #94a3b8;
}

.lookup-form,
.comp-form {
  display: grid;
  gap: 13px;
}

label {
  display: grid;
  gap: 7px;
  color: #344054;
  font-size: 0.86rem;
  font-weight: 750;
}

input,
select,
textarea {
  width: 100%;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line-strong);
  outline: 0;
}

input,
select {
  min-height: 42px;
  padding: 0 11px;
}

textarea {
  padding: 10px 11px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(35, 87, 216, 0.13);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.valuation-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 82px;
  gap: 10px;
}

.source-toggle {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.source-toggle label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  background: #fbfcfe;
  text-align: center;
}

.source-toggle input {
  width: auto;
  min-height: auto;
}

.form-actions {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 9px;
}

.camera-stage {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  max-height: 360px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(35, 87, 216, 0.24), rgba(22, 134, 90, 0.16)),
    #090b0f;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
}

.camera-stage[hidden] {
  display: none;
}

.camera-stage video,
.camera-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.scan-frame {
  position: absolute;
  inset: 9%;
  border: 2px solid rgba(255, 255, 255, 0.82);
  border-radius: 12px;
  box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.12);
  pointer-events: none;
}

.scanner-actions {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 9px;
  margin-top: 10px;
}

.scanner-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 112px;
  gap: 9px;
  align-items: end;
  margin-top: 0;
}

.scanner-status {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 750;
}

.spotlight-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-bottom: 16px;
  padding: 18px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(35, 87, 216, 0.92), rgba(17, 19, 24, 0.96)),
    #111318;
  border-radius: 14px;
  overflow: hidden;
}

.spotlight-copy h2 {
  max-width: 680px;
}

.spotlight-copy p:last-child {
  max-width: 660px;
  margin: 10px 0 0;
  color: #dbeafe;
  line-height: 1.45;
}

.spotlight-panel .kicker {
  color: #bfdbfe;
}

.spotlight-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(86px, 1fr));
  gap: 8px;
}

.spotlight-metrics span {
  display: grid;
  gap: 5px;
  min-height: 74px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius);
  font-weight: 900;
}

.spotlight-metrics small {
  color: #bfdbfe;
  font-size: 0.7rem;
  text-transform: uppercase;
}

.secondary-action {
  color: var(--ink);
  background: var(--green-soft);
  border-color: #a8dfc5;
}

.market-result {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: center;
  margin-top: 18px;
  padding: 14px;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.result-label {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.market-result h2 {
  font-size: 1.45rem;
}

.result-copy {
  margin: 6px 0 0;
  color: #344054;
  line-height: 1.4;
}

.muted {
  color: var(--muted);
}

.mini-card {
  position: relative;
  display: grid;
  place-items: end center;
  width: 58px;
  height: 78px;
  padding: 8px;
  overflow: hidden;
  color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 8px;
  box-shadow: 0 12px 22px rgba(22, 23, 25, 0.16);
}

.mini-card span {
  position: absolute;
  inset: 8px 8px 28px;
  background: rgba(255, 255, 255, 0.72);
  border-radius: 5px;
}

.mini-card strong {
  position: relative;
  font-size: 0.72rem;
  letter-spacing: 0;
}

.art-pokemon {
  background: linear-gradient(145deg, #d64b3f, #f2b84d 55%, #1f74c8);
}

.art-magic {
  background: linear-gradient(145deg, #2d2b72, #6d3fa3 55%, #d49c4c);
}

.art-yugioh {
  background: linear-gradient(145deg, #2b1714, #8b2f35 54%, #d7b35d);
}

.art-onepiece {
  background: linear-gradient(145deg, #1a8a84, #2e5eb8 55%, #e2553d);
}

.art-sports {
  background: linear-gradient(145deg, #1d6f43, #f0c342 58%, #101820);
}

.market-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
  gap: 9px;
  margin-top: 10px;
}

.price-pills {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(108px, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.price-pills span {
  min-width: 0;
  padding: 9px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.price-pills small,
.price-pills strong {
  display: block;
}

.price-pills small {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 850;
  text-transform: uppercase;
}

.market-links a,
.card-actions a {
  display: inline-grid;
  place-items: center;
  color: #173b8f;
  background: var(--blue-soft);
  border-color: #bed0ff;
  text-align: center;
}

.dashboard-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.view-controls {
  min-width: 170px;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.stat-card {
  padding: 14px;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.stat-card span {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
}

.stat-card strong {
  font-size: 1.25rem;
}

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

.sold-data-panel {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
  padding: 14px;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.sold-data-panel[hidden] {
  display: none;
}

.sold-data-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.sold-data-header h3 {
  margin-bottom: 0;
}

.sold-data-header span {
  padding: 6px 9px;
  color: #173b8f;
  background: var(--blue-soft);
  border: 1px solid #bed0ff;
  border-radius: var(--radius);
  font-size: 0.78rem;
  font-weight: 850;
  text-align: right;
}

.sold-results {
  display: grid;
  gap: 10px;
}

.market-snapshot-card {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.snapshot-image {
  display: grid;
  place-items: center;
  width: 132px;
  aspect-ratio: 1;
  overflow: hidden;
  color: var(--muted);
  background: #eef2f7;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 0.78rem;
  font-weight: 800;
  text-align: center;
}

.empty-snapshot .snapshot-image {
  background: #f1f5f9;
}

.snapshot-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.snapshot-body span,
.snapshot-body strong,
.snapshot-body small {
  display: block;
}

.snapshot-body span {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.snapshot-body strong {
  color: var(--green);
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1;
}

.snapshot-body p {
  margin: 10px 0 8px;
  color: #344054;
}

.snapshot-body small {
  color: var(--muted);
  line-height: 1.35;
}

.valuation-confidence {
  display: inline-flex;
  width: fit-content;
  margin-top: 8px;
  padding: 5px 8px;
  color: #694900;
  background: #fff2c2;
  border: 1px solid #f2cd5c;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0;
}

.valuation-confidence.high {
  color: #07533f;
  background: #d9f8ef;
  border-color: #8adfca;
}

.valuation-confidence.low {
  color: #8a3a13;
  background: #ffe7d6;
  border-color: #ffb98b;
}

.valuation-breakdown {
  display: grid;
  gap: 8px;
  margin: 10px 0;
}

.valuation-source-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 10px;
  padding: 9px 10px;
  background: rgba(16, 24, 39, 0.04);
  border: 1px solid rgba(16, 24, 39, 0.08);
  border-radius: 12px;
}

.valuation-source-row span,
.valuation-source-row strong,
.valuation-source-row small {
  margin: 0;
}

.valuation-source-row span {
  color: #172033;
  font-size: 0.82rem;
  font-weight: 900;
}

.valuation-source-row strong {
  color: #18a77e;
  font-size: 0.92rem;
}

.valuation-source-row small {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 760;
}

.sold-more-note {
  padding: 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.72);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  font-size: 0.86rem;
  font-weight: 850;
  text-align: center;
}

.sold-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.sold-thumb {
  display: grid;
  place-items: center;
  width: 104px;
  aspect-ratio: 1;
  overflow: hidden;
  color: var(--muted);
  background: #eef2f7;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 0.78rem;
  font-weight: 800;
  text-align: center;
}

.sold-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sold-body {
  min-width: 0;
}

.sold-title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.sold-title-row h4 {
  margin: 0;
  line-height: 1.28;
}

.sold-title-row strong {
  color: var(--green);
  white-space: nowrap;
}

.sold-body p {
  margin: 7px 0 0;
  color: var(--muted);
  line-height: 1.4;
}

.sold-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.sold-actions a,
.sold-actions button {
  display: inline-grid;
  place-items: center;
  min-height: 34px;
  padding: 0 11px;
  color: #173b8f;
  background: var(--blue-soft);
  border: 1px solid #bed0ff;
  border-radius: var(--radius);
  font-weight: 800;
}

.collection-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.card-topline {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  min-width: 0;
  align-items: center;
}

.card-topline h3 {
  margin-bottom: 4px;
  line-height: 1.2;
}

.card-topline p,
.card-meta,
.card-notes {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.45;
}

.value-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.value-row span {
  min-width: 0;
  padding: 10px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.value-row small {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 850;
  text-transform: uppercase;
}

.value-row strong {
  display: block;
  overflow-wrap: anywhere;
}

.positive strong {
  color: var(--green);
}

.negative strong {
  color: var(--red);
}

.card-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.card-actions button,
.comp-actions button {
  color: var(--ink);
  background: #fff;
  border-color: var(--line);
}

.comp-form {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.comp-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.comp-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 12px;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.comp-item strong,
.comp-item span {
  display: block;
}

.comp-item span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.82rem;
}

.comp-item p {
  margin: 8px 0 0;
  color: #344054;
  line-height: 1.35;
}

.comp-actions {
  display: grid;
  gap: 7px;
  align-content: start;
}

.comp-actions a {
  display: inline-grid;
  place-items: center;
  min-height: 34px;
  color: var(--amber);
  background: var(--amber-soft);
  border-color: #f2ce8f;
}

.comp-actions button {
  min-height: 34px;
}

.empty-state {
  grid-column: 1 / -1;
  display: grid;
  gap: 5px;
  padding: 26px;
  color: var(--muted);
  background: #fbfcfe;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  text-align: center;
}

.empty-state strong {
  color: var(--ink);
}

.compact {
  padding: 18px;
}

.app-footer {
  width: min(1540px, calc(100% - 40px));
  margin: 0 auto 26px;
  color: var(--muted);
  font-size: 0.88rem;
}

.app-legal-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(214, 244, 241, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
}

.app-legal-links a {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(214, 244, 241, 0.12);
  border-radius: 8px;
  color: rgba(247, 248, 251, 0.74);
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

.app-legal-links a:hover,
.app-legal-links a:focus-visible {
  border-color: rgba(107, 208, 199, 0.44);
  color: #f7f8fb;
}

@media (max-width: 1240px) {
  .app-shell {
    grid-template-columns: minmax(300px, 390px) minmax(0, 1fr);
  }

  .comps-panel {
    grid-column: 1 / -1;
    position: static;
  }

  .comp-form {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: end;
  }

  .comp-form button {
    min-height: 42px;
  }
}

@media (max-width: 980px) {
  .app-header,
  .app-shell,
  .home-hero,
  .details-grid {
    grid-template-columns: 1fr;
  }

  .header-actions {
    justify-content: start;
  }

  .lookup-panel {
    position: static;
  }

  .stat-grid,
  .cards-grid,
  .comp-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .spotlight-panel {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .app-header {
    padding: 12px 14px;
  }

  .home-shell,
  .app-shell,
  .app-footer {
    width: calc(100% - 24px);
  }

  .app-legal-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quick-search,
  .form-grid,
  .valuation-grid,
  .source-toggle,
  .form-actions,
  .scanner-actions,
  .scanner-search,
  .market-links,
  .stat-grid,
  .market-snapshot-card,
  .cards-grid,
  .value-row,
  .card-actions,
  .comp-form,
  .sold-item,
  .sold-title-row,
  .comp-item {
    grid-template-columns: 1fr;
  }

  .market-home-panel,
  .vault-strip,
  .scanner-panel {
    padding: 14px;
  }

  .spotlight-metrics {
    grid-template-columns: 1fr;
  }

  .sold-thumb {
    width: 100%;
    max-height: 220px;
  }

  .snapshot-image {
    width: 100%;
    max-height: 240px;
  }

  .dashboard-top {
    display: grid;
  }

  .header-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}

/* Mobile scanner app layout */
.mobile-app {
  width: min(430px, 100%);
  min-height: 100vh;
  min-height: var(--mobile-page-height);
  margin: 0 auto;
  padding: 14px 14px var(--app-bottom-nav-clearance);
  display: grid;
  gap: 14px;
}

.mobile-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.mobile-topbar button {
  min-height: 38px;
  padding: 0 12px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-weight: 850;
}

.scan-home,
.market-card,
.inventory-card {
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.scan-home {
  color: #fff;
  background:
    linear-gradient(145deg, rgba(17, 19, 24, 0.98), rgba(17, 24, 39, 0.94)),
    #111318;
  border-color: rgba(255, 255, 255, 0.08);
}

.scan-copy {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.scan-copy h1 {
  max-width: 300px;
  font-size: 1.8rem;
}

.scan-home .kicker {
  color: #8fb4ff;
}

.mobile-app .scanner-search {
  grid-template-columns: 1fr;
  margin-top: 0;
}

.mobile-app .scanner-search label {
  color: #cbd5e1;
}

.mobile-app .scanner-search input {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
}

.mobile-app .scanner-search input::placeholder {
  color: #94a3b8;
}

.mobile-app .scanner-search button {
  min-height: 48px;
  font-size: 1rem;
}

.mobile-app .scanner-actions {
  grid-template-columns: 1fr 1fr 76px;
}

.camera-button {
  min-height: 42px;
  color: #fff;
  background: var(--blue);
  border: 1px solid var(--blue);
  border-radius: var(--radius);
  font-weight: 850;
}

.mobile-app .camera-stage {
  margin-top: 12px;
  max-height: none;
}

.mobile-app .scanner-status {
  color: #cbd5e1;
}

.market-card,
.inventory-card {
  display: grid;
  gap: 12px;
}

.market-header,
.inventory-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.market-header h2,
.inventory-header h2 {
  margin: 0;
}

.market-header h3 {
  margin: 2px 0 0;
  font-size: 1rem;
}

.market-header span {
  padding: 6px 9px;
  color: #173b8f;
  background: var(--blue-soft);
  border: 1px solid #bed0ff;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 900;
  white-space: nowrap;
}

.mobile-app .sold-data-panel {
  padding: 0;
  background: transparent;
  border: 0;
}

.mobile-app .market-snapshot-card {
  grid-template-columns: 92px minmax(0, 1fr);
  padding: 0;
  border: 0;
}

.mobile-app .snapshot-image {
  width: 92px;
  border-radius: 12px;
}

.mobile-app .snapshot-body strong {
  font-size: 2.1rem;
}

.mobile-app .snapshot-body p {
  margin: 7px 0;
  font-size: 0.92rem;
}

.mobile-app .sold-results,
.mobile-app .market-links {
  display: none;
}

.save-inventory-btn {
  width: 100%;
  min-height: 46px;
  color: #fff;
  background: var(--green);
  border: 1px solid var(--green);
  border-radius: var(--radius);
  font-weight: 900;
}

.save-inventory-btn:disabled {
  color: #64748b;
  background: #eef2f7;
  border-color: var(--line);
}

.mobile-app .stat-grid {
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.mobile-app .stat-card {
  padding: 12px;
}

.mobile-app .stat-card strong {
  font-size: 1.15rem;
}

.mobile-app .cards-grid {
  grid-template-columns: 1fr;
}

.mobile-app .collection-card {
  gap: 10px;
  padding: 12px;
  border-radius: 14px;
}

.mobile-app .card-topline {
  grid-template-columns: 44px minmax(0, 1fr);
}

.mobile-app .mini-card {
  width: 44px;
  height: 60px;
}

.mobile-app .value-row {
  grid-template-columns: repeat(3, 1fr);
}

.mobile-app .card-meta,
.mobile-app .card-notes,
.mobile-app .card-actions {
  display: none;
}

.inventory-header select {
  width: auto;
  min-height: 36px;
  padding: 0 34px 0 10px;
  border-radius: 999px;
}

.app-utilities {
  display: none;
}

.mobile-footer {
  width: min(430px, 100%);
  margin: -66px auto 24px;
  padding: 0 14px;
  color: var(--muted);
  font-size: 0.82rem;
  text-align: center;
}

@media (min-width: 760px) {
  .mobile-app {
    padding-top: 22px;
  }
}

/* Collector mobile dashboard */
body.collector-home {
  min-height: 100vh;
  min-height: var(--mobile-page-height);
  color: #f8fafc;
  background:
    radial-gradient(circle at 85% 0%, rgba(99, 214, 163, 0.16), transparent 260px),
    linear-gradient(180deg, #08090d 0%, #050607 64%, #07080b 100%);
}

.collector-home svg {
  display: block;
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.collector-app {
  width: min(430px, 100%);
  min-height: 100vh;
  min-height: var(--mobile-page-height);
  margin: 0 auto;
  padding: 22px 18px var(--app-bottom-nav-clearance);
  display: grid;
  gap: 18px;
}

.dashboard-header,
.section-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.dashboard-header h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(2.35rem, 12vw, 3.75rem);
  font-weight: 950;
  letter-spacing: 0;
  line-height: 0.92;
  text-transform: uppercase;
}

.eyebrow {
  margin: 0 0 6px;
  color: #63d6a3;
  font-size: 0.74rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.icon-button,
.scan-icon-button {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  color: #f8fafc;
  background: #14151b;
  border: 1px solid #242833;
  box-shadow: none;
}

.icon-button {
  width: 44px;
  height: 44px;
  border-radius: 14px;
}

.scan-icon-button {
  width: 52px;
  height: 52px;
  color: #07110d;
  background: #63d6a3;
  border-color: #63d6a3;
  border-radius: 18px;
}

.hero-value-card,
.scan-card,
.market-card,
.recap-card,
.inventory-card {
  min-width: 0;
  background: rgba(13, 14, 19, 0.92);
  border: 1px solid #20232c;
  border-radius: 22px;
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.34);
}

.hero-value-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  overflow: hidden;
}

.hero-copy h2,
.section-row h2 {
  margin: 0;
  color: #fff;
  font-size: 1.45rem;
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1;
  text-transform: uppercase;
}

.hero-copy span {
  display: block;
  margin: 7px 0 8px;
  color: #8b929f;
  font-size: 0.95rem;
  line-height: 1.35;
}

.hero-copy strong {
  display: block;
  color: #63d6a3;
  font-size: clamp(2rem, 10vw, 3.2rem);
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1;
  overflow-wrap: anywhere;
}

.value-chart {
  height: 190px;
  margin: -4px -2px 0;
}

.value-chart svg {
  width: 100%;
  height: 100%;
}

.chart-area {
  fill: url(#chartFill);
}

.chart-line {
  fill: none;
  stroke: #63d6a3;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 7;
}

.value-chart circle {
  fill: #63d6a3;
}

.range-tabs {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.range-tabs button {
  min-height: 48px;
  padding: 0;
  color: #f4f7fb;
  background: #181a20;
  border: 1px solid #222530;
  border-radius: 14px;
  font-size: 0.94rem;
  font-weight: 950;
  text-transform: uppercase;
}

.range-tabs .active {
  color: #07110d;
  background: #63d6a3;
  border-color: #63d6a3;
}

.scan-card,
.market-card,
.recap-card,
.inventory-card {
  padding: 16px;
}

.collector-app .scanner-search {
  display: grid;
  grid-template-columns: 1fr 92px;
  gap: 10px;
  align-items: end;
  margin-top: 14px;
}

.collector-app label {
  color: #cbd1da;
}

.collector-app input,
.collector-app select,
.collector-app textarea {
  color: #fff;
  background: #12141a;
  border: 1px solid #2a2e39;
}

.collector-app input::placeholder {
  color: #6f7785;
}

.collector-app input:focus,
.collector-app select:focus,
.collector-app textarea:focus {
  border-color: #63d6a3;
  box-shadow: 0 0 0 3px rgba(99, 214, 163, 0.16);
}

.collector-app .primary-action,
.save-inventory-btn,
.recap-card #exportCsvBtn {
  min-height: 46px;
  color: #07110d;
  background: #63d6a3;
  border: 1px solid #63d6a3;
  border-radius: 14px;
  font-weight: 950;
}

.save-inventory-btn {
  width: 100%;
  margin-top: 12px;
}

.save-inventory-btn:disabled {
  color: #79818d;
  background: #191b22;
  border-color: #282b35;
}

.collector-app .secondary-action,
.collector-app .ghost-action {
  min-height: 42px;
  color: #eef2f7;
  background: #181a20;
  border: 1px solid #282b35;
  border-radius: 14px;
  font-weight: 900;
}

.collector-app .scanner-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.collector-app .camera-stage {
  margin-top: 12px;
  border-radius: 18px;
  border-color: #2d3340;
}

.collector-app .scanner-status {
  margin: 10px 0 0;
  color: #8b929f;
}

.status-chip {
  max-width: 130px;
  padding: 7px 10px;
  color: #07110d;
  background: #63d6a3;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
  line-height: 1.15;
  text-align: center;
}

.collector-app .sold-data-panel {
  margin: 14px 0 0;
  padding: 0;
  background: transparent;
  border: 0;
}

.collector-app .market-snapshot-card {
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 13px;
  padding: 12px;
  background: #111318;
  border: 1px solid #242833;
  border-radius: 18px;
}

.collector-app .snapshot-image {
  width: 96px;
  border-color: #2d3340;
  border-radius: 14px;
  background: linear-gradient(145deg, #1a1d25, #0d0f14);
  color: #828a96;
}

.collector-app .snapshot-body span {
  color: #8b929f;
}

.collector-app .snapshot-body strong {
  color: #63d6a3;
  font-size: 2rem;
}

.collector-app .snapshot-body p {
  margin: 8px 0;
  color: #cbd1da;
  line-height: 1.35;
}

.collector-app .snapshot-body small {
  color: #8b929f;
}

.collector-app .sold-results,
.collector-app .market-links {
  display: none;
}

.recap-card .section-row {
  align-items: center;
}

.recap-card h2 {
  margin: 0;
  color: #fff;
  font-size: 1.6rem;
  font-weight: 950;
  text-transform: uppercase;
}

.recap-card #exportCsvBtn {
  min-height: 38px;
  padding: 0 13px;
  border-radius: 999px;
}

.collector-app .stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 16px 0 0;
}

.collector-app .stat-card {
  padding: 0;
  background: transparent;
  border: 0;
}

.collector-app .stat-card span {
  margin: 0 0 5px;
  color: #f8fafc;
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.25;
  text-transform: none;
}

.collector-app .stat-card strong {
  color: #63d6a3;
  font-size: clamp(1.4rem, 7vw, 2rem);
  font-weight: 950;
  line-height: 1;
  overflow-wrap: anywhere;
}

.inventory-card select {
  width: auto;
  min-height: 36px;
  padding: 0 34px 0 12px;
  color: #f8fafc;
  background-color: #181a20;
  border-color: #282b35;
  border-radius: 999px;
  font-weight: 850;
}

.collector-app .cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 14px;
}

.collector-app .collection-card {
  gap: 12px;
  padding: 12px;
  background: #111318;
  border: 1px solid #242833;
  border-radius: 18px;
}

.collector-app .card-topline {
  grid-template-columns: 46px minmax(0, 1fr);
}

.collector-app .card-topline h3 {
  color: #fff;
}

.collector-app .card-topline p,
.collector-app .card-meta,
.collector-app .card-notes {
  color: #8b929f;
}

.collector-app .mini-card {
  width: 46px;
  height: 64px;
  border-radius: 10px;
}

.collector-app .value-row {
  grid-template-columns: repeat(3, 1fr);
}

.collector-app .value-row span {
  padding: 9px;
  background: #171a21;
  border-color: #272b35;
  border-radius: 14px;
}

.collector-app .value-row small {
  color: #8b929f;
}

.collector-app .value-row strong {
  color: #f8fafc;
}

.collector-app .positive strong {
  color: #63d6a3;
}

.collector-app .negative strong {
  color: #ff7f8a;
}

.collector-app .card-meta,
.collector-app .card-notes,
.collector-app .card-actions {
  display: none;
}

.collector-app .empty-state {
  padding: 22px;
  color: #8b929f;
  background: #111318;
  border-color: #2c313d;
  border-radius: 18px;
}

.collector-app .empty-state strong {
  color: #f8fafc;
}

.app-utilities {
  display: none;
}

.bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 10px;
  bottom: max(10px, env(safe-area-inset-bottom));
  z-index: 30;
  width: min(430px, calc(100% - 24px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: end;
  gap: 1px;
  padding: 10px 12px 11px;
  color: #8b929f;
  background: rgba(10, 12, 17, 0.96);
  border: 1px solid rgba(85, 93, 111, 0.48);
  border-radius: 32px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(16px);
}

.bottom-nav a {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 54px;
  padding: 6px 2px 5px;
  align-items: center;
  justify-content: flex-end;
  flex-direction: column;
  gap: 5px;
  border-radius: 18px;
  color: inherit;
  font-size: 0.62rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  line-height: 1;
  text-decoration: none;
  text-transform: uppercase;
  -webkit-tap-highlight-color: transparent;
  transition: color 160ms ease, background 160ms ease, transform 160ms ease;
}

.bottom-nav a:not(.scan-tab)::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -4px;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #7bded2;
  opacity: 0;
  transform: translateX(-50%) scale(0.7);
  transition: opacity 160ms ease, transform 160ms ease;
}

.bottom-nav a:not(.scan-tab) span {
  display: block;
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: clip;
}

.bottom-nav svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
  opacity: 0.9;
}

.bottom-nav .active {
  color: #f8fbff;
}

.bottom-nav a:not(.scan-tab).active::after {
  opacity: 1;
  transform: translateX(-50%) scale(1);
}

.bottom-nav .scan-tab {
  align-self: start;
  min-height: 54px;
  padding: 0;
  justify-content: flex-start;
  gap: 5px;
  color: #f8fbff;
  background: transparent;
  transform: translateY(-24px);
}

.bottom-nav .scan-tab svg {
  width: 64px;
  height: 64px;
  box-sizing: border-box;
  padding: 18px;
  border-radius: 24px;
  color: #041512;
  background: linear-gradient(180deg, #86e5dc 0%, #67c9be 100%);
  box-shadow: 0 18px 34px rgba(67, 216, 202, 0.28), 0 8px 24px rgba(0, 0, 0, 0.34);
  opacity: 1;
}

.bottom-nav .scan-tab span {
  display: block;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  line-height: 1;
  color: #f8fbff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.42);
}

.bottom-nav .scan-tab:active {
  transform: translateY(-21px) scale(0.98);
}

@media (max-width: 360px) {
  .bottom-nav {
    --bottom-nav-scan-slot: 68px;
    width: calc(100% - 16px);
    padding-inline: 8px;
  }

  .bottom-nav a {
    font-size: 0.58rem;
    letter-spacing: 0.07em;
  }

  .bottom-nav .scan-tab svg {
    width: 60px;
    height: 60px;
    padding: 17px;
    border-radius: 22px;
  }

  .collector-app {
    padding-inline: 12px;
  }

  .range-tabs {
    gap: 6px;
  }

  .range-tabs button {
    min-height: 42px;
    font-size: 0.82rem;
  }

  .collector-app .scanner-search,
  .collector-app .market-snapshot-card,
  .collector-app .value-row {
    grid-template-columns: 1fr;
  }

  .collector-app .snapshot-image {
    width: 100%;
    max-height: 230px;
  }
}

/* Friendly scanner-home refresh */
body.collector-home {
  color: #172033;
  background:
    linear-gradient(160deg, rgba(47, 111, 237, 0.14) 0%, rgba(255, 255, 255, 0) 34%),
    linear-gradient(180deg, #f7f9fd 0%, #eef4f8 100%);
}

.collector-app {
  gap: 14px;
  padding: 18px 16px 104px;
}

.app-view {
  display: grid;
  gap: 14px;
}

.app-view[hidden] {
  display: none;
}

html.app-booting.app-initial-route-collection .app-view-home,
html.app-booting.app-initial-route-collection-detail .app-view-home,
html.app-booting.app-initial-route-scan .app-view-home,
html.app-booting.app-initial-route-vendors .app-view-home {
  display: none;
}

html.app-booting.app-initial-route-collection #collectionView[hidden],
html.app-booting.app-initial-route-vendors #vendorView[hidden] {
  display: grid !important;
}

html.app-booting.app-initial-route-collection-detail #collectionItemDetailView[hidden] {
  display: grid !important;
}

html.app-booting.app-initial-route-scan #scannerOverlay[hidden] {
  display: grid !important;
}

html.app-booting.app-initial-route-settings #appMenuOverlay[hidden] {
  display: grid !important;
}

html.app-booting.app-initial-route-collection #collectionGrid:empty::before,
html.app-booting.app-initial-route-collection-detail #collectionItemDetailContent:empty::before {
  content: "Loading collection...";
  display: grid;
  place-items: center;
  min-height: 220px;
  margin: 8px 0;
  color: rgba(247, 248, 251, 0.66);
  font-size: 0.86rem;
  font-weight: 500;
  text-align: center;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 18px;
}

html.app-booting.app-initial-route-collection-detail #collectionItemDetailContent:empty::before {
  content: "Loading card...";
}

.dashboard-header {
  align-items: center;
  justify-content: flex-end;
}

.home-brand-lockup {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 12px;
}

.home-logo {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 58px;
  height: 58px;
  color: #fff;
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 17px;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28);
}

.home-logo-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dashboard-header h1 {
  color: #172033;
  font-size: clamp(1.55rem, 8vw, 2.25rem);
  font-weight: 900;
  line-height: 1.02;
  text-transform: none;
}

.eyebrow {
  color: #2f6fed;
  letter-spacing: 0.1em;
}

.icon-button {
  color: #172033;
  background: #fff;
  border-color: #dbe3ef;
  box-shadow: 0 12px 28px rgba(23, 32, 51, 0.08);
}

.hero-value-card,
.scan-card,
.market-card,
.collection-tab-head,
.collection-section-panel,
.collection-detail-panel,
.collection-stat-row article,
.collection-toolbar {
  color: #172033;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid #dbe3ef;
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(23, 32, 51, 0.08);
}

.hero-value-card {
  position: relative;
  isolation: isolate;
  gap: 16px;
  padding: 18px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(47, 111, 237, 0.09), rgba(24, 167, 126, 0.11)),
    #fff;
}

.hero-value-card::before {
  content: "";
  position: absolute;
  inset: auto 18px 0;
  height: 5px;
  background: linear-gradient(90deg, #2f6fed, #18a77e, #ff7a59);
  border-radius: 999px 999px 0 0;
  z-index: -1;
}

.hero-copy h2,
.section-row h2 {
  color: #172033;
  font-size: 1.38rem;
  font-weight: 900;
  line-height: 1.08;
  text-transform: none;
}

.hero-copy span {
  color: #697386;
}

.value-hub {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 96px;
  gap: 10px;
  align-items: center;
  padding: 14px;
  background: #172033;
  border-radius: 20px;
  overflow: hidden;
}

.value-hub span,
.value-hub strong {
  display: block;
}

.value-hub span {
  color: #aab5c5;
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.value-hub strong {
  margin-top: 6px;
  color: #fff;
  font-size: clamp(1.7rem, 8vw, 2.45rem);
  font-weight: 950;
  line-height: 1;
  overflow-wrap: anywhere;
}

.value-hub-art {
  position: relative;
  height: 106px;
}

.card-slab {
  position: absolute;
  display: block;
  width: 56px;
  height: 78px;
  border: 3px solid rgba(255, 255, 255, 0.82);
  border-radius: 13px;
  box-shadow: 0 14px 24px rgba(0, 0, 0, 0.22);
}

.card-slab::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  top: 11px;
  height: 20px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 8px;
}

.slab-one {
  right: 36px;
  top: 18px;
  background: linear-gradient(145deg, #ff7a59, #ffd166);
  transform: rotate(-12deg);
}

.slab-two {
  right: 18px;
  top: 10px;
  background: linear-gradient(145deg, #2f6fed, #6aa9ff);
  transform: rotate(3deg);
}

.slab-three {
  right: 0;
  top: 20px;
  background: linear-gradient(145deg, #18a77e, #78dfb5);
  transform: rotate(13deg);
}

.home-action-strip {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
}

.portfolio-graph-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid #dbe3ef;
  border-radius: 20px;
}

.portfolio-graph-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.portfolio-graph-head span,
.portfolio-graph-head strong,
.portfolio-graph-head small {
  display: block;
}

.portfolio-graph-head span {
  color: #697386;
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portfolio-graph-head strong {
  margin-top: 3px;
  color: #18a77e;
  font-size: 1.4rem;
  font-weight: 950;
  line-height: 1;
}

.portfolio-graph-head strong.negative {
  color: #d94d45;
}

.portfolio-graph-head small {
  color: #697386;
  font-size: 0.78rem;
  font-weight: 850;
  text-align: right;
  white-space: nowrap;
}

#portfolioGraph {
  width: 100%;
  height: auto;
  overflow: visible;
}

.graph-bg {
  fill: #f8fbff;
}

.graph-grid {
  stroke: #dbe3ef;
  stroke-dasharray: 4 6;
  stroke-width: 1;
}

.gain-bar {
  stroke-linecap: round;
  stroke-width: 5;
  opacity: 0.65;
}

.gain-bar.positive {
  stroke: #18a77e;
}

.gain-bar.negative {
  stroke: #d94d45;
}

.cost-path,
.value-path {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cost-path {
  stroke: #ff9f6e;
  stroke-dasharray: 6 7;
  stroke-width: 3;
}

.value-path {
  stroke: #2f6fed;
  stroke-width: 4;
}

.value-dot {
  fill: #fff;
  stroke: #2f6fed;
  stroke-width: 4;
}

.graph-label {
  fill: #697386;
  font-size: 11px;
  font-weight: 800;
}

.graph-label.right {
  text-anchor: end;
}

#portfolioGraphSummary {
  margin: -2px 0 0;
  color: #697386;
  font-size: 0.82rem;
  line-height: 1.35;
}

.home-action-strip a,
.home-action-strip button {
  display: grid;
  place-items: center;
  min-height: 44px;
  color: #172033;
  background: #fff;
  border: 1px solid #dbe3ef;
  border-radius: 14px;
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(23, 32, 51, 0.06);
}

.home-action-strip > :first-child {
  color: #fff;
  background: #2f6fed;
  border-color: #2f6fed;
}

.collection-tab {
  gap: 14px;
}

.collection-tab-head {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 18px;
}

.collection-tab-head > div {
  min-width: 0;
  flex: 1 1 auto;
}

.collection-back-btn {
  min-height: 38px;
  padding: 0 12px;
  color: #173b8f;
  background: #eaf1ff;
  border: 1px solid #c9d8ff;
  border-radius: 999px;
  font-weight: 950;
}

.collection-back-btn[hidden] {
  display: none;
}

.collection-tab-head h2 {
  margin: 2px 0 0;
  color: #172033;
  font-size: 1.55rem;
  font-weight: 950;
  line-height: 1.02;
}

.collection-tab-head span {
  display: block;
  margin-top: 6px;
  color: #697386;
  line-height: 1.35;
}

.collection-stat-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.collection-stat-row article {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 13px 12px;
  border-radius: 18px;
}

.collection-stat-row span,
.collection-stat-row strong {
  display: block;
}

.collection-stat-row span {
  overflow: hidden;
  color: #697386;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-stat-row strong {
  overflow-wrap: anywhere;
  color: #172033;
  font-size: clamp(1rem, 5vw, 1.35rem);
  font-weight: 950;
  line-height: 1;
}

.collection-stat-row strong.positive {
  color: #18a77e;
}

.collection-stat-row strong.negative {
  color: #d94d45;
}

.collection-section-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.collection-tab.is-section-detail .collection-section-panel {
  display: none;
}

.collection-detail-panel {
  display: grid;
  gap: 12px;
  padding: 12px;
}

.collection-detail-panel[hidden] {
  display: none;
}

.collection-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.collection-panel-head h3 {
  margin: 2px 0 0;
  color: #172033;
  font-size: 1.08rem;
  font-weight: 950;
}

.collection-panel-head button,
.collection-active-row button {
  min-height: 38px;
  padding: 0 13px;
  color: #fff;
  background: #172033;
  border: 1px solid #172033;
  border-radius: 999px;
  font-weight: 950;
}

.collection-section-list {
  display: grid;
  gap: 8px;
}

.collection-section-list.is-reordering {
  -webkit-user-select: none;
  user-select: none;
}

.collection-section-panel,
.collection-section-row,
.collection-section-open,
.collection-section-actions,
.collection-section-copy {
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
}

body.is-section-dragging,
body.is-section-dragging * {
  -webkit-touch-callout: none !important;
  -webkit-user-select: none !important;
  user-select: none !important;
}

.collection-section-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  padding: 10px;
  background: #f8fbff;
  border: 1px solid #dbe3ef;
  border-radius: 16px;
  cursor: pointer;
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.collection-section-placeholder {
  background: rgba(47, 111, 237, 0.08);
  border: 2px dashed rgba(47, 111, 237, 0.28);
  border-radius: 16px;
}

.collection-section-row.is-active {
  background: #eef8f4;
  border-color: rgba(24, 167, 126, 0.38);
  box-shadow: inset 4px 0 0 #18a77e;
}

.collection-section-row.is-dragging {
  z-index: 120;
  pointer-events: none;
  border-color: rgba(47, 111, 237, 0.42);
  box-shadow: 0 16px 34px rgba(23, 32, 51, 0.18);
  transform: scale(1.015);
  transition: none;
  will-change: transform;
}

.collection-section-open {
  display: grid;
  grid-template-columns: 18px 28px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  width: 100%;
  min-height: 42px;
  padding: 0;
  color: #172033;
  text-align: left;
  background: transparent;
  border: 0;
}

.collection-drag-handle {
  display: block;
  width: 16px;
  height: 12px;
  border-block: 2px solid #8a95a6;
  cursor: grab;
  opacity: 0.75;
  touch-action: none;
}

.collection-drag-handle:active {
  cursor: grabbing;
}

.collection-drag-handle::after {
  display: block;
  height: 2px;
  margin-top: 3px;
  background: #8a95a6;
  content: "";
}

.collection-folder-icon {
  display: block;
  width: 28px;
  height: 21px;
  border: 2px solid #18a77e;
  border-radius: 6px;
  background: rgba(24, 167, 126, 0.08);
}

.collection-folder-icon.all {
  background: rgba(24, 167, 126, 0.24);
}

.collection-folder-icon.graded {
  border-color: #2f6fed;
  background: rgba(47, 111, 237, 0.1);
}

.collection-folder-icon.sealed {
  border-color: #ff7a59;
  background: rgba(255, 122, 89, 0.12);
}

.collection-section-copy {
  min-width: 0;
}

.collection-section-copy strong,
.collection-section-copy small {
  display: block;
}

.collection-section-copy strong {
  overflow: hidden;
  color: #172033;
  font-size: 0.96rem;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-section-copy small {
  overflow: hidden;
  margin-top: 3px;
  color: #697386;
  font-size: 0.78rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-section-arrow {
  padding: 6px 9px;
  color: #173b8f;
  background: #eaf1ff;
  border: 1px solid #c9d8ff;
  border-radius: 999px;
  font-size: 0.66rem;
  font-weight: 950;
  text-transform: uppercase;
}

.collection-section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  overflow: visible;
  padding-left: 56px;
}

.collection-section-actions button {
  min-height: 30px;
  padding: 0 9px;
  flex: 0 0 auto;
  color: #172033;
  background: #fff;
  border: 1px solid #dbe3ef;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 900;
}

.collection-section-actions button:disabled {
  color: #aab5c5;
  background: #edf2f7;
}

.collection-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 118px;
  gap: 10px;
  align-items: end;
  padding: 12px;
  border-radius: 18px;
}

.collection-search-field {
  display: grid;
  gap: 6px;
  color: #697386;
  font-size: 0.74rem;
  font-weight: 900;
}

.collection-toolbar select {
  min-height: 44px;
  border-radius: 14px;
}

.collection-list {
  margin-top: 0;
}

.collection-active-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 0 2px;
}

.collection-active-row span,
.collection-active-row strong {
  display: block;
}

.collection-active-row span {
  color: #697386;
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.collection-active-row strong {
  margin-top: 2px;
  color: #172033;
  font-size: 1.05rem;
  font-weight: 950;
}

.collection-tab .collection-card {
  padding: 13px;
  color: #172033;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid #dbe3ef;
  border-radius: 18px;
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.06);
}

.collection-tab .card-topline {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 11px;
  align-items: center;
}

.collection-card-image {
  width: 56px;
  height: 78px;
  object-fit: cover;
  background: #eef4f8;
  border: 1px solid #dbe3ef;
  border-radius: 10px;
}

.collection-tab .card-topline h3 {
  color: #172033;
  font-size: 1rem;
  line-height: 1.12;
}

.collection-tab .card-topline p,
.collection-tab .card-meta,
.collection-tab .card-notes {
  color: #697386;
}

.collection-tab .mini-card {
  width: 56px;
  height: 78px;
}

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

.collection-tab .value-row span {
  background: #f8fbff;
  border-color: #dbe3ef;
  border-radius: 14px;
}

.collection-tab .value-row small {
  color: #697386;
}

.collection-tab .value-row strong {
  color: #172033;
}

.collection-tab .positive strong {
  color: #18a77e;
}

.collection-tab .negative strong {
  color: #d94d45;
}

.collection-tab .card-meta,
.collection-tab .card-notes,
.collection-tab .card-price-note {
  display: block;
}

.collection-tab .card-price-note {
  margin-top: -2px;
  color: #173b8f;
  font-size: 0.78rem;
  font-weight: 850;
}

.collection-tab .card-actions {
  display: flex;
  gap: 7px;
  overflow-x: auto;
}

.collection-tab .card-actions::-webkit-scrollbar {
  display: none;
}

.collection-tab .card-actions a,
.collection-tab .card-actions button {
  flex: 0 0 auto;
  min-height: 32px;
  padding: 0 10px;
  color: #172033;
  background: #fff;
  border: 1px solid #dbe3ef;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 900;
}

body.is-collection-detail {
  background: #030406;
}

body.is-collection-detail .collector-app {
  max-width: 760px;
  min-height: 100svh;
  min-height: var(--mobile-page-height);
  padding-top: 12px;
  background: #030406;
}

body.is-collection-detail .dashboard-header {
  display: none;
}

.collection-tab.is-section-detail {
  gap: 14px;
  align-content: start;
  margin: -12px -16px -104px;
  padding: 12px 14px calc(112px + env(safe-area-inset-bottom));
  color: #f7f8fb;
  background:
    radial-gradient(circle at 18% 0%, rgba(77, 116, 255, 0.18), transparent 28%),
    linear-gradient(180deg, #05070b 0%, #020304 100%);
  min-height: calc(100svh - 12px);
  min-height: calc(var(--mobile-page-height) - 12px);
}

.collection-tab.is-section-detail .collection-tab-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 0 4px;
  color: #f7f8fb;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-tab-head > div {
  display: none;
}

.collection-tab.is-section-detail .collection-back-btn,
.collection-tab.is-section-detail .scan-icon-button {
  min-height: 44px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-back-btn {
  padding: 0 16px;
  font-weight: 900;
}

.collection-tab.is-section-detail .collection-stat-row,
.collection-tab.is-section-detail .collection-section-panel,
.collection-tab.is-section-detail .collection-active-row {
  display: none;
}

.collection-tab.is-section-detail .collection-detail-panel {
  gap: 22px;
  padding: 0 4px;
  color: #f7f8fb;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.collection-portfolio-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 50px 50px;
  gap: 10px;
  align-items: center;
}

.collection-portfolio-search {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) 34px;
  gap: 10px;
  align-items: center;
  min-height: 52px;
  padding: 0 10px 0 16px;
  color: #f7f8fb;
  background: #030406;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
}

.collection-portfolio-search svg,
.collection-portfolio-icon svg,
.collection-portfolio-filter svg,
.collection-portfolio-hero svg,
.collection-portfolio-actions svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-portfolio-search > svg {
  color: #f7f8fb;
}

.collection-portfolio-search input {
  min-width: 0;
  min-height: 44px;
  padding: 0;
  color: #f7f8fb;
  background: transparent;
  border: 0;
  font-size: 1rem;
  font-weight: 800;
}

.collection-portfolio-search input::placeholder {
  color: rgba(247, 248, 251, 0.76);
}

.collection-portfolio-search button,
.collection-portfolio-icon,
.collection-portfolio-filter {
  display: grid;
  place-items: center;
  color: #f7f8fb;
  background: #030406;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
}

.collection-portfolio-search button {
  width: 34px;
  height: 34px;
  padding: 8px;
  border: 0;
  background: transparent;
}

.collection-portfolio-icon,
.collection-portfolio-filter {
  position: relative;
  width: 50px;
  height: 50px;
  padding: 13px;
}

.collection-portfolio-icon.is-active {
  color: #fff36d;
  border-color: rgba(255, 243, 109, 0.58);
}

.collection-portfolio-filter select {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
}

.collection-portfolio-hero {
  display: grid;
  justify-items: center;
  gap: 8px;
  text-align: center;
}

.collection-portfolio-hero p {
  margin: 0;
  color: #f7f8fb;
  font-size: 1.06rem;
  font-weight: 850;
}

.collection-portfolio-hero p strong {
  color: #65c5bb;
}

.collection-portfolio-hero div {
  display: inline-grid;
  grid-template-columns: auto 38px;
  gap: 10px;
  align-items: center;
}

.collection-portfolio-hero div > strong {
  color: #f7f8fb;
  font-size: clamp(2.55rem, 12vw, 4rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.collection-portfolio-hero div > span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 10px;
  color: rgba(247, 248, 251, 0.62);
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
}

.collection-portfolio-hero small {
  color: rgba(247, 248, 251, 0.6);
  font-size: 0.86rem;
  font-weight: 850;
}

.collection-portfolio-hero small.positive {
  color: #65c5bb;
}

.collection-portfolio-hero small.negative {
  color: #ff917f;
}

.collection-portfolio-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  align-items: start;
}

.collection-portfolio-actions button {
  display: grid;
  justify-items: center;
  gap: 8px;
  min-width: 0;
  color: #65c5bb;
  background: transparent;
  border: 0;
  font-weight: 850;
  text-align: center;
}

.collection-portfolio-actions button > span {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  padding: 15px;
  color: #65c5bb;
  background: #030406;
  border: 1px solid rgba(101, 197, 187, 0.28);
  border-radius: 999px;
}

.collection-portfolio-actions button:first-child > span {
  border-color: transparent;
  background:
    linear-gradient(#030406, #030406) padding-box,
    conic-gradient(from 30deg, #65c5bb, #316dff, #b65cff, #fff36d, #65c5bb) border-box;
  border: 2px solid transparent;
}

.collection-portfolio-actions strong {
  display: block;
  color: #65c5bb;
  font-size: clamp(0.66rem, 2.9vw, 0.78rem);
  line-height: 1.15;
}

.collection-tab.is-section-detail .collection-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 0;
}

.collection-tab.is-section-detail .empty-state {
  grid-column: 1 / -1;
  color: rgba(247, 248, 251, 0.72);
  background: #07090d;
  border-color: rgba(255, 255, 255, 0.14);
}

.collection-tab.is-section-detail .empty-state strong {
  color: #fff;
}

.collection-tab.is-section-detail .collection-card {
  gap: 10px;
  padding: 12px 10px;
  color: #f7f8fb;
  background: #030406;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  box-shadow: none;
}

.portfolio-card-image-wrap {
  display: grid;
  place-items: center;
  min-height: 132px;
}

.collection-tab.is-section-detail .collection-card-image {
  width: min(124px, 88%);
  height: auto;
  aspect-ratio: 63 / 88;
  object-fit: cover;
  background: #111722;
  border: 0;
  border-radius: 8px;
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.42);
}

.collection-tab.is-section-detail .mini-card {
  width: min(124px, 88%);
  height: auto;
  aspect-ratio: 63 / 88;
  border-radius: 8px;
}

.portfolio-card-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.collection-tab.is-section-detail .portfolio-card-copy h3 {
  margin: 0;
  color: #f7f8fb;
  font-size: clamp(1rem, 4vw, 1.2rem);
  line-height: 1.08;
  font-weight: 900;
}

.collection-tab.is-section-detail .portfolio-card-copy p {
  margin: 0;
  color: rgba(247, 248, 251, 0.82);
  font-size: clamp(0.76rem, 3.4vw, 0.92rem);
  line-height: 1.22;
}

.collection-tab.is-section-detail .portfolio-card-copy .portfolio-card-condition {
  color: #65c5bb;
}

.portfolio-card-footer {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
  align-items: end;
  margin-top: 12px;
}

.portfolio-card-footer > span:first-child {
  color: #f7f8fb;
  font-size: 0.76rem;
  font-weight: 850;
}

.portfolio-card-inventory {
  display: grid;
  gap: 5px;
  align-self: end;
}

.portfolio-card-inventory button {
  width: max-content;
  max-width: 100%;
  min-height: 26px;
  padding: 0 9px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 900;
  text-align: left;
}

.portfolio-card-footer > span:last-child {
  display: grid;
  justify-items: end;
  min-width: 0;
  text-align: right;
}

.portfolio-card-footer strong,
.portfolio-card-footer small {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.portfolio-card-footer strong {
  color: #f7f8fb;
  font-size: 0.96rem;
  line-height: 1.1;
}

.portfolio-card-footer small {
  color: rgba(247, 248, 251, 0.72);
  font-size: 0.76rem;
  line-height: 1.15;
}

.portfolio-card-footer .positive strong,
.portfolio-card-footer .positive small {
  color: #a4ded8;
}

.portfolio-card-footer .negative strong,
.portfolio-card-footer .negative small {
  color: #ff917f;
}

.collection-tab.is-section-detail .card-meta,
.collection-tab.is-section-detail .card-price-note {
  margin: 0;
  color: rgba(247, 248, 251, 0.54);
  font-size: 0.68rem;
  line-height: 1.25;
}

.collection-tab.is-section-detail .card-actions {
  gap: 6px;
  padding-top: 2px;
}

.collection-tab.is-section-detail .card-actions a,
.collection-tab.is-section-detail .card-actions button {
  min-height: 28px;
  padding: 0 8px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.14);
  font-size: 0.66rem;
}

@media (max-width: 380px) {
  .collection-portfolio-actions {
    gap: 7px;
  }

  .collection-portfolio-actions button > span {
    width: 46px;
    height: 46px;
    padding: 13px;
  }

  .collection-tab.is-section-detail .collection-list {
    gap: 9px;
  }

  .collection-tab.is-section-detail .collection-card {
    padding: 10px 8px;
  }
}

.collection-section-picker {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: grid;
  align-items: end;
  background: rgba(8, 12, 22, 0.42);
}

.collection-section-picker-panel {
  width: min(430px, calc(100% - 20px));
  max-height: min(76vh, 620px);
  margin: 0 auto 10px;
  padding: 10px 14px 14px;
  overflow: auto;
  color: #172033;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid #dbe3ef;
  border-radius: 24px;
  box-shadow: 0 -18px 45px rgba(15, 23, 42, 0.18);
}

.scanner-save-confirmation {
  position: fixed;
  right: 14px;
  bottom: calc(18px + env(safe-area-inset-bottom));
  left: 14px;
  z-index: 1300;
  display: grid;
  justify-items: center;
  pointer-events: none;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 180ms ease, transform 180ms ease;
}

.scanner-save-confirmation.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.scanner-save-confirmation-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  width: min(430px, 100%);
  padding: 12px;
  color: #f8fbff;
  background:
    linear-gradient(145deg, rgba(21, 32, 45, 0.96), rgba(4, 8, 14, 0.94)),
    rgba(4, 8, 14, 0.94);
  border: 1px solid rgba(126, 211, 202, 0.34);
  border-radius: 18px;
  box-shadow: 0 22px 48px rgba(2, 4, 10, 0.36);
  pointer-events: auto;
  backdrop-filter: blur(18px);
}

.scanner-save-confirmation-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: #06120e;
  background: #7bdca5;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.02em;
}

.scanner-save-confirmation-card strong,
.scanner-save-confirmation-card small {
  display: block;
}

.scanner-save-confirmation-card strong {
  color: #ffffff;
  font-size: 0.95rem;
  line-height: 1.1;
}

.scanner-save-confirmation-card small {
  margin-top: 3px;
  color: rgba(226, 232, 240, 0.78);
  font-size: 0.78rem;
  line-height: 1.25;
}

.scanner-save-confirmation-card button {
  min-width: 46px;
  min-height: 34px;
  padding: 0 12px;
  color: #06120e;
  background: #7ed3ca;
  border: 0;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.sheet-handle {
  display: block;
  width: 52px;
  height: 5px;
  margin: 2px auto 14px;
  background: #cbd5e1;
  border: 0;
  border-radius: 999px;
}

.collection-section-picker-head span,
.collection-section-picker-head strong {
  display: block;
}

.collection-section-picker-head span {
  color: #2f6fed;
  font-size: 0.74rem;
  font-weight: 950;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.collection-section-picker-head strong {
  margin-top: 3px;
  font-size: 1.2rem;
  font-weight: 950;
}

.collection-section-picker-list {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.collection-section-picker-list button {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  width: 100%;
  min-height: 56px;
  padding: 10px;
  color: #172033;
  text-align: left;
  background: #f8fbff;
  border: 1px solid #dbe3ef;
  border-radius: 16px;
}

.collection-section-picker-list strong,
.collection-section-picker-list small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-section-picker-list strong {
  font-size: 0.95rem;
  font-weight: 950;
}

.collection-section-picker-list small {
  margin-top: 2px;
  color: #697386;
  font-size: 0.76rem;
  font-weight: 800;
}

.collection-section-picker-cancel {
  width: 100%;
  min-height: 44px;
  margin-top: 12px;
  color: #172033;
  background: #fff;
  border: 1px solid #dbe3ef;
  border-radius: 999px;
  font-weight: 950;
}

.collection-section-manager {
  position: fixed;
  inset: 0;
  z-index: 1240;
  display: grid;
  align-items: end;
  padding: 12px;
  background: rgba(2, 6, 13, 0.58);
  backdrop-filter: blur(12px);
}

.collection-section-manager-panel {
  display: grid;
  gap: 12px;
  width: min(480px, 100%);
  max-height: min(78vh, 660px);
  margin: 0 auto max(10px, env(safe-area-inset-bottom));
  padding: 10px 12px 14px;
  overflow: auto;
  color: #f7f8fb;
  background:
    radial-gradient(220px 150px at 12% 0%, rgba(126, 211, 202, 0.16), transparent 72%),
    linear-gradient(145deg, rgba(20, 31, 49, 0.97), rgba(5, 9, 17, 0.98));
  border: 1px solid rgba(126, 211, 202, 0.22);
  border-radius: 22px;
  box-shadow: 0 -22px 54px rgba(0, 0, 0, 0.36), inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.collection-section-manager-panel .sheet-handle {
  background: rgba(224, 231, 244, 0.28);
}

.collection-section-manager-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.collection-section-manager-head span,
.collection-section-manager-head strong {
  display: block;
}

.collection-section-manager-head span {
  color: #7ed3ca;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.collection-section-manager-head strong {
  margin-top: 2px;
  color: #ffffff;
  font-size: 1.12rem;
  line-height: 1.1;
}

.collection-section-manager-head button,
.collection-section-manager-add button,
.collection-section-manager-actions button {
  min-height: 34px;
  color: #06110f;
  background: linear-gradient(135deg, #a8f2be, #8edcd4);
  border: 1px solid rgba(166, 244, 207, 0.46);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.collection-section-manager-add {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 7px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(126, 211, 202, 0.16);
  border-radius: 14px;
}

.collection-section-manager-add input {
  min-width: 0;
  min-height: 36px;
  padding: 0 10px;
  color: #ffffff;
  background: rgba(3, 7, 14, 0.58);
  border: 1px solid rgba(224, 231, 244, 0.1);
  border-radius: 11px;
  font-size: 0.88rem;
  font-weight: 850;
}

.collection-section-manager-add input::placeholder {
  color: rgba(224, 231, 244, 0.46);
}

.collection-section-manager-add button {
  min-width: 62px;
  padding: 0 14px;
}

.collection-section-manager-list {
  display: grid;
  gap: 9px;
}

.collection-section-manager-row {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  padding: 9px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(224, 231, 244, 0.1);
  border-radius: 16px;
}

.collection-section-manager-row.is-primary {
  border-color: rgba(255, 209, 102, 0.34);
  box-shadow: inset 3px 0 0 rgba(255, 209, 102, 0.68);
}

.collection-section-manager-main {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 9px;
  color: rgba(224, 231, 244, 0.48);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(224, 231, 244, 0.12);
  border-radius: 12px;
}

.collection-section-manager-row.is-primary .collection-section-manager-main {
  color: #ffd166;
  background: rgba(255, 209, 102, 0.14);
  border-color: rgba(255, 209, 102, 0.24);
}

.collection-section-manager-main svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.collection-section-manager-name {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 5px 8px;
  align-items: center;
  min-width: 0;
}

.collection-section-manager-name span {
  color: #9db9ff;
  font-size: 0.58rem;
  font-weight: 950;
  letter-spacing: 0.11em;
}

.collection-section-manager-name input {
  min-width: 0;
  width: 100%;
  height: 34px;
  padding: 0 9px;
  color: #ffffff;
  background: rgba(5, 9, 17, 0.5);
  border: 1px solid rgba(126, 211, 202, 0.14);
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 900;
}

.collection-section-manager-name small {
  grid-column: 1 / -1;
  color: rgba(224, 231, 244, 0.52);
  font-size: 0.72rem;
  font-weight: 850;
}

.collection-section-manager-actions {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.collection-section-manager-actions button {
  min-width: 74px;
  padding: 0 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.13);
}

.collection-section-manager-actions button[data-section-action="delete"] {
  color: #ffd4ce;
  border-color: rgba(255, 145, 127, 0.26);
}

.collection-section-manager-actions button:disabled {
  color: rgba(224, 231, 244, 0.32);
  background: rgba(255, 255, 255, 0.04);
}

.scan-icon-button {
  color: #fff;
  background: #2f6fed;
  border-color: #2f6fed;
  box-shadow: 0 14px 26px rgba(47, 111, 237, 0.2);
}

.collector-app label {
  color: #374151;
}

.collector-app input,
.collector-app select,
.collector-app textarea {
  color: #172033;
  background: #f8fbff;
  border-color: #cfdae8;
}

.collector-app input::placeholder {
  color: #8a95a6;
}

.collector-app input:focus,
.collector-app select:focus,
.collector-app textarea:focus {
  border-color: #2f6fed;
  box-shadow: 0 0 0 3px rgba(47, 111, 237, 0.14);
}

.collector-app .primary-action {
  color: #fff;
  background: #ff7a59;
  border-color: #ff7a59;
}

.collector-app .secondary-action,
.collector-app .ghost-action {
  color: #172033;
  background: #f7f9fd;
  border-color: #dbe3ef;
}

.collector-app .camera-stage {
  border-color: #cfd9e7;
  background:
    linear-gradient(135deg, rgba(47, 111, 237, 0.22), rgba(24, 167, 126, 0.2)),
    #172033;
}

.collector-app .scanner-status {
  color: #697386;
}

.status-chip {
  color: #172033;
  background: #ffd166;
}

.collector-app .market-snapshot-card {
  background: #f8fbff;
  border-color: #dbe3ef;
}

.collector-app .snapshot-image {
  color: #697386;
  background: #eef4f8;
  border-color: #dbe3ef;
}

.collector-app .snapshot-body span {
  color: #697386;
}

.collector-app .snapshot-body strong {
  color: #2f6fed;
}

.collector-app .snapshot-body p {
  color: #374151;
}

.collector-app .snapshot-body small {
  color: #697386;
}

.save-inventory-btn {
  color: #fff;
  background: #18a77e;
  border-color: #18a77e;
}

.save-inventory-btn:disabled {
  color: #8a95a6;
  background: #edf2f7;
  border-color: #dbe3ef;
}

.bottom-nav {
  color: #697386;
  background: rgba(255, 255, 255, 0.96);
  border-top-color: #dbe3ef;
  box-shadow: 0 -14px 34px rgba(23, 32, 51, 0.08);
}

.bottom-nav .active {
  color: #2f6fed;
}

.bottom-nav .scan-tab {
  color: #fff;
  background: #172033;
}

@media (max-width: 360px) {
  .value-hub,
  .collector-app .scanner-search,
  .collector-app .market-snapshot-card {
    grid-template-columns: 1fr;
  }

  .value-hub-art {
    height: 92px;
  }

  .collector-app .snapshot-image {
    width: 100%;
  }
}

/* Standalone card scanner */
html.scanner-active-root,
html.scanner-active-root body {
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
}

body.scanner-active {
  position: fixed;
  inset: 0;
  width: 100%;
  overflow: hidden;
}

.scanner-overlay[hidden] {
  display: none;
}

.scanner-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: 100%;
  height: var(--scanner-layout-height);
  min-height: var(--scanner-layout-height);
  overflow: hidden;
  overscroll-behavior: none;
  z-index: 1000;
  color: #fff;
  background: #02040a;
}

.scanner-overlay.scan-lab-camera-active {
  z-index: 1210;
}

/* MEMORY LINE: Scan Queue Safe Area Fix START */
.scanner-shell {
  --scanner-frame-top: clamp(66px, 7.5svh, 96px);
  --scanner-frame-width: min(92vw, 480px);
  --scanner-guide-width: var(--scanner-frame-width);
  --scanner-frame-side: max(14px, calc((100vw - var(--scanner-frame-width)) / 2));
  --scanner-queue-bottom: max(6px, calc(env(safe-area-inset-bottom) + 6px));
  --scanner-queue-height: 162px;
  --scanner-control-height: 38px;
  --scanner-control-queue-gap: 8px;
  --scanner-frame-control-gap: 24px;
  --scanner-search-height: clamp(34px, 4.6svh, 40px);
  position: relative;
  width: 100%;
  max-width: 100%;
  height: var(--scanner-layout-height);
  min-height: var(--scanner-layout-height);
  overflow: hidden;
  overscroll-behavior: none;
  background: #02040a;
}
/* MEMORY LINE: Scan Queue Safe Area Fix END */

.scanner-overlay .camera-stage {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-height: none;
  margin: 0;
  aspect-ratio: auto;
  background: #02040a;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  overscroll-behavior: none;
  touch-action: none;
}

.scanner-overlay .camera-stage[hidden] {
  display: none;
}

.scanner-overlay .camera-stage video,
.scanner-overlay .camera-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.scanner-manual-search-bar {
  --scanner-search-glow: linear-gradient(120deg, #52ffe0, #4ea1ff, #9b6cff, #78ffb7, #52ffe0);
  position: relative;
  isolation: isolate;
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  justify-self: center;
  width: min(calc(var(--scanner-guide-width, var(--scanner-frame-width)) - 28px), calc(100vw - 112px), 452px);
  min-width: 0;
  max-width: min(calc(var(--scanner-guide-width, var(--scanner-frame-width)) - 28px), calc(100vw - 112px), 452px);
  height: var(--scanner-search-height);
  min-height: var(--scanner-search-height);
  margin: 0 auto;
  padding: 1px;
  color: #ecfffb;
  background: var(--scanner-search-glow);
  background-size: 300% 300%;
  border: 0;
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(14px);
  pointer-events: auto;
  animation: scannerSearchGlowMove 6s linear infinite;
}

.scanner-manual-search-bar::before {
  position: absolute;
  inset: -1px;
  z-index: -1;
  background: inherit;
  background-size: inherit;
  border-radius: inherit;
  filter: blur(4px);
  opacity: 0.16;
  pointer-events: none;
  content: "";
  animation: inherit;
}

.scanner-manual-search-bar:focus-within {
  box-shadow: 0 9px 20px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(82, 255, 224, 0.14);
}

.scanner-manual-search-field {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  width: 100%;
  height: 100%;
  min-width: 0;
  overflow: hidden;
  padding: 0 18px;
  background: rgba(8, 11, 19, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: inherit;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), inset 0 -12px 28px rgba(82, 161, 255, 0.06);
  backdrop-filter: blur(18px);
}

.scanner-manual-search-icon {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  color: rgba(223, 248, 255, 0.94);
  background: transparent;
  border: 0;
  filter: drop-shadow(0 0 7px rgba(82, 255, 224, 0.18));
}

.scanner-manual-search-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.35;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.scanner-manual-search-entry {
  position: relative;
  display: grid;
  align-items: center;
  min-width: 0;
  height: 100%;
}

.scanner-manual-search-bar input {
  position: relative;
  z-index: 2;
  grid-area: 1 / 1;
  width: 100%;
  min-width: 0;
  height: 100%;
  padding: 0;
  color: #f8fffd;
  background: transparent;
  border: 0;
  outline: 0;
  caret-color: #52ffe0;
  font-size: clamp(0.76rem, 2.4vw, 0.9rem);
  font-weight: 760;
  letter-spacing: 0;
}

.scanner-manual-search-bar input::placeholder {
  color: transparent;
  opacity: 0;
}

.scanner-manual-search-placeholder {
  grid-area: 1 / 1;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  color: rgba(255, 255, 255, 0.68);
  font-size: clamp(0.76rem, 2.4vw, 0.9rem);
  line-height: 1;
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.scanner-manual-search-field:focus-within .scanner-manual-search-placeholder,
.scanner-manual-search-bar input:not(:placeholder-shown) + .scanner-manual-search-placeholder {
  opacity: 0;
  transform: translateY(2px);
}

.scanner-search-prefix {
  flex: 0 0 auto;
  color: rgba(255, 255, 255, 1);
  font-weight: 840;
  white-space: nowrap;
}

.scanner-search-placeholder-query {
  position: relative;
  display: block;
  flex: 1 1 auto;
  min-width: 0;
  height: 1.1em;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.68);
  white-space: nowrap;
}

.scanner-search-placeholder-query > span {
  position: absolute;
  inset: 0;
  overflow: hidden;
  opacity: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
  transform: translateY(8px);
  animation: scannerSearchQueryCycle 15s ease-in-out infinite;
}

.scanner-search-placeholder-query > span:nth-child(2) {
  animation-delay: 3s;
}

.scanner-search-placeholder-query > span:nth-child(3) {
  animation-delay: 6s;
}

.scanner-search-placeholder-query > span:nth-child(4) {
  animation-delay: 9s;
}

.scanner-search-placeholder-query > span:nth-child(5) {
  animation-delay: 12s;
}

.scanner-manual-search-bar input::-webkit-search-cancel-button,
.scanner-manual-search-bar input::-webkit-search-decoration {
  appearance: none;
}

@keyframes scannerSearchGlowMove {
  0% {
    background-position: 0% 50%;
  }

  100% {
    background-position: 300% 50%;
  }
}

@keyframes scannerSearchQueryCycle {
  0%,
  15% {
    opacity: 1;
    transform: translateY(0);
  }

  20%,
  100% {
    opacity: 0;
    transform: translateY(-8px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .scanner-manual-search-bar,
  .scanner-manual-search-bar::before,
  .scanner-search-placeholder-query > span {
    animation: none;
  }

  .scanner-search-placeholder-query > span:first-child {
    opacity: 1;
    transform: none;
  }
}

.scanner-top-close-btn {
  position: absolute;
  z-index: 4;
  top: 50%;
  left: max(14px, env(safe-area-inset-left));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: var(--scanner-search-height);
  padding: 0 2px;
  color: #fff;
  background: transparent;
  border: 0;
  border-radius: 0;
  font-size: 0.82rem;
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1;
  text-shadow: 0 2px 8px rgba(2, 4, 10, 0.92), 0 0 18px rgba(2, 4, 10, 0.72);
  cursor: pointer;
  pointer-events: auto;
  transform: translateY(-50%);
}

.scanner-overlay-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 3;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: calc(max(16px, env(safe-area-inset-top)) + 58px) 16px 24px;
  background: linear-gradient(180deg, rgba(2, 4, 10, 0.92), rgba(2, 4, 10, 0));
}

.scanner-overlay-top button {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  backdrop-filter: blur(12px);
}

.scanner-overlay-top > div {
  position: absolute;
  top: calc(max(16px, env(safe-area-inset-top)) + 58px);
  left: 50%;
  z-index: 1;
  display: grid;
  align-items: center;
  width: calc(100% - 188px);
  height: 44px;
  min-width: 0;
  pointer-events: none;
  text-align: center;
  transform: translateX(-50%);
}

.scanner-overlay-sr-title {
  position: absolute;
  width: 1px;
  min-height: 0;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.scanner-reset-bottom {
  display: inline-grid;
  place-items: center;
  width: auto;
  min-width: 70px;
  height: 38px;
  padding: 0 14px;
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 999px;
  backdrop-filter: blur(12px);
}

.scanner-game-mode {
  display: flex;
  flex: 1 1 190px;
  align-items: center;
  justify-content: center;
  gap: 3px;
  max-width: 246px;
  min-width: 0;
  height: 38px;
  padding: 4px;
  color: #dff8eb;
  background: rgba(2, 4, 10, 0.68);
  border: 1px solid rgba(126, 211, 202, 0.28);
  border-radius: 999px;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

.scanner-game-mode button {
  display: inline-grid;
  place-items: center;
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  padding: 0 7px;
  color: rgba(236, 255, 251, 0.78);
  background: transparent;
  border: 0;
  border-radius: 999px;
  font-size: 0.5rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
}

.scanner-game-mode button.is-active {
  color: #06120e;
  background: linear-gradient(135deg, #9fe7ff, #9df0b4);
  box-shadow: 0 8px 18px rgba(98, 211, 151, 0.24);
}

.scanner-game-mode button:focus-visible {
  outline: 2px solid #9fc1ff;
  outline-offset: 2px;
}

.scanner-overlay-top svg {
  width: 1.1rem;
  height: 1.1rem;
}

.scanner-overlay-top .eyebrow {
  color: #8fb8ff;
}

.scanner-overlay-top h2 {
  margin: 0;
  overflow: hidden;
  color: #fff;
  font-size: clamp(1rem, 4.2vw, 1.15rem);
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scanner-overlay .scan-frame {
  --scanner-frame-scale: 1;
  --scanner-focus-mask: rgba(2, 4, 10, 0.18);
  --scanner-tray-reserved: calc(var(--scanner-queue-bottom) + var(--scanner-queue-height) + var(--scanner-control-queue-gap) + var(--scanner-control-height) + var(--scanner-frame-control-gap));
  --scanner-corner-inset: 0px;
  --scanner-lock-meter: 0%;
  --scanner-lock-color: rgba(255, 255, 255, 0.92);
  --scanner-card-left: 0%;
  --scanner-card-top: 0%;
  --scanner-card-right: 100%;
  --scanner-card-bottom: 100%;
  position: absolute;
  top: var(--scanner-frame-top);
  right: auto;
  bottom: auto;
  left: 50%;
  width: var(--scanner-guide-width, var(--scanner-frame-width));
  max-width: calc(100vw - 28px);
  max-height: calc(var(--scanner-layout-height) - var(--scanner-frame-top) - var(--scanner-tray-reserved));
  aspect-ratio: 63 / 88;
  border: 0;
  border-radius: 24px;
  box-shadow: 0 0 0 999px rgba(2, 4, 10, 0.18), 0 18px 44px rgba(2, 4, 10, 0.3);
  pointer-events: none;
  transform: translateX(-50%) scale(var(--scanner-frame-scale));
  transform-origin: center;
  transition: box-shadow 180ms ease, transform 180ms ease;
}

.scanner-overlay .scan-frame::before {
  position: absolute;
  inset: -110vmax;
  border: 110vmax solid var(--scanner-focus-mask);
  border-radius: calc(110vmax + 24px);
  content: "";
  filter: blur(1px);
  pointer-events: none;
}

.scanner-overlay .scan-frame span {
  position: absolute;
  z-index: 2;
  width: 54px;
  height: 54px;
  border-color: rgba(255, 255, 255, 0.96);
  filter: drop-shadow(0 4px 12px rgba(2, 4, 10, 0.48));
  transition: border-color 180ms ease, filter 180ms ease, transform 180ms ease;
}

.scanner-overlay .scan-frame span:nth-child(1) {
  top: var(--scanner-card-top);
  left: var(--scanner-card-left);
  border-top: 6px solid;
  border-left: 6px solid;
  border-radius: 24px 0 0;
  transform: translate(var(--scanner-corner-inset), var(--scanner-corner-inset));
}

.scanner-overlay .scan-frame span:nth-child(2) {
  top: var(--scanner-card-top);
  left: var(--scanner-card-right);
  border-top: 6px solid;
  border-right: 6px solid;
  border-radius: 0 24px 0 0;
  transform: translate(calc(-100% - var(--scanner-corner-inset)), var(--scanner-corner-inset));
}

.scanner-overlay .scan-frame span:nth-child(3) {
  top: var(--scanner-card-bottom);
  left: var(--scanner-card-right);
  border-right: 6px solid;
  border-bottom: 6px solid;
  border-radius: 0 0 24px;
  transform: translate(calc(-100% - var(--scanner-corner-inset)), calc(-100% - var(--scanner-corner-inset)));
}

.scanner-overlay .scan-frame span:nth-child(4) {
  top: var(--scanner-card-bottom);
  left: var(--scanner-card-left);
  border-bottom: 6px solid;
  border-left: 6px solid;
  border-radius: 0 0 0 24px;
  transform: translate(var(--scanner-corner-inset), calc(-100% - var(--scanner-corner-inset)));
}

.scanner-overlay .scan-tap-hint {
  position: absolute;
  z-index: 2;
  right: 9%;
  bottom: calc(7% + 38px);
  color: #fff;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.01em;
  line-height: 1;
  background: transparent;
  border: 0;
  text-shadow: 0 2px 8px rgba(2, 4, 10, 0.9), 0 0 16px rgba(2, 4, 10, 0.62);
  pointer-events: none;
}

.scanner-overlay .scan-lock-meter {
  position: absolute;
  z-index: 2;
  right: 8%;
  bottom: 7%;
  left: 8%;
  height: 5px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  box-shadow: 0 5px 16px rgba(2, 4, 10, 0.24);
}

.scanner-overlay .scan-lock-meter i {
  display: block;
  width: var(--scanner-lock-meter);
  height: 100%;
  background: var(--scanner-lock-color);
  border-radius: inherit;
  transition: width 180ms ease, background 180ms ease;
}

.scanner-overlay .scan-lock-label {
  position: absolute;
  z-index: 2;
  right: 8%;
  bottom: calc(7% + 12px);
  padding: 4px 8px;
  color: #06120e;
  background: rgba(255, 255, 255, 0.88);
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  box-shadow: 0 7px 18px rgba(2, 4, 10, 0.22);
}

.scanner-overlay .scan-card-outline {
  position: absolute;
  z-index: 2;
  top: var(--scanner-card-top);
  right: calc(100% - var(--scanner-card-right));
  bottom: calc(100% - var(--scanner-card-bottom));
  left: var(--scanner-card-left);
  border: 3px solid rgba(255, 255, 255, 0.72);
  border-radius: 24px;
  box-shadow:
    inset 0 0 0 2px rgba(2, 4, 10, 0.34),
    0 0 0 1px rgba(255, 255, 255, 0.16),
    0 0 28px rgba(255, 255, 255, 0.08);
}

.scanner-overlay .scan-axis {
  position: absolute;
  z-index: 2;
  background: rgba(255, 255, 255, 0.28);
  box-shadow: 0 0 18px rgba(2, 4, 10, 0.24);
}

.scanner-overlay .scan-axis-vertical {
  top: 9%;
  bottom: 9%;
  left: 50%;
  width: 1px;
}

.scanner-overlay .scan-axis-horizontal {
  top: 50%;
  right: 9%;
  left: 9%;
  height: 1px;
}

.scanner-overlay .scan-aim-dot {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 10px;
  background: rgba(255, 255, 255, 0.9);
  border: 2px solid rgba(2, 4, 10, 0.42);
  border-radius: 999px;
  box-shadow: 0 0 0 8px rgba(255, 255, 255, 0.1), 0 8px 18px rgba(2, 4, 10, 0.28);
  transform: translate(-50%, -50%);
}

.scanner-overlay .scan-frame.is-holding {
  --scanner-lock-color: #e6aa35;
  --scanner-focus-mask: rgba(2, 4, 10, 0.2);
  box-shadow: 0 0 0 999px rgba(2, 4, 10, 0.24), 0 0 0 3px rgba(230, 170, 53, 0.5), 0 0 28px rgba(230, 170, 53, 0.2);
}

.scanner-overlay .scan-frame.is-holding span {
  border-color: #e6aa35;
  filter: drop-shadow(0 0 10px rgba(230, 170, 53, 0.48));
}

.scanner-overlay .scan-frame.is-holding .scan-lock-label {
  color: #2a1700;
  background: rgba(230, 170, 53, 0.92);
}

.scanner-overlay .scan-frame.is-ready {
  --scanner-lock-color: #62d397;
  --scanner-focus-mask: rgba(2, 4, 10, 0.22);
  box-shadow: 0 0 0 999px rgba(2, 4, 10, 0.22), 0 0 0 4px rgba(98, 211, 151, 0.62), 0 0 34px rgba(98, 211, 151, 0.26);
}

.scanner-overlay .scan-frame.is-ready span {
  border-color: #62d397;
  filter: drop-shadow(0 0 10px rgba(98, 211, 151, 0.52));
}

.scanner-overlay .scan-frame.is-ready .scan-card-outline {
  border-color: rgba(98, 211, 151, 0.86);
  box-shadow:
    inset 0 0 0 2px rgba(2, 4, 10, 0.32),
    0 0 0 1px rgba(98, 211, 151, 0.28),
    0 0 28px rgba(98, 211, 151, 0.18);
}

.scanner-overlay .scan-frame.is-ready .scan-axis,
.scanner-overlay .scan-frame.is-ready .scan-aim-dot {
  background: rgba(98, 211, 151, 0.62);
}

.scanner-overlay .scan-frame.is-ready .scan-lock-label {
  color: #06120e;
  background: rgba(98, 211, 151, 0.92);
}

.scanner-overlay .scan-frame.is-frame-locked {
  --scanner-lock-color: #b9ffd8;
  --scanner-focus-mask: rgba(2, 4, 10, 0.22);
  box-shadow: 0 0 0 999px rgba(2, 4, 10, 0.2), 0 0 0 4px rgba(98, 211, 151, 0.72), 0 0 38px rgba(98, 211, 151, 0.36);
}

.scanner-overlay .scan-frame.is-frame-locked span,
.scanner-overlay .scan-frame.is-frame-locked .scan-card-outline {
  transition-duration: 90ms;
}

.scanner-overlay .scan-frame.is-frame-locked .scan-lock-label {
  background: rgba(185, 255, 216, 0.94);
}

.scanner-overlay .scan-frame.is-captured {
  --scanner-corner-inset: 18px;
  --scanner-lock-color: #fff;
  --scanner-focus-mask: rgba(2, 4, 10, 0.18);
  box-shadow: 0 0 0 999px rgba(2, 4, 10, 0.18), 0 0 0 4px rgba(255, 255, 255, 0.84), 0 0 32px rgba(98, 211, 151, 0.55);
  --scanner-frame-scale: 0.992;
}

.scanner-overlay .scan-frame.is-error {
  --scanner-lock-color: #f59e0b;
  --scanner-focus-mask: rgba(2, 4, 10, 0.2);
  box-shadow: 0 0 0 999px rgba(2, 4, 10, 0.2), 0 0 0 4px rgba(245, 158, 11, 0.86), 0 0 32px rgba(245, 158, 11, 0.38);
  --scanner-frame-scale: 0.996;
}

.scanner-overlay .scan-frame.is-warning {
  --scanner-lock-color: #f59e0b;
}

.scanner-overlay .scan-frame.is-warning .scan-lock-label {
  color: #fff;
  background: rgba(245, 158, 11, 0.78);
}

.scanner-overlay .scan-frame.is-low-scan,
.scanner-overlay .scan-frame.is-high-scan {
  --scanner-lock-color: #62d397;
}

.scanner-overlay .scan-frame.is-low-scan span,
.scanner-overlay .scan-frame.is-high-scan span {
  border-color: #62d397;
  filter: drop-shadow(0 0 10px rgba(98, 211, 151, 0.42));
}

.scanner-overlay .scan-frame.is-low-scan .scan-lock-label,
.scanner-overlay .scan-frame.is-high-scan .scan-lock-label {
  color: #06120e;
  background: rgba(98, 211, 151, 0.92);
}

.scanner-overlay .scan-frame.is-mid-scan {
  --scanner-lock-color: #e6aa35;
}

.scanner-overlay .scan-frame.is-mid-scan span {
  border-color: #e6aa35;
  filter: drop-shadow(0 0 10px rgba(230, 170, 53, 0.48));
}

.scanner-overlay .scan-frame.is-mid-scan .scan-lock-label {
  color: #2a1700;
  background: rgba(230, 170, 53, 0.92);
}

.scanner-overlay .scan-guide-number-left {
  bottom: 4%;
  left: 4%;
  width: 38%;
}

.scanner-overlay .scan-guide-number-right {
  right: 4%;
  bottom: 4%;
  justify-content: flex-end;
  width: 36%;
}

.scanner-detection-panel,
.scanner-match-card,
.scanner-capture-tray,
.scanner-top-control-bar,
.scanner-overlay-actions {
  position: absolute;
  left: 14px;
  right: 14px;
  z-index: 3;
}

.scanner-capture-tray {
  position: fixed;
  top: auto;
  height: var(--scanner-queue-height);
  max-height: var(--scanner-queue-height);
  bottom: var(--scanner-queue-bottom);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr);
  grid-template-areas:
    "head"
    "list";
  align-items: stretch;
  gap: 8px;
  padding: 10px;
  background: rgba(2, 4, 10, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 20px;
  backdrop-filter: blur(18px);
  overflow: hidden;
  overscroll-behavior: contain;
  touch-action: pan-x;
}

.scanner-capture-tray[hidden] {
  display: none;
}

.scanner-overlay[data-scanner-mode="vendor"] .scanner-shell {
  --scanner-queue-height: 162px;
}

.scanner-vendor-terms {
  grid-column: 3;
  align-self: stretch;
  justify-self: stretch;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  align-items: center;
  gap: 2px;
  min-width: 0;
  height: 48px;
  padding: 4px;
  color: #f8fafc;
  background: rgba(5, 7, 11, 0.72);
  border: 1px solid rgba(126, 211, 202, 0.28);
  border-radius: 16px;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
}

.scanner-vendor-terms[hidden] {
  display: none;
}

.scanner-vendor-percent-row {
  display: grid;
  align-items: center;
  gap: 3px;
  min-width: 0;
}

.scanner-vendor-terms-label {
  min-width: 0;
  overflow: hidden;
  color: #a8bdff;
  padding: 0 4px;
  font-size: 0.38rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  line-height: 1;
  text-align: center;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.scanner-vendor-percent-row > button {
  min-width: 0;
  min-height: 26px;
  color: #06120e;
  background: #ffd166;
  border: 0;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 950;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.scanner-vendor-percent-row {
  grid-template-columns: 26px minmax(42px, 1fr) 26px;
}

.scanner-vendor-percent-row label {
  display: grid;
  align-items: center;
  min-width: 0;
  min-height: 26px;
  padding: 0 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
}

.scanner-vendor-percent-row input {
  width: 100%;
  min-width: 0;
  min-height: 0;
  height: 20px;
  max-height: 20px;
  padding: 0;
  color: #f8fafc;
  appearance: textfield;
  background: transparent;
  border: 0;
  font-size: 0.66rem;
  font-weight: 950;
  line-height: 1;
  text-align: right;
}

.scanner-vendor-percent-row input::-webkit-inner-spin-button,
.scanner-vendor-percent-row input::-webkit-outer-spin-button {
  margin: 0;
  appearance: none;
}

.scanner-overlay .scanner-detection-panel,
.scanner-overlay .scanner-match-card {
  display: none !important;
}

.scanner-tray-head {
  grid-area: head;
  display: grid;
  grid-template-columns: minmax(74px, 1fr) minmax(136px, auto) minmax(128px, 1fr);
  align-items: center;
  gap: 8px;
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.scanner-tray-head small {
  justify-self: end;
  min-width: 0;
  overflow: hidden;
  color: #9fc1ff;
  font: inherit;
  letter-spacing: 0.05em;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scanner-queue-status-stack {
  display: grid;
  align-content: center;
  justify-items: end;
  gap: 4px;
  min-width: 0;
}

/* MEMORY LINE: Scanner Controls Layout Fix START */
.scanner-queue-actions {
  position: fixed;
  bottom: max(18px, calc(env(safe-area-inset-bottom) + 18px));
  left: var(--scanner-frame-side);
  right: var(--scanner-frame-side);
  z-index: 1004;
  display: grid;
  grid-template-columns: minmax(78px, 0.78fr) minmax(0, 178px) minmax(128px, 0.94fr);
  visibility: visible;
  opacity: 1;
  align-items: center;
  justify-content: center;
  gap: 10px;
  pointer-events: auto;
  transform: translateZ(0);
  will-change: transform;
}

.scanner-queue-actions .scanner-reset-bottom {
  grid-column: 1;
  justify-self: start;
}

.scanner-queue-actions .scanner-game-mode {
  grid-column: 2;
  justify-self: center;
  width: 100%;
}

.scanner-queue-actions .scanner-vendor-terms {
  grid-column: 3;
}

.scanner-overlay.has-scan-queue .scanner-queue-actions {
  bottom: calc(var(--scanner-queue-bottom) + var(--scanner-queue-height) + var(--scanner-control-queue-gap));
}

.scanner-reset-bottom,
.scanner-bulk-add,
.scanner-game-mode,
.scanner-vendor-terms,
.scanner-auto-scan-button {
  transition: opacity 160ms ease, visibility 160ms ease, transform 160ms ease;
}

.scanner-overlay.sheet-open .scanner-reset-bottom,
.scanner-overlay.sheet-open .scanner-bulk-add,
.scanner-overlay.sheet-open .scanner-game-mode,
.scanner-overlay.sheet-open .scanner-vendor-terms,
.scanner-overlay.sheet-open .scanner-auto-scan-button,
.scanner-overlay.sheet-expanded .scanner-reset-bottom,
.scanner-overlay.sheet-expanded .scanner-bulk-add,
.scanner-overlay.sheet-expanded .scanner-game-mode,
.scanner-overlay.sheet-expanded .scanner-vendor-terms,
.scanner-overlay.sheet-expanded .scanner-auto-scan-button,
.scanner-overlay.is-dragging-sheet .scanner-reset-bottom,
.scanner-overlay.is-dragging-sheet .scanner-bulk-add,
.scanner-overlay.is-dragging-sheet .scanner-game-mode,
.scanner-overlay.is-dragging-sheet .scanner-vendor-terms,
.scanner-overlay.is-dragging-sheet .scanner-auto-scan-button {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(8px);
}
/* MEMORY LINE: Scanner Controls Layout Fix END */

.scanner-bulk-add {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  justify-self: start;
  min-width: 86px;
  height: 28px;
  padding: 0 10px;
  color: #06120e;
  background: #62d397;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  font-size: 0.52rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.scanner-bulk-add:disabled {
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.1);
}

.scanner-queue-total {
  display: inline-grid;
  grid-template-columns: auto auto;
  align-items: center;
  justify-self: center;
  gap: 7px;
  min-width: 138px;
  height: 30px;
  padding: 0 12px;
  color: #dff8eb;
  background: rgba(5, 7, 11, 0.76);
  border: 1px solid rgba(126, 211, 202, 0.4);
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(14px);
  white-space: nowrap;
}

.scanner-queue-total[hidden] {
  display: none;
}

.scanner-queue-total span {
  color: #9fc1ff;
  font-size: 0.5rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
}

.scanner-queue-total strong {
  color: #8ee6ad;
  font-size: 0.82rem;
  font-weight: 950;
  line-height: 1;
}

.scanner-queue-total.is-empty strong {
  color: #94a3b8;
}

.scanner-capture-list {
  grid-area: list;
  display: flex;
  align-items: stretch;
  gap: 9px;
  min-height: 0;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  padding-bottom: 2px;
  scrollbar-width: none;
}

@media (max-width: 760px) {
  .scanner-overlay input,
  .scanner-overlay select,
  .scanner-overlay textarea {
    font-size: 16px !important;
  }

  .scanner-overlay,
  .scanner-shell,
  .scanner-overlay .camera-stage {
    max-width: 100%;
    overflow: hidden;
  }

  .scanner-shell {
    --scanner-frame-top: clamp(96px, 10.5svh, 118px);
    --scanner-frame-width: min(90vw, 420px);
    --scanner-guide-width: min(86vw, 404px);
    --scanner-queue-height: 168px;
    --scanner-frame-control-gap: 18px;
    --scanner-frame-side: max(14px, calc((100vw - var(--scanner-frame-width)) / 2));
    --scanner-queue-bottom: max(4px, calc(env(safe-area-inset-bottom) + 4px));
    --scanner-search-height: clamp(32px, 5svh, 38px);
  }

  .scanner-manual-search-bar {
    width: min(calc(var(--scanner-guide-width) - 28px), calc(100vw - 112px), 344px);
    max-width: min(calc(var(--scanner-guide-width) - 28px), calc(100vw - 112px), 344px);
    height: var(--scanner-search-height);
    min-height: var(--scanner-search-height);
    padding: 1px;
    grid-template-columns: minmax(0, 1fr);
    transform: translateX(20px);
  }

  .scanner-capture-tray {
    top: auto;
    height: var(--scanner-queue-height);
    max-height: var(--scanner-queue-height);
    bottom: var(--scanner-queue-bottom);
    gap: 6px;
    padding: 8px;
    border-radius: 16px;
  }

  .scanner-tray-head {
    grid-template-columns: minmax(78px, 0.7fr) minmax(118px, auto) minmax(132px, 1fr);
    gap: 6px;
    margin-bottom: 0;
    font-size: 0.58rem;
  }

  .scanner-queue-actions {
    grid-template-columns: minmax(72px, 0.7fr) minmax(0, 174px) minmax(124px, 0.9fr);
    left: var(--scanner-frame-side);
    right: var(--scanner-frame-side);
    gap: 7px;
  }

  .scanner-game-mode {
    flex-basis: 168px;
    max-width: 204px;
    height: 34px;
    padding: 3px;
  }

  .scanner-vendor-terms {
    height: 46px;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto 1fr;
    gap: 2px;
    padding: 4px;
  }

  .scanner-vendor-terms-label {
    padding: 0 3px;
    font-size: 0.34rem;
    letter-spacing: 0.06em;
    text-align: center;
  }

  .scanner-vendor-percent-row {
    grid-template-columns: 24px minmax(34px, 1fr) 24px;
    gap: 2px;
  }

  .scanner-vendor-percent-row > button,
  .scanner-vendor-percent-row label {
    min-height: 24px;
  }

  .scanner-vendor-percent-row input {
    min-height: 0 !important;
    height: 20px !important;
    max-height: 20px !important;
    appearance: textfield;
    font-size: 0.62rem !important;
    line-height: 1 !important;
  }

  .scanner-game-mode button {
    padding-inline: 5px;
    font-size: 0.43rem;
    letter-spacing: 0.025em;
  }

  .scanner-bulk-add {
    min-width: 78px;
    height: 26px;
    padding-inline: 8px;
    font-size: 0.46rem;
  }

  .scanner-queue-total {
    min-width: 118px;
    height: 28px;
    padding-inline: 10px;
    gap: 5px;
  }

  .scanner-queue-total span {
    font-size: 0.44rem;
  }

  .scanner-queue-total strong {
    font-size: 0.76rem;
  }

  .scanner-capture-list {
    gap: 7px;
    max-height: 92px;
  }

  .scanner-job {
    height: 92px;
    min-width: 172px;
    max-width: 198px;
    min-height: 0;
    padding: 6px;
    border-radius: 14px;
  }

  .scanner-job-open {
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 8px;
    min-height: 80px;
    padding: 0 46px 18px 0;
  }

  .scanner-job img {
    width: 36px;
    height: 50px;
    border-radius: 8px;
  }

  .scanner-job-copy span {
    font-size: 0.54rem;
  }

  .scanner-job-copy strong {
    font-size: 0.72rem;
  }

  .scanner-job-copy small {
    font-size: 0.64rem;
  }

  .scanner-job b {
    left: 44px;
    bottom: 5px;
    font-size: 0.78rem;
  }

  .scanner-job-remove {
    width: 24px;
    height: 24px;
  }

  .scanner-job-add {
    min-width: 46px;
    height: 24px;
    padding-inline: 8px;
    font-size: 0.58rem;
  }

  .scanner-job::after {
    top: 38px;
    right: 11px;
  }
}

@media (max-width: 380px) {
  .scanner-overlay .scan-frame {
    --scanner-guide-width: min(76vw, 286px);
  }

  .scanner-queue-actions {
    left: var(--scanner-frame-side);
    right: var(--scanner-frame-side);
    grid-template-columns: minmax(54px, 0.5fr) minmax(0, 1fr) minmax(100px, 0.76fr);
    gap: 6px;
  }

  .scanner-tray-head {
    grid-template-columns: minmax(58px, 0.7fr) minmax(96px, auto) minmax(92px, 1fr);
    gap: 5px;
  }

  .scanner-game-mode {
    grid-column: 2;
    max-width: none;
  }

  .scanner-vendor-terms {
    grid-column: 3;
    grid-template-columns: minmax(0, 1fr);
    height: 44px;
  }

  .scanner-vendor-terms-label {
    display: block;
    font-size: 0.3rem;
    letter-spacing: 0.045em;
  }

  .scanner-queue-actions .scanner-reset-bottom {
    grid-column: 1;
  }

  .scanner-manual-search-bar {
    min-width: 0;
    width: min(calc(var(--scanner-guide-width) - 20px), calc(100vw - 104px), 286px);
    max-width: min(calc(var(--scanner-guide-width) - 20px), calc(100vw - 104px), 286px);
    height: 34px;
    min-height: 34px;
    padding: 1px;
    grid-template-columns: minmax(0, 1fr);
  }

  .scanner-manual-search-field {
    grid-template-columns: 19px minmax(0, 1fr);
    gap: 10px;
    padding: 0 14px;
  }

  .scanner-manual-search-icon svg {
    width: 19px;
    height: 19px;
  }

  .scanner-manual-search-icon {
    width: 19px;
    height: 19px;
  }

  .scanner-manual-search-bar input {
    height: 100%;
    font-size: 0.78rem;
  }

  .scanner-manual-search-placeholder {
    gap: 5px;
    font-size: 0.78rem;
  }

  .scanner-bulk-add {
    min-width: 74px;
    padding-inline: 6px;
    font-size: 0.45rem;
    letter-spacing: 0.03em;
  }

  .scanner-queue-total {
    min-width: 104px;
    padding-inline: 7px;
  }

  .scanner-queue-total span {
    display: none;
  }

  .scanner-queue-total strong {
    font-size: 0.78rem;
  }

  .scanner-tray-head .scanner-auto-scan-toggle {
    width: min(100%, 88px);
    height: 24px;
    padding: 0 7px;
    font-size: 0.49rem;
  }

  .scanner-reset-bottom {
    min-width: 54px;
    height: 30px;
    padding-inline: 8px;
    font-size: 0.56rem;
  }
}

@media (max-width: 760px) and (max-height: 740px) {
  .scanner-overlay .scan-frame {
    --scanner-guide-width: min(58vw, 260px);
  }

  .scanner-overlay .scan-frame span {
    width: 42px;
    height: 42px;
  }
}

.scanner-capture-list::-webkit-scrollbar {
  display: none;
}

.scanner-job {
  position: relative;
  display: block;
  box-sizing: border-box;
  height: 104px;
  min-width: 220px;
  max-width: 260px;
  min-height: 0;
  overflow: hidden;
  padding: 8px;
  color: #fff;
  background: rgba(255, 255, 255, 0.11);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 16px;
}

.scanner-job::after {
  position: absolute;
  right: 13px;
  top: 42px;
  width: 7px;
  height: 7px;
  background: #9fc1ff;
  border-radius: 999px;
  box-shadow: 0 0 0 4px rgba(159, 193, 255, 0.12);
  content: "";
}

.scanner-job-pricing::after,
.scanner-job-identifying::after {
  animation: scannerPulse 880ms ease-in-out infinite;
}

.scanner-job-done::after,
.scanner-job-matched::after {
  background: #62d397;
  box-shadow: 0 0 0 4px rgba(98, 211, 151, 0.14);
}

.scanner-job-error::after,
.scanner-job-review::after {
  background: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.scanner-job-review {
  border-color: rgba(245, 158, 11, 0.46);
}

.scanner-job-review .scanner-job-copy span {
  color: #fbbf24;
}

.scanner-job-open {
  position: relative;
  display: grid;
  grid-template-columns: 44px minmax(112px, 1fr);
  gap: 9px;
  align-items: center;
  width: 100%;
  min-height: 88px;
  padding: 0 58px 22px 0;
  color: inherit;
  text-align: left;
  background: transparent;
  border: 0;
}

.scanner-job-remove {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  color: #fff;
  background: rgba(2, 4, 10, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 950;
  line-height: 1;
  backdrop-filter: blur(10px);
}

.scanner-job-add {
  position: absolute;
  right: 8px;
  bottom: 8px;
  z-index: 2;
  display: grid;
  place-items: center;
  min-width: 52px;
  height: 28px;
  padding: 0 10px;
  color: #06120e;
  background: #62d397;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.24);
}

.scanner-job-add:disabled {
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.1);
  box-shadow: none;
}

.scanner-job-added {
  border-color: rgba(98, 211, 151, 0.42);
}

.scanner-job-added .scanner-job-add {
  color: #dff8eb;
  background: rgba(98, 211, 151, 0.18);
}

.scanner-job img {
  width: 44px;
  height: 62px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 9px;
}

.scanner-job-copy {
  min-width: 0;
}

.scanner-job-copy span,
.scanner-job-copy strong,
.scanner-job-copy small,
.scanner-job b {
  display: block;
}

.scanner-job-copy span {
  color: #9fc1ff;
  font-size: 0.62rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.scanner-job-copy strong {
  overflow: hidden;
  margin-top: 3px;
  color: #fff;
  font-size: 0.82rem;
  line-height: 1.12;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scanner-job-copy small {
  overflow: hidden;
  margin-top: 3px;
  color: #cbd5e1;
  font-size: 0.72rem;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scanner-job b {
  position: absolute;
  bottom: 5px;
  left: 53px;
  color: #62d397;
  font-size: 0.9rem;
  line-height: 1;
}

@media (max-width: 760px) {
  .scanner-job {
    height: 92px;
    min-width: 172px;
    max-width: 198px;
    min-height: 0;
    padding: 6px;
    border-radius: 14px;
  }

  .scanner-job-open {
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 8px;
    min-height: 80px;
    padding: 0 46px 18px 0;
  }

  .scanner-job img {
    width: 36px;
    height: 50px;
    border-radius: 8px;
  }

  .scanner-job-copy span {
    font-size: 0.54rem;
  }

  .scanner-job-copy strong {
    font-size: 0.72rem;
  }

  .scanner-job-copy small {
    font-size: 0.64rem;
  }

  .scanner-job b {
    left: 44px;
    bottom: 5px;
    font-size: 0.78rem;
  }

  .scanner-job-remove {
    width: 24px;
    height: 24px;
  }

  .scanner-job-add {
    min-width: 46px;
    height: 24px;
    padding-inline: 8px;
    font-size: 0.58rem;
  }

  .scanner-job::after {
    top: 38px;
    right: 11px;
  }
}

.scanner-job-sheet {
  --scanner-sheet-backdrop-opacity: 0;
  --scanner-sheet-close-y: calc(100% + max(24px, env(safe-area-inset-bottom)));
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  align-items: end;
  pointer-events: auto;
  overscroll-behavior: contain;
}

.scanner-job-sheet::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: rgba(2, 4, 10, 0.38);
  backdrop-filter: blur(18px) saturate(80%) brightness(0.78);
  -webkit-backdrop-filter: blur(18px) saturate(80%) brightness(0.78);
  content: "";
  opacity: var(--scanner-sheet-backdrop-opacity);
  pointer-events: auto;
  transition: opacity 220ms ease;
  will-change: opacity;
}

.scanner-job-sheet.is-open {
  --scanner-sheet-backdrop-opacity: 1;
}

.scanner-job-sheet.is-closing {
  --scanner-sheet-backdrop-opacity: 0;
  pointer-events: none;
}

.scanner-job-sheet.is-dragging::before {
  transition: none;
}

.scanner-job-sheet[hidden] {
  display: none;
}

.scanner-job-sheet-panel {
  position: relative;
  z-index: 1;
  pointer-events: auto;
  max-height: min(74vh, 640px);
  margin: 0 10px max(10px, env(safe-area-inset-bottom));
  overflow-x: hidden;
  overflow-y: auto;
  color: #f8fafc;
  background: rgba(18, 22, 29, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 26px 26px 20px 20px;
  box-shadow: 0 -22px 54px rgba(0, 0, 0, 0.42);
  overscroll-behavior: contain;
  scroll-behavior: smooth;
  touch-action: pan-y;
  transform: translate3d(0, var(--scanner-sheet-close-y), 0);
  transition:
    transform 240ms cubic-bezier(0.2, 0.88, 0.22, 1),
    max-height 220ms ease,
    height 220ms ease;
  will-change: transform;
  backface-visibility: hidden;
  contain: paint;
  -webkit-overflow-scrolling: touch;
}

.scanner-job-sheet.is-open .scanner-job-sheet-panel {
  transform: translate3d(0, 0, 0);
}

.scanner-job-sheet.is-dragging .scanner-job-sheet-panel {
  transition: none;
}

.scanner-job-sheet-panel.is-expanded {
  height: min(90dvh, 760px);
  max-height: min(90dvh, 760px);
  margin-bottom: max(6px, env(safe-area-inset-bottom));
}

.scanner-sheet-handle {
  display: block;
  width: 52px;
  height: 5px;
  margin: 10px auto 4px;
  padding: 0;
  background: rgba(148, 163, 184, 0.62);
  border: 0;
  border-radius: 999px;
  touch-action: none;
}

.scanner-job-sheet-panel.is-expanded .scanner-sheet-handle {
  width: 66px;
  background: rgba(126, 211, 202, 0.76);
}

.scanner-sheet-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 10px 16px 12px;
  touch-action: none;
}

.scanner-sheet-head span,
.scanner-sheet-result span {
  display: block;
  color: #a8bdff;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.scanner-sheet-head h3 {
  max-width: 100%;
  overflow: hidden;
  margin: 3px 0 0;
  color: #fff;
  font-size: 0.98rem;
  font-weight: 800;
  line-height: 1.06;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scanner-sheet-head small {
  display: block;
  margin-top: 4px;
  color: #a5adba;
  font-size: 0.78rem;
  font-weight: 750;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.scanner-sheet-head button {
  min-height: 36px;
  padding: 0 13px;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  font-weight: 950;
}

.scanner-sheet-edit {
  display: grid;
  grid-template-columns: minmax(170px, 44fr) minmax(0, 56fr);
  gap: 10px;
  padding: 0 16px 14px;
}

.scanner-sheet-match-rail {
  display: grid;
  gap: 10px;
  align-content: start;
  min-width: 0;
}

.scanner-sheet-capture-preview {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 5 / 7;
  overflow: hidden;
  background: #05070b;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
}

.scanner-sheet-capture-preview img {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #05070b;
}

.scanner-job-sheet-panel.is-sealed-product .scanner-sheet-capture-preview {
  aspect-ratio: 1 / 1;
}

.scanner-job-sheet-panel.is-sealed-product .scanner-sheet-capture-preview img {
  padding: 6px;
  object-fit: contain;
}

.scanner-sheet-candidates {
  display: grid;
  gap: 8px;
}

.scanner-sheet-candidates[hidden] {
  display: none;
}

.scanner-sheet-candidates header {
  display: grid;
  gap: 5px;
}

.scanner-sheet-candidates header span {
  color: #a8bdff;
  font-size: 0.62rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  line-height: 1.1;
  text-transform: uppercase;
}

.scanner-sheet-candidates header b {
  justify-self: start;
  padding: 5px 8px;
  color: #b8ffdf;
  background: rgba(98, 211, 151, 0.12);
  border: 1px solid rgba(98, 211, 151, 0.34);
  border-radius: 999px;
  font-size: 0.61rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
}

.scanner-sheet-candidate-list {
  display: grid;
  gap: 7px;
  max-height: min(42vh, 330px);
  overflow-y: auto;
  padding-right: 3px;
  overscroll-behavior: contain;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.scanner-sheet-candidate-option {
  width: 100%;
  min-height: 116px;
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
  overflow: hidden;
  padding: 9px;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  text-align: left;
}

.scanner-sheet-candidate-option.is-selected {
  background: rgba(126, 211, 202, 0.14);
  border-color: rgba(126, 211, 202, 0.55);
  box-shadow: inset 0 0 0 1px rgba(126, 211, 202, 0.18);
}

.scanner-sheet-candidate-option img,
.scanner-sheet-candidate-empty {
  align-self: center;
  width: 62px;
  height: 88px;
  background: #05070b;
  border: 1px solid rgba(126, 211, 202, 0.34);
  border-radius: 9px;
}

.scanner-sheet-candidate-option img {
  object-fit: cover;
}

.scanner-sheet-candidate-option.is-product {
  grid-template-columns: 70px minmax(0, 1fr);
}

.scanner-sheet-candidate-option.is-product img,
.scanner-sheet-candidate-option.is-product .scanner-sheet-candidate-empty {
  width: 70px;
  height: 70px;
  padding: 3px;
  object-fit: contain;
  border-radius: 9px;
}

.scanner-sheet-candidate-empty {
  position: relative;
  display: block;
}

.scanner-sheet-candidate-option span {
  display: grid;
  gap: 4px;
  align-content: center;
  justify-items: start;
  min-width: 0;
  overflow: hidden;
}

.scanner-sheet-candidate-option strong {
  display: block;
  max-width: 100%;
  max-height: calc(2 * 1.06em);
  overflow: hidden;
  color: #f8fafc;
  font-size: 0.76rem;
  font-weight: 860;
  letter-spacing: 0;
  line-height: 1.06;
  overflow-wrap: anywhere;
  text-overflow: clip;
}

.scanner-sheet-candidate-option small {
  display: block;
  max-width: 100%;
  max-height: calc(2 * 1.1em);
  overflow: hidden;
  color: #a5adba;
  font-size: 0.58rem;
  font-weight: 740;
  letter-spacing: 0;
  line-height: 1.1;
  overflow-wrap: anywhere;
  text-overflow: clip;
}

.scanner-sheet-candidate-price {
  max-width: 100%;
  overflow: hidden;
  color: #b8ffdf;
  font-size: 0.84rem;
  font-style: normal;
  font-variant-numeric: tabular-nums;
  font-weight: 860;
  letter-spacing: 0;
  line-height: 1;
  text-overflow: clip;
  white-space: nowrap;
}

.scanner-sheet-candidate-option b {
  justify-self: start;
  max-width: 100%;
  padding: 4px 8px;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  font-size: 0.58rem;
  font-weight: 840;
  letter-spacing: 0.03em;
  line-height: 1;
  overflow: hidden;
  text-overflow: clip;
  text-transform: uppercase;
  white-space: nowrap;
}

.scanner-sheet-form {
  display: grid;
  gap: 7px;
  align-content: start;
}

.scanner-sheet-form label {
  display: grid;
  gap: 5px;
  color: #a5adba;
  font-size: 0.72rem;
  font-weight: 850;
}

.scanner-sheet-form input,
.scanner-sheet-form select {
  width: 100%;
  min-height: 34px;
  padding: 0 10px;
  color: #f8fafc;
  background: #05070b;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 760;
}

.scanner-sheet-form input::placeholder {
  color: #7c8493;
}

.scanner-sheet-lookup-field {
  position: relative;
}

.scanner-sheet-lookup-head {
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
}

.scanner-sheet-lookup-title {
  min-width: 0;
  color: #a5adba;
  font-size: 0.72rem;
  font-weight: 850;
}

.scanner-sheet-lookup-field::before {
  position: absolute;
  bottom: 18px;
  left: 16px;
  z-index: 1;
  width: 15px;
  height: 15px;
  border: 3px solid #7ed3ca;
  border-radius: 999px;
  content: "";
  pointer-events: none;
}

.scanner-sheet-lookup-field::after {
  position: absolute;
  bottom: 16px;
  left: 31px;
  z-index: 1;
  width: 10px;
  height: 3px;
  background: #7ed3ca;
  border-radius: 999px;
  content: "";
  pointer-events: none;
  transform: rotate(45deg);
}

.scanner-sheet-lookup-field input {
  min-height: 52px;
  padding-inline: 44px 12px;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 0.64rem;
  font-weight: 560;
  letter-spacing: 0;
  border-color: rgba(126, 211, 202, 0.54);
  box-shadow: inset 0 0 0 1px rgba(126, 211, 202, 0.12), 0 0 0 4px rgba(126, 211, 202, 0.06);
}

.scanner-job-sheet-panel.is-graded-scan .scanner-sheet-lookup-field input {
  font-size: 0.62rem;
}

.scanner-sheet-match-tools {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: center;
}

.scanner-sheet-match-tools a,
.scanner-sheet-match-tools span {
  min-width: 0;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 12px;
  font-size: 0.74rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  text-decoration: none;
  text-transform: uppercase;
}

.scanner-sheet-match-tools a {
  color: #06120e;
  background: #7bc8c0;
}

.scanner-sheet-match-tools a[data-market-link-type="tcgplayer"],
.scanner-sheet-match-tools a[data-market-link-type="ebaySold"] {
  position: relative;
  overflow: hidden;
  min-height: 48px;
  padding: 3px 10px;
  color: #05070a;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.68);
}

.scanner-sheet-match-tools a[data-market-link-type="tcgplayer"] img {
  display: block;
  width: min(154px, 100%);
  height: 44px;
  object-fit: contain;
}

.scanner-sheet-match-tools a[data-market-link-type="ebaySold"] img {
  display: block;
  width: min(138px, 100%);
  height: 44px;
  object-fit: contain;
}

.scanner-sheet-match-tools .scanner-market-link-label {
  position: absolute;
  width: 1px;
  min-height: 0;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.scanner-sheet-action-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  align-items: stretch;
}

.scanner-sheet-form .scanner-sheet-confirm-btn {
  width: 100%;
  min-height: 42px;
  color: #06120e;
  background: #62d397;
  border: 1px solid #62d397;
  border-radius: 12px;
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1.05;
  text-transform: uppercase;
  white-space: nowrap;
}

.scanner-sheet-form .scanner-sheet-confirm-btn {
  min-height: 38px;
  padding: 0 12px;
  font-size: 0.68rem;
  letter-spacing: 0.02em;
}

.scanner-sheet-form .scanner-sheet-confirm-btn.is-confirmed {
  color: #b8ffdf;
  background: rgba(98, 211, 151, 0.13);
  border-color: rgba(98, 211, 151, 0.35);
}

.scanner-sheet-form .scanner-sheet-confirm-btn:disabled {
  opacity: 0.68;
}

.scanner-sheet-form select {
  appearance: none;
}

.scanner-sheet-field-row {
  display: grid;
  grid-template-columns: minmax(132px, 1fr) minmax(64px, 92px);
  gap: 12px;
  max-width: 100%;
}

.scanner-sheet-field-row label {
  min-width: 0;
  min-height: 50px;
  align-content: end;
  gap: 4px;
}

.scanner-sheet-field-row select {
  min-width: 0;
  padding-inline: 10px 22px;
}

.scanner-sheet-cost-field {
  gap: 3px;
  max-width: 78%;
  margin-top: 4px;
}

.scanner-sheet-cost-input-wrap {
  position: relative;
  display: block;
  min-width: 0;
}

.scanner-sheet-cost-input-wrap input {
  position: relative;
  z-index: 1;
  background: #05070b;
}

.scanner-sheet-cost-typing {
  position: absolute;
  top: 50%;
  left: 12px;
  z-index: 2;
  width: 0;
  max-width: 5ch;
  overflow: hidden;
  color: #8f98a8;
  border-right: 2px solid rgba(126, 211, 202, 0.7);
  font-size: 0.84rem;
  font-weight: 760;
  line-height: 1;
  pointer-events: none;
  white-space: nowrap;
  transform: translateY(-50%);
  animation: scannerCostTyping 3.2s steps(5, end) infinite;
}

.scanner-sheet-cost-input-wrap:focus-within .scanner-sheet-cost-typing,
.scanner-sheet-cost-input-wrap input:not(:placeholder-shown) + .scanner-sheet-cost-typing {
  opacity: 0;
  animation: none;
}

@keyframes scannerCostTyping {
  0%,
  12% {
    width: 0;
  }

  38%,
  56% {
    width: 5ch;
  }

  82%,
  100% {
    width: 0;
  }
}

.scanner-sheet-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
  max-width: 78%;
  padding-bottom: max(18px, env(safe-area-inset-bottom));
}

.scanner-sheet-form button {
  min-height: 42px;
  color: #06120e;
  background: #7bc8c0;
  border: 1px solid #7bc8c0;
  border-radius: 12px;
  font-weight: 950;
}

.scanner-sheet-form .scanner-sheet-add-btn {
  min-height: 44px;
  color: #06251b;
  background: #8bd7ce;
  border-color: #8bd7ce;
  font-size: 0.82rem;
}

.scanner-sheet-form button:disabled {
  opacity: 0.68;
}

.scanner-sheet-market-history {
  display: grid;
  gap: 10px;
  margin: 0 16px 14px;
  padding: 14px;
  color: #f8fafc;
  background: #05070b;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.scanner-sheet-market-history[hidden] {
  display: none;
}

.scanner-market-history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.scanner-market-history-head span {
  display: block;
  color: #f8fafc;
  font-size: 0.82rem;
  font-weight: 850;
  line-height: 1.1;
}

.scanner-market-history-head strong {
  display: block;
  margin-top: 8px;
  color: #31e981;
  font-size: clamp(1.65rem, 8vw, 2.15rem);
  font-weight: 850;
  line-height: 0.95;
  letter-spacing: 0;
}

.scanner-market-history-head b {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 900;
}

.scanner-market-moves {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  color: #a5adba;
  font-size: 0.68rem;
  font-weight: 850;
  line-height: 1.2;
}

.scanner-market-moves span {
  white-space: nowrap;
}

.scanner-market-moves .positive {
  color: #31e981;
}

.scanner-market-moves .negative {
  color: #ff917f;
}

.scanner-market-chart {
  position: relative;
  min-height: 174px;
  overflow: hidden;
  cursor: crosshair;
  touch-action: none;
}

.scanner-market-chart svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.scanner-market-grid {
  stroke: rgba(255, 255, 255, 0.18);
  stroke-width: 1;
}

.scanner-market-axis,
.scanner-market-date {
  fill: #9ca3af;
  font-size: 11px;
  font-weight: 800;
}

.scanner-market-date.right {
  text-anchor: end;
}

.scanner-market-area {
  fill: url(#scannerMarketAreaFill);
}

.scanner-market-line {
  fill: none;
  stroke: #f1f5d0;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 3.5;
}

.scanner-market-dot {
  fill: #f8fafc;
  stroke: #9fbe55;
  stroke-width: 3;
}

.scanner-market-crosshair {
  stroke: rgba(255, 255, 255, 0.34);
  stroke-dasharray: 3 5;
  stroke-width: 1.2;
}

.scanner-market-selected-dot {
  fill: #05070b;
  stroke: #e8f5b8;
  stroke-width: 3.5;
}

.scanner-market-crosshair,
.scanner-market-selected-dot,
.scanner-market-svg-tooltip {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 120ms ease, visibility 120ms ease;
}

.scanner-market-chart.is-pointer-active .scanner-market-crosshair,
.scanner-market-chart.is-pointer-active .scanner-market-selected-dot,
.scanner-market-chart.is-pointer-active .scanner-market-svg-tooltip {
  opacity: 1;
  visibility: visible;
}

.scanner-market-hit {
  fill: transparent;
  pointer-events: all;
  stroke: transparent;
}

.scanner-market-svg-tooltip rect {
  fill: rgba(8, 11, 18, 0.94);
  stroke: rgba(141, 215, 207, 0.48);
  stroke-width: 1;
}

.scanner-market-svg-tooltip text {
  fill: #f8fafc;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
}

.scanner-market-svg-tooltip text + text {
  fill: #31e981;
  font-size: 12px;
}

.scanner-market-range-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
}

.scanner-market-range-row button {
  appearance: none;
  min-height: 30px;
  color: #aab3c2;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0;
}

.scanner-market-range-row button.is-active {
  color: #061012;
  background: #8dd7cf;
  border-color: rgba(141, 215, 207, 0.88);
}

.scanner-market-range-row button:focus-visible {
  outline: 2px solid #8dd7cf;
  outline-offset: 2px;
}

.scanner-market-condition-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.scanner-market-condition-row::-webkit-scrollbar {
  display: none;
}

.scanner-market-condition-row button {
  appearance: none;
  display: grid;
  gap: 6px;
  min-width: 92px;
  padding: 10px 12px;
  text-align: left;
  color: #a5adba;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  cursor: pointer;
}

.scanner-market-condition-row button.is-active {
  color: #f8fafc;
  background: rgba(148, 163, 184, 0.22);
  border-color: rgba(168, 189, 255, 0.72);
  box-shadow: inset 0 0 0 1px rgba(168, 189, 255, 0.24);
}

.scanner-market-condition-row button:focus-visible {
  outline: 2px solid #8dd7cf;
  outline-offset: 2px;
}

.scanner-market-condition-row b,
.scanner-market-condition-row strong,
.scanner-market-condition-row small {
  display: block;
}

.scanner-market-condition-row b {
  font-size: 0.68rem;
  font-weight: 950;
}

.scanner-market-condition-row strong {
  overflow: hidden;
  font-size: 0.96rem;
  font-weight: 950;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scanner-market-condition-row small {
  color: #8dd7cf;
  font-size: 0.62rem;
  font-weight: 900;
  text-transform: uppercase;
}

.scanner-sheet-market-history p {
  margin: 0;
  color: #8b94a3;
  font-size: 0.68rem;
  font-weight: 750;
  line-height: 1.35;
}

.scanner-sheet-result {
  margin: 0 16px 12px;
  padding: 13px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
}

.scanner-sheet-result-top {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
}

.scanner-sheet-result-top b {
  flex: none;
  color: #cbd5e1;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.scanner-sheet-result-top b.is-strong {
  color: #b8ffdf;
}

.scanner-sheet-result-top b.is-low {
  color: #ffd0ca;
}

.scanner-sheet-result strong {
  display: block;
  margin-top: 4px;
  color: #fff;
  font-size: 1.35rem;
  line-height: 1.05;
}

.scanner-sheet-result p,
.scanner-sheet-result small {
  display: block;
  margin: 6px 0 0;
  color: #a5adba;
  line-height: 1.3;
}

.scanner-sheet-listings {
  display: grid;
  gap: 8px;
  padding: 0 16px 16px;
}

.scanner-sheet-listing {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 11px;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
}

.scanner-sheet-listing strong,
.scanner-sheet-listing span,
.scanner-sheet-listing small {
  display: block;
}

.scanner-sheet-listing strong {
  overflow: hidden;
  color: #fff;
  font-size: 0.82rem;
  line-height: 1.22;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scanner-sheet-listing span {
  color: #8bd7ce;
  font-weight: 950;
  white-space: nowrap;
}

.scanner-sheet-listing small {
  margin-top: 4px;
  color: #a5adba;
  font-size: 0.72rem;
  line-height: 1.2;
}

@keyframes scannerPulse {
  0%,
  100% {
    opacity: 0.45;
    transform: scale(0.92);
  }
  50% {
    opacity: 1;
    transform: scale(1.08);
  }
}

.scanner-detection-panel {
  bottom: calc(126px + env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: minmax(0, 1fr) 64px;
  gap: 12px;
  align-items: center;
  padding: 12px;
  background: rgba(2, 4, 10, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 20px;
  backdrop-filter: blur(18px);
}

.scanner-detection-copy span,
.scanner-detection-copy strong,
.scanner-detection-copy small {
  display: block;
}

.scanner-detection-copy span {
  color: #9fc1ff;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.scanner-detection-copy strong {
  margin-top: 4px;
  color: #fff;
  font-size: 1.08rem;
  line-height: 1.14;
}

.scanner-detection-copy small {
  margin-top: 3px;
  color: #cbd5e1;
  line-height: 1.25;
}

#scannerMatchImage {
  width: 64px;
  height: 90px;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.32);
}

.scanner-match-card {
  bottom: calc(212px + env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 10px;
  background: rgba(255, 255, 255, 0.92);
  color: #172033;
  border-radius: 18px;
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.28);
}

.scanner-match-card[hidden] {
  display: none;
}

.scanner-match-card img {
  width: 48px;
  height: 68px;
  object-fit: cover;
  border-radius: 8px;
}

.scanner-match-card span,
.scanner-match-card strong,
.scanner-match-card small {
  display: block;
}

.scanner-match-card span {
  color: #2f6fed;
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.scanner-match-card strong {
  margin-top: 3px;
  font-size: 1rem;
  line-height: 1.12;
}

.scanner-match-card small {
  margin-top: 3px;
  color: #697386;
  line-height: 1.2;
}

.scanner-top-control-bar {
  top: max(4px, calc(env(safe-area-inset-top) + 4px));
  bottom: auto;
  left: 0;
  right: 0;
  z-index: 4;
  display: block;
  height: var(--scanner-search-height);
  pointer-events: none;
}

.scanner-top-control-bar > * {
  pointer-events: auto;
}

.scanner-auto-scan-toggle {
  position: relative;
  display: inline-grid;
  place-items: center;
  justify-self: end;
  min-width: 96px;
  height: 34px;
  padding: 0 12px;
  color: #ecfffb;
  background: rgba(2, 4, 10, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
  cursor: pointer;
  font-size: 0.58rem;
  font-weight: 950;
  letter-spacing: 0.055em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

@media (max-width: 760px) {
  .scanner-top-control-bar {
    top: max(16px, calc(env(safe-area-inset-top) + 0px));
    left: 0;
    right: 0;
    height: var(--scanner-search-height);
  }

  .scanner-auto-scan-toggle {
    min-width: 88px;
    height: 30px;
    padding-inline: 10px;
    font-size: 0.52rem;
  }
}

.scanner-tray-head .scanner-auto-scan-toggle {
  width: min(100%, 96px);
  min-width: 0;
  height: 24px;
  padding: 0 8px;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.24);
}

.scanner-auto-scan-toggle input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.scanner-auto-scan-text {
  display: block;
  overflow: hidden;
  line-height: 1;
  text-overflow: ellipsis;
}

.scanner-auto-scan-toggle.is-enabled {
  color: #06120e;
  background: #62d397;
  border-color: rgba(255, 255, 255, 0.36);
  box-shadow: 0 0 0 6px rgba(98, 211, 151, 0.15), 0 0 22px rgba(98, 211, 151, 0.38);
}

.scanner-auto-scan-toggle:active {
  transform: scale(0.95);
}

.scanner-auto-scan-toggle input:focus-visible ~ .scanner-auto-scan-text {
  outline: 2px solid #9fc1ff;
  outline-offset: 3px;
  border-radius: 999px;
}

.scanner-overlay-actions {
  bottom: max(16px, env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 9px;
}

.scanner-overlay-actions[hidden] {
  display: none;
}

.scanner-overlay-actions button[hidden] {
  display: none;
}

.scanner-overlay-actions button {
  min-height: 52px;
  border-radius: 16px;
  font-weight: 950;
}

.scanner-overlay-actions .primary-action {
  color: #fff;
  background: #2f6fed;
  border-color: #2f6fed;
}

.scanner-overlay-actions .secondary-action,
.scanner-overlay-actions .ghost-action {
  color: #fff;
  background: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(14px);
}

.scanner-overlay-actions .primary-action:disabled {
  color: rgba(255, 255, 255, 0.56);
  background: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 255, 255, 0.16);
}

body.is-collection-detail .bottom-nav {
  bottom: max(10px, env(safe-area-inset-bottom));
  width: min(430px, calc(100% - 28px));
  padding: 8px 10px;
  color: rgba(247, 248, 251, 0.72);
  background: rgba(13, 15, 20, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.36);
}

body.is-collection-detail .bottom-nav .active {
  color: #f7f8fb;
  background: rgba(101, 197, 187, 0.34);
}

body.is-collection-detail .bottom-nav .scan-tab {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
}

/* Section disclosure final placement */
.collection-portfolio-toolbar {
  grid-template-columns: minmax(0, 1fr) 44px 44px;
  grid-template-areas:
    "search search search"
    "sections favorite filter"
    "sectionlist sectionlist sectionlist";
}

.collection-section-disclosure {
  display: contents;
}

.collection-sections-toggle {
  grid-area: sections;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto 18px;
  gap: 7px;
  align-items: center;
  min-width: 0;
  min-height: 48px;
  padding: 6px 8px;
  color: #f7f8fb;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.045)),
    rgba(8, 12, 19, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.collection-sections-toggle svg,
.collection-sections-chevron {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-sections-toggle-icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 10px;
  color: #ffd166;
  background: rgba(255, 209, 102, 0.14);
  border: 1px solid rgba(255, 209, 102, 0.24);
  border-radius: 11px;
}

.collection-sections-toggle-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.collection-sections-toggle-copy strong,
.collection-sections-toggle-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-sections-toggle-copy strong {
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 950;
  line-height: 1.12;
}

.collection-sections-toggle-copy small {
  color: rgba(224, 231, 244, 0.58);
  font-size: 0.62rem;
  font-weight: 850;
}

.collection-sections-count {
  display: grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  color: #06110f;
  background: #74ccc3;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.collection-sections-chevron {
  width: 18px;
  height: 18px;
  color: rgba(224, 231, 244, 0.58);
  transition: transform 160ms ease, color 160ms ease;
}

.collection-sections-toggle.is-open {
  border-color: rgba(116, 204, 195, 0.38);
}

.collection-sections-toggle.is-open .collection-sections-chevron {
  color: #74ccc3;
  transform: rotate(180deg);
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs {
  grid-area: sectionlist;
  margin: 0;
  padding: 0 0 2px;
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs[hidden] {
  display: none;
}

/* Section disclosure final placement */
.collection-portfolio-toolbar {
  grid-template-columns: minmax(0, 1fr) 48px 48px;
  grid-template-areas:
    "search search search"
    "sections favorite filter"
    "sectionlist sectionlist sectionlist";
}

.collection-section-disclosure {
  display: contents;
}

.collection-sections-toggle {
  grid-area: sections;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 20px;
  gap: 8px;
  align-items: center;
  min-width: 0;
  min-height: 48px;
  padding: 6px 8px;
  color: #f7f8fb;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.045)),
    rgba(8, 12, 19, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.collection-sections-toggle svg,
.collection-sections-chevron {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-sections-toggle-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 10px;
  color: #ffd166;
  background: rgba(255, 209, 102, 0.14);
  border: 1px solid rgba(255, 209, 102, 0.24);
  border-radius: 11px;
}

.collection-sections-toggle-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.collection-sections-toggle-copy strong,
.collection-sections-toggle-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-sections-toggle-copy strong {
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 950;
  line-height: 1.12;
}

.collection-sections-toggle-copy small {
  color: rgba(224, 231, 244, 0.58);
  font-size: 0.62rem;
  font-weight: 850;
}

.collection-sections-count {
  display: grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  color: #06110f;
  background: #74ccc3;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.collection-sections-chevron {
  width: 20px;
  height: 20px;
  color: rgba(224, 231, 244, 0.58);
  transition: transform 160ms ease, color 160ms ease;
}

.collection-sections-toggle.is-open {
  border-color: rgba(116, 204, 195, 0.38);
}

.collection-sections-toggle.is-open .collection-sections-chevron {
  color: #74ccc3;
  transform: rotate(180deg);
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs {
  grid-area: sectionlist;
  margin: 0;
  padding: 0 0 2px;
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs[hidden] {
  display: none;
}

/* Collection action row */
.collection-tools-panel {
  display: grid;
  gap: 9px;
}

.collection-tools-panel.collection-action-hub {
  grid-template-columns: minmax(96px, 1fr) repeat(2, minmax(82px, 0.9fr));
  align-items: stretch;
}

.collection-action-button {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
  min-height: 46px;
  padding: 7px 8px;
  color: #f7f8fb;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(126, 211, 202, 0.035)),
    rgba(8, 14, 24, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.055), 0 10px 24px rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(18px);
}

.collection-action-button span {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  color: #7ed3ca;
}

.collection-action-button svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-action-button strong {
  min-width: 0;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 760;
  line-height: 1;
  overflow-wrap: anywhere;
}

/* Collapsed collection section picker */
.collection-section-disclosure {
  display: contents;
}

.collection-sections-toggle {
  grid-area: sections;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 20px;
  gap: 8px;
  align-items: center;
  min-width: 0;
  min-height: 48px;
  padding: 6px 8px;
  color: #f7f8fb;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.045)),
    rgba(8, 12, 19, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.collection-sections-toggle svg,
.collection-sections-chevron {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-sections-toggle-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 10px;
  color: #ffd166;
  background: rgba(255, 209, 102, 0.14);
  border: 1px solid rgba(255, 209, 102, 0.24);
  border-radius: 11px;
}

.collection-sections-toggle-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.collection-sections-toggle-copy strong,
.collection-sections-toggle-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-sections-toggle-copy strong {
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 950;
  line-height: 1.12;
}

.collection-sections-toggle-copy small {
  color: rgba(224, 231, 244, 0.58);
  font-size: 0.62rem;
  font-weight: 850;
}

.collection-sections-count {
  display: grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  color: #06110f;
  background: #74ccc3;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.collection-sections-chevron {
  width: 20px;
  height: 20px;
  color: rgba(224, 231, 244, 0.58);
  transition: transform 160ms ease, color 160ms ease;
}

.collection-sections-toggle.is-open {
  border-color: rgba(116, 204, 195, 0.38);
}

.collection-sections-toggle.is-open .collection-sections-chevron {
  color: #74ccc3;
  transform: rotate(180deg);
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs {
  grid-area: sectionlist;
  margin: 0;
  padding: 0 0 2px;
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs[hidden] {
  display: none;
}

/* Full app dark mode */
:root {
  --page: #05070b;
  --panel: #0a0d13;
  --panel-strong: #f7f8fb;
  --ink: #f7f8fb;
  --muted: #9aa6b8;
  --line: rgba(255, 255, 255, 0.12);
  --line-strong: rgba(255, 255, 255, 0.2);
  --green: #65c5bb;
  --green-soft: rgba(101, 197, 187, 0.14);
  --blue: #7ea4ff;
  --blue-soft: rgba(126, 164, 255, 0.16);
  --red: #ff917f;
  --amber: #ffd166;
  --amber-soft: rgba(255, 209, 102, 0.14);
  --shadow: 0 18px 42px rgba(0, 0, 0, 0.36);
  --shadow-strong: 0 28px 70px rgba(0, 0, 0, 0.48);
}

html {
  color-scheme: dark;
  background: #05070b;
}

body,
body.collector-home {
  color: #f7f8fb;
  background:
    radial-gradient(circle at 12% -4%, rgba(47, 111, 237, 0.2), transparent 30%),
    radial-gradient(circle at 90% 5%, rgba(101, 197, 187, 0.16), transparent 28%),
    linear-gradient(180deg, #05070b 0%, #080b11 45%, #05070b 100%);
}

body:not(.is-collection-detail) .collector-app {
  background: transparent;
}

input,
select,
textarea {
  color: #f7f8fb;
  background: #0f141d;
  border-color: rgba(255, 255, 255, 0.16);
}

input::placeholder,
textarea::placeholder {
  color: rgba(247, 248, 251, 0.42);
}

.dashboard-header {
  color: #f7f8fb;
}

.dashboard-header h1,
.hero-copy h2,
.section-row h2,
.collection-tab-head h2,
.collection-panel-head h3,
.collection-section-copy strong,
.collection-active-row strong,
.collection-tab .card-topline h3,
.collector-app .card-topline h3,
.sold-title-row h4,
.scanner-sheet-head h3,
.scanner-sheet-result strong,
.scanner-sheet-listing strong {
  color: #f7f8fb;
}

.home-logo {
  color: #06110f;
  background: #000;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28);
}

.eyebrow,
.scanner-sheet-head span,
.scanner-sheet-result span {
  color: #9db9ff;
}

.icon-button,
.scan-icon-button,
.collection-back-btn,
.collection-panel-head button,
.collection-active-row button,
.home-action-strip a,
.home-action-strip button,
.market-links a,
.sold-actions a,
.sold-actions button,
.collection-section-actions button,
.collection-tab .card-actions a,
.collection-tab .card-actions button,
.scanner-sheet-head button {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: none;
}

.hero-value-card,
.scan-card,
.market-card,
.collection-tab-head,
.collection-section-panel,
.collection-detail-panel,
.collection-stat-row article,
.collection-toolbar,
.portfolio-graph-card,
.market-snapshot-card,
.sold-item,
.collection-tab .collection-card,
.collection-section-picker-panel,
.scanner-job-sheet-panel,
.scanner-sheet-result,
.scanner-sheet-listing {
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025)),
    #0a0d13;
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.28);
}

.hero-value-card {
  background:
    linear-gradient(135deg, rgba(126, 164, 255, 0.16), rgba(101, 197, 187, 0.12)),
    #0a0d13;
}

.value-hub {
  background:
    linear-gradient(135deg, rgba(101, 197, 187, 0.14), rgba(126, 164, 255, 0.1)),
    #05070b;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-copy span,
.value-hub span,
.portfolio-graph-head span,
.portfolio-graph-head small,
#portfolioGraphSummary,
.collector-app .scanner-status,
.collection-tab-head span,
.collection-stat-row span,
.collection-section-copy small,
.collection-active-row span,
.collection-tab .card-topline p,
.collection-tab .card-meta,
.collection-tab .card-notes,
.collection-tab .card-price-note,
.collector-app .snapshot-body p,
.collector-app .snapshot-body small,
.sold-body p,
.scanner-sheet-head small,
.scanner-sheet-form label,
.scanner-sheet-result p,
.scanner-sheet-result small,
.scanner-sheet-listing small {
  color: rgba(247, 248, 251, 0.62);
}

.portfolio-graph-head strong,
.collection-stat-row strong.positive,
.collection-tab .positive strong,
.portfolio-card-footer .positive strong,
.portfolio-card-footer .positive small {
  color: #65c5bb;
}

.portfolio-graph-head strong.negative,
.collection-stat-row strong.negative,
.collection-tab .negative strong,
.portfolio-card-footer .negative strong,
.portfolio-card-footer .negative small {
  color: #ff917f;
}

.graph-bg {
  fill: #070a10;
}

.graph-grid {
  stroke: rgba(255, 255, 255, 0.13);
}

.value-dot {
  fill: #05070b;
  stroke: #7ea4ff;
}

.graph-label {
  fill: rgba(247, 248, 251, 0.5);
}

.home-action-strip > :first-child,
.primary-action,
.save-inventory-btn,
.scanner-sheet-form button {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.save-inventory-btn:disabled,
.collection-section-actions button:disabled,
.scanner-sheet-form button:disabled {
  color: rgba(247, 248, 251, 0.38);
  background: rgba(255, 255, 255, 0.055);
  border-color: rgba(255, 255, 255, 0.08);
}

.scanner-search,
.quick-search,
.lookup-form,
.comp-form,
.market-result {
  color: #f7f8fb;
  background: #0a0d13;
  border-color: rgba(255, 255, 255, 0.12);
}

.scanner-search label,
.quick-search input,
.lookup-form label,
.comp-form label {
  color: rgba(247, 248, 251, 0.62);
}

.scanner-search input,
.quick-search input,
.lookup-form input,
.lookup-form select,
.lookup-form textarea,
.comp-form input,
.comp-form select,
.scanner-sheet-form input,
.scanner-sheet-form select {
  color: #f7f8fb;
  background: #05070b;
  border-color: rgba(255, 255, 255, 0.14);
}

.status-chip {
  color: #1a1200;
  background: #ffd166;
}

.valuation-source-row,
.sold-more-note {
  color: #f7f8fb;
  background: rgba(5, 7, 11, 0.78);
  border-color: rgba(255, 255, 255, 0.12);
}

.valuation-source-row span {
  color: #f7f8fb;
}

.valuation-source-row small,
.sold-more-note {
  color: rgba(247, 248, 251, 0.62);
}

.valuation-source-row strong {
  color: #65c5bb;
}

.collector-app .market-snapshot-card,
.collector-app .snapshot-image,
.snapshot-image,
.sold-thumb,
.collection-card-image,
.scanner-sheet-capture-preview,
.scanner-sheet-capture-preview img,
.scanner-sheet-candidate-option img,
.scanner-sheet-candidate-empty {
  background: #070a10;
  border-color: rgba(255, 255, 255, 0.12);
}

.collector-app .snapshot-body span,
.snapshot-body span {
  color: #9db9ff;
}

.collector-app .snapshot-body strong,
.snapshot-body strong,
.sold-title-row strong,
.scanner-sheet-listing span {
  color: #65c5bb;
}

.collection-section-row {
  color: #f7f8fb;
  background: #0a0d13;
  border-color: rgba(255, 255, 255, 0.12);
}

.collection-section-row.is-active {
  background: rgba(101, 197, 187, 0.11);
  border-color: rgba(101, 197, 187, 0.45);
  box-shadow: inset 4px 0 0 #65c5bb;
}

.collection-section-placeholder {
  background: rgba(126, 164, 255, 0.1);
  border-color: rgba(126, 164, 255, 0.34);
}

.collection-section-open {
  color: #f7f8fb;
}

.collection-drag-handle,
.collection-drag-handle::after {
  border-color: rgba(247, 248, 251, 0.58);
}

.collection-drag-handle::after {
  background: rgba(247, 248, 251, 0.58);
}

.collection-folder-icon {
  background: rgba(101, 197, 187, 0.1);
  border-color: #65c5bb;
}

.collection-folder-icon.all {
  background: rgba(101, 197, 187, 0.28);
}

.collection-folder-icon.graded {
  background: rgba(126, 164, 255, 0.12);
  border-color: #7ea4ff;
}

.collection-folder-icon.sealed {
  background: rgba(255, 145, 127, 0.12);
  border-color: #ff917f;
}

.collection-section-arrow {
  color: #dbe6ff;
  background: rgba(126, 164, 255, 0.12);
  border-color: rgba(126, 164, 255, 0.25);
}

.collection-tab .value-row span {
  background: #070a10;
  border-color: rgba(255, 255, 255, 0.12);
}

.collection-tab .value-row small,
.collection-tab .value-row strong {
  color: #f7f8fb;
}

.mini-card,
.collection-tab .mini-card {
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.34);
}

.collection-section-picker {
  background: rgba(0, 0, 0, 0.6);
}

.collection-section-picker-list button,
.collection-section-picker-cancel {
  color: #f7f8fb;
  background: #070a10;
  border-color: rgba(255, 255, 255, 0.12);
}

.collection-section-picker-list small {
  color: rgba(247, 248, 251, 0.62);
}

.scanner-job-sheet-panel {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.025)),
    #0a0d13;
  border-color: rgba(255, 255, 255, 0.14);
}

.scanner-sheet-handle {
  background: rgba(247, 248, 251, 0.28);
}

.scanner-sheet-form .scanner-sheet-add-btn {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.bottom-nav {
  bottom: max(10px, env(safe-area-inset-bottom));
  width: min(430px, calc(100% - 28px));
  padding: 8px 10px;
  color: rgba(247, 248, 251, 0.68);
  background: rgba(10, 13, 19, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.36);
}

.bottom-nav .active {
  color: #f7f8fb;
  background: rgba(101, 197, 187, 0.28);
}

.bottom-nav .scan-tab {
  color: #06110f;
  background: #65c5bb;
}

/* Vault section browse redesign */
.collection-tab:not(.is-section-detail) {
  gap: 12px;
}

body.is-collection-tab:not(.is-collection-detail) .collector-app {
  padding-top: 12px;
}

body.is-collection-tab:not(.is-collection-detail) .dashboard-header {
  display: none;
}

.collection-tab:not(.is-section-detail) .collection-tab-head {
  padding: 14px 0 4px;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.collection-tab:not(.is-section-detail) .collection-tab-head h2 {
  font-size: clamp(1.9rem, 9vw, 2.7rem);
}

.collection-tab:not(.is-section-detail) .collection-tab-head span {
  max-width: 22rem;
  color: rgba(247, 248, 251, 0.6);
  font-size: 0.98rem;
}

.collection-tab:not(.is-section-detail) .collection-stat-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.collection-tab:not(.is-section-detail) .collection-stat-row article {
  min-height: 86px;
  padding: 13px 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025)),
    #0a0d13;
  border-color: rgba(255, 255, 255, 0.1);
  border-radius: 18px;
}

.collection-tab:not(.is-section-detail) .collection-stat-row strong {
  color: #f7f8fb;
  font-size: clamp(1.3rem, 5.4vw, 1.8rem);
  line-height: 1;
}

.collection-tab:not(.is-section-detail) .collection-stat-row strong.positive {
  color: #65c5bb;
}

.collection-section-panel {
  gap: 12px;
  padding: 16px;
  overflow: hidden;
}

.collection-panel-head {
  align-items: start;
}

.collection-panel-head h3 {
  font-size: 1.35rem;
}

.collection-panel-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 8px;
  justify-content: flex-end;
  margin-top: -2px;
}

.collection-panel-actions button,
.collection-section-filters button {
  min-height: 38px;
  padding: 0 14px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 999px;
  font-weight: 900;
}

.collection-panel-actions button.is-active,
.collection-section-filters button.is-active {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.collection-section-search {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  min-height: 46px;
  padding: 0 14px;
  color: rgba(247, 248, 251, 0.64);
  background: #05070b;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
}

.collection-section-search svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.collection-section-search input {
  min-width: 0;
  min-height: 42px;
  padding: 0;
  color: #f7f8fb;
  background: transparent;
  border: 0;
  font-weight: 850;
}

.collection-section-filters {
  display: flex;
  gap: 8px;
  margin-inline: -2px;
  padding: 0 2px 2px;
  overflow-x: auto;
  scrollbar-width: none;
}

.collection-section-filters::-webkit-scrollbar {
  display: none;
}

.collection-section-filters button {
  flex: 0 0 auto;
  min-height: 34px;
  padding-inline: 12px;
  font-size: 0.74rem;
}

.collection-all-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 16px;
  background:
    linear-gradient(135deg, rgba(101, 197, 187, 0.16), rgba(126, 164, 255, 0.1)),
    #070a10;
  border: 1px solid rgba(101, 197, 187, 0.26);
  border-radius: 18px;
}

.collection-all-summary span,
.collection-all-summary strong,
.collection-all-summary small {
  display: block;
}

.collection-all-summary span {
  color: #9db9ff;
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.collection-all-summary strong {
  margin-top: 4px;
  color: #f7f8fb;
  font-size: clamp(1.8rem, 8vw, 2.7rem);
  line-height: 1;
}

.collection-all-summary small {
  margin-top: 7px;
  color: rgba(247, 248, 251, 0.62);
  font-weight: 800;
}

.collection-all-summary p {
  margin: 0;
  color: #65c5bb;
  font-size: 1.2rem;
  font-weight: 950;
  white-space: nowrap;
}

.collection-all-summary p.negative {
  color: #ff917f;
}

.collection-section-list {
  gap: 10px;
}

.collection-section-row {
  gap: 0;
  min-height: 82px;
  padding: 0;
  border-radius: 18px;
}

.collection-section-row.is-active {
  box-shadow: inset 4px 0 0 #65c5bb;
}

.collection-section-open {
  grid-template-columns: 0 32px minmax(0, 1fr) auto;
  gap: 12px;
  min-height: 82px;
  padding: 14px;
}

.collection-section-panel:not(.is-editing) .collection-drag-handle,
.collection-section-panel:not(.is-editing) .collection-section-actions {
  display: none;
}

.collection-section-panel.is-editing .collection-section-open {
  grid-template-columns: 20px 32px minmax(0, 1fr) auto;
}

.collection-drag-handle {
  width: 18px;
  height: 14px;
}

.collection-folder-icon {
  width: 32px;
  height: 25px;
  border-radius: 8px;
}

.collection-section-type {
  display: inline-grid;
  width: max-content;
  margin: 0 0 5px;
  padding: 3px 7px;
  color: #65c5bb;
  background: rgba(101, 197, 187, 0.12);
  border: 1px solid rgba(101, 197, 187, 0.2);
  border-radius: 999px;
  font-size: 0.58rem;
  font-weight: 950;
  letter-spacing: 0.1em;
}

.collection-section-copy strong {
  font-size: 1.04rem;
}

.collection-section-copy small {
  font-size: 0.82rem;
}

.collection-section-arrow {
  display: inline-grid;
  place-items: center;
  padding: 8px 11px;
  color: #dbe6ff;
  background: rgba(126, 164, 255, 0.14);
  border-color: rgba(126, 164, 255, 0.25);
  white-space: nowrap;
}

.collection-section-actions {
  padding: 0 14px 14px 58px;
}

.collection-section-actions button {
  min-height: 34px;
  padding-inline: 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.13);
  font-size: 0.76rem;
}

.collection-section-actions button:first-child {
  min-width: 36px;
}

.collection-section-row.is-favorite .collection-folder-icon {
  box-shadow: 0 0 0 3px rgba(255, 209, 102, 0.12);
}

@media (max-width: 380px) {
  .collection-section-panel {
    padding: 14px;
  }

  .collection-panel-head {
    display: grid;
  }

  .collection-panel-actions {
    width: 100%;
  }

  .collection-panel-actions button {
    flex: 1 1 0;
  }

  .collection-section-copy strong {
    font-size: 0.96rem;
  }

  .collection-section-copy small {
    font-size: 0.76rem;
  }
}

.collection-section-panel:not(.is-editing) .collection-section-open {
  grid-template-columns: 32px minmax(0, 1fr) 74px;
}

.collection-section-panel.is-editing .collection-section-open {
  grid-template-columns: 20px 32px minmax(0, 1fr) 74px;
}

.collection-section-panel .collection-section-arrow {
  width: 74px;
  min-width: 0;
}

/* Collection overview polish */
.collection-tab:not(.is-section-detail) .collection-tab-head {
  gap: 12px;
  padding-top: 10px;
}

.collection-tab:not(.is-section-detail) .collection-tab-head h2 {
  font-size: clamp(2rem, 8.5vw, 2.55rem);
  line-height: 0.98;
}

.collection-tab:not(.is-section-detail) .collection-tab-head span {
  margin-top: 8px;
  font-size: 0.9rem;
  line-height: 1.25;
}

.collection-tab:not(.is-section-detail) #collectionSummaryText {
  display: none;
}

.collection-tab:not(.is-section-detail) .scan-icon-button {
  width: 58px;
  height: 58px;
  border-radius: 22px;
}

.collection-section-panel {
  gap: 10px;
  padding: 14px;
  border-radius: 24px;
}

.collection-section-filters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
  margin: 0;
  padding: 0;
  overflow: visible;
}

.collection-section-filters button {
  width: 100%;
  min-height: 34px;
  padding-inline: 6px;
  font-size: 0.7rem;
}

.collection-all-summary {
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  padding: 14px;
  border-radius: 18px;
}

.collection-all-summary > div {
  min-width: 0;
}

.collection-all-summary strong {
  overflow: hidden;
  max-width: 100%;
  font-size: clamp(2rem, 9vw, 2.95rem);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-all-summary small {
  overflow: hidden;
  margin-top: 6px;
  font-size: 0.82rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-all-summary p {
  justify-self: start;
  padding: 5px 10px;
  background: rgba(101, 197, 187, 0.12);
  border: 1px solid rgba(101, 197, 187, 0.24);
  border-radius: 999px;
  font-size: 0.88rem;
  line-height: 1;
}

.collection-all-summary p.negative {
  background: rgba(255, 145, 127, 0.12);
  border-color: rgba(255, 145, 127, 0.24);
}

.collection-panel-actions {
  gap: 9px;
  margin-top: 0;
}

.collection-panel-actions button {
  min-height: 36px;
  padding-inline: 16px;
}

.collection-section-list {
  gap: 8px;
}

.collection-section-row {
  min-height: 74px;
  border-radius: 16px;
}

.collection-section-row.is-active {
  box-shadow: inset 3px 0 0 #65c5bb;
}

.collection-section-panel:not(.is-editing) .collection-section-open {
  grid-template-columns: 30px minmax(0, 1fr) 64px;
}

.collection-section-panel.is-editing .collection-section-open {
  grid-template-columns: 18px 30px minmax(0, 1fr) 64px;
}

.collection-section-open {
  gap: 10px;
  min-height: 74px;
  padding: 12px;
}

.collection-folder-icon {
  width: 30px;
  height: 24px;
}

.collection-section-type {
  margin-bottom: 3px;
  padding: 2px 7px;
  font-size: 0.54rem;
  letter-spacing: 0.1em;
}

.collection-section-copy strong {
  font-size: 1rem;
  line-height: 1.05;
}

.collection-section-copy small {
  margin-top: 4px;
  font-size: 0.78rem;
}

.collection-section-panel .collection-section-arrow {
  width: 64px;
  padding: 7px 8px;
  font-size: 0.68rem;
}

.collection-all-summary {
  justify-items: center;
  text-align: center;
}

.collection-all-summary span,
.collection-all-summary strong {
  text-align: center;
}

@media (max-width: 380px) {
  .collection-section-panel {
    padding: 12px;
  }

  .collection-section-filters {
    gap: 6px;
  }

  .collection-section-filters button {
    font-size: 0.66rem;
  }

  .collection-panel-actions button {
    padding-inline: 12px;
  }
}

/* Direct collection portfolio */
.collection-tab.is-section-detail .collection-tab-head {
  display: none;
}

.collection-tab.is-section-detail .collection-section-panel {
  display: grid;
  gap: 10px;
  padding: 0 4px;
  overflow: visible;
  color: #f7f8fb;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.collection-section-panel-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  min-width: 0;
}

.collection-section-nav-title {
  display: grid;
  min-width: 0;
}

.collection-section-nav-title span,
.collection-section-nav-title strong {
  display: block;
}

.collection-section-nav-title span {
  color: rgba(247, 248, 251, 0.52);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.collection-section-nav-title strong {
  overflow: hidden;
  margin-top: 2px;
  color: #f7f8fb;
  font-size: 1.08rem;
  font-weight: 950;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-tab.is-section-detail .collection-panel-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 54px;
  gap: 8px;
  width: 100%;
  margin: 0;
}

.collection-tab.is-section-detail .collection-panel-actions button {
  min-width: 0;
  min-height: 34px;
  padding: 0 8px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 900;
}

.collection-tab.is-section-detail .collection-panel-actions button.is-active {
  color: #06110f;
  background: #ffd166;
  border-color: #ffd166;
}

.collection-tab.is-section-detail .collection-section-tabs {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  margin: 0 -4px;
  padding: 0 4px 2px;
  overflow-x: auto;
  scrollbar-width: none;
}

.collection-tab.is-section-detail .collection-section-tabs::-webkit-scrollbar {
  display: none;
}

.collection-tab.is-section-detail .collection-section-tab {
  flex: 0 0 auto;
  min-width: min(44vw, 178px);
  height: 54px;
  min-height: 0;
  align-self: flex-start;
  overflow: hidden;
  padding: 0;
  background: #030406;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-section-tab.is-active {
  background: rgba(101, 197, 187, 0.18);
  border-color: rgba(101, 197, 187, 0.48);
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-section-tab.is-favorite {
  border-color: rgba(255, 209, 102, 0.56);
}

.collection-tab.is-section-detail .collection-section-tab .collection-section-open,
.collection-tab.is-section-detail .collection-section-panel:not(.is-editing) .collection-section-open,
.collection-tab.is-section-detail .collection-section-panel.is-editing .collection-section-open {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  height: 52px;
  min-height: 52px;
  padding: 7px 12px;
}

.collection-tab.is-section-detail .collection-section-panel.is-editing .collection-section-open {
  grid-template-columns: 18px 22px minmax(0, 1fr);
}

.collection-tab.is-section-detail .collection-section-panel:not(.is-editing) .collection-drag-handle {
  display: none;
}

.collection-tab-star {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  color: rgba(247, 248, 251, 0.26);
}

.collection-tab-star svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.collection-section-tab.is-favorite .collection-tab-star {
  color: #ffd166;
  filter: drop-shadow(0 0 8px rgba(255, 209, 102, 0.34));
}

.collection-tab.is-section-detail .collection-section-copy {
  display: grid;
  min-width: 0;
  text-align: left;
}

.collection-tab.is-section-detail .collection-section-copy strong {
  overflow: hidden;
  color: #f7f8fb;
  font-size: 0.88rem;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-tab.is-section-detail .collection-section-copy small {
  overflow: hidden;
  margin-top: 3px;
  color: rgba(247, 248, 251, 0.54);
  font-size: 0.68rem;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-tab.is-section-detail .collection-section-actions {
  gap: 6px;
  padding: 0 10px 10px;
}

.collection-tab.is-section-detail .collection-section-actions button:first-child {
  color: #1a1200;
  background: #ffd166;
  border-color: #ffd166;
}

.collection-tab.is-section-detail .collection-detail-panel {
  padding-top: 2px;
}

@media (max-width: 380px) {
  .collection-tab.is-section-detail .collection-section-panel-head {
    align-items: start;
  }

  .collection-section-nav-title strong {
    font-size: 1rem;
  }

  .collection-tab.is-section-detail .collection-panel-actions button {
    padding-inline: 10px;
  }

  .collection-tab.is-section-detail .collection-section-tab {
    min-width: min(52vw, 164px);
  }
}

.collection-tab.is-section-detail .collection-section-panel-head {
  display: none;
}

/* CardPriceCheck distinct collection identity */
body.is-collection-detail {
  color: #16202f;
  background: #f3f6fb;
}

body.is-collection-detail .collector-app {
  background: #f3f6fb;
}

.collection-tab.is-section-detail {
  color: #16202f;
  margin: -12px 0 -104px;
  padding-inline: 0;
  background:
    linear-gradient(180deg, rgba(246, 198, 79, 0.18) 0, rgba(114, 181, 173, 0.1) 180px, rgba(243, 246, 251, 0) 360px),
    #f3f6fb;
}

.collection-tab.is-section-detail .collection-section-tab {
  background: rgba(255, 255, 255, 0.92);
  border-color: #d9e1ec;
}

.collection-tab.is-section-detail .collection-section-tab.is-active {
  background: #fff7dd;
  border-color: #e1bc48;
}

.collection-tab.is-section-detail .collection-section-tab.is-favorite {
  border-color: #d39f1f;
}

.collection-tab.is-section-detail .collection-section-copy strong {
  color: #16202f;
}

.collection-tab.is-section-detail .collection-section-copy small {
  color: #667085;
}

.collection-tab-star {
  color: #9ba8b8;
}

.collection-section-tab.is-favorite .collection-tab-star {
  color: #d39f1f;
  filter: none;
}

.collection-portfolio-search {
  color: #16202f;
  background: #ffffff;
  border-color: #d9e1ec;
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(19, 31, 49, 0.06);
}

.collection-portfolio-search > svg {
  color: #233349;
}

.collection-portfolio-search input {
  color: #16202f;
}

.collection-portfolio-search input::placeholder {
  color: #8a95a6;
}

.collection-portfolio-search button,
.collection-portfolio-icon,
.collection-portfolio-filter {
  color: #233349;
  background: #ffffff;
  border-color: #d9e1ec;
  border-radius: 14px;
}

.collection-portfolio-icon.is-active {
  color: #d39f1f;
  background: #fff7dd;
  border-color: #e1bc48;
}

.collection-portfolio-hero {
  justify-items: stretch;
  gap: 10px;
  padding: 16px;
  text-align: left;
  background: #ffffff;
  border: 1px solid #d9e1ec;
  border-left: 5px solid #d39f1f;
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(19, 31, 49, 0.08);
}

.collection-portfolio-hero p {
  display: grid;
  gap: 3px;
  color: #667085;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.collection-portfolio-hero p span,
.collection-portfolio-hero p strong {
  display: block;
}

.collection-portfolio-hero p strong {
  color: #16202f;
  font-size: 1.14rem;
  letter-spacing: 0;
  text-transform: none;
}

.collection-portfolio-hero div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  width: 100%;
}

.collection-portfolio-hero div > strong {
  color: #16202f;
  font-size: clamp(2.35rem, 11vw, 3.6rem);
}

.collection-portfolio-hero div > span {
  width: 42px;
  height: 42px;
  color: #4c5b70;
  background: #eef3f8;
}

.collection-portfolio-hero small,
.collection-portfolio-hero small.positive {
  color: #2f756e;
}

.collection-portfolio-hero small.negative {
  color: #b55145;
}

.collection-portfolio-actions {
  grid-template-columns: minmax(0, 1fr);
  gap: 9px;
}

.collection-portfolio-actions button {
  grid-template-columns: 38px minmax(0, 1fr);
  justify-items: stretch;
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 10px;
  color: #16202f;
  background: #ffffff;
  border: 1px solid #d9e1ec;
  border-radius: 14px;
  text-align: left;
  box-shadow: 0 12px 26px rgba(19, 31, 49, 0.06);
}

.collection-portfolio-actions button > span {
  width: 38px;
  height: 38px;
  padding: 10px;
  color: #2f756e;
  background: #e6f4f1;
  border: 0;
  border-radius: 12px;
}

.collection-portfolio-actions button:first-child > span {
  color: #8a5d00;
  background: #fff2c2;
  border: 0;
}

.collection-portfolio-actions strong {
  color: #16202f;
  font-size: 0.82rem;
  line-height: 1.12;
  overflow-wrap: anywhere;
  white-space: normal;
}

.collection-tab.is-section-detail .empty-state,
.collection-tab.is-section-detail .collection-card {
  color: #16202f;
  background: #ffffff;
  border-color: #d9e1ec;
  box-shadow: 0 14px 34px rgba(19, 31, 49, 0.08);
}

.collection-tab.is-section-detail .empty-state strong,
.collection-tab.is-section-detail .portfolio-card-copy h3 {
  color: #16202f;
}

.collection-tab.is-section-detail .portfolio-card-copy p {
  color: #4c5b70;
}

.collection-tab.is-section-detail .portfolio-card-copy .portfolio-card-condition,
.portfolio-card-footer .positive strong,
.portfolio-card-footer .positive small {
  color: #2f756e;
}

.portfolio-card-footer > span:first-child,
.portfolio-card-footer strong {
  color: #16202f;
}

.collection-tab.is-section-detail .portfolio-card-inventory button {
  color: #16202f;
  background: #f5f7fb;
  border-color: #d9e1ec;
}

.portfolio-card-footer small,
.collection-tab.is-section-detail .card-meta,
.collection-tab.is-section-detail .card-price-note {
  color: #6e7b8d;
}

.collection-tab.is-section-detail .card-actions a,
.collection-tab.is-section-detail .card-actions button {
  color: #16202f;
  background: #f5f7fb;
  border-color: #d9e1ec;
}

.collection-bulk-toolbar {
  color: #16202f;
  background: #fff7dd;
  border-color: #e1bc48;
}

.collection-bulk-select-all,
.collection-bulk-actions button {
  color: #16202f;
  background: #ffffff;
  border-color: #e5d6a7;
}

#collectionBulkSelectedCount {
  color: #16202f;
}

.collection-bulk-actions button:nth-child(2) {
  color: #16202f;
  background: #f6c64f;
  border-color: #f6c64f;
}

.collection-card-select {
  color: #233349;
  background: rgba(255, 255, 255, 0.92);
  border-color: #d9e1ec;
}

.collection-card-select[aria-pressed="true"] {
  color: #16202f;
  background: #f6c64f;
  border-color: #f6c64f;
}

.collection-tab.is-section-detail .collection-card.is-selected {
  border-color: #d39f1f;
  box-shadow: inset 0 0 0 1px rgba(211, 159, 31, 0.34), 0 14px 34px rgba(19, 31, 49, 0.1);
}

body.is-collection-detail .bottom-nav {
  color: #667085;
  background: rgba(255, 255, 255, 0.94);
  border-color: #d9e1ec;
  box-shadow: 0 18px 44px rgba(19, 31, 49, 0.14);
}

body.is-collection-detail .bottom-nav .active {
  color: #16202f;
  background: #fff2c2;
}

body.is-collection-detail .bottom-nav .scan-tab {
  color: #16202f;
  background: #eef3f8;
}

/* Collection bulk selection */
.collection-bulk-toolbar {
  position: relative;
  z-index: 28;
  align-self: start;
  display: grid;
  gap: 10px;
  padding: 10px;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 209, 102, 0.12), rgba(255, 255, 255, 0.035)),
    #07090d;
  border: 1px solid rgba(255, 209, 102, 0.28);
  border-radius: 16px;
}

.collection-bulk-toolbar[hidden] {
  display: none;
}

body.is-collection-bulk-mode .collection-bulk-toolbar:not([hidden]) {
  position: fixed;
  left: 50%;
  top: auto;
  bottom: calc(var(--app-bottom-nav-clearance) + 8px);
  z-index: 42;
  width: min(720px, calc(100% - 24px));
  max-height: min(42dvh, 280px);
  overflow: auto;
  transform: translateX(-50%);
  -webkit-overflow-scrolling: touch;
}

.collection-bulk-select-all {
  display: flex;
  gap: 9px;
  align-items: center;
  min-height: 38px;
  padding: 0 10px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
}

.collection-bulk-select-all input {
  width: 18px;
  height: 18px;
  accent-color: #ffd166;
}

#collectionBulkSelectedCount {
  color: #f7f8fb;
}

.collection-bulk-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.collection-bulk-actions button {
  min-width: 0;
  min-height: 36px;
  padding: 0 8px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 900;
}

.collection-bulk-actions button:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.collection-bulk-actions button:nth-child(2) {
  color: #1a1200;
  background: #ffd166;
  border-color: #ffd166;
}

.collection-bulk-actions button:nth-child(3) {
  color: #ffb1a4;
}

.collection-bulk-actions button:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.collection-tab.is-section-detail .collection-card {
  position: relative;
  -webkit-touch-callout: none;
}

.collection-tab.is-section-detail .collection-card.is-selectable {
  -webkit-user-select: none;
  user-select: none;
  touch-action: pan-y;
}

.collection-tab.is-section-detail .collection-card.is-selected {
  border-color: rgba(255, 209, 102, 0.66);
  box-shadow: inset 0 0 0 1px rgba(255, 209, 102, 0.22);
}

.collection-card-select {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 4;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  color: rgba(247, 248, 251, 0.72);
  background: rgba(3, 4, 6, 0.84);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 10px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.34);
}

.collection-card-select span {
  display: block;
  width: 17px;
  height: 17px;
  border: 2px solid currentColor;
  border-radius: 5px;
}

.collection-card-select[aria-pressed="true"] {
  color: #1a1200;
  background: #ffd166;
  border-color: #ffd166;
}

.collection-card-select[aria-pressed="true"] span {
  position: relative;
  border-color: #1a1200;
}

.collection-card-select[aria-pressed="true"] span::after {
  position: absolute;
  left: 3px;
  top: 0;
  width: 7px;
  height: 11px;
  border: solid #1a1200;
  border-width: 0 2px 2px 0;
  content: "";
  transform: rotate(45deg);
}

.collection-list.is-bulk-mode .card-actions {
  display: none;
}

@media (max-width: 380px) {
  .collection-bulk-actions {
    gap: 6px;
  }

  .collection-bulk-actions button {
    padding-inline: 6px;
    font-size: 0.68rem;
  }
}

/* CardPriceCheck dark glass collection refresh */
body.is-collection-detail {
  color: #f7f8fb;
  background: #070a10;
}

body.is-collection-detail .collector-app {
  background:
    linear-gradient(180deg, rgba(23, 30, 45, 0.96) 0%, rgba(7, 10, 16, 0.98) 46%, #05070b 100%);
}

.collection-tab.is-section-detail {
  color: #f7f8fb;
  margin: -12px 0 -104px;
  padding: 12px 14px calc(112px + env(safe-area-inset-bottom));
  overflow-x: hidden;
  background:
    linear-gradient(180deg, rgba(28, 36, 54, 0.9) 0, rgba(12, 17, 27, 0.94) 310px, rgba(5, 7, 11, 0.98) 100%);
}

.collection-tab.is-section-detail .collection-section-panel,
.collection-tab.is-section-detail .collection-detail-panel {
  color: #f7f8fb;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-section-tabs {
  gap: 9px;
  padding-bottom: 4px;
}

.collection-tab.is-section-detail .collection-section-tab {
  flex-basis: min(40vw, 144px);
  width: min(40vw, 144px);
  min-width: 0;
  background: rgba(255, 255, 255, 0.075);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 12px 30px rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(18px);
}

.collection-tab.is-section-detail .collection-section-tab.is-active {
  background: rgba(116, 204, 195, 0.14);
  border-color: rgba(116, 204, 195, 0.44);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 14px 34px rgba(20, 156, 144, 0.1);
}

.collection-tab.is-section-detail .collection-section-tab.is-favorite {
  border-color: rgba(255, 209, 102, 0.62);
}

.collection-tab.is-section-detail .collection-section-copy strong {
  color: #f7f8fb;
}

.collection-tab.is-section-detail .collection-section-copy small {
  color: rgba(224, 231, 244, 0.58);
}

.collection-tab-star {
  color: rgba(224, 231, 244, 0.34);
}

.collection-section-tab.is-favorite .collection-tab-star {
  color: #ffd166;
  filter: drop-shadow(0 0 10px rgba(255, 209, 102, 0.3));
}

.collection-portfolio-toolbar {
  gap: 9px;
  grid-template-columns: minmax(0, 1fr) 48px 48px;
  grid-template-areas:
    "search search search"
    "sections favorite filter"
    "sectionlist sectionlist sectionlist";
}

.collection-portfolio-search,
.collection-portfolio-icon,
.collection-portfolio-filter {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.13);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.collection-portfolio-search {
  grid-area: search;
  min-width: 0;
  max-width: none;
  overflow: hidden;
  grid-template-columns: 22px minmax(0, 1fr) 30px;
  min-height: 50px;
  padding: 0 8px 0 14px;
  border-radius: 16px;
}

.collection-portfolio-icon,
.collection-portfolio-filter {
  width: 48px;
  height: 48px;
  padding: 12px;
  border-radius: 14px;
}

.collection-portfolio-icon {
  grid-area: favorite;
}

.collection-portfolio-filter {
  grid-area: filter;
}

.collection-portfolio-search > svg {
  color: rgba(247, 248, 251, 0.9);
}

.collection-portfolio-search input {
  width: 100%;
  min-width: 0;
  color: #f7f8fb;
  background-color: transparent !important;
  border: 0;
  border-radius: 0;
  box-shadow: none !important;
  -webkit-appearance: none;
  appearance: none;
}

.collection-portfolio-search button {
  width: 30px;
  height: 30px;
  padding: 7px;
  color: rgba(247, 248, 251, 0.75);
  background: transparent;
  border: 0;
  box-shadow: none;
}

.collection-portfolio-search input::placeholder {
  color: rgba(224, 231, 244, 0.58);
}

.collection-portfolio-search input::-webkit-search-cancel-button,
.collection-portfolio-search input::-webkit-search-decoration {
  display: none;
}

.collection-portfolio-icon.is-active {
  color: #ffd166;
  background: rgba(255, 209, 102, 0.12);
  border-color: rgba(255, 209, 102, 0.56);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 12px 30px rgba(255, 209, 102, 0.08);
}

.collection-portfolio-hero {
  justify-items: stretch;
  gap: 11px;
  padding: 16px;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.115), rgba(255, 255, 255, 0.055)),
    rgba(8, 12, 19, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-left: 4px solid rgba(255, 209, 102, 0.78);
  border-radius: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.09), 0 22px 52px rgba(0, 0, 0, 0.26);
  backdrop-filter: blur(22px);
}

.collection-portfolio-hero p {
  display: grid;
  gap: 3px;
  margin: 0;
  color: rgba(224, 231, 244, 0.62);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.collection-portfolio-hero p span,
.collection-portfolio-hero p strong {
  display: block;
}

.collection-portfolio-hero p strong {
  color: #f7f8fb;
  font-size: 1.08rem;
  letter-spacing: 0;
  text-transform: none;
}

.collection-portfolio-hero div {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  gap: 10px;
  align-items: center;
}

.collection-portfolio-hero div > strong {
  color: #ffffff;
  font-size: clamp(2.35rem, 11vw, 3.55rem);
  line-height: 0.95;
  text-shadow: 0 14px 34px rgba(0, 0, 0, 0.22);
}

.collection-portfolio-hero div > span {
  display: none;
}

.collection-portfolio-hero small,
.collection-portfolio-hero small.positive {
  color: #74ccc3;
}

.collection-portfolio-hero small.negative {
  color: #ff9b8e;
}

.collection-portfolio-actions {
  grid-template-columns: minmax(0, 1fr);
  gap: 9px;
}

.collection-portfolio-actions button {
  grid-template-columns: 38px minmax(0, 1fr);
  justify-items: stretch;
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 10px;
  color: #f7f8fb;
  text-align: left;
  background: rgba(255, 255, 255, 0.075);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.collection-portfolio-actions button > span {
  width: 38px;
  height: 38px;
  padding: 10px;
  color: #74ccc3;
  background: rgba(116, 204, 195, 0.12);
  border: 1px solid rgba(116, 204, 195, 0.2);
  border-radius: 10px;
}

.collection-portfolio-actions button:first-child > span {
  color: #ffd166;
  background: rgba(255, 209, 102, 0.14);
  border: 1px solid rgba(255, 209, 102, 0.22);
}

.collection-portfolio-actions strong {
  color: #f7f8fb;
  font-size: 0.84rem;
  line-height: 1.12;
  overflow-wrap: anywhere;
  white-space: normal;
}

.collection-tab.is-section-detail .empty-state,
.collection-tab.is-section-detail .collection-card {
  color: #f7f8fb;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.04)),
    rgba(6, 9, 14, 0.76);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 16px 36px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(18px);
}

.collection-tab.is-section-detail .collection-card {
  border-radius: 8px;
}

.collection-tab.is-section-detail .empty-state strong,
.collection-tab.is-section-detail .portfolio-card-copy h3 {
  color: #ffffff;
}

.collection-tab.is-section-detail .portfolio-card-copy p {
  color: rgba(224, 231, 244, 0.8);
}

.collection-tab.is-section-detail .portfolio-card-copy .portfolio-card-condition,
.portfolio-card-footer .positive strong,
.portfolio-card-footer .positive small {
  color: #74ccc3;
}

.portfolio-card-footer > span:first-child,
.portfolio-card-footer strong {
  color: #f7f8fb;
}

.collection-tab.is-section-detail .portfolio-card-inventory button {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.065);
  border-color: rgba(255, 255, 255, 0.13);
}

.portfolio-card-footer small,
.collection-tab.is-section-detail .card-meta,
.collection-tab.is-section-detail .card-price-note {
  color: rgba(224, 231, 244, 0.56);
}

.collection-tab.is-section-detail .card-actions a,
.collection-tab.is-section-detail .card-actions button {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.065);
  border-color: rgba(255, 255, 255, 0.13);
}

.collection-bulk-toolbar {
  color: #f7f8fb;
  background:
    linear-gradient(145deg, rgba(255, 209, 102, 0.14), rgba(255, 255, 255, 0.055)),
    rgba(8, 12, 19, 0.82);
  border-color: rgba(255, 209, 102, 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
}

.collection-bulk-select-all,
.collection-bulk-actions button {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.13);
}

#collectionBulkSelectedCount {
  color: #f7f8fb;
}

.collection-bulk-actions button:nth-child(2) {
  color: #1b1403;
  background: #ffd166;
  border-color: #ffd166;
}

.collection-card-select {
  color: rgba(247, 248, 251, 0.76);
  background: rgba(7, 10, 16, 0.84);
  border-color: rgba(255, 255, 255, 0.22);
}

.collection-card-select[aria-pressed="true"] {
  color: #1b1403;
  background: #ffd166;
  border-color: #ffd166;
}

.collection-tab.is-section-detail .collection-card.is-selected {
  border-color: rgba(255, 209, 102, 0.66);
  box-shadow: inset 0 0 0 1px rgba(255, 209, 102, 0.24), 0 16px 36px rgba(0, 0, 0, 0.2);
}

body.is-collection-detail .bottom-nav {
  color: rgba(224, 231, 244, 0.62);
  background: rgba(10, 14, 22, 0.88);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 -18px 42px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(20px);
}

body.is-collection-detail .bottom-nav .active {
  color: #f7f8fb;
  background: rgba(116, 204, 195, 0.18);
}

body.is-collection-detail .bottom-nav .scan-tab {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
}
/* Section disclosure final placement after dark glass */
.collection-portfolio-toolbar {
  grid-template-columns: minmax(0, 1fr) 48px 48px;
  grid-template-areas:
    "search search search"
    "sections favorite filter"
    "sectionlist sectionlist sectionlist";
}

.collection-section-disclosure {
  display: contents;
}

.collection-sections-toggle {
  grid-area: sections;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 20px;
  gap: 8px;
  align-items: center;
  min-width: 0;
  min-height: 48px;
  padding: 6px 8px;
  color: #f7f8fb;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.045)),
    rgba(8, 12, 19, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.collection-sections-toggle svg,
.collection-sections-chevron {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-sections-toggle-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 10px;
  color: #ffd166;
  background: rgba(255, 209, 102, 0.14);
  border: 1px solid rgba(255, 209, 102, 0.24);
  border-radius: 11px;
}

.collection-sections-toggle-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.collection-sections-toggle-copy strong,
.collection-sections-toggle-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-sections-toggle-copy strong {
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 950;
  line-height: 1.12;
}

.collection-sections-toggle-copy small {
  color: rgba(224, 231, 244, 0.58);
  font-size: 0.62rem;
  font-weight: 850;
}

.collection-sections-count {
  display: grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  color: #06110f;
  background: #74ccc3;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.collection-sections-chevron {
  width: 20px;
  height: 20px;
  color: rgba(224, 231, 244, 0.58);
  transition: transform 160ms ease, color 160ms ease;
}

.collection-sections-toggle.is-open {
  border-color: rgba(116, 204, 195, 0.38);
}

.collection-sections-toggle.is-open .collection-sections-chevron {
  color: #74ccc3;
  transform: rotate(180deg);
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs {
  grid-area: sectionlist;
  margin: 0;
  padding: 0 0 2px;
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs[hidden] {
  display: none;
}

/* Section disclosure no-overlap override */
.collection-section-disclosure {
  grid-area: sections;
  display: grid;
  min-width: 0;
  gap: 8px;
}

.collection-section-disclosure .collection-sections-toggle,
.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs {
  grid-area: auto;
}

.collection-tab.is-section-detail .collection-section-disclosure .collection-section-tabs {
  max-width: 100%;
  overflow-x: auto;
}

/* Centered collection selector hero */
.collection-portfolio-hero {
  justify-items: center;
  text-align: center;
  border-left-color: rgba(255, 255, 255, 0.13);
  border-top: 3px solid rgba(255, 209, 102, 0.78);
}

.collection-portfolio-hero .collection-hero-section-row {
  justify-items: center;
  width: 100%;
  font-size: 1rem;
  letter-spacing: 0;
  text-transform: none;
}

.collection-detail-section-select-label {
  display: inline-grid;
  grid-template-columns: auto minmax(0, auto) 18px;
  gap: 6px;
  align-items: center;
  max-width: 100%;
  min-height: 42px;
  padding: 6px 10px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.075);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 14px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.collection-detail-section-select-label span {
  color: rgba(224, 231, 244, 0.66);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: none;
}

.collection-detail-section-select-label select {
  min-width: 0;
  max-width: min(48vw, 220px);
  color: #ffffff;
  background: transparent;
  border: 0;
  border-radius: 0;
  font: inherit;
  font-size: 0.94rem;
  font-weight: 950;
  text-align: center;
  text-overflow: ellipsis;
  -webkit-appearance: none;
  appearance: none;
}

.collection-detail-section-select-label select:focus {
  outline: none;
}

.collection-detail-section-select-label:focus-within {
  border-color: rgba(116, 204, 195, 0.45);
}

.collection-detail-section-select-label svg {
  width: 18px;
  height: 18px;
  color: #74ccc3;
  fill: currentColor;
}

.collection-portfolio-hero div {
  justify-items: center;
}

.collection-portfolio-hero div > strong,
.collection-portfolio-hero small {
  width: 100%;
  text-align: center;
}

/* Remove redundant section disclosure from toolbar */
.collection-portfolio-toolbar {
  grid-template-columns: 44px minmax(0, 1fr);
  grid-template-areas:
    "search search"
    "filter .";
}

.collection-portfolio-filter {
  width: 44px;
  height: 44px;
  padding: 11px;
}

/* Keep the primary-section star with the section selector */
.collection-detail-section-select-label {
  grid-template-columns: auto 22px minmax(0, auto) 18px;
}

.collection-main-section-star {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  color: #ffd166;
  background: transparent;
  border: 0;
  border-radius: 999px;
  filter: drop-shadow(0 0 10px rgba(255, 209, 102, 0.34));
}

.collection-main-section-star.is-active {
  color: #ffd166;
}

.collection-main-section-star svg {
  width: 100%;
  height: 100%;
  color: inherit;
  fill: currentColor;
}

.collection-main-section-star:not(.is-active) {
  color: rgba(224, 231, 244, 0.34);
  filter: none;
}

/* Keep the direct collection layout inside mobile viewport */
body.is-collection-detail,
body.is-collection-detail .collector-app,
.collection-tab.is-section-detail {
  overflow-x: hidden;
}

.collection-tab.is-section-detail {
  max-width: 100%;
}

.collection-detail-section-select-label select {
  max-width: min(40vw, 190px);
}

/* Original home portfolio pulse chart */
.portfolio-pulse-card {
  position: relative;
  isolation: isolate;
  gap: 16px;
  padding: 18px 14px 16px;
  overflow: hidden;
  background:
    linear-gradient(160deg, rgba(126, 164, 255, 0.14), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.032)),
    rgba(6, 9, 15, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 28px;
  box-shadow: 0 28px 72px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(22px);
}

.portfolio-pulse-card > * {
  min-width: 0;
}

.portfolio-pulse-card::before {
  content: "";
  position: absolute;
  inset: 0 20px auto;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(101, 197, 187, 0.9), rgba(255, 209, 102, 0.58), transparent);
  border-radius: 999px;
}

.portfolio-pulse-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.portfolio-mode-tabs {
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  min-width: 0;
  gap: clamp(6px, 2vw, 10px);
  overflow: hidden;
}

.portfolio-mode-tabs button {
  position: relative;
  min-height: 38px;
  padding: 0 2px;
  color: rgba(247, 248, 251, 0.48);
  background: transparent;
  border: 0;
  border-radius: 0;
  font-size: clamp(0.86rem, 3.65vw, 1.24rem);
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1;
  white-space: nowrap;
}

.portfolio-mode-tabs button::after {
  content: "";
  position: absolute;
  left: 2px;
  right: 2px;
  bottom: 0;
  height: 3px;
  background: transparent;
  border-radius: 999px;
}

.portfolio-mode-tabs button.is-active {
  color: #ffffff;
}

.portfolio-mode-tabs button.is-active::after {
  background: linear-gradient(90deg, #65c5bb, #7ea4ff);
}

.portfolio-currency-pill {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 8px;
  min-height: 36px;
  padding: 5px 10px 5px 6px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 950;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.portfolio-currency-pill span {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  color: #06110f;
  background: #65c5bb;
  border-radius: 999px;
  font-size: 1rem;
}

.portfolio-pulse-copy {
  display: grid;
  gap: 6px;
  padding: 4px 4px 0;
}

.portfolio-chart-copy {
  width: min(92%, 340px);
  margin: 2px auto -6px;
  padding: 0 8px;
  justify-items: center;
  text-align: center;
  pointer-events: none;
}

.portfolio-pulse-copy h2,
.portfolio-pulse-copy h2 strong,
.portfolio-pulse-copy > strong,
.portfolio-pulse-copy > span {
  display: block;
  min-width: 0;
}

.portfolio-pulse-copy h2 {
  margin: 0;
  color: #f7f8fb;
  font-size: clamp(1.36rem, 6vw, 2rem);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: 0;
}

.portfolio-collection-selector {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.35em;
  max-width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 6px;
  color: inherit;
  background: transparent;
  font: inherit;
  line-height: inherit;
  letter-spacing: inherit;
  text-align: center;
  pointer-events: auto;
  cursor: pointer;
}

.portfolio-collection-selector:focus-visible {
  outline: 2px solid rgba(126, 211, 202, 0.72);
  outline-offset: 4px;
}

.portfolio-collection-selector span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.portfolio-pulse-copy h2 strong {
  color: #65c5bb;
  font: inherit;
}

.portfolio-pulse-copy > strong {
  color: #ffffff;
  font-size: clamp(2.55rem, 13vw, 4.25rem);
  font-weight: 950;
  letter-spacing: 0;
  line-height: 0.94;
  max-width: 100%;
  white-space: nowrap;
  text-shadow: 0 12px 34px rgba(0, 0, 0, 0.32);
  font-variant-numeric: tabular-nums;
}

.portfolio-pulse-copy > span {
  color: #65c5bb;
  font-size: clamp(1.02rem, 4.6vw, 1.38rem);
  font-weight: 950;
  line-height: 1.15;
}

.portfolio-pulse-copy > span.negative {
  color: #ff917f;
}

.portfolio-pulse-copy > span.expense {
  color: #f6c66f;
}

.portfolio-chart-wrap {
  position: relative;
  min-width: 0;
  width: min(100vw, 430px);
  justify-self: start;
  margin: -12px calc(50% - min(50vw, 215px)) -6px;
  touch-action: pan-y;
}

#portfolioGraph {
  width: 100%;
  height: auto;
  aspect-ratio: 360 / 220;
  overflow: visible;
  cursor: ew-resize;
  outline: none;
}

#portfolioGraph:focus-visible {
  filter: drop-shadow(0 0 0 rgba(0, 0, 0, 0));
}

#portfolioGraph .graph-bg,
.portfolio-pulse-card .graph-bg {
  fill: rgba(1, 3, 7, 0.46);
}

.portfolio-pulse-card .graph-grid {
  stroke: rgba(255, 255, 255, 0.075);
  stroke-dasharray: 2 10;
  stroke-width: 1;
}

.portfolio-area-path {
  fill: url(#portfolioAreaFill);
  filter: drop-shadow(0 -8px 24px rgba(101, 197, 187, 0.1));
}

.portfolio-area-path.negative {
  filter: drop-shadow(0 -8px 24px rgba(255, 145, 127, 0.09));
}

.portfolio-area-path.expense {
  filter: drop-shadow(0 -8px 24px rgba(246, 198, 111, 0.1));
}

.portfolio-pulse-card .value-path {
  fill: none;
  stroke: #65c5bb;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 4.4;
  filter: drop-shadow(0 0 14px rgba(101, 197, 187, 0.2));
}

.portfolio-pulse-card .value-path.negative {
  stroke: #ff917f;
  filter: drop-shadow(0 0 14px rgba(255, 145, 127, 0.18));
}

.portfolio-pulse-card .value-path.expense {
  stroke: #f6c66f;
  filter: drop-shadow(0 0 14px rgba(246, 198, 111, 0.18));
}

.portfolio-pulse-card .cost-path {
  fill: none;
  stroke: rgba(255, 209, 102, 0.5);
  stroke-dasharray: 5 8;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2.3;
}

.portfolio-zero-line {
  stroke: rgba(255, 255, 255, 0.2);
  stroke-dasharray: 4 8;
  stroke-width: 1.2;
}

.portfolio-mid-dot {
  fill: rgba(247, 248, 251, 0.62);
}

.portfolio-focus {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 120ms ease, visibility 120ms ease;
}

.portfolio-focus.is-visible {
  opacity: 1;
  visibility: visible;
}

.portfolio-focus-line {
  stroke: rgba(255, 255, 255, 0.34);
  stroke-dasharray: 4 6;
  stroke-width: 1.15;
}

.portfolio-focus-ring {
  fill: rgba(101, 197, 187, 0.16);
  stroke: rgba(255, 255, 255, 0.86);
  stroke-width: 2.4;
}

.portfolio-focus-dot {
  fill: #65c5bb;
  stroke: #06110f;
  stroke-width: 1.8;
}

.portfolio-focus.negative .portfolio-focus-dot {
  fill: #ff917f;
}

.portfolio-focus.expense .portfolio-focus-dot {
  fill: #f6c66f;
}

.portfolio-chart-tooltip rect {
  fill: rgba(6, 10, 15, 0.9);
  stroke: rgba(126, 211, 202, 0.34);
  stroke-width: 1;
  filter: drop-shadow(0 12px 20px rgba(0, 0, 0, 0.34));
}

.portfolio-chart-tooltip text {
  fill: rgba(247, 248, 251, 0.68);
  font-size: 9.8px;
  font-weight: 520;
  letter-spacing: 0;
}

.portfolio-chart-tooltip .portfolio-tooltip-value {
  fill: #f8fbff;
  font-size: 11.4px;
  font-weight: 620;
}

.portfolio-chart-tooltip .portfolio-tooltip-move.positive {
  fill: #7ed3ca;
}

.portfolio-chart-tooltip .portfolio-tooltip-move.negative {
  fill: #ff917f;
}

.portfolio-chart-tooltip .portfolio-tooltip-move.expense {
  fill: #f6c66f;
}

.portfolio-hit-zone {
  fill: transparent;
  pointer-events: all;
}

.portfolio-pulse-card .graph-label {
  fill: rgba(247, 248, 251, 0.48);
  font-size: 11px;
  font-weight: 850;
}

.portfolio-range-tabs {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  margin-top: -6px;
  padding: 5px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.105);
  border-radius: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.portfolio-range-tabs button {
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
  min-height: 40px;
  padding: 0;
  color: rgba(247, 248, 251, 0.52);
  background: transparent;
  border: 0;
  border-radius: 13px;
  font-size: clamp(0.76rem, 3.1vw, 0.88rem);
  font-weight: 950;
  letter-spacing: 0;
}

.portfolio-range-tabs button::after {
  content: "";
  position: absolute;
  left: clamp(10px, 2.6vw, 14px);
  right: clamp(10px, 2.6vw, 14px);
  bottom: 6px;
  height: 2px;
  background: transparent;
  border-radius: 999px;
}

.portfolio-range-tabs button.is-active {
  color: #ffffff;
}

.portfolio-range-tabs button.is-active::after {
  background: linear-gradient(90deg, #65c5bb, #7ea4ff);
}

.realized-ledger-panel {
  --realized-sale-row-height: 82px;
  display: grid;
  gap: 12px;
  min-width: 0;
  padding-top: 2px;
}

.realized-ledger-panel[hidden] {
  display: none;
}

.realized-ledger-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  padding: 4px 2px 0;
}

.realized-ledger-head div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.realized-ledger-head span,
.realized-ledger-summary span,
.realized-sale-net span {
  color: rgba(247, 248, 251, 0.5);
  font-size: 0.68rem;
  font-weight: 520;
  letter-spacing: 0;
  line-height: 1.1;
  text-transform: uppercase;
}

.realized-ledger-head h3 {
  margin: 0;
  color: #f7f8fb;
  font-size: clamp(1.02rem, 4.2vw, 1.26rem);
  font-weight: 520;
  line-height: 1.05;
  letter-spacing: 0;
}

.realized-ledger-head button {
  flex: 0 0 auto;
  min-height: 36px;
  padding: 0 13px;
  color: #06110f;
  background: linear-gradient(135deg, #a7efe5, #7ea4ff);
  border: 0;
  border-radius: 12px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 520;
  letter-spacing: 0;
  box-shadow: 0 12px 24px rgba(126, 211, 202, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.32);
}

#realizedResetLedgerBtn {
  color: #ffb6aa;
  background: rgba(255, 145, 127, 0.08);
  border: 1px solid rgba(255, 145, 127, 0.24);
  box-shadow: none;
}

.realized-ledger-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.realized-ledger-summary article {
  min-width: 0;
  display: grid;
  gap: 4px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 13px;
}

.realized-ledger-summary strong {
  color: #f7f8fb;
  font-size: clamp(0.86rem, 3.5vw, 1rem);
  font-weight: 520;
  line-height: 1;
  overflow-wrap: anywhere;
}

.realized-ledger-summary article.is-positive strong,
.realized-sale-row.is-positive .realized-sale-net strong {
  color: #7ed3ca;
}

.realized-ledger-summary article.is-negative strong,
.realized-sale-row.is-negative .realized-sale-net strong {
  color: #ff917f;
}

.realized-ledger-summary article.is-expense strong,
.expense-purchase-row .realized-sale-net strong {
  color: #f6c66f;
}

.expense-breakdown {
  display: grid;
  gap: 8px;
  padding: 10px;
  background:
    linear-gradient(135deg, rgba(246, 198, 111, 0.095), rgba(126, 164, 255, 0.055)),
    rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(246, 198, 111, 0.13);
  border-radius: 14px;
}

.expense-category-row {
  display: grid;
  grid-template-columns: minmax(76px, 0.9fr) minmax(72px, 1fr) auto;
  gap: 9px;
  align-items: center;
  min-width: 0;
}

.expense-category-row div:first-child {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.expense-category-row strong,
.expense-category-row span,
.expense-category-row em {
  display: block;
  min-width: 0;
  letter-spacing: 0;
}

.expense-category-row strong {
  overflow: hidden;
  color: #f7f8fb;
  font-size: 0.78rem;
  font-weight: 520;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.expense-category-row span {
  color: rgba(247, 248, 251, 0.5);
  font-size: 0.68rem;
  font-weight: 400;
  line-height: 1.12;
}

.expense-category-meter {
  position: relative;
  height: 7px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.075);
  border-radius: 999px;
}

.expense-category-bar {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--expense-category-width, 0%);
  background: linear-gradient(90deg, #f6c66f, #7ed3ca);
  border-radius: inherit;
}

.expense-category-row em {
  color: #f6c66f;
  font-size: 0.76rem;
  font-style: normal;
  font-weight: 520;
  line-height: 1;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.expense-breakdown-empty {
  display: grid;
  gap: 4px;
  color: rgba(247, 248, 251, 0.58);
  text-align: center;
}

.expense-breakdown-empty strong {
  color: #f7f8fb;
  font-size: 0.84rem;
  font-weight: 520;
}

.expense-breakdown-empty span {
  font-size: 0.74rem;
  font-weight: 400;
  line-height: 1.28;
}

.expense-purchase-row {
  border-color: rgba(246, 198, 111, 0.12);
}

.expense-purchase-row .realized-sale-image {
  background: linear-gradient(145deg, #f6c66f, #7ed3ca);
}

.realized-ledger-list {
  display: grid;
  gap: 8px;
  max-height: calc((var(--realized-sale-row-height) * 3) + 16px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 2px;
  scroll-padding-block: 2px;
  scroll-snap-type: y proximity;
  scrollbar-color: rgba(126, 211, 202, 0.55) rgba(255, 255, 255, 0.06);
  scrollbar-width: thin;
}

.realized-ledger-list::-webkit-scrollbar {
  width: 6px;
}

.realized-ledger-list::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
}

.realized-ledger-list::-webkit-scrollbar-thumb {
  background: rgba(126, 211, 202, 0.56);
  border-radius: 999px;
}

.realized-sale-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 9px;
  background: rgba(3, 6, 11, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  min-height: var(--realized-sale-row-height);
  scroll-snap-align: start;
}

.realized-sale-image {
  display: grid;
  place-items: center;
  width: 44px;
  aspect-ratio: 0.716;
  overflow: hidden;
  color: #06110f;
  background: linear-gradient(145deg, #7ed3ca, #7ea4ff);
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 520;
}

.realized-sale-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.realized-sale-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.realized-sale-copy strong,
.realized-sale-copy span,
.realized-sale-copy small,
.realized-sale-net strong {
  display: block;
  min-width: 0;
}

.realized-sale-copy strong {
  overflow: hidden;
  color: #f7f8fb;
  font-size: 0.88rem;
  font-weight: 520;
  line-height: 1.12;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.realized-sale-copy span,
.realized-sale-copy small {
  color: rgba(247, 248, 251, 0.55);
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.22;
  overflow-wrap: anywhere;
}

.realized-sale-net {
  display: grid;
  gap: 4px;
  justify-items: end;
  min-width: 76px;
  text-align: right;
}

.realized-sale-net strong {
  color: #f7f8fb;
  font-size: 0.9rem;
  font-weight: 520;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.realized-sale-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.realized-sale-actions button {
  min-height: 26px;
  padding: 0 8px;
  color: rgba(247, 248, 251, 0.72);
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 9px;
  font: inherit;
  font-size: 0.65rem;
  font-weight: 520;
  letter-spacing: 0;
}

.realized-sale-actions button[data-realized-sale-action="delete"] {
  color: #ffb6aa;
  border-color: rgba(255, 145, 127, 0.22);
}

.realized-ledger-empty {
  display: grid;
  gap: 5px;
  padding: 14px;
  color: rgba(247, 248, 251, 0.62);
  text-align: center;
  background: rgba(255, 255, 255, 0.045);
  border: 1px dashed rgba(126, 211, 202, 0.22);
  border-radius: 14px;
}

.realized-ledger-empty strong {
  color: #f7f8fb;
  font-size: 0.9rem;
  font-weight: 520;
}

.realized-ledger-empty span {
  font-size: 0.78rem;
  font-weight: 400;
  line-height: 1.3;
}

.portfolio-pulse-footer {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 12px;
  padding: 0 4px;
}

.portfolio-pulse-footer span,
.portfolio-pulse-footer strong,
.portfolio-pulse-footer small {
  display: block;
}

.portfolio-pulse-footer span {
  color: rgba(247, 248, 251, 0.52);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portfolio-pulse-footer strong {
  margin-top: 3px;
  color: #65c5bb;
  font-size: 1.12rem;
  font-weight: 950;
  line-height: 1;
}

.portfolio-pulse-footer strong.negative {
  color: #ff917f;
}

.portfolio-pulse-footer small {
  max-width: 50%;
  color: rgba(247, 248, 251, 0.6);
  font-size: 0.8rem;
  font-weight: 850;
  text-align: right;
}

.portfolio-pulse-card #portfolioGraphSummary {
  margin: -6px 4px 0;
  color: rgba(247, 248, 251, 0.55);
  font-size: 0.82rem;
  line-height: 1.35;
}

@media (max-width: 370px) {
  .portfolio-pulse-card {
    padding-inline: 12px;
  }

  .realized-ledger-panel {
    --realized-sale-row-height: 108px;
  }

  .portfolio-pulse-top {
    align-items: flex-start;
    gap: 8px;
  }

  .portfolio-mode-tabs {
    gap: 6px;
  }

  .portfolio-currency-pill {
    padding-right: 8px;
    font-size: 0.78rem;
  }

  .portfolio-range-tabs {
    gap: 4px;
  }

  .portfolio-range-tabs button {
    min-height: 36px;
    font-size: 0.8rem;
  }

  .realized-ledger-summary {
    grid-template-columns: 1fr;
  }

  .realized-sale-row {
    grid-template-columns: 38px minmax(0, 1fr);
  }

  .realized-sale-image {
    width: 38px;
  }

  .realized-sale-net {
    grid-column: 2;
    justify-items: start;
    min-width: 0;
    text-align: left;
  }

  .realized-sale-actions {
    justify-content: flex-start;
  }

  .expense-category-row {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .expense-category-meter {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

/* Vendor show-floor workspace */
.vendor-tab {
  gap: 14px;
  min-width: 0;
  max-width: 100%;
  overflow-x: hidden;
}

.vendor-tab,
.vendor-tab * {
  font-family: var(--app-ui-font);
}

.vendor-hero-card,
.vendor-deal-card,
.vendor-ledger-card,
.vendor-batch-card,
.vendor-summary-grid article {
  min-width: 0;
  max-width: 100%;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.032)),
    rgba(8, 12, 18, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(22px);
}

.vendor-hero-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px;
  background:
    linear-gradient(135deg, rgba(255, 209, 102, 0.16), transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.032)),
    rgba(8, 12, 18, 0.92);
}

.vendor-hero-card h2,
.vendor-section-head h2 {
  margin: 0;
  color: #ffffff;
  font-size: 1.45rem;
  font-weight: 950;
  line-height: 1;
  letter-spacing: 0;
}

.vendor-hero-card span {
  display: block;
  margin-top: 7px;
  color: rgba(247, 248, 251, 0.62);
  font-size: 0.9rem;
  font-weight: 850;
}

.vendor-hero-card button {
  display: grid;
  place-items: center;
  gap: 4px;
  min-width: 72px;
  min-height: 60px;
  color: #06110f;
  background: #ffd166;
  border: 1px solid #ffd166;
  border-radius: 18px;
  font-weight: 950;
}

.vendor-hero-card button svg {
  width: 1.35rem;
  height: 1.35rem;
}

.vendor-hero-card button span {
  margin-top: 0;
  color: inherit;
  font-size: 0.78rem;
  line-height: 1;
}

.vendor-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.vendor-quick-actions {
  display: flex;
  justify-content: center;
}

.vendor-quick-actions button {
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 8px;
  width: min(100%, 360px);
  min-width: 0;
  min-height: 106px;
  padding: 16px;
  color: #f7f8fb;
  text-align: center;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.035)),
    rgba(8, 12, 18, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 18px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
}

.vendor-quick-actions button.primary {
  width: min(100%, 360px);
  color: #06110f;
  background: #ffd166;
  border-color: #ffd166;
}

.vendor-quick-actions svg {
  width: 1.4rem;
  height: 1.4rem;
}

.vendor-quick-actions strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 950;
  line-height: 1.05;
}

.vendor-quick-actions span {
  display: block;
  color: rgba(247, 248, 251, 0.62);
  font-size: 0.72rem;
  font-weight: 850;
  line-height: 1.2;
}

.vendor-quick-actions button.primary span {
  color: rgba(6, 17, 15, 0.62);
}

.vendor-summary-grid article {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 14px;
  border-radius: 18px;
}

.vendor-summary-grid span,
.vendor-quote-strip span,
.vendor-ledger-line span {
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.vendor-summary-grid strong {
  color: #f7f8fb;
  font-size: clamp(1.24rem, 6vw, 1.75rem);
  font-weight: 950;
  line-height: 1;
  overflow-wrap: anywhere;
}

.vendor-summary-grid .positive strong,
.vendor-quote-strip .positive strong,
.vendor-line-side.positive strong {
  color: #65c5bb;
}

.vendor-summary-grid .negative strong,
.vendor-quote-strip .negative strong,
.vendor-line-side.negative strong {
  color: #ff917f;
}

.vendor-deal-card,
.vendor-ledger-card,
.vendor-batch-card {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.vendor-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.vendor-section-head > span {
  display: grid;
  place-items: center;
  min-height: 34px;
  padding: 0 12px;
  color: #06110f;
  background: #65c5bb;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 950;
}

.vendor-deal-form {
  display: grid;
  gap: 12px;
}

.vendor-mode-toggle {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  padding: 5px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 16px;
}

.vendor-mode-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.vendor-mode-toggle span {
  display: grid;
  place-items: center;
  min-height: 38px;
  color: rgba(247, 248, 251, 0.56);
  border-radius: 12px;
  font-size: clamp(0.78rem, 3.4vw, 0.88rem);
  font-weight: 950;
}

.vendor-mode-toggle input:checked + span {
  color: #ffffff;
  background:
    linear-gradient(135deg, rgba(255, 209, 102, 0.34), rgba(101, 197, 187, 0.18)),
    rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.vendor-deal-form label {
  display: grid;
  gap: 7px;
  min-width: 0;
  color: rgba(247, 248, 251, 0.68);
  font-size: 0.76rem;
  font-weight: 900;
}

.vendor-deal-form input {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  color: #ffffff;
  background: rgba(3, 6, 10, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 14px;
  font-size: 0.96rem;
  font-weight: 850;
}

.vendor-deal-form input::placeholder {
  color: rgba(247, 248, 251, 0.36);
}

.vendor-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.vendor-quote-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.vendor-quote-strip article {
  min-width: 0;
  padding: 11px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.105);
  border-radius: 15px;
}

.vendor-quote-strip strong {
  display: block;
  margin-top: 5px;
  color: #ffffff;
  font-size: 1.06rem;
  font-weight: 950;
  line-height: 1;
  overflow-wrap: anywhere;
}

.vendor-form-actions,
.vendor-ledger-actions,
.vendor-batch-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.vendor-batch-actions {
  grid-template-columns: auto;
  justify-content: end;
}

.vendor-form-actions button,
.vendor-ledger-actions button,
.vendor-batch-actions button,
.vendor-line-actions button {
  min-height: 42px;
  padding: 0 14px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  font-weight: 950;
}

.vendor-form-actions button:first-child {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.vendor-batch-actions button:disabled {
  opacity: 0.48;
}

.vendor-batch-panel {
  display: grid;
  gap: 10px;
}

.vendor-batch-empty {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 13px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.105);
  border-radius: 16px;
}

.vendor-batch-empty strong {
  color: #ffffff;
  font-size: 0.98rem;
  font-weight: 950;
}

.vendor-batch-empty span,
.vendor-batch-list p {
  margin: 0;
  color: rgba(247, 248, 251, 0.62);
  font-size: 0.78rem;
  line-height: 1.32;
  font-weight: 800;
}

.vendor-batch-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.vendor-batch-stats article {
  min-width: 0;
  padding: 11px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.105);
  border-radius: 15px;
}

.vendor-batch-stats span,
.vendor-batch-list small {
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.vendor-batch-stats strong,
.vendor-batch-list strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-weight: 950;
  line-height: 1.05;
}

.vendor-batch-stats .positive strong {
  color: #65c5bb;
}

.vendor-batch-stats .negative strong {
  color: #ff917f;
}

.vendor-batch-list {
  display: grid;
  gap: 8px;
}

.vendor-batch-list article {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  min-width: 0;
  padding: 9px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 14px;
}

.vendor-batch-list img,
.vendor-line-thumb {
  width: 42px;
  height: 58px;
  object-fit: cover;
  background: rgba(3, 6, 10, 0.8);
  border-radius: 7px;
}

.vendor-batch-list span {
  min-width: 0;
}

.vendor-batch-list strong,
.vendor-batch-list small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vendor-ledger-list {
  display: grid;
  gap: 10px;
}

.vendor-ledger-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  min-width: 0;
  padding: 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.052);
  border: 1px solid rgba(255, 255, 255, 0.105);
  border-radius: 17px;
}

.vendor-ledger-line.has-thumb {
  grid-template-columns: auto minmax(0, 1fr) auto;
}

.vendor-line-main {
  min-width: 0;
}

.vendor-line-main strong,
.vendor-line-main small,
.vendor-line-main p {
  display: block;
  min-width: 0;
}

.vendor-line-main strong {
  margin-top: 4px;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 950;
  line-height: 1.12;
}

.vendor-line-main small,
.vendor-line-main p {
  margin: 5px 0 0;
  color: rgba(247, 248, 251, 0.6);
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.28;
}

.vendor-line-main .vendor-line-save-note {
  color: rgba(101, 197, 187, 0.86);
}

.vendor-line-side {
  display: grid;
  justify-items: end;
  gap: 8px;
}

.vendor-line-side strong {
  font-size: 0.98rem;
  font-weight: 950;
}

.vendor-line-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  min-width: 76px;
  width: 100%;
}

.vendor-line-actions button {
  min-height: 32px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.74rem;
}

.vendor-line-add {
  color: #cffff8;
  background: rgba(101, 197, 187, 0.18);
  border-color: rgba(101, 197, 187, 0.34);
}

.vendor-line-add[disabled] {
  color: rgba(247, 248, 251, 0.5);
  background: rgba(255, 255, 255, 0.055);
  border-color: rgba(255, 255, 255, 0.1);
  opacity: 1;
}

.vendor-line-delete {
  color: #f7f8fb;
}

@media (max-width: 360px) {
  .vendor-deal-card,
  .vendor-ledger-card,
  .vendor-batch-card,
  .vendor-hero-card {
    padding-inline: 14px;
  }

  .vendor-form-grid,
  .vendor-quote-strip {
    gap: 8px;
  }

  .vendor-deal-form input {
    padding-inline: 10px;
    font-size: 0.9rem;
  }

  .vendor-form-actions {
    grid-template-columns: minmax(0, 1fr) 72px;
  }

  .vendor-quick-actions {
    gap: 8px;
  }

  .vendor-quick-actions button {
    min-height: 88px;
    padding: 12px;
  }
}

/* App menu and appearance settings */
.app-menu-overlay[hidden] {
  display: none;
}

.app-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  align-items: end;
  justify-items: center;
}

.app-menu-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(8px);
}

.app-menu-panel {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 14px;
  width: min(430px, calc(100% - 24px));
  max-height: min(760px, calc(var(--mobile-page-height) - 28px));
  margin-bottom: max(12px, env(safe-area-inset-bottom));
  padding: 16px;
  overflow: auto;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.035)),
    rgba(8, 12, 18, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  box-shadow: 0 34px 86px rgba(0, 0, 0, 0.52);
}

.app-menu-head,
.app-setting-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.app-menu-head h2 {
  margin: 0;
  color: #ffffff;
  font-size: 1.55rem;
  font-weight: 950;
  line-height: 1;
}

.app-menu-head span,
.app-account-card p,
.app-setting-row span,
.app-menu-tool span {
  color: rgba(247, 248, 251, 0.62);
  font-size: 0.84rem;
  font-weight: 800;
  line-height: 1.32;
}

.app-menu-head button {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
}

.app-menu-tabs,
.theme-toggle {
  display: grid;
  gap: 6px;
  padding: 5px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 16px;
}

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

.theme-toggle {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  min-width: 204px;
}

.app-menu-tabs button,
.theme-toggle button,
.app-menu-action-row button,
.app-setting-row > button {
  min-height: 38px;
  padding: 0 10px;
  color: rgba(247, 248, 251, 0.62);
  background: transparent;
  border: 0;
  border-radius: 12px;
  font-size: 0.84rem;
  font-weight: 950;
}

.app-menu-tabs button.is-active,
.theme-toggle button.is-active {
  color: #06110f;
  background: #65c5bb;
}

.app-menu-section {
  display: grid;
  gap: 12px;
}

.app-menu-section[hidden] {
  display: none;
}

.app-account-card,
.app-setting-row,
.app-menu-tool {
  min-width: 0;
  padding: 14px;
  color: #f7f8fb;
  text-align: left;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 18px;
}

.app-account-profile {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-width: 0;
}

.app-account-avatar {
  position: relative;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 58px;
  height: 58px;
  padding: 0;
  overflow: hidden;
  color: #06110f;
  background: linear-gradient(135deg, #65c5bb, #ffd166);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 16px;
}

.app-account-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.app-account-avatar img[hidden] {
  display: none;
}

.app-account-avatar b {
  font-size: 1rem;
  font-weight: 950;
  letter-spacing: 0;
}

.app-account-identity {
  min-width: 0;
}

.app-account-card span {
  display: inline-grid;
  place-items: center;
  min-height: 28px;
  padding: 0 10px;
  color: #06110f;
  background: #ffd166;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.app-avatar-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 12px;
}

.app-avatar-actions[hidden] {
  display: none;
}

.app-avatar-actions button {
  min-height: 36px;
  padding: 0 10px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 950;
}

.app-avatar-actions button:first-of-type {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.app-avatar-actions button:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.app-account-card strong,
.app-setting-row strong,
.app-menu-tool strong {
  display: block;
  margin-top: 9px;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 950;
  line-height: 1.1;
}

.app-setting-row strong {
  margin-top: 0;
}

.app-menu-action-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.app-menu-action-row.is-single {
  grid-template-columns: minmax(0, 1fr);
}

.app-menu-action-row [hidden] {
  display: none !important;
}

.app-menu-action-row button,
.app-setting-row > button {
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.app-menu-action-row button:first-child,
.app-setting-row > button {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.app-menu-action-row button:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.app-account-management {
  display: grid;
  gap: 10px;
}

.app-account-management[hidden] {
  display: none;
}

.app-account-manager-section {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 13px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
}

.app-account-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.app-account-section-head span,
.app-account-field span,
.app-account-session-info,
.app-account-copy,
.app-account-facts span,
.app-account-status {
  color: rgba(247, 248, 251, 0.62);
  font-size: 0.78rem;
  font-weight: 850;
  line-height: 1.32;
}

.app-account-section-head strong {
  color: #ffffff;
  font-size: 0.98rem;
  font-weight: 950;
  line-height: 1.1;
  text-align: right;
}

.app-account-field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.app-account-field input {
  width: 100%;
  min-height: 42px;
  padding: 0 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.075);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 12px;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 850;
  outline: none;
}

.app-account-field input:focus {
  border-color: rgba(101, 197, 187, 0.9);
  box-shadow: 0 0 0 3px rgba(101, 197, 187, 0.16);
}

.app-account-field input[readonly] {
  color: rgba(247, 248, 251, 0.66);
  background: rgba(255, 255, 255, 0.045);
}

.app-account-danger-field input {
  border-color: rgba(255, 154, 154, 0.3);
}

.app-account-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.app-account-facts span {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 9px 10px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 12px;
}

.app-account-facts b {
  overflow-wrap: anywhere;
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 950;
}

.app-account-session-info,
.app-account-copy,
.app-account-status {
  margin: 0;
}

.app-account-status {
  min-height: 16px;
}

.app-account-status.is-error {
  color: #ffb7b7;
}

.app-account-status.is-success {
  color: #8ce8bf;
}

.app-account-status.is-warning {
  color: #ffd166;
}

.app-account-manager-section > button,
.app-account-management-actions button {
  min-height: 40px;
  padding: 0 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  font-size: 0.84rem;
  font-weight: 950;
}

.app-account-manager-section > button,
.app-account-management-actions button:first-child {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.app-account-management-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.app-account-management-actions.is-single {
  grid-template-columns: minmax(0, 1fr);
}

#appAccountDeleteAccountBtn {
  color: #200909;
  background: #ff9a9a;
  border-color: #ff9a9a;
}

#appAccountDeleteAccountBtn:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.app-account-manager-section button:disabled,
.app-account-management-actions button:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.app-menu-tool {
  display: grid;
  gap: 5px;
  width: 100%;
}

.app-menu-tool strong {
  margin-top: 0;
}

.app-auth-sheet[hidden] {
  display: none;
}

.app-auth-sheet {
  position: fixed;
  inset: 0;
  z-index: 92;
  display: grid;
  align-items: end;
  justify-items: center;
}

.app-auth-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.64);
  backdrop-filter: blur(10px);
}

.app-auth-panel {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 14px;
  width: min(430px, calc(100% - 24px));
  margin-bottom: max(12px, env(safe-area-inset-bottom));
  padding: 16px;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.035)),
    rgba(10, 14, 20, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  box-shadow: 0 34px 86px rgba(0, 0, 0, 0.58);
}

.app-auth-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.app-auth-head h2 {
  margin: 0;
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 950;
  line-height: 1.05;
}

.app-auth-head span,
.app-auth-field span,
.app-auth-status {
  color: rgba(247, 248, 251, 0.64);
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.34;
}

.app-auth-close {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
}

.app-auth-mode {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  padding: 5px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 16px;
}

.app-auth-mode button {
  min-height: 38px;
  padding: 0 10px;
  color: rgba(247, 248, 251, 0.62);
  background: transparent;
  border: 0;
  border-radius: 12px;
  font-size: 0.84rem;
  font-weight: 950;
}

.app-auth-mode button.is-active {
  color: #06110f;
  background: #65c5bb;
}

.app-auth-mode[hidden] {
  display: none;
}

.app-auth-field {
  display: grid;
  gap: 7px;
}

.app-auth-field[hidden] {
  display: none;
}

.app-auth-field input {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.085);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 13px;
  font: inherit;
  font-size: 1rem;
  font-weight: 800;
  outline: none;
}

.app-auth-field input:focus {
  border-color: rgba(101, 197, 187, 0.9);
  box-shadow: 0 0 0 3px rgba(101, 197, 187, 0.18);
}

.app-auth-status {
  min-height: 18px;
  margin: 0;
}

.app-auth-inline-actions {
  display: flex;
  justify-content: flex-end;
  min-height: 22px;
  margin-top: -6px;
}

.app-auth-inline-actions[hidden] {
  display: none;
}

.app-auth-text-action {
  min-height: 28px;
  padding: 0;
  color: #9fded8;
  background: transparent;
  border: 0;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.app-auth-text-action:disabled {
  color: rgba(247, 248, 251, 0.34);
}

.app-auth-status.is-error {
  color: #ffb7b7;
}

.app-auth-status.is-success {
  color: #8ce8bf;
}

.app-auth-resend {
  justify-self: start;
  min-height: 34px;
  padding: 0;
  color: #9fded8;
  background: transparent;
  border: 0;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.app-auth-resend[hidden] {
  display: none;
}

.app-auth-resend:disabled {
  color: rgba(247, 248, 251, 0.34);
}

.app-auth-actions {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 8px;
}

.app-auth-actions button {
  min-height: 42px;
  padding: 0 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 13px;
  font-size: 0.88rem;
  font-weight: 950;
}

.app-auth-actions button[type="submit"] {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

.app-auth-actions button:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.app-admin-sheet[hidden] {
  display: none;
}

.app-admin-sheet {
  position: fixed;
  inset: 0;
  z-index: 94;
  display: grid;
  align-items: end;
  justify-items: center;
}

.app-admin-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.66);
  backdrop-filter: blur(10px);
}

.app-admin-panel {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 14px;
  width: min(430px, calc(100% - 24px));
  max-height: min(760px, calc(var(--mobile-page-height) - 28px));
  margin-bottom: max(12px, env(safe-area-inset-bottom));
  padding: 16px;
  overflow: auto;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.035)),
    rgba(10, 14, 20, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  box-shadow: 0 34px 86px rgba(0, 0, 0, 0.58);
}

.app-admin-head,
.admin-health-summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.app-admin-head h2 {
  margin: 0;
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 950;
  line-height: 1.05;
}

.app-admin-head span,
.admin-health-card span,
.admin-health-summary span,
.admin-health-summary time {
  color: rgba(247, 248, 251, 0.64);
  font-size: 0.78rem;
  font-weight: 850;
  line-height: 1.32;
}

.app-admin-close {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
}

.app-admin-health-body {
  display: grid;
  gap: 12px;
}

.scan-lab-sheet[hidden] {
  display: none;
}

.scan-lab-sheet {
  position: fixed;
  inset: 0;
  z-index: 1205;
  display: grid;
  place-items: stretch;
  padding: max(12px, env(safe-area-inset-top)) 12px max(12px, env(safe-area-inset-bottom));
  overflow: auto;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(5, 8, 13, 0.94), rgba(5, 8, 13, 0.98)),
    #05070b;
}

.scan-lab-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 14px;
  width: min(620px, 100%);
  min-height: min(760px, calc(var(--mobile-page-height) - 24px));
  margin: 0 auto;
}

.scan-lab-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 18px;
}

.scan-lab-head h2 {
  margin: 2px 0;
  color: #ffffff;
  font-size: 1.45rem;
  line-height: 1.05;
}

.scan-lab-head span {
  color: rgba(247, 248, 251, 0.68);
  font-size: 0.82rem;
  font-weight: 850;
}

.scan-lab-close {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
}

.scan-lab-close svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.scan-lab-body {
  display: grid;
  gap: 14px;
  align-content: start;
}

.scan-lab-capture,
.scan-lab-form,
.scan-lab-results {
  display: grid;
  gap: 12px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
}

.scan-lab-camera-button {
  display: grid;
  place-items: center;
  min-height: 48px;
  color: #05100e;
  border: 0;
  font-weight: 950;
  font-family: inherit;
  background: #65c5bb;
  border-radius: 14px;
  text-align: center;
}

.scan-lab-frame-button {
  background: #a8bdff;
}

.scan-lab-camera-button input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  opacity: 0;
  pointer-events: none;
}

.scan-lab-preview {
  display: grid;
  place-items: center;
  min-height: 220px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.34);
  border: 1px dashed rgba(255, 255, 255, 0.18);
  border-radius: 16px;
}

.scan-lab-preview img {
  width: 100%;
  max-height: 360px;
  object-fit: contain;
}

.scan-lab-form label {
  display: grid;
  gap: 6px;
  color: rgba(247, 248, 251, 0.7);
  font-size: 0.78rem;
  font-weight: 850;
}

.scan-lab-form input,
.scan-lab-form select,
.scan-lab-form textarea {
  width: 100%;
  min-height: 44px;
  color: #f7f8fb;
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 12px;
}

.scan-lab-form textarea {
  padding: 10px 12px;
  resize: vertical;
}

.scan-lab-check {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
}

.scan-lab-check input {
  width: 20px;
  min-height: 20px;
}

.scan-lab-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.scan-lab-actions button {
  min-height: 46px;
  color: #f7f8fb;
  font-weight: 950;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
}

.scan-lab-actions button:first-child {
  color: #05100e;
  background: #65c5bb;
  border-color: #65c5bb;
}

.scan-lab-result-grid {
  display: grid;
  gap: 10px;
}

.scan-lab-result-card,
.scan-lab-compare {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
}

.scan-lab-result-card header,
.scan-lab-compare header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.scan-lab-result-card dl {
  display: grid;
  gap: 7px;
  margin: 0;
}

.scan-lab-result-card dl div {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 10px;
}

.scan-lab-result-card dt {
  color: rgba(247, 248, 251, 0.55);
  font-size: 0.74rem;
  font-weight: 900;
}

.scan-lab-result-card dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
  color: #ffffff;
  font-weight: 850;
}

.scan-lab-error {
  margin: 0;
  color: #ffb9a8;
  font-size: 0.84rem;
  font-weight: 850;
}

.scan-lab-compare {
  overflow-x: auto;
}

.scan-lab-compare table {
  width: 100%;
  min-width: 480px;
  border-collapse: collapse;
  font-size: 0.82rem;
}

.scan-lab-compare th,
.scan-lab-compare td {
  padding: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  text-align: left;
}

.admin-health-summary {
  padding: 12px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 16px;
}

.admin-cache-health {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: rgba(101, 197, 187, 0.09);
  border: 1px solid rgba(101, 197, 187, 0.28);
  border-radius: 16px;
}

.admin-cache-health.is-warn {
  background: rgba(255, 209, 102, 0.08);
  border-color: rgba(255, 209, 102, 0.32);
}

.admin-cache-health-head,
.admin-cache-foot {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.admin-cache-health-head strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 950;
  line-height: 1.12;
}

.admin-cache-health-head span,
.admin-cache-foot,
.admin-cache-metric span {
  color: rgba(247, 248, 251, 0.66);
  font-size: 0.74rem;
  font-weight: 850;
  line-height: 1.28;
}

.admin-cache-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.admin-cache-metric {
  min-width: 0;
  display: grid;
  gap: 5px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 12px;
}

.admin-cache-metric strong {
  min-width: 0;
  color: #ffffff;
  font-size: 1.08rem;
  font-weight: 950;
  line-height: 1;
  overflow-wrap: anywhere;
}

.admin-usage-breakdown {
  display: grid;
  gap: 8px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
}

.admin-usage-breakdown-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.admin-usage-breakdown-head span,
.admin-usage-list p,
.admin-usage-row b {
  margin: 0;
  color: rgba(247, 248, 251, 0.64);
  font-size: 0.72rem;
  font-weight: 850;
  line-height: 1.25;
}

.admin-usage-breakdown-head strong,
.admin-usage-list strong {
  min-width: 0;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 950;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.admin-usage-list {
  min-width: 0;
  display: grid;
  gap: 6px;
  padding: 8px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 8px;
}

.admin-usage-row {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 8px;
}

.admin-usage-row span {
  min-width: 0;
  color: rgba(247, 248, 251, 0.9);
  font-size: 0.74rem;
  font-weight: 900;
  line-height: 1.22;
  overflow-wrap: anywhere;
}

.admin-usage-row b {
  text-align: right;
  overflow-wrap: anywhere;
}

.admin-cache-warning {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 9px 10px;
  color: rgba(255, 240, 185, 0.9);
  background: rgba(255, 209, 102, 0.1);
  border: 1px solid rgba(255, 209, 102, 0.22);
  border-radius: 10px;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.admin-cache-warning strong {
  color: #fff2bd;
  font-size: 0.74rem;
}

.admin-cache-warning time {
  color: rgba(247, 248, 251, 0.62);
}

.admin-cache-foot {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.admin-cache-foot time {
  margin-left: auto;
}

.admin-health-summary strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.admin-health-summary time {
  text-align: right;
}

.admin-support-lookup {
  display: grid;
  gap: 10px;
  padding: 12px;
  background: rgba(168, 189, 255, 0.08);
  border: 1px solid rgba(168, 189, 255, 0.24);
  border-radius: 16px;
}

.admin-support-lookup-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.admin-support-lookup-head span,
.admin-support-lookup-head b,
.admin-support-status,
.admin-support-facts span,
.admin-support-count span,
.admin-support-count b {
  color: rgba(247, 248, 251, 0.66);
  font-size: 0.74rem;
  font-weight: 850;
  line-height: 1.28;
}

.admin-support-lookup-head strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 950;
  line-height: 1.12;
}

.admin-support-lookup-head b {
  flex: 0 0 auto;
  padding: 5px 8px;
  color: #dbe4ff;
  background: rgba(168, 189, 255, 0.12);
  border: 1px solid rgba(168, 189, 255, 0.24);
  border-radius: 999px;
}

.admin-support-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.admin-support-form input {
  min-width: 0;
  min-height: 42px;
  padding: 0 12px;
  color: #f7f8fb;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 12px;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 850;
}

.admin-support-form button {
  min-height: 42px;
  padding: 0 14px;
  color: #06110f;
  background: #65c5bb;
  border: 1px solid #65c5bb;
  border-radius: 12px;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 950;
}

.admin-support-form button:disabled,
.admin-support-form input:disabled {
  opacity: 0.58;
}

.admin-support-status {
  min-height: 1em;
  margin: 0;
}

.admin-support-status.is-success {
  color: #9af0c5;
}

.admin-support-status.is-error {
  color: #ffb9a8;
}

.admin-support-result {
  display: grid;
  gap: 10px;
  padding: 10px;
  background: rgba(0, 0, 0, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 12px;
}

.admin-support-result header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.admin-support-result header span {
  color: rgba(247, 248, 251, 0.66);
  font-size: 0.74rem;
  font-weight: 850;
}

.admin-support-result header strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-size: 0.94rem;
  font-weight: 950;
  line-height: 1.12;
  overflow-wrap: anywhere;
}

.admin-support-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-support-facts span {
  min-width: 0;
  display: grid;
  gap: 4px;
  padding: 8px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 8px;
}

.admin-support-facts b {
  min-width: 0;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.admin-support-count-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-support-count {
  min-width: 0;
  display: grid;
  gap: 5px;
  padding: 9px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 8px;
}

.admin-support-count strong {
  color: #ffffff;
  font-size: 1rem;
  font-weight: 950;
  line-height: 1;
}

.admin-health-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.admin-health-card {
  min-width: 0;
  display: grid;
  gap: 6px;
  padding: 11px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 14px;
}

.admin-health-card.is-warn {
  border-color: rgba(255, 209, 102, 0.32);
}

.admin-health-card strong {
  min-width: 0;
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 950;
  line-height: 1.12;
}

.admin-health-card b {
  color: #f7f8fb;
  font-size: 1.15rem;
  font-weight: 950;
}

.admin-health-pill {
  justify-self: start;
  min-height: 24px;
  padding: 4px 8px;
  color: #06110f;
  background: #65c5bb;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 950;
}

.admin-health-pill.is-warn {
  color: #211900;
  background: #ffd166;
}

@media (max-width: 520px) {
  .admin-cache-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-support-form,
  .admin-support-facts,
  .admin-support-count-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .admin-cache-foot time {
    width: 100%;
    margin-left: 0;
  }
}

body.is-menu-open,
body.is-auth-sheet-open,
body.is-admin-sheet-open {
  overflow: hidden;
}

/* MEMORY LINE: SHARED TRADE LINK START */
body.is-shared-trade-route .bottom-nav {
  display: none;
}

.shared-trade-view {
  position: relative;
  display: grid;
  gap: 14px;
  width: min(980px, 100%);
  min-height: var(--mobile-page-height);
  margin: 0 auto;
  padding: 14px 12px max(104px, env(safe-area-inset-bottom));
  color: #f7f8fb;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
}

.shared-trade-view[hidden] {
  display: none;
}

.shared-trade-header {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-width: 0;
  padding: 12px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(126, 211, 202, 0.055)),
    rgba(7, 13, 24, 0.72);
  border: 1px solid rgba(126, 211, 202, 0.16);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 18px 44px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(18px);
}

.shared-trade-header button {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
}

.shared-trade-header svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.shared-trade-header h2 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(1.28rem, 6vw, 2.12rem);
  font-weight: 520;
  line-height: 1;
  overflow-wrap: anywhere;
}

.shared-trade-header span {
  display: block;
  margin-top: 4px;
  color: rgba(247, 248, 251, 0.62);
  font-size: 0.78rem;
  font-weight: 400;
  line-height: 1.24;
}

.shared-trade-value-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  margin-top: 9px;
  padding: 8px 9px;
  min-width: 0;
  color: #f7f8fb;
  background: rgba(159, 232, 209, 0.08);
  border: 1px solid rgba(159, 232, 209, 0.16);
  border-radius: 8px;
}

.shared-trade-value-summary[hidden] {
  display: none;
}

.shared-trade-value-summary span {
  margin: 0;
  min-width: 0;
  color: rgba(247, 248, 251, 0.66);
  font-size: 0.66rem;
  font-weight: 520;
  line-height: 1.1;
  text-transform: uppercase;
}

.shared-trade-value-summary strong {
  min-width: 0;
  color: #9fe8d1;
  font-size: clamp(0.86rem, 3.8vw, 1.08rem);
  font-weight: 580;
  line-height: 1;
  overflow-wrap: anywhere;
  text-align: right;
}

.shared-trade-value-summary.is-hidden-value {
  background: rgba(255, 255, 255, 0.055);
  border-color: rgba(255, 255, 255, 0.1);
}

.shared-trade-value-summary.is-hidden-value strong {
  color: rgba(247, 248, 251, 0.7);
  font-size: clamp(0.74rem, 3.3vw, 0.9rem);
}

.shared-trade-view .eyebrow {
  font-family: inherit;
  font-weight: 500;
  letter-spacing: 0.16em;
}

.shared-trade-note {
  padding: 11px 12px;
  color: #e9fff9;
  background:
    linear-gradient(135deg, rgba(126, 211, 202, 0.18), rgba(126, 164, 255, 0.08)),
    rgba(8, 14, 24, 0.76);
  border: 1px solid rgba(126, 211, 202, 0.24);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  font-size: 0.84rem;
  font-weight: 450;
  line-height: 1.28;
}

.shared-trade-view .shared-trade-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding-bottom: 16px;
}

.shared-trade-view .shared-trade-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  min-height: 0;
  padding: 9px;
  overflow: hidden;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.04)),
    rgba(7, 10, 16, 0.92);
  border: 1px solid rgba(236, 255, 251, 0.12);
  border-radius: 8px;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.shared-trade-view .shared-trade-card .portfolio-card-image-wrap {
  display: grid;
  place-items: center;
  width: 100%;
  height: clamp(142px, 40vw, 236px);
  min-height: 0;
  padding: 8px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.015)),
    rgba(3, 5, 9, 0.64);
  border: 1px solid rgba(255, 255, 255, 0.055);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.shared-trade-view .shared-trade-card .collection-card-image,
.shared-trade-view .shared-trade-card .mini-card {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.shared-trade-view .shared-trade-card.is-slab-portfolio .portfolio-slab-preview {
  width: auto;
  max-width: 94%;
  height: 100%;
  max-height: 100%;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.28);
}

.shared-trade-view .shared-trade-card .portfolio-card-main {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.shared-trade-view .shared-trade-card .portfolio-card-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.shared-trade-view .shared-trade-card .portfolio-card-copy h3 {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: #ffffff;
  font-size: clamp(0.86rem, 3.7vw, 0.98rem);
  font-weight: 460;
  line-height: 1.12;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.shared-trade-view .shared-trade-card .portfolio-card-copy p {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: rgba(224, 231, 244, 0.7);
  font-size: 0.7rem;
  font-weight: 400;
  line-height: 1.15;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.shared-trade-view .shared-trade-card .portfolio-card-footer {
  display: grid;
  min-width: 0;
}

.shared-trade-view .shared-trade-card .portfolio-card-market {
  display: grid;
  justify-items: start;
  gap: 2px;
  width: 100%;
  min-width: 0;
  text-align: left;
}

.shared-trade-view .shared-trade-card .portfolio-card-market small {
  display: block;
  justify-self: start;
  color: #7ed3ca;
  font-size: 0.52rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.shared-trade-view .shared-trade-card .portfolio-card-price-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  width: 100%;
  min-width: 0;
}

.shared-trade-view .shared-trade-card .portfolio-card-price-row strong {
  min-width: 0;
  color: #9fe8d1;
  font-size: clamp(0.86rem, 3.6vw, 1rem);
  font-weight: 480;
  line-height: 1;
  overflow-wrap: anywhere;
}

.shared-trade-view .shared-trade-card .portfolio-card-qty {
  justify-self: end;
  min-height: 22px;
  padding: 4px 7px;
  color: rgba(247, 248, 251, 0.78);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 450;
  line-height: 1;
}

.shared-trade-view .shared-trade-card.is-wanted {
  border-color: rgba(101, 197, 187, 0.62);
  box-shadow: inset 0 0 0 1px rgba(101, 197, 187, 0.24), 0 20px 46px rgba(0, 0, 0, 0.26);
}

.shared-trade-badges {
  align-items: center;
  gap: 4px;
}

.shared-trade-badges span {
  min-height: 18px;
  padding: 3px 7px;
  font-size: 0.56rem;
  font-weight: 450;
  line-height: 1;
}

.shared-trade-view .shared-trade-card-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  margin-top: 0;
}

.shared-trade-card-actions button,
.trade-submit-btn {
  min-height: 36px;
  color: #06110f;
  background: #9fe8d1;
  border: 1px solid #9fe8d1;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 950;
}

.shared-trade-card-actions button {
  font-size: 0.76rem;
  font-weight: 500;
}

.shared-trade-view .shared-trade-card.is-wanted .shared-trade-card-actions button {
  color: #1b1604;
  background: #ffd166;
  border-color: #ffd166;
}

.shared-trade-basket {
  position: fixed;
  left: 14px;
  right: 14px;
  bottom: max(14px, env(safe-area-inset-bottom));
  z-index: 50;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(138px, 0.72fr);
  gap: 12px;
  align-items: center;
  width: min(640px, calc(100% - 28px));
  margin: 0 auto;
  padding: 11px;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.04)),
    rgba(7, 10, 15, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(18px);
}

.shared-trade-basket span,
.trade-link-head span,
.trade-proposal-sides > section > span,
.trade-offer-suggestions small {
  display: block;
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
}

.shared-trade-basket span {
  font-weight: 450;
}

.shared-trade-basket strong {
  display: block;
  margin-top: 2px;
  color: #ffffff;
  font-size: 0.96rem;
  font-weight: 520;
}

.shared-trade-basket-status {
  display: block;
  margin-top: 3px;
  color: #9fe8d1;
  font-size: 0.74rem;
  font-weight: 620;
  text-transform: capitalize;
}

.shared-trade-basket button {
  min-height: 40px;
  padding: 0 12px;
  color: #06110f;
  background: #9fe8d1;
  border: 0;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 720;
  white-space: nowrap;
}

.shared-trade-basket button:disabled,
.trade-submit-btn:disabled {
  color: rgba(247, 248, 251, 0.38);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.08);
}

.trade-link-sheet,
.trade-offer-sheet,
.trade-inbox-sheet {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  align-items: end;
  justify-items: center;
  padding: 14px;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(8px);
}

.trade-link-panel,
.trade-offer-panel,
.trade-inbox-panel {
  display: grid;
  gap: 14px;
  width: min(520px, 100%);
  max-height: min(820px, calc(var(--mobile-page-height) - 28px));
  padding: 16px;
  overflow: auto;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.04)),
    rgba(8, 12, 18, 0.97);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  box-shadow: 0 34px 86px rgba(0, 0, 0, 0.52);
}

.trade-link-head {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
}

.trade-link-head strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-size: 1.25rem;
  font-weight: 950;
  line-height: 1.05;
}

.trade-link-head strong.is-even {
  color: #9fe8d1;
}

.trade-link-head strong.is-under {
  color: #ffd166;
}

.trade-link-head strong.is-over {
  color: #c7d7ff;
}

.trade-link-head small {
  display: block;
  margin-top: 5px;
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.32;
}

.trade-link-head button,
.trade-link-actions button {
  min-height: 38px;
  padding: 0 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 950;
}

.trade-link-form {
  display: grid;
  gap: 12px;
}

.trade-toggle-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 13px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 16px;
}

.trade-toggle-row input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  accent-color: #9fe8d1;
}

.trade-toggle-row strong,
.trade-offer-suggestions strong {
  display: block;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 950;
}

.trade-toggle-row small {
  display: block;
  margin-top: 2px;
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.8rem;
  font-weight: 800;
  line-height: 1.3;
}

.trade-note-field {
  display: grid;
  gap: 7px;
}

.trade-note-field span {
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.74rem;
  font-weight: 900;
  text-transform: uppercase;
}

.trade-note-field textarea,
.trade-note-field input {
  width: 100%;
  padding: 11px 12px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 800;
}

.trade-note-field textarea {
  min-height: 86px;
  resize: vertical;
}

.trade-note-field input {
  min-height: 46px;
}

.trade-cash-offer {
  display: grid;
  gap: 10px;
}

.trade-offer-submit-status {
  margin: 0;
  padding: 10px 12px;
  color: #9fe8d1;
  background: rgba(159, 232, 209, 0.08);
  border: 1px solid rgba(159, 232, 209, 0.14);
  border-radius: 14px;
  font-size: 0.82rem;
  font-weight: 850;
  line-height: 1.32;
}

.trade-link-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.trade-receipt-actions {
  grid-template-columns: minmax(0, 1fr);
}

.trade-link-actions button:first-child {
  color: #f7f8fb;
}

.trade-submit-btn {
  color: #06110f;
}

.trade-link-actions button:disabled {
  color: rgba(247, 248, 251, 0.34);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.08);
}

.trade-link-output {
  margin: 0;
  padding: 11px 12px;
  overflow-wrap: anywhere;
  color: #9fe8d1;
  background: rgba(159, 232, 209, 0.08);
  border: 1px solid rgba(159, 232, 209, 0.16);
  border-radius: 14px;
  font-size: 0.8rem;
  font-weight: 850;
  line-height: 1.35;
}

.trade-proposal-sides {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.trade-proposal-sides section {
  display: grid;
  gap: 8px;
  align-content: start;
  min-width: 0;
  padding: 12px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 16px;
}

.trade-proposal-sides p,
.trade-proposal-item {
  display: grid;
  gap: 3px;
  margin: 0;
  padding: 9px;
  color: rgba(247, 248, 251, 0.72);
  background: rgba(255, 255, 255, 0.045);
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 850;
  line-height: 1.28;
}

.trade-proposal-item {
  grid-template-columns: minmax(0, 1fr) 58px;
  gap: 10px;
  align-items: center;
}

.trade-proposal-item-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.trade-proposal-thumb {
  display: grid;
  place-items: center;
  justify-self: end;
  width: 58px;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  color: rgba(247, 248, 251, 0.62);
  background: rgba(8, 12, 18, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 9px;
}

.trade-proposal-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.trade-proposal-thumb span {
  font-size: 0.82rem;
  font-weight: 950;
}

.trade-proposal-sides p strong,
.trade-proposal-sides section > strong,
.trade-proposal-item strong {
  color: #ffffff;
  font-weight: 950;
}

.trade-proposal-item em {
  color: #9fe8d1;
  font-style: normal;
  font-weight: 950;
}

.trade-proposal-item.is-unavailable {
  border: 1px solid rgba(255, 209, 102, 0.32);
}

.trade-offer-suggestions {
  display: grid;
  gap: 2px;
}

.trade-offer-card-list,
.trade-inbox-list {
  display: grid;
  gap: 9px;
}

.trade-offer-card-choice {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 48px;
  gap: 10px;
  align-items: center;
  width: 100%;
  min-height: 66px;
  padding: 10px 12px;
  color: #f7f8fb;
  text-align: left;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 15px;
}

.trade-offer-card-choice > span:first-child {
  min-width: 0;
}

.trade-offer-card-choice.is-selected {
  color: #06110f;
  background: #9fe8d1;
  border-color: #9fe8d1;
}

.trade-offer-card-choice strong,
.trade-offer-card-choice small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.trade-offer-card-choice small {
  margin-top: 2px;
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.78rem;
  font-weight: 800;
}

.trade-offer-card-choice.is-selected small {
  color: rgba(6, 17, 15, 0.66);
}

.trade-offer-card-choice em {
  color: #9fe8d1;
  font-style: normal;
  font-size: 0.78rem;
  font-weight: 950;
}

.trade-offer-card-choice.is-selected em {
  color: #06110f;
}

.trade-offer-card-thumb {
  display: grid;
  place-items: center;
  width: 48px;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  color: rgba(247, 248, 251, 0.62);
  background: rgba(8, 12, 18, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
}

.trade-offer-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.trade-offer-card-thumb span {
  font-size: 0.72rem;
  font-weight: 950;
}

.trade-offer-card-choice.is-selected .trade-offer-card-thumb {
  color: rgba(6, 17, 15, 0.72);
  background: rgba(6, 17, 15, 0.12);
  border-color: rgba(6, 17, 15, 0.18);
}

.trade-offer-empty button {
  min-height: 42px;
  margin-top: 8px;
  padding: 0 14px;
  color: #06110f;
  background: #9fe8d1;
  border: 0;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 950;
}

.trade-inbox-proposal {
  display: grid;
  gap: 12px;
  padding: 13px;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 18px;
}

.trade-inbox-proposal header {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  justify-content: space-between;
}

.trade-inbox-proposal header span {
  color: rgba(247, 248, 251, 0.58);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.trade-inbox-proposal header strong {
  display: block;
  margin-top: 4px;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 950;
}

.trade-inbox-proposal header em,
.trade-fit-pill {
  margin: 0;
  color: #9fe8d1;
  font-style: normal;
  font-size: 0.78rem;
  font-weight: 950;
  text-transform: capitalize;
}

.trade-inbox-message {
  margin: 0;
  color: rgba(247, 248, 251, 0.72);
  font-size: 0.84rem;
  font-weight: 800;
  line-height: 1.35;
}

.trade-inbox-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

.trade-inbox-actions button {
  min-height: 36px;
  padding: 0 8px;
  color: #f7f8fb;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.trade-inbox-actions button:first-child {
  color: #06110f;
  background: #9fe8d1;
  border-color: #9fe8d1;
}

@media (max-width: 560px) {
  .trade-proposal-sides,
  .trade-link-actions,
  .trade-inbox-actions {
    grid-template-columns: minmax(0, 1fr);
  }

  .shared-trade-basket {
    grid-template-columns: minmax(0, 1fr) minmax(128px, 0.62fr);
  }

  .shared-trade-basket button {
    width: 100%;
  }
}

@media (max-width: 360px) {
  .shared-trade-view {
    padding-inline: 10px;
  }

  .shared-trade-view .shared-trade-grid {
    gap: 8px;
  }

  .shared-trade-view .shared-trade-card {
    padding: 8px;
  }

  .shared-trade-view .shared-trade-card .portfolio-card-image-wrap {
    height: clamp(132px, 40vw, 174px);
  }

  .shared-trade-basket {
    grid-template-columns: minmax(0, 1fr);
  }
}
/* MEMORY LINE: SHARED TRADE LINK END */

body.theme-light,
body.theme-light.collector-home {
  color: #172033;
  background:
    radial-gradient(circle at 14% -6%, rgba(126, 164, 255, 0.2), transparent 30%),
    radial-gradient(circle at 92% 2%, rgba(101, 197, 187, 0.18), transparent 28%),
    linear-gradient(180deg, #eef4f8 0%, #f8fbff 48%, #edf2f7 100%);
}

body.theme-light .dashboard-header,
body.theme-light .dashboard-header h1,
body.theme-light .hero-copy h2,
body.theme-light .section-row h2,
body.theme-light .collection-tab-head h2,
body.theme-light .collection-active-row strong,
body.theme-light .collection-tab .card-topline h3,
body.theme-light .vendor-hero-card h2,
body.theme-light .vendor-section-head h2,
body.theme-light .portfolio-pulse-copy h2,
body.theme-light .app-menu-head h2 {
  color: #172033;
}

body.theme-light .hero-value-card,
body.theme-light .scan-card,
body.theme-light .market-card,
body.theme-light .collection-tab-head,
body.theme-light .collection-detail-panel,
body.theme-light .collection-section-panel,
body.theme-light .collection-tab .collection-card,
body.theme-light .vendor-hero-card,
body.theme-light .vendor-deal-card,
body.theme-light .vendor-ledger-card,
body.theme-light .vendor-summary-grid article,
body.theme-light .portfolio-pulse-card,
body.theme-light .app-menu-panel,
body.theme-light .app-account-card,
body.theme-light .app-account-manager-section,
body.theme-light .app-account-facts span {
  color: #172033;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(245, 248, 252, 0.86)),
    #ffffff;
  border-color: rgba(23, 32, 51, 0.12);
  box-shadow: 0 18px 42px rgba(23, 32, 51, 0.1);
}

body.theme-light .icon-button,
body.theme-light .scan-icon-button,
body.theme-light .collection-back-btn,
body.theme-light .home-action-strip a,
body.theme-light .home-action-strip button,
body.theme-light .vendor-form-actions button,
body.theme-light .vendor-ledger-actions button,
body.theme-light .app-menu-head button,
body.theme-light .app-menu-action-row button,
body.theme-light .app-account-manager-section > button,
body.theme-light .app-account-management-actions button,
body.theme-light .app-setting-row > button {
  color: #172033;
  background: rgba(255, 255, 255, 0.8);
  border-color: rgba(23, 32, 51, 0.14);
}

body.theme-light .primary-action,
body.theme-light .save-inventory-btn,
body.theme-light .scan-icon-button,
body.theme-light .home-action-strip > :first-child,
body.theme-light .vendor-form-actions button:first-child,
body.theme-light .app-menu-action-row button:first-child,
body.theme-light .app-account-manager-section > button,
body.theme-light .app-account-management-actions button:first-child,
body.theme-light .app-setting-row > button,
body.theme-light .app-menu-tabs button.is-active,
body.theme-light .theme-toggle button.is-active {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

body.theme-light .app-menu-tabs,
body.theme-light .theme-toggle {
  background: rgba(23, 32, 51, 0.055);
  border-color: rgba(23, 32, 51, 0.12);
}

body.theme-light .app-menu-tabs button,
body.theme-light .theme-toggle button {
  color: rgba(23, 32, 51, 0.72);
}

body.theme-light .app-menu-tabs button:not(.is-active):hover,
body.theme-light .theme-toggle button:not(.is-active):hover {
  color: #172033;
  background: rgba(23, 32, 51, 0.06);
}

body.theme-light .app-menu-action-row button:disabled,
body.theme-light .app-account-manager-section button:disabled,
body.theme-light .app-account-management-actions button:disabled {
  color: rgba(23, 32, 51, 0.38);
  background: rgba(23, 32, 51, 0.035);
  border-color: rgba(23, 32, 51, 0.08);
}

body.theme-light #appAccountDeleteAccountBtn:disabled {
  color: rgba(23, 32, 51, 0.38);
  background: rgba(23, 32, 51, 0.035);
  border-color: rgba(23, 32, 51, 0.08);
}

body.theme-light input,
body.theme-light select,
body.theme-light textarea,
body.theme-light .vendor-deal-form input {
  color: #172033;
  background: #ffffff;
  border-color: rgba(23, 32, 51, 0.16);
}

body.theme-light input::placeholder,
body.theme-light textarea::placeholder {
  color: rgba(23, 32, 51, 0.42);
}

body.theme-light .hero-copy span,
body.theme-light .value-hub span,
body.theme-light .portfolio-pulse-copy > span,
body.theme-light #portfolioGraphSummary,
body.theme-light .collector-app .scanner-status,
body.theme-light .collection-active-row span,
body.theme-light .collection-tab .card-topline p,
body.theme-light .vendor-hero-card span,
body.theme-light .vendor-summary-grid span,
body.theme-light .vendor-quote-strip span,
body.theme-light .vendor-line-main small,
body.theme-light .vendor-line-main p,
body.theme-light .app-menu-head span,
body.theme-light .app-account-card p,
body.theme-light .app-account-section-head span,
body.theme-light .app-account-field span,
body.theme-light .app-account-session-info,
body.theme-light .app-account-copy,
body.theme-light .app-account-facts span,
body.theme-light .app-account-status,
body.theme-light .app-setting-row span,
body.theme-light .app-menu-tool span {
  color: rgba(23, 32, 51, 0.62);
}

body.theme-light .portfolio-pulse-copy > strong,
body.theme-light .value-hub strong,
body.theme-light .vendor-summary-grid strong,
body.theme-light .vendor-quote-strip strong,
body.theme-light .vendor-line-main strong,
body.theme-light .app-account-card strong,
body.theme-light .app-account-section-head strong,
body.theme-light .app-account-facts b,
body.theme-light .app-setting-row strong,
body.theme-light .app-menu-tool strong {
  color: #172033;
}

body.theme-light #portfolioGraph .graph-bg,
body.theme-light .portfolio-pulse-card .graph-bg {
  fill: rgba(255, 255, 255, 0.72);
}

body.theme-light .portfolio-pulse-card .graph-grid {
  stroke: rgba(23, 32, 51, 0.12);
}

body.theme-light .bottom-nav {
  color: rgba(23, 32, 51, 0.62);
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(23, 32, 51, 0.12);
  box-shadow: 0 18px 44px rgba(23, 32, 51, 0.12);
}

body.theme-light .bottom-nav .active {
  color: #172033;
  background: rgba(101, 197, 187, 0.28);
}

body.theme-light .bottom-nav .scan-tab {
  color: #06110f;
  background: #65c5bb;
}

body.theme-clear,
body.theme-clear.collector-home {
  color: #101827;
  background:
    radial-gradient(circle at 10% -10%, rgba(101, 197, 187, 0.34), transparent 34%),
    radial-gradient(circle at 92% 0%, rgba(126, 164, 255, 0.32), transparent 30%),
    radial-gradient(circle at 52% 100%, rgba(255, 209, 102, 0.18), transparent 34%),
    linear-gradient(145deg, #edf5fb 0%, #fbfdff 44%, #e7eef7 100%);
}

body.theme-clear .dashboard-header,
body.theme-clear .dashboard-header h1,
body.theme-clear .hero-copy h2,
body.theme-clear .section-row h2,
body.theme-clear .collection-tab-head h2,
body.theme-clear .collection-active-row strong,
body.theme-clear .collection-tab .card-topline h3,
body.theme-clear .vendor-hero-card h2,
body.theme-clear .vendor-section-head h2,
body.theme-clear .portfolio-pulse-copy h2,
body.theme-clear .app-menu-head h2 {
  color: #101827;
}

body.theme-clear .eyebrow {
  color: #6481e8;
}

body.theme-clear .home-logo {
  color: #ffffff;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

body.theme-clear .hero-value-card,
body.theme-clear .scan-card,
body.theme-clear .market-card,
body.theme-clear .collection-tab-head,
body.theme-clear .collection-detail-panel,
body.theme-clear .collection-section-panel,
body.theme-clear .collection-tab .collection-card,
body.theme-clear .vendor-hero-card,
body.theme-clear .vendor-deal-card,
body.theme-clear .vendor-ledger-card,
body.theme-clear .vendor-summary-grid article,
body.theme-clear .portfolio-pulse-card,
body.theme-clear .app-menu-panel,
body.theme-clear .app-account-card,
body.theme-clear .app-setting-row,
body.theme-clear .app-menu-tool {
  color: #101827;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.28)),
    rgba(255, 255, 255, 0.34);
  border-color: rgba(255, 255, 255, 0.58);
  box-shadow: 0 26px 70px rgba(49, 71, 101, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(26px) saturate(180%);
  -webkit-backdrop-filter: blur(26px) saturate(180%);
}

body.theme-clear .app-menu-backdrop {
  background: rgba(46, 57, 72, 0.36);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
}

body.theme-clear .app-menu-tabs,
body.theme-clear .theme-toggle {
  background: rgba(255, 255, 255, 0.24);
  border-color: rgba(255, 255, 255, 0.54);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(18px) saturate(170%);
  -webkit-backdrop-filter: blur(18px) saturate(170%);
}

body.theme-clear .app-menu-tabs button,
body.theme-clear .theme-toggle button {
  color: rgba(16, 24, 39, 0.74);
}

body.theme-clear .app-menu-tabs button.is-active,
body.theme-clear .theme-toggle button.is-active,
body.theme-clear .primary-action,
body.theme-clear .save-inventory-btn,
body.theme-clear .scan-icon-button,
body.theme-clear .home-action-strip > :first-child,
body.theme-clear .vendor-form-actions button:first-child,
body.theme-clear .app-menu-action-row button:first-child,
body.theme-clear .app-setting-row > button {
  color: #06110f;
  background: rgba(101, 197, 187, 0.78);
  border-color: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55), 0 12px 28px rgba(101, 197, 187, 0.18);
}

body.theme-clear .icon-button,
body.theme-clear .scan-icon-button,
body.theme-clear .collection-back-btn,
body.theme-clear .home-action-strip a,
body.theme-clear .home-action-strip button,
body.theme-clear .vendor-form-actions button,
body.theme-clear .vendor-ledger-actions button,
body.theme-clear .app-menu-head button,
body.theme-clear .app-menu-action-row button,
body.theme-clear .app-setting-row > button {
  color: #101827;
  background: rgba(255, 255, 255, 0.34);
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.62), 0 14px 30px rgba(49, 71, 101, 0.14);
  backdrop-filter: blur(18px) saturate(170%);
  -webkit-backdrop-filter: blur(18px) saturate(170%);
}

body.theme-clear .app-menu-tabs button.is-active,
body.theme-clear .theme-toggle button.is-active,
body.theme-clear .primary-action,
body.theme-clear .save-inventory-btn,
body.theme-clear .scan-icon-button,
body.theme-clear .home-action-strip > :first-child,
body.theme-clear .vendor-form-actions button:first-child,
body.theme-clear .app-menu-action-row button:first-child,
body.theme-clear .app-setting-row > button {
  color: #06110f;
  background: rgba(101, 197, 187, 0.78);
  border-color: rgba(255, 255, 255, 0.48);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55), 0 12px 28px rgba(101, 197, 187, 0.18);
}

body.theme-clear input,
body.theme-clear select,
body.theme-clear textarea,
body.theme-clear .vendor-deal-form input {
  color: #101827;
  background: rgba(255, 255, 255, 0.58);
  border-color: rgba(255, 255, 255, 0.62);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.68);
}

body.theme-clear input::placeholder,
body.theme-clear textarea::placeholder {
  color: rgba(16, 24, 39, 0.44);
}

body.theme-clear .hero-copy span,
body.theme-clear .value-hub span,
body.theme-clear .portfolio-pulse-copy > span,
body.theme-clear #portfolioGraphSummary,
body.theme-clear .collector-app .scanner-status,
body.theme-clear .collection-active-row span,
body.theme-clear .collection-tab .card-topline p,
body.theme-clear .vendor-hero-card span,
body.theme-clear .vendor-summary-grid span,
body.theme-clear .vendor-quote-strip span,
body.theme-clear .vendor-line-main small,
body.theme-clear .vendor-line-main p,
body.theme-clear .app-menu-head span,
body.theme-clear .app-account-card p,
body.theme-clear .app-setting-row span,
body.theme-clear .app-menu-tool span {
  color: rgba(16, 24, 39, 0.62);
}

body.theme-clear .portfolio-pulse-copy > strong,
body.theme-clear .value-hub strong,
body.theme-clear .vendor-summary-grid strong,
body.theme-clear .vendor-quote-strip strong,
body.theme-clear .vendor-line-main strong,
body.theme-clear .app-account-card strong,
body.theme-clear .app-setting-row strong,
body.theme-clear .app-menu-tool strong {
  color: #101827;
}

body.theme-clear #portfolioGraph .graph-bg,
body.theme-clear .portfolio-pulse-card .graph-bg {
  fill: rgba(255, 255, 255, 0.38);
}

body.theme-clear .portfolio-pulse-card .graph-grid {
  stroke: rgba(16, 24, 39, 0.12);
}

body.theme-clear .bottom-nav {
  color: rgba(16, 24, 39, 0.62);
  background: rgba(255, 255, 255, 0.34);
  border-color: rgba(255, 255, 255, 0.58);
  box-shadow: 0 20px 44px rgba(49, 71, 101, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.68);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
}

body.theme-clear .bottom-nav .active {
  color: #101827;
  background: rgba(255, 255, 255, 0.35);
}

body.theme-clear .app-menu-action-row button:disabled {
  color: rgba(16, 24, 39, 0.38);
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.34);
}

/* Crystal clear appearance mode */
body.theme-clear,
body.theme-clear.collector-home {
  color: #101827;
  background:
    linear-gradient(128deg, rgba(99, 211, 202, 0.18), rgba(255, 255, 255, 0) 34%, rgba(126, 164, 255, 0.18) 64%, rgba(255, 255, 255, 0)),
    linear-gradient(62deg, rgba(255, 255, 255, 0.94), rgba(232, 243, 252, 0.86) 46%, rgba(247, 251, 255, 0.96)),
    #f4f9fd;
}

body.theme-clear .dashboard-header {
  color: #101827;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.24), rgba(255, 255, 255, 0));
  border-color: rgba(255, 255, 255, 0.48);
}

body.theme-clear .hero-value-card,
body.theme-clear .scan-card,
body.theme-clear .market-card,
body.theme-clear .collection-tab-head,
body.theme-clear .collection-detail-panel,
body.theme-clear .collection-section-panel,
body.theme-clear .collection-tab .collection-card,
body.theme-clear .vendor-hero-card,
body.theme-clear .vendor-deal-card,
body.theme-clear .vendor-ledger-card,
body.theme-clear .vendor-summary-grid article,
body.theme-clear .portfolio-pulse-card,
body.theme-clear .app-menu-panel,
body.theme-clear .app-account-card,
body.theme-clear .app-setting-row,
body.theme-clear .app-menu-tool,
body.theme-clear .bottom-nav {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  color: #101827;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.44), rgba(255, 255, 255, 0.16) 54%, rgba(255, 255, 255, 0.08)),
    rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.74);
  box-shadow:
    0 28px 72px rgba(46, 67, 95, 0.18),
    0 8px 22px rgba(46, 67, 95, 0.1),
    inset 0 1px 1px rgba(255, 255, 255, 0.92),
    inset 0 -1px 0 rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(34px) saturate(210%) contrast(1.04);
  -webkit-backdrop-filter: blur(34px) saturate(210%) contrast(1.04);
}

body.theme-clear .app-menu-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.54), rgba(255, 255, 255, 0.2) 58%, rgba(255, 255, 255, 0.1)),
    rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 34px 96px rgba(16, 24, 39, 0.26),
    inset 0 1px 1px rgba(255, 255, 255, 0.96),
    inset 0 -1px 0 rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(42px) saturate(230%) contrast(1.06);
  -webkit-backdrop-filter: blur(42px) saturate(230%) contrast(1.06);
}

body.theme-clear .hero-value-card::before,
body.theme-clear .scan-card::before,
body.theme-clear .market-card::before,
body.theme-clear .collection-tab-head::before,
body.theme-clear .collection-detail-panel::before,
body.theme-clear .collection-section-panel::before,
body.theme-clear .collection-tab .collection-card::before,
body.theme-clear .vendor-hero-card::before,
body.theme-clear .vendor-deal-card::before,
body.theme-clear .vendor-ledger-card::before,
body.theme-clear .vendor-summary-grid article::before,
body.theme-clear .portfolio-pulse-card::before,
body.theme-clear .app-menu-panel::before,
body.theme-clear .app-account-card::before,
body.theme-clear .app-setting-row::before,
body.theme-clear .app-menu-tool::before,
body.theme-clear .bottom-nav::before {
  content: "";
  position: absolute;
  inset: 1px;
  height: auto;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.16) 34%, rgba(255, 255, 255, 0) 62%),
    linear-gradient(315deg, rgba(126, 164, 255, 0.11), rgba(101, 197, 187, 0.08) 48%, rgba(255, 255, 255, 0));
  opacity: 0.82;
}

body.theme-clear .app-menu-backdrop {
  background:
    linear-gradient(130deg, rgba(16, 24, 39, 0.24), rgba(255, 255, 255, 0.18)),
    rgba(29, 38, 52, 0.28);
  backdrop-filter: blur(24px) saturate(170%);
  -webkit-backdrop-filter: blur(24px) saturate(170%);
}

body.theme-clear .app-menu-tabs,
body.theme-clear .theme-toggle {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.42), rgba(255, 255, 255, 0.16)),
    rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.7);
  box-shadow:
    inset 0 1px 1px rgba(255, 255, 255, 0.86),
    inset 0 -1px 0 rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(26px) saturate(200%);
  -webkit-backdrop-filter: blur(26px) saturate(200%);
}

body.theme-clear .app-menu-tabs button,
body.theme-clear .theme-toggle button {
  color: rgba(16, 24, 39, 0.78);
}

body.theme-clear .app-menu-tabs button:not(.is-active):hover,
body.theme-clear .theme-toggle button:not(.is-active):hover {
  color: #101827;
  background: rgba(255, 255, 255, 0.28);
}

body.theme-clear .app-menu-tabs button.is-active,
body.theme-clear .theme-toggle button.is-active,
body.theme-clear .primary-action,
body.theme-clear .save-inventory-btn,
body.theme-clear .scan-icon-button,
body.theme-clear .home-action-strip > :first-child,
body.theme-clear .vendor-form-actions button:first-child,
body.theme-clear .app-menu-action-row button:first-child,
body.theme-clear .app-setting-row > button {
  color: #06110f;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.38), rgba(101, 197, 187, 0.72)),
    rgba(101, 197, 187, 0.68);
  border-color: rgba(255, 255, 255, 0.76);
  box-shadow:
    0 14px 34px rgba(42, 155, 145, 0.2),
    inset 0 1px 1px rgba(255, 255, 255, 0.86),
    inset 0 -1px 0 rgba(6, 17, 15, 0.1);
}

body.theme-clear .icon-button,
body.theme-clear .collection-back-btn,
body.theme-clear .home-action-strip a,
body.theme-clear .home-action-strip button,
body.theme-clear .vendor-form-actions button,
body.theme-clear .vendor-ledger-actions button,
body.theme-clear .app-menu-head button,
body.theme-clear .app-menu-action-row button,
body.theme-clear .app-setting-row > button {
  color: #101827;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.42), rgba(255, 255, 255, 0.14)),
    rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.7);
  box-shadow:
    0 14px 30px rgba(46, 67, 95, 0.12),
    inset 0 1px 1px rgba(255, 255, 255, 0.86),
    inset 0 -1px 0 rgba(15, 23, 42, 0.07);
  backdrop-filter: blur(24px) saturate(200%);
  -webkit-backdrop-filter: blur(24px) saturate(200%);
}

body.theme-clear .scan-icon-button,
body.theme-clear .app-setting-row > button,
body.theme-clear .app-menu-action-row button:first-child {
  color: #06110f;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.38), rgba(101, 197, 187, 0.72)),
    rgba(101, 197, 187, 0.68);
}

body.theme-clear input,
body.theme-clear select,
body.theme-clear textarea,
body.theme-clear .vendor-deal-form input {
  color: #101827;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.56), rgba(255, 255, 255, 0.24)),
    rgba(255, 255, 255, 0.34);
  border-color: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.86), inset 0 -1px 0 rgba(15, 23, 42, 0.06);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
}

body.theme-clear .bottom-nav {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.44), rgba(255, 255, 255, 0.18)),
    rgba(255, 255, 255, 0.22);
}

body.theme-clear .bottom-nav .active {
  color: #101827;
  background: rgba(255, 255, 255, 0.28);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.76);
}

/* Smoked crystal clear mode */
body.theme-clear,
body.theme-clear.collector-home {
  color: #f6f8fc;
  background:
    radial-gradient(circle at 12% -8%, rgba(102, 211, 201, 0.28), transparent 34%),
    radial-gradient(circle at 90% 0%, rgba(126, 164, 255, 0.22), transparent 32%),
    radial-gradient(circle at 52% 96%, rgba(255, 209, 102, 0.09), transparent 36%),
    linear-gradient(180deg, #08111c 0%, #111b28 45%, #07101a 100%);
}

body.theme-clear .dashboard-header {
  color: #f6f8fc;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0));
  border-color: rgba(255, 255, 255, 0.12);
}

body.theme-clear .dashboard-header h1,
body.theme-clear .hero-copy h2,
body.theme-clear .section-row h2,
body.theme-clear .collection-tab-head h2,
body.theme-clear .collection-active-row strong,
body.theme-clear .collection-tab .card-topline h3,
body.theme-clear .vendor-hero-card h2,
body.theme-clear .vendor-section-head h2,
body.theme-clear .portfolio-pulse-copy h2,
body.theme-clear .app-menu-head h2,
body.theme-clear #soldDataTitle,
body.theme-clear #scannerTitle {
  color: #f8fbff;
  text-shadow: 0 14px 34px rgba(0, 0, 0, 0.2);
}

body.theme-clear .portfolio-pulse-copy h2 strong,
body.theme-clear .eyebrow,
body.theme-clear .portfolio-pulse-copy > span,
body.theme-clear .portfolio-pulse-footer strong,
body.theme-clear .value-hub strong,
body.theme-clear .snapshot-body strong {
  color: #8de1d9;
}

body.theme-clear .hero-value-card,
body.theme-clear .scan-card,
body.theme-clear .market-card,
body.theme-clear .collection-tab-head,
body.theme-clear .collection-detail-panel,
body.theme-clear .collection-section-panel,
body.theme-clear .collection-tab .collection-card,
body.theme-clear .vendor-hero-card,
body.theme-clear .vendor-deal-card,
body.theme-clear .vendor-ledger-card,
body.theme-clear .vendor-summary-grid article,
body.theme-clear .portfolio-pulse-card,
body.theme-clear .app-menu-panel,
body.theme-clear .app-account-card,
body.theme-clear .app-setting-row,
body.theme-clear .app-menu-tool,
body.theme-clear .bottom-nav {
  color: #f6f8fc;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.055) 54%, rgba(255, 255, 255, 0.025)),
    rgba(10, 18, 29, 0.54);
  border-color: rgba(255, 255, 255, 0.24);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.34),
    0 8px 28px rgba(102, 211, 201, 0.08),
    inset 0 1px 1px rgba(255, 255, 255, 0.56),
    inset 0 -1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(30px) saturate(190%);
  -webkit-backdrop-filter: blur(30px) saturate(190%);
}

body.theme-clear .portfolio-pulse-card,
body.theme-clear .scan-card,
body.theme-clear .market-card {
  background:
    linear-gradient(150deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.055) 48%, rgba(141, 225, 217, 0.045)),
    rgba(11, 19, 31, 0.58);
}

body.theme-clear .app-menu-panel {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.075) 58%, rgba(255, 255, 255, 0.035)),
    rgba(9, 16, 27, 0.68);
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow:
    0 34px 96px rgba(0, 0, 0, 0.46),
    inset 0 1px 1px rgba(255, 255, 255, 0.62),
    inset 0 -1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(44px) saturate(210%);
  -webkit-backdrop-filter: blur(44px) saturate(210%);
}

body.theme-clear .hero-value-card::before,
body.theme-clear .scan-card::before,
body.theme-clear .market-card::before,
body.theme-clear .collection-tab-head::before,
body.theme-clear .collection-detail-panel::before,
body.theme-clear .collection-section-panel::before,
body.theme-clear .collection-tab .collection-card::before,
body.theme-clear .vendor-hero-card::before,
body.theme-clear .vendor-deal-card::before,
body.theme-clear .vendor-ledger-card::before,
body.theme-clear .vendor-summary-grid article::before,
body.theme-clear .portfolio-pulse-card::before,
body.theme-clear .app-menu-panel::before,
body.theme-clear .app-account-card::before,
body.theme-clear .app-setting-row::before,
body.theme-clear .app-menu-tool::before,
body.theme-clear .bottom-nav::before {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0.09) 34%, rgba(255, 255, 255, 0) 62%),
    linear-gradient(315deg, rgba(126, 164, 255, 0.11), rgba(102, 211, 201, 0.09) 50%, rgba(255, 255, 255, 0));
  opacity: 0.7;
}

body.theme-clear .app-menu-backdrop {
  background:
    radial-gradient(circle at 50% 20%, rgba(102, 211, 201, 0.1), transparent 38%),
    rgba(1, 5, 12, 0.5);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
}

body.theme-clear .app-menu-tabs,
body.theme-clear .theme-toggle,
body.theme-clear .portfolio-range-tabs,
body.theme-clear .portfolio-currency-pill {
  color: #f6f8fc;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.045)),
    rgba(7, 13, 23, 0.42);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.34), 0 10px 28px rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
}

body.theme-clear .app-menu-tabs button,
body.theme-clear .theme-toggle button,
body.theme-clear .portfolio-range-tabs button,
body.theme-clear .portfolio-mode-tabs button {
  color: rgba(246, 248, 252, 0.66);
}

body.theme-clear .app-menu-tabs button.is-active,
body.theme-clear .theme-toggle button.is-active,
body.theme-clear .primary-action,
body.theme-clear .save-inventory-btn,
body.theme-clear .scan-icon-button,
body.theme-clear .home-action-strip > :first-child,
body.theme-clear .vendor-form-actions button:first-child,
body.theme-clear .app-menu-action-row button:first-child,
body.theme-clear .app-setting-row > button {
  color: #06110f;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.28), rgba(102, 211, 201, 0.76)),
    rgba(102, 211, 201, 0.68);
  border-color: rgba(255, 255, 255, 0.34);
  box-shadow:
    0 16px 36px rgba(102, 211, 201, 0.16),
    inset 0 1px 1px rgba(255, 255, 255, 0.6),
    inset 0 -1px 0 rgba(6, 17, 15, 0.16);
}

body.theme-clear .home-action-strip a,
body.theme-clear .home-action-strip button,
body.theme-clear .icon-button,
body.theme-clear .collection-back-btn,
body.theme-clear .vendor-form-actions button,
body.theme-clear .vendor-ledger-actions button,
body.theme-clear .app-menu-head button,
body.theme-clear .app-menu-action-row button {
  color: #f6f8fc;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.04)),
    rgba(8, 14, 24, 0.42);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.34), 0 12px 28px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(22px) saturate(180%);
  -webkit-backdrop-filter: blur(22px) saturate(180%);
}

body.theme-clear .home-logo {
  color: #ffffff;
  background: #000;
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

body.theme-clear .scanner-search {
  background: transparent;
}

body.theme-clear .collector-app label,
body.theme-clear .scanner-search label {
  color: rgba(246, 248, 252, 0.74);
  background: transparent;
}

body.theme-clear input,
body.theme-clear select,
body.theme-clear textarea,
body.theme-clear .vendor-deal-form input,
body.theme-clear .scanner-search input {
  color: #f8fbff;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.105), rgba(255, 255, 255, 0.035)),
    rgba(4, 9, 17, 0.42);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.28), 0 10px 24px rgba(0, 0, 0, 0.14);
  backdrop-filter: blur(20px) saturate(170%);
  -webkit-backdrop-filter: blur(20px) saturate(170%);
}

body.theme-clear input::placeholder,
body.theme-clear textarea::placeholder,
body.theme-clear .scanner-search input::placeholder {
  color: rgba(246, 248, 252, 0.44);
}

body.theme-clear input:focus,
body.theme-clear select:focus,
body.theme-clear textarea:focus {
  border-color: rgba(141, 225, 217, 0.64);
  box-shadow: 0 0 0 3px rgba(141, 225, 217, 0.16), inset 0 1px 1px rgba(255, 255, 255, 0.32);
}

body.theme-clear .hero-copy span,
body.theme-clear .value-hub span,
body.theme-clear .portfolio-pulse-copy > span,
body.theme-clear #portfolioGraphSummary,
body.theme-clear .collector-app .scanner-status,
body.theme-clear .collection-active-row span,
body.theme-clear .collection-tab .card-topline p,
body.theme-clear .vendor-hero-card span,
body.theme-clear .vendor-summary-grid span,
body.theme-clear .vendor-quote-strip span,
body.theme-clear .vendor-line-main small,
body.theme-clear .vendor-line-main p,
body.theme-clear .app-menu-head span,
body.theme-clear .app-account-card p,
body.theme-clear .app-setting-row span,
body.theme-clear .app-menu-tool span,
body.theme-clear .snapshot-body p,
body.theme-clear .snapshot-body small {
  color: rgba(246, 248, 252, 0.66);
}

body.theme-clear .portfolio-pulse-copy > strong,
body.theme-clear .value-hub strong,
body.theme-clear .vendor-summary-grid strong,
body.theme-clear .vendor-quote-strip strong,
body.theme-clear .vendor-line-main strong,
body.theme-clear .app-account-card strong,
body.theme-clear .app-setting-row strong,
body.theme-clear .app-menu-tool strong {
  color: #f8fbff;
}

body.theme-clear #portfolioGraph .graph-bg,
body.theme-clear .portfolio-pulse-card .graph-bg {
  fill: rgba(4, 10, 18, 0.38);
}

body.theme-clear .portfolio-pulse-card .graph-grid {
  stroke: rgba(246, 248, 252, 0.14);
}

body.theme-clear .portfolio-pulse-card .graph-label {
  fill: rgba(246, 248, 252, 0.64);
}

body.theme-clear .portfolio-pulse-card .value-path {
  stroke: #8de1d9;
  filter: drop-shadow(0 0 12px rgba(141, 225, 217, 0.22));
}

body.theme-clear .portfolio-mid-dot {
  fill: rgba(246, 248, 252, 0.7);
}

body.theme-clear .market-snapshot-card,
body.theme-clear .sold-snapshot article,
body.theme-clear .snapshot-image {
  color: #f6f8fc;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.04)),
    rgba(4, 9, 17, 0.46);
  border-color: rgba(255, 255, 255, 0.18);
}

body.theme-clear .valuation-source-row,
body.theme-clear .sold-more-note {
  color: #f6f8fc;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(146, 184, 255, 0.04)),
    rgba(5, 11, 22, 0.35);
  border-color: rgba(159, 186, 255, 0.2);
}

body.theme-clear .valuation-source-row span,
body.theme-clear .valuation-source-row small,
body.theme-clear .sold-more-note {
  color: rgba(246, 248, 252, 0.76);
}

body.theme-clear .valuation-source-row strong {
  color: #7df4e7;
}

body.theme-clear .valuation-confidence {
  color: #06110f;
  background: rgba(255, 209, 102, 0.82);
  border-color: rgba(255, 255, 255, 0.36);
}

body.theme-clear .valuation-confidence.high {
  background: rgba(125, 244, 231, 0.82);
}

body.theme-clear .valuation-confidence.low {
  background: rgba(255, 183, 135, 0.82);
}

body.theme-clear .status-chip,
body.theme-clear .app-account-card span,
body.theme-clear .portfolio-currency-pill span {
  color: #06110f;
  background: rgba(255, 209, 102, 0.86);
}

body.theme-clear .bottom-nav {
  color: rgba(246, 248, 252, 0.62);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.055)),
    rgba(8, 14, 24, 0.64);
  border-color: rgba(255, 255, 255, 0.24);
}

body.theme-clear .bottom-nav .active {
  color: #f8fbff;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.34);
}

body.theme-clear .app-menu-action-row button:disabled {
  color: rgba(246, 248, 252, 0.36);
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(255, 255, 255, 0.1);
}

/* Clear mode text color system */
body.theme-clear {
  --clear-text: #f8fbff;
  --clear-muted: #b8c6dd;
  --clear-label: #b7c8ff;
  --clear-aqua: #8de1d9;
  --clear-blue: #9fbaff;
  --clear-lavender: #c7b8ff;
  --clear-gold: #ffd166;
  --clear-coral: #ff9f92;
}

body.theme-clear .eyebrow,
body.theme-clear .portfolio-pulse-footer span,
body.theme-clear .snapshot-body > span,
body.theme-clear .vendor-line-main small,
body.theme-clear .vendor-summary-grid span,
body.theme-clear .vendor-quote-strip span,
body.theme-clear .app-menu-tool span,
body.theme-clear .app-setting-row span,
body.theme-clear .collection-tab .card-topline p,
body.theme-clear .scanner-search label {
  color: var(--clear-label);
}

body.theme-clear .portfolio-pulse-copy h2 strong,
body.theme-clear #collectionActiveTitle,
body.theme-clear .collection-active-row strong,
body.theme-clear .collection-tab .card-topline h3,
body.theme-clear .vendor-hero-card h2 {
  color: var(--clear-aqua);
  background: linear-gradient(90deg, var(--clear-aqua), var(--clear-blue) 58%, var(--clear-lavender));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: none;
}

body.theme-clear #portfolioHeroValue,
body.theme-clear #portfolioGraphGain,
body.theme-clear .snapshot-body strong,
body.theme-clear .value-hub strong,
body.theme-clear .vendor-summary-grid strong,
body.theme-clear .vendor-quote-strip strong,
body.theme-clear .portfolio-pulse-copy > span,
body.theme-clear .portfolio-pulse-footer strong {
  color: var(--clear-aqua);
  text-shadow: 0 0 24px rgba(141, 225, 217, 0.16);
}

body.theme-clear #portfolioHeroSub.negative,
body.theme-clear #portfolioGraphGain.negative,
body.theme-clear .portfolio-pulse-copy > span.negative,
body.theme-clear .portfolio-pulse-footer strong.negative,
body.theme-clear .value-hub strong.negative {
  color: var(--clear-coral);
  text-shadow: 0 0 24px rgba(255, 159, 146, 0.16);
}

body.theme-clear #portfolioGraphSummary,
body.theme-clear .collector-app .scanner-status,
body.theme-clear .snapshot-body p,
body.theme-clear .snapshot-body small,
body.theme-clear .collection-active-row span,
body.theme-clear .vendor-line-main p,
body.theme-clear .app-account-card p {
  color: var(--clear-muted);
}

body.theme-clear .status-chip,
body.theme-clear .app-account-card span,
body.theme-clear .portfolio-currency-pill span {
  color: #201607;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.24), var(--clear-gold));
}

body.theme-clear .app-menu-tabs button.is-active,
body.theme-clear .theme-toggle button.is-active {
  color: #06110f;
}

body.theme-clear .bottom-nav .active {
  color: var(--clear-aqua);
}

body.theme-clear .bottom-nav .scan-tab,
body.theme-clear .bottom-nav .scan-tab span {
  color: #06110f;
}

body.theme-clear .bottom-nav {
  position: fixed;
  left: 50%;
  bottom: max(10px, env(safe-area-inset-bottom));
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  width: min(430px, calc(100% - 28px));
  transform: translateX(-50%);
}

body.theme-clear .portfolio-mode-tabs button.is-active,
body.theme-clear .portfolio-range-tabs button.is-active {
  color: var(--clear-aqua);
  text-shadow: none;
}

body.theme-clear .portfolio-mode-tabs button.is-active::after,
body.theme-clear .portfolio-range-tabs button.is-active::after {
  background: linear-gradient(90deg, var(--clear-aqua), var(--clear-blue));
  opacity: 0.9;
}

/* Prism color lift for clear mode */
body.theme-clear {
  --clear-text: #fbfdff;
  --clear-muted: #c7d3e8;
  --clear-label: #c7d7ff;
  --clear-aqua: #7df4e7;
  --clear-blue: #92b8ff;
  --clear-lavender: #d2b8ff;
  --clear-pink: #ffa8d2;
  --clear-gold: #ffd86f;
  --clear-coral: #ff9f92;
}

body.theme-clear,
body.theme-clear.collector-home {
  background:
    linear-gradient(118deg, rgba(125, 244, 231, 0.16), rgba(125, 244, 231, 0) 24%, rgba(146, 184, 255, 0.18) 48%, rgba(210, 184, 255, 0.11) 72%, rgba(255, 216, 111, 0.09)),
    linear-gradient(180deg, #050b14 0%, #0d1928 44%, #07111d 100%);
}

body.theme-clear .hero-value-card,
body.theme-clear .scan-card,
body.theme-clear .market-card,
body.theme-clear .collection-tab-head,
body.theme-clear .collection-detail-panel,
body.theme-clear .collection-section-panel,
body.theme-clear .collection-tab .collection-card,
body.theme-clear .vendor-hero-card,
body.theme-clear .vendor-deal-card,
body.theme-clear .vendor-ledger-card,
body.theme-clear .vendor-summary-grid article,
body.theme-clear .portfolio-pulse-card,
body.theme-clear .app-menu-panel,
body.theme-clear .app-account-card,
body.theme-clear .app-setting-row,
body.theme-clear .app-menu-tool {
  background:
    linear-gradient(146deg, rgba(255, 255, 255, 0.19), rgba(255, 255, 255, 0.064) 42%, rgba(125, 244, 231, 0.05) 70%, rgba(210, 184, 255, 0.045)),
    rgba(7, 15, 27, 0.6);
  border-color: rgba(159, 186, 255, 0.3);
  box-shadow:
    0 32px 86px rgba(0, 0, 0, 0.38),
    0 10px 34px rgba(125, 244, 231, 0.09),
    inset 0 1px 1px rgba(255, 255, 255, 0.62),
    inset 0 -1px 0 rgba(125, 244, 231, 0.12);
}

body.theme-clear .portfolio-pulse-card,
body.theme-clear .scan-card,
body.theme-clear .market-card {
  background:
    linear-gradient(145deg, rgba(125, 244, 231, 0.12), rgba(255, 255, 255, 0.07) 38%, rgba(146, 184, 255, 0.075) 64%, rgba(210, 184, 255, 0.055)),
    rgba(8, 17, 31, 0.62);
}

body.theme-clear .portfolio-pulse-card::before,
body.theme-clear .scan-card::before,
body.theme-clear .market-card::before,
body.theme-clear .collection-tab-head::before,
body.theme-clear .collection-tab .collection-card::before,
body.theme-clear .vendor-hero-card::before,
body.theme-clear .app-menu-panel::before,
body.theme-clear .bottom-nav::before {
  background:
    linear-gradient(126deg, rgba(255, 255, 255, 0.36), rgba(125, 244, 231, 0.12) 28%, rgba(146, 184, 255, 0.1) 52%, rgba(210, 184, 255, 0.08) 72%, rgba(255, 255, 255, 0)),
    linear-gradient(315deg, rgba(255, 216, 111, 0.08), rgba(255, 255, 255, 0) 42%);
  opacity: 0.82;
}

body.theme-clear .dashboard-header h1,
body.theme-clear .hero-copy h2,
body.theme-clear .section-row h2,
body.theme-clear .collection-tab-head h2,
body.theme-clear .portfolio-pulse-copy h2,
body.theme-clear .app-menu-head h2,
body.theme-clear #scannerTitle,
body.theme-clear #soldDataTitle {
  color: var(--clear-text);
  text-shadow: 0 12px 34px rgba(0, 0, 0, 0.3);
}

body.theme-clear .portfolio-pulse-copy h2 strong,
body.theme-clear #collectionActiveTitle,
body.theme-clear .collection-active-row strong,
body.theme-clear .collection-tab .card-topline h3,
body.theme-clear .vendor-hero-card h2,
body.theme-clear .sold-title-row h4 {
  color: var(--clear-aqua);
  background: linear-gradient(92deg, var(--clear-aqua), var(--clear-blue) 45%, var(--clear-lavender) 78%, var(--clear-pink));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: none;
}

body.theme-clear .eyebrow,
body.theme-clear .portfolio-pulse-footer span,
body.theme-clear .snapshot-body > span,
body.theme-clear .vendor-line-main small,
body.theme-clear .vendor-summary-grid span,
body.theme-clear .vendor-quote-strip span,
body.theme-clear .app-menu-tool span,
body.theme-clear .app-setting-row span,
body.theme-clear .collection-tab .card-topline p,
body.theme-clear .scanner-search label {
  color: var(--clear-label);
  text-shadow: 0 0 18px rgba(146, 184, 255, 0.16);
}

body.theme-clear #portfolioHeroValue,
body.theme-clear #portfolioGraphGain,
body.theme-clear .snapshot-body strong,
body.theme-clear .value-hub strong,
body.theme-clear .vendor-summary-grid strong,
body.theme-clear .vendor-quote-strip strong,
body.theme-clear .portfolio-pulse-copy > span,
body.theme-clear .portfolio-pulse-footer strong {
  color: var(--clear-aqua);
  text-shadow:
    0 0 18px rgba(125, 244, 231, 0.18),
    0 0 36px rgba(146, 184, 255, 0.12);
}

body.theme-clear #portfolioHeroSub.negative,
body.theme-clear #portfolioGraphGain.negative,
body.theme-clear .portfolio-pulse-copy > span.negative,
body.theme-clear .portfolio-pulse-footer strong.negative,
body.theme-clear .value-hub strong.negative {
  color: var(--clear-coral);
  text-shadow: 0 0 26px rgba(255, 159, 146, 0.2);
}

body.theme-clear #portfolioGraphSummary,
body.theme-clear .collector-app .scanner-status,
body.theme-clear .snapshot-body p,
body.theme-clear .snapshot-body small,
body.theme-clear .collection-active-row span,
body.theme-clear .vendor-line-main p,
body.theme-clear .app-account-card p {
  color: var(--clear-muted);
}

body.theme-clear .portfolio-range-tabs,
body.theme-clear .portfolio-currency-pill,
body.theme-clear .app-menu-tabs,
body.theme-clear .theme-toggle {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.14), rgba(125, 244, 231, 0.05) 54%, rgba(210, 184, 255, 0.045)),
    rgba(4, 10, 20, 0.5);
  border-color: rgba(159, 186, 255, 0.24);
}

body.theme-clear .app-menu-tabs button.is-active,
body.theme-clear .theme-toggle button.is-active,
body.theme-clear .primary-action,
body.theme-clear .save-inventory-btn,
body.theme-clear .scan-icon-button,
body.theme-clear .home-action-strip > :first-child,
body.theme-clear .vendor-form-actions button:first-child,
body.theme-clear .app-menu-action-row button:first-child,
body.theme-clear .app-setting-row > button {
  color: #04110f;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.32), rgba(125, 244, 231, 0.82) 52%, rgba(146, 184, 255, 0.54)),
    rgba(125, 244, 231, 0.72);
  border-color: rgba(255, 255, 255, 0.44);
  box-shadow:
    0 18px 42px rgba(125, 244, 231, 0.18),
    inset 0 1px 1px rgba(255, 255, 255, 0.68),
    inset 0 -1px 0 rgba(4, 17, 15, 0.18);
}

body.theme-clear .home-action-strip a,
body.theme-clear .home-action-strip button,
body.theme-clear .icon-button,
body.theme-clear .collection-back-btn,
body.theme-clear .vendor-form-actions button,
body.theme-clear .vendor-ledger-actions button,
body.theme-clear .app-menu-head button,
body.theme-clear .app-menu-action-row button {
  color: var(--clear-text);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.16), rgba(146, 184, 255, 0.055) 58%, rgba(210, 184, 255, 0.045)),
    rgba(6, 13, 24, 0.54);
  border-color: rgba(159, 186, 255, 0.24);
}

body.theme-clear input,
body.theme-clear select,
body.theme-clear textarea,
body.theme-clear .vendor-deal-form input,
body.theme-clear .scanner-search input {
  color: var(--clear-text);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.13), rgba(125, 244, 231, 0.035) 58%, rgba(146, 184, 255, 0.035)),
    rgba(3, 8, 16, 0.52);
  border-color: rgba(159, 186, 255, 0.28);
}

body.theme-clear input::placeholder,
body.theme-clear textarea::placeholder,
body.theme-clear .scanner-search input::placeholder {
  color: rgba(199, 211, 232, 0.58);
}

body.theme-clear .portfolio-pulse-card .value-path {
  stroke: var(--clear-aqua);
  filter: drop-shadow(0 0 14px rgba(125, 244, 231, 0.3));
}

body.theme-clear .portfolio-pulse-card .cost-path {
  stroke: rgba(255, 216, 111, 0.74);
}

body.theme-clear .portfolio-pulse-card .graph-label {
  fill: rgba(199, 215, 255, 0.76);
}

body.theme-clear .status-chip,
body.theme-clear .app-account-card span,
body.theme-clear .portfolio-currency-pill span {
  color: #1d1504;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.32), var(--clear-gold));
  box-shadow: 0 10px 24px rgba(255, 216, 111, 0.18), inset 0 1px 1px rgba(255, 255, 255, 0.68);
}

body.theme-clear .bottom-nav {
  position: fixed;
  left: 50%;
  bottom: max(10px, env(safe-area-inset-bottom));
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  width: min(430px, calc(100% - 28px));
  color: rgba(199, 215, 255, 0.78);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.17), rgba(125, 244, 231, 0.055) 52%, rgba(210, 184, 255, 0.045)),
    rgba(5, 12, 23, 0.74);
  border-color: rgba(159, 186, 255, 0.3);
  transform: translateX(-50%);
}

body.theme-clear .bottom-nav .active {
  color: var(--clear-aqua);
  background: rgba(125, 244, 231, 0.12);
}

@media (max-width: 430px) {
  .app-setting-row {
    flex-direction: column;
    align-items: stretch;
  }

  .theme-toggle,
  .app-setting-row > button {
    width: 100%;
    min-width: 0;
  }
}

.collection-tab.is-section-detail .collection-portfolio-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 560px;
  padding: 18px 16px 17px;
  color: #f7f8fb;
  background: #030406;
  border: 1px solid #272b33;
  border-radius: 10px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 18px 42px rgba(0, 0, 0, 0.24);
  overflow: hidden;
}

body.theme-light .collection-tab.is-section-detail .collection-portfolio-card,
body.theme-clear .collection-tab.is-section-detail .collection-portfolio-card {
  color: #f7f8fb;
  background: #030406;
  border-color: #272b33;
}

.collection-tab.is-section-detail .collection-portfolio-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 28%);
}

.collection-tab.is-section-detail .collection-portfolio-card > * {
  position: relative;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-image-wrap {
  min-height: 250px;
  align-content: start;
}

.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .portfolio-slab-preview {
  width: min(184px, 90%);
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy {
  gap: 4px;
  min-height: 128px;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy h3 {
  color: #f7f8fb;
  font-size: 1.18rem;
  line-height: 1.08;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy p {
  color: rgba(247, 248, 251, 0.86);
  font-size: 0.84rem;
  line-height: 1.2;
  font-weight: 760;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy .portfolio-card-condition {
  display: flex;
  align-items: flex-start;
  gap: 5px;
  color: rgba(247, 248, 251, 0.68);
  font-weight: 820;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-condition span:last-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.portfolio-card-grader-mark {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  color: #f7f8fb;
  font-size: 0.92rem;
  line-height: 1;
  font-weight: 950;
}

.portfolio-card-grader-mark-psa span:nth-child(1),
.portfolio-card-grader-mark-psa span:nth-child(3) {
  color: #0874bf;
}

.portfolio-card-grader-mark-psa span:nth-child(2) {
  color: #f04438;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer {
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: 8px;
  align-items: end;
  margin-top: auto;
  padding-top: 10px;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory {
  gap: 4px;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory button {
  display: block;
  width: 100%;
  max-width: 100%;
  min-height: auto;
  padding: 0;
  color: #f7f8fb;
  background: transparent;
  border: 0;
  border-radius: 0;
  overflow: hidden;
  font-size: 0.82rem;
  line-height: 1.15;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory button + button {
  color: rgba(247, 248, 251, 0.62);
  font-size: 0.72rem;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer > span:last-child {
  gap: 2px;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer strong {
  color: #f7f8fb;
  font-size: 1.05rem;
  line-height: 1.05;
  font-weight: 880;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer small {
  color: rgba(247, 248, 251, 0.82);
  font-size: 0.78rem;
  line-height: 1.12;
  font-weight: 760;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer .positive strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer .positive small {
  color: #74ccc3;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer .negative strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer .negative small {
  color: #ff917f;
}

.collection-tab.is-section-detail .collection-portfolio-card .card-actions {
  gap: 7px;
  margin-top: 2px;
  padding-top: 0;
  opacity: 0.78;
}

.collection-tab.is-section-detail .collection-portfolio-card .card-actions a,
.collection-tab.is-section-detail .collection-portfolio-card .card-actions button {
  min-height: 28px;
  padding: 0 9px;
  color: rgba(247, 248, 251, 0.9);
  background: rgba(255, 255, 255, 0.065);
  border-color: rgba(255, 255, 255, 0.14);
  font-size: 0.72rem;
}

@media (max-width: 430px) {
  .collection-tab.is-section-detail .collection-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .collection-tab.is-section-detail .collection-portfolio-card {
    min-height: auto;
    padding: 15px 14px 14px;
    gap: 10px;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-image-wrap {
    min-height: 230px;
  }

  .collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .portfolio-slab-preview {
    width: min(170px, 72vw);
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy {
    min-height: auto;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy h3 {
    font-size: 1.26rem;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy p {
    font-size: 0.9rem;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding-top: 6px;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer > span:last-child {
    justify-items: end;
    text-align: right;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer strong {
    font-size: 1.16rem;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer small,
  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory button {
    font-size: 0.82rem;
  }
}

/* MEMORY LINE: PSA PORTFOLIO SLAB START */
/* MEMORY LINE: Correct PSA Slab Renderer START */
.psa-slab-render {
  position: relative;
  display: block;
  width: min(128px, 100%);
  aspect-ratio: 977 / 1610;
  container-type: inline-size;
  isolation: isolate;
  padding: 0;
  overflow: visible;
  color: #050505;
  background: transparent;
  border: 0;
  border-radius: 6px;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.34);
}

.psa-slab-render::before,
.psa-slab-render::after {
  display: none;
}

.psa-slab-template {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}

/* MEMORY LINE: Exact PSA Label Template START */
.psa-slab-grade-label {
  position: absolute;
  top: 4.7%;
  left: 9.05%;
  z-index: 4;
  display: block;
  width: 81.9%;
  height: auto;
  aspect-ratio: 1166 / 386;
  box-sizing: border-box;
  padding: 0;
  overflow: visible;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  pointer-events: none;
}

.psa-label-template {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: fill;
  pointer-events: none;
}
/* MEMORY LINE: Exact PSA Label Template END */

/* MEMORY LINE: PSA Dynamic Label Text START */
.psa-label-grade-text-mask,
.psa-label-grade-number-mask {
  position: absolute;
  z-index: 2;
  display: block;
  background: #ffffff;
  pointer-events: none;
}

.psa-label-grade-text-mask {
  left: 6.9%;
  top: 21.7%;
  width: 41%;
  height: 29.5%;
}

.psa-label-grade-number-mask {
  right: 6.7%;
  top: 18.4%;
  width: 32.5%;
  height: 49%;
}

.portfolio-slab-label-grade-text {
  position: absolute;
  left: 7.05%;
  top: 22.2%;
  z-index: 3;
  display: block;
  max-width: 40.5%;
  overflow: hidden;
  color: #030303;
  font-size: clamp(8px, 9.5cqw, 74px);
  line-height: 0.95;
  font-weight: 430;
  letter-spacing: 0;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.portfolio-slab-label-grade-number {
  position: absolute;
  right: 7.8%;
  top: 15.7%;
  z-index: 3;
  color: #030303;
  font-size: clamp(18px, 23cqw, 162px);
  font-weight: 360;
  line-height: 0.96;
  letter-spacing: 0;
  text-align: right;
}
/* MEMORY LINE: PSA Dynamic Label Text END */

.portfolio-slab-sr-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
/* MEMORY LINE: Correct PSA Slab Renderer END */

/* MEMORY LINE: PSA Card Window Placement START */
.psa-slab-card-window {
  position: absolute;
  left: 16.7%;
  top: 32.4%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 66.6%;
  height: 53.8%;
  overflow: hidden;
  background: #171717;
  border: 0;
  border-radius: 8.5% / 5.8%;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.08),
    inset 0 0 16px rgba(0, 0, 0, 0.38);
}

.psa-slab-card-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  background: #171717;
  border-radius: 6.8% / 4.6%;
  filter: saturate(1.03) contrast(1.02);
}

.psa-slab-card-fallback {
  display: grid;
  place-items: center;
  width: 86%;
  min-height: 42%;
  color: rgba(255, 255, 255, 0.72);
  border: 1px dashed rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  font-size: clamp(6px, 5cqw, 18px);
  font-weight: 760;
  line-height: 1.1;
  text-align: center;
}
/* MEMORY LINE: PSA Card Window Placement END */

/* MEMORY LINE: Blank CGC Template Integration START */
.cgc-slab-render {
  position: relative;
  display: block;
  width: min(128px, 100%);
  aspect-ratio: 967 / 1627;
  container-type: inline-size;
  isolation: isolate;
  padding: 0;
  overflow: visible;
  color: #050505;
  background: transparent;
  border: 0;
  border-radius: 6px;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.34);
}

.cgc-slab-render::before,
.cgc-slab-render::after {
  display: none;
}

.cgc-slab-template {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}
/* MEMORY LINE: Blank CGC Template Integration END */

/* MEMORY LINE: CGC Pristine Template Integration START */
.cgc-pristine-slab-render {
  position: relative;
  display: block;
  width: min(128px, 100%);
  aspect-ratio: 958 / 1642;
  container-type: inline-size;
  isolation: isolate;
  padding: 0;
  overflow: visible;
  color: #050505;
  background: transparent;
  border: 0;
  border-radius: 6px;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.34);
}

.cgc-pristine-slab-render::before,
.cgc-pristine-slab-render::after {
  display: none;
}

.cgc-pristine-slab-template {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
}
/* MEMORY LINE: CGC Pristine Template Integration END */

/* MEMORY LINE: CGC Card Window Placement START */
.cgc-slab-card-window {
  position: absolute;
  left: 13.8%;
  top: 31.85%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 72%;
  height: 64%;
  overflow: hidden;
  border: 0;
  border-radius: 1.8% / 1.2%;
}

.cgc-slab-card-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  border-radius: 1.6% / 1.05%;
}
/* MEMORY LINE: CGC Card Window Placement END */

/* MEMORY LINE: CGC Pristine Card Window Placement START */
.cgc-pristine-card-window {
  position: absolute;
  left: 10.35%;
  top: 28.75%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 79.3%;
  height: 66%;
  overflow: hidden;
  border: 0;
  border-radius: 0.4%;
}

.cgc-pristine-card-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  border-radius: 0.4%;
}
/* MEMORY LINE: CGC Pristine Card Window Placement END */

/* MEMORY LINE: CGC Dynamic Grade Overlay START */
.cgc-slab-grade-label {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: block;
  pointer-events: none;
}

.cgc-slab-label-grade-text {
  position: absolute;
  left: 11.7%;
  top: 17.75%;
  z-index: 3;
  display: block;
  width: 50.8%;
  overflow: hidden;
  color: #030303;
  font-size: clamp(5px, 4.8cqw, 34px);
  line-height: 1;
  font-weight: 820;
  letter-spacing: 0;
  text-align: center;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
  transform: translateY(-50%);
}

.cgc-slab-label-grade-number {
  position: absolute;
  left: 66%;
  top: 17.75%;
  z-index: 3;
  display: grid;
  width: 18%;
  color: #030303;
  font-size: clamp(11px, 11cqw, 76px);
  font-weight: 820;
  line-height: 0.95;
  letter-spacing: 0;
  text-align: center;
  white-space: nowrap;
  transform: translateY(-50%);
}
/* MEMORY LINE: CGC Dynamic Grade Overlay END */

/* MEMORY LINE: Vault Slab Thumbnail Fit Fix START */
.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .portfolio-card-image-wrap {
  width: 128px;
  max-width: 128px;
  aspect-ratio: 977 / 1610;
  min-height: 0;
  padding: 6px;
  overflow: visible;
}

.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .psa-slab-render,
.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .cgc-slab-render,
.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .cgc-pristine-slab-render {
  width: 100%;
  max-width: 100%;
}

.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio {
  grid-template-columns: 136px minmax(0, 1fr);
  overflow: visible;
}

@media (max-width: 380px) {
  .collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .portfolio-card-image-wrap {
    width: 112px;
    max-width: 112px;
  }

  .collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio {
    grid-template-columns: 120px minmax(0, 1fr);
  }
}
/* MEMORY LINE: Vault Slab Thumbnail Fit Fix END */
/* MEMORY LINE: PSA PORTFOLIO SLAB END */

/* MEMORY LINE: VENDOR LEDGER TYPOGRAPHY START */
.vendor-ledger-card,
.vendor-ledger-card * {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
}

.vendor-ledger-card {
  gap: 10px;
  padding: 14px;
  color: #ffffff;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.092), rgba(255, 255, 255, 0.034)),
    rgba(8, 12, 18, 0.96);
  border-color: rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  box-shadow: 0 24px 58px rgba(0, 0, 0, 0.36);
}

.vendor-ledger-card .vendor-section-head {
  align-items: center;
  gap: 8px;
}

.vendor-ledger-card .vendor-section-head > div:first-child {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.vendor-ledger-card .vendor-section-head h2 {
  margin: 0;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #ffffff;
  line-height: 1.05;
}

.vendor-ledger-card .eyebrow {
  margin: 0;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: rgba(138, 176, 255, 0.72);
  line-height: 1;
  text-transform: uppercase;
}

.vendor-ledger-list {
  gap: 12px;
}

.vendor-ledger-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 14px;
  color: #ffffff;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.078), rgba(255, 255, 255, 0.03)),
    rgba(13, 18, 27, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 36px rgba(0, 0, 0, 0.24);
}

.vendor-ledger-line.has-thumb {
  grid-template-columns: 58px minmax(0, 1fr);
}

.vendor-ledger-line.has-thumb .vendor-line-side {
  grid-column: 1 / -1;
}

.vendor-line-thumb {
  width: 58px;
  height: 80px;
  border-radius: 10px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28);
}

.vendor-line-main {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.vendor-ledger-card .vendor-line-type {
  display: block;
  font-family: inherit;
  font-size: clamp(0.8125rem, 3.1vw, 0.9375rem);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.38;
  color: rgba(255, 255, 255, 0.6);
  text-transform: none;
}

.vendor-ledger-card .vendor-line-main .vendor-line-name {
  display: block;
  margin: 0;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: clamp(1.375rem, 5.2vw, 1.625rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.06;
  color: #ffffff;
  overflow-wrap: anywhere;
}

.vendor-ledger-card .vendor-line-main .vendor-line-details {
  display: block;
  margin: 2px 0 0;
  font-family: inherit;
  font-size: clamp(0.8125rem, 3.1vw, 0.9375rem);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.38;
  color: rgba(255, 255, 255, 0.6);
}

.vendor-ledger-card .vendor-line-main .vendor-line-secondary {
  display: block;
  margin: 0;
  font-family: inherit;
  font-size: clamp(0.8125rem, 3.1vw, 0.9375rem);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.38;
  color: rgba(255, 255, 255, 0.6);
}

.vendor-ledger-card .vendor-line-main .vendor-line-save-note {
  display: block;
  margin: 0;
  font-family: inherit;
  font-size: clamp(0.8125rem, 3.1vw, 0.9375rem);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.38;
  color: rgba(255, 255, 255, 0.6);
}

.vendor-line-side {
  display: flex;
  width: 100%;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.vendor-ledger-card .vendor-line-side strong {
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: clamp(1.75rem, 6.8vw, 2.125rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #7df4e7;
  line-height: 1;
  text-shadow: 0 0 24px rgba(125, 244, 231, 0.16);
  white-space: nowrap;
}

.vendor-ledger-card .vendor-line-side.negative strong {
  color: #ff917f;
  text-shadow: 0 0 24px rgba(255, 145, 127, 0.14);
}

.vendor-line-actions button {
  min-height: 38px;
  padding: 0 14px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.095);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-family: "SF Pro Text", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 0.9375rem;
  font-weight: 600;
  border-radius: 999px;
  letter-spacing: 0;
  line-height: 1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.vendor-ledger-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: nowrap;
}

.vendor-ledger-actions button {
  min-height: 30px;
  padding: 0 10px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.095);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-family: "SF Pro Text", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 12px;
  font-weight: 600;
  border-radius: 999px;
  letter-spacing: 0;
  line-height: 1;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.vendor-line-actions {
  display: flex;
  width: auto;
  min-width: 0;
  justify-content: flex-end;
  gap: 6px;
}

.vendor-line-add {
  color: #dffffb;
  background: rgba(125, 244, 231, 0.16);
  border-color: rgba(125, 244, 231, 0.3);
}

.vendor-line-add[disabled] {
  color: rgba(255, 255, 255, 0.48);
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.1);
}

.vendor-line-delete {
  color: rgba(255, 255, 255, 0.88);
}

@media (min-width: 720px) {
  .vendor-ledger-line {
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 22px;
  }

  .vendor-ledger-line.has-thumb {
    grid-template-columns: 68px minmax(0, 1fr) auto;
  }

  .vendor-ledger-line.has-thumb .vendor-line-side {
    grid-column: auto;
  }

  .vendor-line-thumb {
    width: 68px;
    height: 94px;
  }

  .vendor-line-side {
    display: grid;
    width: auto;
    justify-items: end;
    align-content: start;
  }
}

@media (max-width: 430px) {
  .vendor-ledger-card {
    padding: 16px;
  }

  .vendor-ledger-actions {
    align-self: center;
  }

  .vendor-line-side {
    align-items: flex-end;
  }

  .vendor-line-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }

  .vendor-line-actions button {
    min-width: 82px;
  }
}
/* MEMORY LINE: VENDOR LEDGER TYPOGRAPHY END */

/* MEMORY LINE: VENDOR SECONDARY TYPOGRAPHY START */
.vendor-tab,
.vendor-tab * {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Arial, sans-serif;
}

.vendor-tab .vendor-quick-actions span,
.vendor-tab .vendor-summary-grid span,
.vendor-tab .vendor-quote-strip span,
.vendor-tab .vendor-batch-empty span,
.vendor-tab .vendor-batch-list p,
.vendor-tab .vendor-batch-list small,
.vendor-tab .vendor-batch-stats span,
.vendor-tab .vendor-deal-form input::placeholder,
.vendor-tab .vendor-ledger-card .vendor-line-type,
.vendor-tab .vendor-ledger-card .vendor-line-main .vendor-line-details,
.vendor-tab .vendor-ledger-card .vendor-line-main .vendor-line-secondary,
.vendor-tab .vendor-ledger-card .vendor-line-main .vendor-line-save-note,
.vendor-tab .vendor-ledger-card .empty-state span {
  font-family: inherit;
  font-size: clamp(0.8125rem, 3.1vw, 0.9375rem);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.38;
  color: rgba(255, 255, 255, 0.6);
  text-transform: none;
}

.vendor-tab .vendor-deal-form input {
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.38;
}

.vendor-tab .vendor-deal-form input::placeholder {
  opacity: 1;
}

.vendor-tab .vendor-deal-form label {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.25;
}

.vendor-tab .eyebrow {
  font-weight: 600;
}

.vendor-tab .vendor-batch-card .vendor-section-head h2,
.vendor-tab .vendor-deal-card .vendor-section-head h2 {
  font-size: clamp(1.25rem, 5vw, 1.45rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.02;
}

.vendor-tab .vendor-section-head > span,
.vendor-tab .vendor-mode-toggle span,
.vendor-tab .vendor-form-actions button,
.vendor-tab .vendor-ledger-actions button,
.vendor-tab .vendor-batch-actions button,
.vendor-tab .vendor-line-actions button {
  font-weight: 600;
  letter-spacing: 0;
}

.vendor-tab .vendor-quick-actions strong,
.vendor-tab .vendor-batch-empty strong,
.vendor-tab .vendor-batch-list strong {
  font-weight: 600;
  letter-spacing: -0.01em;
}

.vendor-tab .vendor-summary-grid strong,
.vendor-tab .vendor-quote-strip strong {
  font-weight: 700;
  letter-spacing: -0.02em;
}
/* MEMORY LINE: VENDOR SECONDARY TYPOGRAPHY END */

/* MEMORY LINE: MOBILE VIEWPORT GUARD START */
html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

.collector-app,
.mobile-app {
  width: 100%;
  max-width: 430px;
  min-width: 0;
}

body.is-collection-detail .collector-app {
  width: 100%;
  max-width: 760px;
}

.collector-app > *,
.app-view,
.hero-value-card,
.scan-card,
.market-card,
.portfolio-pulse-card,
.collection-detail-panel,
.vendor-tab,
.vendor-hero-card,
.vendor-deal-card,
.vendor-ledger-card,
.vendor-batch-card {
  min-width: 0;
  max-width: 100%;
}

@media (max-width: 430px) {
  .collector-app {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .bottom-nav {
    width: calc(100% - 20px);
  }

  .home-action-strip,
  .vendor-batch-actions,
  .vendor-form-actions,
  .vendor-ledger-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .home-action-strip > *,
  .vendor-batch-actions button,
  .vendor-form-actions button,
  .vendor-ledger-actions button {
    min-width: 0;
    padding-inline: 8px;
    white-space: normal;
  }

  .vendor-hero-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 72px;
    align-items: center;
  }
}
/* MEMORY LINE: MOBILE VIEWPORT GUARD END */

/* MEMORY LINE: MOBILE DOCK NAV START */
.bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: stretch;
  gap: 1px;
  width: min(398px, calc(100vw - 40px));
  min-height: 78px;
  padding: 8px 6px max(9px, env(safe-area-inset-bottom));
  overflow: visible;
  color: #98a3ad;
  background:
    linear-gradient(180deg, rgba(24, 33, 43, 0.74), rgba(8, 13, 20, 0.58)),
    rgba(8, 13, 20, 0.58);
  border: 1px solid rgba(214, 244, 241, 0.14);
  border-radius: 28px;
  box-shadow:
    0 16px 36px rgba(0, 0, 0, 0.36),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -1px 0 rgba(255, 255, 255, 0.035);
  transform: translateX(-50%);
  backdrop-filter: blur(26px) saturate(170%);
  -webkit-backdrop-filter: blur(26px) saturate(170%);
}

.bottom-nav > * {
  position: relative;
  z-index: 1;
}

.bottom-nav a {
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 58px;
  padding: 7px 0 6px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  overflow: visible;
  color: inherit;
  background: transparent;
  border-radius: 20px;
  font-size: 0.6rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
  text-decoration: none;
  text-transform: none;
  -webkit-tap-highlight-color: transparent;
  transition: color 160ms ease, transform 160ms ease, opacity 160ms ease;
}

.bottom-nav a::before {
  content: "";
  display: none;
}

.bottom-nav a:not(.scan-tab)::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -4px;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  display: none;
  opacity: 0;
  background: #65c5bb;
  box-shadow: 0 0 12px rgba(101, 197, 187, 0.9);
  transform: translateX(-50%) scale(0.72);
  transition: opacity 160ms ease, transform 160ms ease;
}

.bottom-nav .scan-tab::after {
  content: "";
  display: none;
}

.bottom-nav svg {
  width: 24px;
  height: 24px;
  box-sizing: border-box;
  flex: 0 0 auto;
  color: currentColor;
  opacity: 0.78;
  filter: none;
  transition: opacity 160ms ease, transform 160ms ease, color 160ms ease, filter 160ms ease;
}

.bottom-nav a:not(.scan-tab) span {
  display: block;
  max-width: 100%;
  overflow: hidden;
  color: currentColor;
  white-space: nowrap;
  text-overflow: clip;
}

.bottom-nav a span,
.bottom-nav .scan-tab span {
  font-size: 0.6rem;
  font-weight: 500;
}

.bottom-nav a.active,
.bottom-nav a[aria-current="page"] {
  color: #f8fbff;
  background: transparent;
}

.bottom-nav a.active:not(.scan-tab),
.bottom-nav a[aria-current="page"]:not(.scan-tab) {
  background: transparent;
  box-shadow: none;
}

.bottom-nav a:not(.scan-tab).active::after {
  opacity: 0;
  transform: translateX(-50%) scale(0.72);
}

.bottom-nav a.active svg,
.bottom-nav a[aria-current="page"] svg,
.bottom-nav a:active svg {
  color: #7ed3ca;
  opacity: 1;
  filter: drop-shadow(0 0 12px rgba(126, 211, 202, 0.58));
  transform: translateY(-1px);
}

.bottom-nav .scan-tab {
  align-self: stretch;
  min-height: 58px;
  padding: 7px 0 6px;
  justify-content: center;
  gap: 4px;
  color: inherit;
  background: transparent;
  transform: none;
}

.bottom-nav .scan-tab svg {
  width: 24px;
  height: 24px;
  padding: 0;
  color: currentColor;
  opacity: 0.78;
  background: transparent;
  border-radius: 0;
  box-shadow: none;
  filter: none;
}

.bottom-nav .scan-tab span {
  display: block;
  margin-top: 0;
  color: currentColor;
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1;
  text-shadow: none;
}

.bottom-nav .scan-tab.active svg {
  color: #7ed3ca;
  background: transparent;
  box-shadow: none;
  filter: drop-shadow(0 0 12px rgba(126, 211, 202, 0.58));
}

.bottom-nav .scan-tab:active {
  transform: none;
}

body.theme-light .bottom-nav {
  color: rgba(23, 32, 51, 0.56);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(240, 248, 248, 0.64)),
    rgba(255, 255, 255, 0.58);
  border-color: rgba(23, 32, 51, 0.12);
  box-shadow:
    0 16px 34px rgba(23, 32, 51, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

body.theme-light .bottom-nav a.active,
body.theme-light .bottom-nav a[aria-current="page"] {
  color: #172033;
  background: transparent;
}

body.theme-light .bottom-nav a.active svg,
body.theme-light .bottom-nav a[aria-current="page"] svg {
  color: #137d75;
}

body.theme-light .bottom-nav .scan-tab span {
  color: currentColor;
}

body.theme-clear .bottom-nav {
  color: rgba(218, 230, 255, 0.64);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.13), rgba(8, 13, 20, 0.48)),
    rgba(5, 12, 23, 0.5);
  border-color: rgba(184, 244, 238, 0.18);
}

body.theme-clear .bottom-nav a.active,
body.theme-clear .bottom-nav a[aria-current="page"] {
  color: #f8fbff;
  background: transparent;
}

body.theme-clear .bottom-nav a.active svg,
body.theme-clear .bottom-nav a[aria-current="page"] svg {
  color: #8fe5dc;
}

body.theme-clear .bottom-nav .scan-tab,
body.theme-clear .bottom-nav .scan-tab span {
  color: currentColor;
}

body.theme-clear .bottom-nav .scan-tab svg {
  color: currentColor;
}

@media (max-width: 370px) {
  .bottom-nav {
    width: calc(100vw - 20px);
    min-height: 76px;
    padding-inline: 6px;
  }

  .bottom-nav a {
    font-size: 0.58rem;
    letter-spacing: 0;
  }

  .bottom-nav svg {
    width: 22px;
    height: 22px;
  }

  .bottom-nav .scan-tab svg {
    width: 22px;
    height: 22px;
    padding: 0;
    border-radius: 0;
  }
}
/* MEMORY LINE: MOBILE DOCK NAV END */

/* MEMORY LINE: VENDOR MODE START */
.vendor-full-mode-link {
  display: grid;
  min-height: 42px;
  padding: 0 14px;
  place-items: center;
  border: 1px solid rgba(131, 216, 208, 0.34);
  border-radius: 999px;
  color: #06110f;
  background: #83d8d0;
  font-size: 0.78rem;
  font-weight: 950;
  text-decoration: none;
}
/* MEMORY LINE: VENDOR MODE END */

/* MEMORY LINE: VAULT SUMMARY UI START */
body.is-collection-detail {
  --vault-hud-accent: #7ed3ca;
  --vault-hud-accent-strong: #a6f4cf;
  --vault-hud-glass: rgba(8, 14, 24, 0.58);
  --vault-hud-border: rgba(126, 211, 202, 0.1);
  --vault-hud-border-strong: rgba(126, 211, 202, 0.28);
  --vault-hud-muted: rgba(224, 231, 244, 0.58);
  background:
    radial-gradient(720px 380px at 50% -18%, rgba(126, 211, 202, 0.11), transparent 62%),
    linear-gradient(180deg, #111827 0%, #08111e 44%, #03070d 100%);
}

body.is-collection-detail .collector-app {
  max-width: 1120px;
  padding-top: max(8px, env(safe-area-inset-top));
}

.collection-tab.is-section-detail {
  gap: 8px;
}

.collection-tab.is-section-detail .collection-detail-panel {
  display: grid;
  gap: 8px;
  padding: 0 0 6px;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-portfolio-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  grid-template-areas:
    "search filter";
  gap: 8px;
  margin-bottom: 0;
}

.collection-tab.is-section-detail .collection-portfolio-search,
.collection-tab.is-section-detail .collection-portfolio-filter {
  min-height: 38px;
  color: #f7f8fb;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.032), rgba(255, 255, 255, 0.012)),
    var(--vault-hud-glass);
  border: 1px solid var(--vault-hud-border);
  border-radius: 15px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045), 0 8px 20px rgba(0, 0, 0, 0.13);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease, background 160ms ease;
}

.collection-tab.is-section-detail .collection-portfolio-search {
  grid-template-columns: 18px minmax(0, 1fr) 26px;
  gap: 7px;
  padding: 0 6px 0 11px;
}

.collection-tab.is-section-detail .collection-portfolio-search input {
  min-height: 0;
  font-size: 0.86rem;
  font-weight: 780;
  letter-spacing: 0;
}

.collection-tab.is-section-detail .collection-portfolio-search input::placeholder {
  color: rgba(224, 231, 244, 0.54);
}

.collection-tab.is-section-detail .collection-portfolio-search button {
  width: 26px;
  height: 26px;
  padding: 6px;
  color: rgba(224, 231, 244, 0.66);
  border-radius: 9px;
}

.collection-tab.is-section-detail .collection-portfolio-search > svg {
  width: 18px;
  height: 18px;
  color: rgba(247, 248, 251, 0.88);
}

.collection-tab.is-section-detail .collection-portfolio-search:focus-within,
.collection-tab.is-section-detail .collection-portfolio-filter:focus-within {
  border-color: var(--vault-hud-border-strong);
  box-shadow: 0 0 0 1px rgba(126, 211, 202, 0.12), 0 12px 26px rgba(0, 0, 0, 0.2);
}

.collection-tab.is-section-detail .collection-portfolio-search:active {
  transform: translateY(1px);
}

.collection-tab.is-section-detail .collection-portfolio-filter {
  grid-area: filter;
  justify-self: end;
  width: 38px;
  height: 38px;
  padding: 9px;
  color: rgba(224, 231, 244, 0.7);
}

.collection-tab.is-section-detail .collection-portfolio-filter:active {
  transform: translateY(1px);
}

.collection-tab.is-section-detail .collection-portfolio-filter select {
  cursor: pointer;
}

.collection-tab.is-section-detail .collection-portfolio-hero {
  display: grid;
  justify-items: center;
  gap: 4px;
  min-height: 0;
  padding: 7px 0 9px;
  overflow: visible;
  text-align: center;
  background: transparent;
  border: 0;
  border-radius: 14px;
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-portfolio-hero .collection-hero-section-row {
  justify-items: center;
  justify-self: center;
  width: auto;
  max-width: 100%;
  margin: 0;
}

.collection-tab.is-section-detail .collection-detail-section-select-label {
  display: grid;
  grid-template-columns: auto 18px minmax(0, max-content) 16px;
  gap: 5px;
  justify-self: center;
  width: fit-content;
  max-width: min(100%, 292px);
  min-height: 31px;
  padding: 4px 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.015)),
    rgba(17, 26, 42, 0.68);
  border-color: rgba(126, 211, 202, 0.1);
  border-radius: 12px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045);
}

.collection-tab.is-section-detail .collection-detail-section-select-label span {
  color: var(--vault-hud-muted);
  font-size: 0.74rem;
  line-height: 1;
}

.collection-tab.is-section-detail .collection-detail-section-select-label select {
  width: auto;
  height: 20px;
  max-width: min(34vw, 132px);
  min-height: 0;
  min-width: 0;
  padding: 0;
  color: #ffffff;
  font-size: 0.9rem;
  line-height: 1.05;
  text-align: left;
}

.collection-tab.is-section-detail .collection-detail-section-select-label:active {
  transform: translateY(1px);
}

.collection-tab.is-section-detail .collection-main-section-star {
  width: 18px;
  height: 18px;
}

.collection-tab.is-section-detail .collection-detail-section-select-label > svg {
  width: 16px;
  height: 16px;
  color: var(--vault-hud-accent);
}

.collection-tab.is-section-detail .collection-portfolio-hero div {
  position: relative;
  isolation: isolate;
  display: grid;
  justify-items: center;
  gap: 0;
  min-width: 0;
  width: 100%;
  text-align: center;
}

.collection-tab.is-section-detail .collection-portfolio-hero div > span {
  display: none;
}

.collection-tab.is-section-detail .collection-portfolio-hero div > strong {
  display: block;
  max-width: 100%;
  color: #ffffff;
  font-size: clamp(2.34rem, 10.8vw, 3.55rem);
  font-weight: 950;
  line-height: 0.94;
  letter-spacing: 0;
  overflow-wrap: anywhere;
  text-align: center;
  text-shadow: none;
  white-space: normal;
}
/* MEMORY LINE: VAULT SUMMARY UI END */

.collection-tools-panel {
  display: grid;
  gap: 7px;
  margin-top: 0;
}

.collection-tools-panel.collection-action-hub {
  grid-template-columns: minmax(100px, 1.03fr) repeat(2, minmax(82px, 0.9fr));
  align-items: stretch;
}

.collection-trade-hub-toggle {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 22px;
  gap: 7px;
  align-items: center;
  min-height: 44px;
  padding: 7px 9px 7px 10px;
  color: #06110f;
  text-align: center;
  background: linear-gradient(145deg, #b6f1e3, #7ed3ca);
  border: 1px solid rgba(169, 234, 216, 0.54);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.48), 0 10px 24px rgba(126, 211, 202, 0.18);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.collection-trade-hub-toggle:active {
  transform: translateY(1px);
}

.collection-trade-hub-toggle:focus-visible {
  outline: 0;
  border-color: rgba(255, 255, 255, 0.72);
  box-shadow: 0 0 0 2px rgba(126, 211, 202, 0.2), 0 12px 28px rgba(126, 211, 202, 0.22);
}

.collection-trade-text-icon {
  display: block;
  min-width: 0;
  color: #06110f;
  font-size: 0.82rem;
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1;
  overflow-wrap: anywhere;
  text-transform: uppercase;
  white-space: nowrap;
}

.collection-trade-hub-count {
  display: grid;
  place-items: center;
  min-width: 21px;
  height: 21px;
  padding: 0 6px;
  color: #a9ead8;
  background: rgba(6, 17, 15, 0.84);
  border-radius: 999px;
  font-size: 0.66rem;
  font-weight: 950;
}

.collection-trade-hub-toggle.is-open {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.52), 0 0 0 2px rgba(126, 211, 202, 0.14), 0 14px 32px rgba(126, 211, 202, 0.26);
}

.collection-action-button {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 5px;
  align-items: center;
  min-height: 44px;
  padding: 7px;
  color: #f7f8fb;
  text-align: left;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.035), rgba(126, 211, 202, 0.02)),
    rgba(8, 14, 24, 0.55);
  border: 1px solid rgba(126, 211, 202, 0.12);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 8px 20px rgba(0, 0, 0, 0.13);
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease, background 160ms ease;
}

.collection-action-button:active {
  transform: translateY(1px);
}

.collection-action-button:focus-visible {
  outline: 0;
  border-color: rgba(126, 211, 202, 0.38);
  box-shadow: 0 0 0 2px rgba(126, 211, 202, 0.14), 0 10px 24px rgba(0, 0, 0, 0.18);
}

.collection-action-button span {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  color: #7ed3ca;
}

.collection-trade-hub-actions {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.collection-trade-hub-actions[hidden] {
  display: none;
}

.collection-trade-hub-actions button {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  justify-items: stretch;
  align-items: center;
  gap: 10px;
  min-width: 0;
  min-height: 42px;
  padding: 7px;
  color: #f7f8fb;
  text-align: left;
  background: rgba(255, 255, 255, 0.075);
  border: 1px solid rgba(126, 211, 202, 0.18);
  border-radius: 12px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 14px 34px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.collection-trade-hub-actions button > span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 10px;
  color: #74ccc3;
  background: rgba(116, 204, 195, 0.12);
  border: 1px solid rgba(116, 204, 195, 0.2);
  border-radius: 10px;
}

.collection-trade-hub-actions svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-trade-hub-actions strong {
  display: block;
  min-width: 0;
  color: #f7f8fb;
  font-size: 0.84rem;
  font-weight: 950;
  line-height: 1.12;
  overflow-wrap: anywhere;
  white-space: normal;
}

.collection-action-button svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.collection-action-button strong {
  display: block;
  min-width: 0;
  color: #f7f8fb;
  font-size: 0.68rem;
  font-weight: 760;
  line-height: 1.05;
  overflow: hidden;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 380px) {
  .collection-tab.is-section-detail .collection-detail-section-select-label {
    max-width: min(100%, 268px);
  }

  .collection-tab.is-section-detail .collection-portfolio-hero div > strong {
    font-size: clamp(2.08rem, 10.2vw, 3.15rem);
  }
}

/* MEMORY LINE: VAULT COLLECTION CARD UI START */
.collection-tab.is-section-detail .collection-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding-bottom: 4px;
}

body.is-collection-bulk-mode .collection-tab.is-section-detail .collection-list {
  padding-bottom: calc(var(--app-bottom-nav-clearance) + 236px);
}

.collection-tab.is-section-detail .collection-portfolio-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 0;
  padding: 10px;
  overflow: hidden;
  color: #f7f8fb;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.035)), rgba(9, 13, 23, 0.72);
  border: 1px solid rgba(236, 255, 251, 0.085);
  border-radius: 8px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.045);
}

.collection-tab.is-section-detail .collection-portfolio-card::before {
  display: none;
}

.collection-tab.is-section-detail .collection-portfolio-card .collection-card-select {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-image-wrap {
  display: grid;
  place-items: center;
  align-self: start;
  width: 100%;
  height: clamp(194px, 46vw, 356px);
  aspect-ratio: auto;
  min-height: 0;
  padding: 0 4px 3px;
  overflow: hidden;
  border: 0;
  background: transparent;
  border-radius: 8px;
  box-shadow: none;
}

.collection-tab.is-section-detail .collection-portfolio-card .collection-card-image {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  padding: 0;
  aspect-ratio: auto;
  object-fit: contain;
  background: transparent;
  border: 0;
  border-radius: 9px;
}

.collection-tab.is-section-detail .collection-portfolio-card .mini-card {
  width: 100%;
  height: 100%;
}

.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio {
  min-height: 0;
  overflow: hidden;
}

.collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .portfolio-slab-preview {
  width: min(214px, 90%);
}

.portfolio-card-main {
  display: grid;
  grid-template-rows: auto auto auto;
  gap: 6px;
  min-width: 0;
  min-height: 0;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
  min-height: 0;
  align-content: start;
}

.vault-card-badge-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  min-width: 0;
}

.vault-card-badge-row span {
  max-width: 100%;
  min-height: 18px;
  padding: 3px 7px;
  overflow: hidden;
  color: #c8d7ff;
  background: rgba(126, 164, 255, 0.12);
  border: 1px solid rgba(126, 164, 255, 0.18);
  border-radius: 999px;
  font-size: 0.58rem;
  font-weight: 900;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vault-card-badge-row span:first-child {
  color: #aef3cf;
  background: rgba(98, 211, 151, 0.12);
  border-color: rgba(98, 211, 151, 0.2);
}

.vault-card-edit-menu {
  position: relative;
  z-index: 6;
}

.vault-card-edit-menu[open] {
  flex: 1 0 100%;
  width: 100%;
}

.vault-card-edit-toggle {
  display: grid;
  place-items: center;
  min-height: 18px;
  padding: 3px 8px;
  color: #0b151a;
  cursor: pointer;
  background: linear-gradient(135deg, #a7efc1, #8fded5);
  border: 1px solid rgba(207, 255, 239, 0.45);
  border-radius: 999px;
  box-shadow: 0 8px 18px rgba(126, 211, 202, 0.14);
  font-size: 0.58rem;
  font-weight: 920;
  line-height: 1;
}

.vault-card-edit-toggle::-webkit-details-marker {
  display: none;
}

.vault-card-edit-menu:not([open]) .vault-card-edit-actions {
  display: none;
}

.vault-card-edit-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  width: 100%;
  margin-top: 5px;
  padding: 6px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.055)),
    rgba(7, 11, 18, 0.96);
  border: 1px solid rgba(236, 255, 251, 0.16);
  border-radius: 8px;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.09);
}

.vault-card-edit-actions button {
  min-width: 0;
  min-height: 26px;
  padding: 0 7px;
  color: rgba(247, 248, 251, 0.88);
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 7px;
  font-size: 0.62rem;
  font-weight: 840;
}

.vault-card-edit-actions button[data-action="delete"] {
  color: #ffb1a4;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy h3 {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: #ffffff;
  font-size: 0.98rem;
  font-weight: 880;
  line-height: 1.12;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy p {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: rgba(224, 231, 244, 0.62);
  font-size: 0.72rem;
  font-weight: 720;
  line-height: 1.16;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 5px;
  align-items: start;
  margin-top: 0;
  padding-top: 0;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  width: 100%;
  min-width: 0;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory button,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory button + button {
  width: auto;
  min-height: 24px;
  padding: 4px 7px;
  overflow: hidden;
  color: rgba(247, 248, 251, 0.76);
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  font-size: 0.66rem;
  font-weight: 820;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer .portfolio-card-market {
  display: grid;
  justify-items: start;
  gap: 2px;
  width: 100%;
  min-width: 0;
  text-align: left;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market small,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market em {
  display: block;
  max-width: 100%;
  overflow: hidden;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market small {
  color: rgba(219, 231, 255, 0.68);
  font-size: 0.52rem;
  font-weight: 450;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market strong {
  color: #95f0af;
  font-size: 0.86rem;
  font-weight: 450;
  line-height: 1;
  letter-spacing: -0.01em;
  text-shadow: none;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-price-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 5px;
  width: 100%;
  min-width: 0;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-price-row strong {
  flex: 1 1 auto;
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: normal;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-qty,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-paid,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-sell {
  min-height: 23px;
  padding: 4px 7px;
  color: rgba(247, 248, 251, 0.76);
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  font-size: 0.64rem;
  font-weight: 820;
  line-height: 1;
  white-space: nowrap;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-qty {
  flex: 0 0 auto;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-accounting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-sell {
  flex: 0 0 auto;
  color: #06251b;
  background: #8bd7ce;
  border-color: rgba(139, 215, 206, 0.76);
  box-shadow: 0 6px 14px rgba(126, 211, 202, 0.18);
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-paid {
  justify-self: start;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market em {
  display: flex;
  align-items: baseline;
  gap: 4px;
  color: rgba(224, 231, 244, 0.68);
  font-size: 0.62rem;
  font-weight: 400;
  line-height: 1.05;
}

.portfolio-card-market-check {
  display: block;
  max-width: 100%;
  overflow: hidden;
  color: rgba(206, 215, 228, 0.6);
  font-size: 0.72rem;
  font-weight: 650;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vault-card-badge-row .portfolio-card-market-check {
  flex: 1 1 74px;
  min-width: 0;
  min-height: 18px;
  padding: 3px 0;
  background: transparent;
  border-color: transparent;
  border-radius: 0;
  box-shadow: none;
  font-size: 0.62rem;
  font-weight: 820;
}

.portfolio-card-market-check.is-fresh {
  color: rgba(126, 211, 202, 0.76);
}

.portfolio-card-market-check.is-due {
  color: rgba(236, 206, 132, 0.8);
}

.portfolio-card-market-check.is-refreshing {
  color: rgba(178, 222, 255, 0.82);
}

.portfolio-card-market-check.is-failed {
  color: rgba(255, 145, 127, 0.86);
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-percent {
  color: currentColor;
  opacity: 0.82;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market.positive em {
  color: #7ed3ca;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market.positive strong {
  color: #95f0af;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market.negative em {
  color: #ff917f;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market.negative strong {
  color: #ff917f;
}

@media (min-width: 760px) {
  .collection-tab.is-section-detail .collection-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 380px) {
  .collection-tab.is-section-detail .collection-portfolio-card {
    gap: 7px;
    padding: 9px;
  }

  .collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-image-wrap {
    height: clamp(172px, 51vw, 256px);
    padding: 0 2px 2px;
  }

  .collection-tab.is-section-detail .collection-portfolio-card.is-slab-portfolio .portfolio-slab-preview {
    width: min(176px, 96%);
  }
}
/* MEMORY LINE: VAULT COLLECTION CARD UI END */

/* MEMORY LINE: VAULT BOTTOM NAV SAFE AREA START */
body.is-collection-detail .collector-app {
  padding-bottom: calc(96px + env(safe-area-inset-bottom));
}

body.is-collection-tab .collector-app {
  padding-bottom: calc(128px + env(safe-area-inset-bottom));
}

.bottom-nav {
  bottom: 0;
  min-height: 78px;
  padding: 8px 6px max(9px, env(safe-area-inset-bottom));
  border-radius: 28px;
}

body.is-collection-detail .bottom-nav {
  bottom: 0;
}

body.is-collection-tab .bottom-nav {
  bottom: 0;
  width: min(398px, calc(100vw - 40px));
  min-height: 78px;
  padding: 8px 6px max(9px, env(safe-area-inset-bottom));
  align-items: stretch;
  gap: 1px;
  color: #98a3ad;
  background:
    linear-gradient(180deg, rgba(24, 33, 43, 0.74), rgba(8, 13, 20, 0.58)),
    rgba(8, 13, 20, 0.58);
  border: 1px solid rgba(214, 244, 241, 0.14);
  border-radius: 28px;
  box-shadow:
    0 16px 36px rgba(0, 0, 0, 0.36),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -1px 0 rgba(255, 255, 255, 0.035);
}

body.is-collection-tab .bottom-nav a {
  min-height: 58px;
  justify-content: center;
  gap: 4px;
  padding: 7px 0 6px;
  color: #98a3ad;
  border-radius: 20px;
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0;
}

body.is-collection-tab .bottom-nav a[data-nav-key="collection"] {
  transform: none;
}

body.is-collection-tab .bottom-nav svg {
  width: 24px;
  height: 24px;
  opacity: 0.78;
}

body.is-collection-tab .bottom-nav a.active:not(.scan-tab),
body.is-collection-tab .bottom-nav a[aria-current="page"]:not(.scan-tab) {
  color: #fff;
  background: transparent;
  box-shadow: none;
}

body.is-collection-tab .bottom-nav a.active span,
body.is-collection-tab .bottom-nav a[aria-current="page"] span {
  color: #fff;
}

body.is-collection-tab .bottom-nav a.active svg,
body.is-collection-tab .bottom-nav a[aria-current="page"] svg {
  color: #64d0c4;
  opacity: 1;
}

body.is-collection-tab .bottom-nav a:not(.scan-tab)::after {
  display: none;
}

body.is-collection-tab .bottom-nav .scan-tab {
  align-self: stretch;
  min-height: 58px;
  justify-content: center;
  color: #98a3ad;
  background: transparent;
  border-radius: 20px;
  box-shadow: none;
}

body.is-collection-tab .bottom-nav .scan-tab svg {
  width: 24px;
  height: 24px;
  color: currentColor;
}

body.is-collection-tab .bottom-nav .scan-tab span {
  color: currentColor;
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0;
}

.bottom-nav a span,
.bottom-nav .scan-tab span,
body.is-collection-tab .bottom-nav a span,
body.is-collection-tab .bottom-nav .scan-tab span {
  font-size: 0.6rem;
  font-weight: 500;
}

.bottom-nav a,
.bottom-nav .scan-tab {
  min-height: 58px;
  gap: 4px;
  padding-top: 7px;
  padding-bottom: 6px;
}

.bottom-nav a:not(.scan-tab)::after {
  display: none;
}

@media (max-width: 370px) {
  .bottom-nav {
    min-height: 76px;
  }
}
/* MEMORY LINE: VAULT BOTTOM NAV SAFE AREA END */

/* MEMORY LINE: Catalog Futuristic Polish START */
body.catalog-search-active {
  --catalog-bg-0: #02040a;
  --catalog-bg-1: #07101c;
  --catalog-ink: #f7fffd;
  --catalog-muted: rgba(219, 231, 255, 0.74);
  --catalog-muted-strong: rgba(236, 255, 251, 0.84);
  --catalog-panel: rgba(12, 17, 27, 0.72);
  --catalog-line: rgba(186, 247, 238, 0.18);
  --catalog-line-strong: rgba(143, 224, 167, 0.38);
  --catalog-accent: #95f0af;
  --catalog-accent-2: #7ed3ca;
  --catalog-accent-3: #8fb4ff;
  --catalog-radius: 8px;
  --catalog-shadow-soft: 0 22px 64px rgba(0, 0, 0, 0.36);
  --catalog-shadow-tight: 0 14px 34px rgba(0, 0, 0, 0.32);
  color: var(--catalog-ink);
  background:
    radial-gradient(760px 520px at 14% -12%, rgba(126, 211, 202, 0.26), transparent 70%),
    radial-gradient(640px 520px at 96% 0%, rgba(143, 180, 255, 0.17), transparent 64%),
    linear-gradient(180deg, #07101c 0%, #02040a 44%, #030611 100%);
}

.catalog-search-page {
  position: relative;
  isolation: isolate;
  overflow-x: hidden;
  padding: max(66px, calc(env(safe-area-inset-top) + 38px)) 22px max(30px, env(safe-area-inset-bottom));
  background:
    linear-gradient(180deg, rgba(126, 211, 202, 0.09), transparent 220px),
    transparent;
}

.catalog-search-page::before,
.catalog-search-page::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
}

.catalog-search-page::before {
  opacity: 0.42;
  background-image:
    linear-gradient(rgba(126, 211, 202, 0.13) 1px, transparent 1px),
    linear-gradient(90deg, rgba(126, 211, 202, 0.1) 1px, transparent 1px);
  background-position: center top;
  background-size: 44px 44px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.78), transparent 58%);
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.78), transparent 58%);
}

.catalog-search-page::after {
  opacity: 0.78;
  background:
    radial-gradient(circle at 50% 0%, rgba(149, 240, 175, 0.16), transparent 42%),
    linear-gradient(180deg, transparent 0%, rgba(2, 4, 10, 0.68) 78%);
}

.catalog-search-head,
.catalog-search-form,
.catalog-state,
.catalog-results {
  position: relative;
  z-index: 1;
  width: min(1180px, 100%);
}

.catalog-search-head {
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 14px;
  margin-bottom: 16px;
}

.catalog-exit-btn {
  min-width: 74px;
  height: 48px;
  padding: 0 18px;
  color: var(--catalog-ink);
  font-size: 0.98rem;
  font-weight: 860;
  letter-spacing: 0;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.045)),
    rgba(12, 17, 27, 0.72);
  border-color: rgba(236, 255, 251, 0.18);
  border-radius: var(--catalog-radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16), 0 16px 34px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(18px) saturate(1.15);
  -webkit-backdrop-filter: blur(18px) saturate(1.15);
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease;
}

.catalog-exit-btn:active {
  transform: scale(0.97);
}

.catalog-exit-btn:focus-visible,
.catalog-search-submit:focus-visible,
.catalog-result-tabs button:focus-visible,
.catalog-grade-price-btn:focus-visible,
.catalog-add-collection-btn:focus-visible,
.catalog-save-sheet button:focus-visible,
.catalog-save-form input:focus-visible,
.catalog-save-form select:focus-visible,
.catalog-result-condition-select:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px rgba(126, 211, 202, 0.24), 0 0 0 1px rgba(126, 211, 202, 0.72) inset;
}

.catalog-search-head h1 {
  margin: 0 0 4px;
  color: var(--catalog-ink);
  font-size: 3rem;
  font-weight: 920;
  letter-spacing: 0;
  line-height: 0.96;
  text-wrap: balance;
}

.catalog-search-head span {
  max-width: min(44rem, 100%);
  color: var(--catalog-muted);
  font-size: 0.94rem;
  font-weight: 760;
  letter-spacing: 0;
}

.catalog-search-form {
  margin-bottom: 14px;
}

.catalog-search-field {
  min-height: 58px;
  padding: 0 17px;
  color: #e9fffb;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.055)),
    rgba(12, 17, 27, 0.76);
  border-color: rgba(126, 211, 202, 0.28);
  border-radius: var(--catalog-radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), var(--catalog-shadow-tight);
  backdrop-filter: blur(20px) saturate(1.18);
  -webkit-backdrop-filter: blur(20px) saturate(1.18);
}

.catalog-search-field:focus-within {
  border-color: rgba(149, 240, 175, 0.7);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 18px 46px rgba(0, 0, 0, 0.34), 0 0 0 3px rgba(126, 211, 202, 0.14);
}

.catalog-search-field svg {
  width: 20px;
  height: 20px;
  color: rgba(236, 255, 251, 0.78);
  filter: drop-shadow(0 0 12px rgba(126, 211, 202, 0.32));
}

.catalog-search-field input {
  height: 56px;
  color: var(--catalog-ink);
  font-size: 1.08rem;
  font-weight: 850;
  letter-spacing: 0;
}

.catalog-search-field input::placeholder {
  color: rgba(219, 231, 255, 0.52);
}

.catalog-state {
  color: var(--catalog-muted-strong);
  background: var(--catalog-panel);
  border-color: rgba(236, 255, 251, 0.12);
  border-radius: var(--catalog-radius);
  box-shadow: var(--catalog-shadow-tight);
  backdrop-filter: blur(18px) saturate(1.14);
  -webkit-backdrop-filter: blur(18px) saturate(1.14);
}

.catalog-results {
  gap: 16px;
}

.catalog-result-tabs {
  gap: 7px;
  padding: 6px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.105), rgba(255, 255, 255, 0.04)),
    rgba(9, 13, 23, 0.74);
  border: 1px solid rgba(236, 255, 251, 0.11);
  border-radius: var(--catalog-radius);
  box-shadow: var(--catalog-shadow-tight);
  backdrop-filter: blur(20px) saturate(1.16);
  -webkit-backdrop-filter: blur(20px) saturate(1.16);
}

.catalog-result-tabs button {
  min-height: 50px;
  padding: 0 14px;
  color: rgba(236, 255, 251, 0.72);
  background: transparent;
  border-color: transparent;
  border-radius: var(--catalog-radius);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  transition: transform 150ms ease, color 150ms ease, background 150ms ease, box-shadow 150ms ease;
}

.catalog-result-tabs button:active {
  transform: scale(0.985);
}

.catalog-result-tabs button.is-active {
  color: #04120f;
  background: linear-gradient(135deg, var(--catalog-accent), var(--catalog-accent-2));
  box-shadow: 0 12px 32px rgba(126, 211, 202, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.38);
}

.catalog-result-tabs button strong {
  min-width: 30px;
  height: 30px;
  padding: 0 9px;
  background: rgba(255, 255, 255, 0.24);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-size: 0.74rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.catalog-result-section {
  gap: 13px;
}

.catalog-result-section-head {
  padding: 0 4px;
}

.catalog-result-section-head h2 {
  color: rgba(219, 231, 255, 0.74);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
}

.catalog-result-section-head span {
  min-width: 30px;
  padding: 5px 9px;
  color: #04120f;
  background: linear-gradient(135deg, var(--catalog-accent), var(--catalog-accent-2));
  box-shadow: 0 10px 24px rgba(126, 211, 202, 0.18);
}

.catalog-result-card-grid {
  gap: 14px;
}

.catalog-result-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  gap: 12px;
  padding: 12px;
  background:
    radial-gradient(160px 120px at 84% 0%, rgba(126, 211, 202, 0.16), transparent 72%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.052)),
    rgba(9, 13, 23, 0.78);
  border-color: rgba(236, 255, 251, 0.12);
  border-radius: var(--catalog-radius);
  box-shadow: var(--catalog-shadow-tight);
  backdrop-filter: blur(18px) saturate(1.08);
  -webkit-backdrop-filter: blur(18px) saturate(1.08);
  transform: translateZ(0);
  transition: transform 170ms ease, border-color 170ms ease, box-shadow 170ms ease, background 170ms ease;
}

.catalog-result-card::before {
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(149, 240, 175, 0.58), rgba(126, 211, 202, 0.34), transparent);
  content: "";
}

.catalog-result-card::after {
  position: absolute;
  top: -72px;
  right: -56px;
  z-index: -1;
  width: 154px;
  height: 154px;
  background: radial-gradient(circle, rgba(143, 180, 255, 0.14), transparent 68%);
  content: "";
}

.catalog-result-card:active {
  transform: translateY(1px) scale(0.995);
}

.catalog-result-media {
  aspect-ratio: 1 / 1;
  background:
    radial-gradient(circle at 50% 35%, rgba(236, 255, 251, 0.13), transparent 52%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.035)),
    rgba(0, 0, 0, 0.22);
  border-color: rgba(236, 255, 251, 0.13);
  border-radius: var(--catalog-radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), inset 0 -24px 42px rgba(0, 0, 0, 0.16);
}

.catalog-result-media img {
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, 0.34));
}

.catalog-result-image-fallback {
  color: rgba(219, 231, 255, 0.66);
  font-size: 0.62rem;
}

.catalog-result-copy {
  grid-template-rows: auto auto auto auto minmax(0, 1fr);
  gap: 7px;
}

.catalog-result-label-row {
  gap: 5px;
}

.catalog-result-kind {
  color: rgba(143, 180, 255, 0.92);
  font-size: 0.58rem;
  letter-spacing: 0.1em;
}

.catalog-result-best-badge,
.catalog-result-confidence-badge {
  min-height: 20px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 0.56rem;
  line-height: 1;
}

.catalog-result-best-badge {
  color: #04120f;
  background: linear-gradient(135deg, var(--catalog-accent), var(--catalog-accent-2));
}

.catalog-result-confidence-badge {
  color: rgba(236, 255, 251, 0.78);
  background: rgba(143, 180, 255, 0.13);
  border: 1px solid rgba(143, 180, 255, 0.13);
}

.catalog-result-copy strong {
  min-height: 2.22em;
  color: #ffffff;
  font-size: 1.02rem;
  font-weight: 880;
  letter-spacing: 0;
  line-height: 1.11;
}

.catalog-result-copy small {
  color: rgba(236, 255, 251, 0.67);
  font-size: 0.76rem;
  font-weight: 680;
}

.catalog-result-meta {
  gap: 5px;
}

.catalog-result-meta span {
  max-width: 100%;
  min-height: 23px;
  padding: 4px 8px;
  overflow: hidden;
  color: rgba(219, 231, 255, 0.86);
  background: rgba(126, 211, 202, 0.105);
  border-color: rgba(126, 211, 202, 0.18);
  border-radius: 999px;
  font-size: 0.61rem;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.catalog-result-footer {
  gap: 8px;
  margin-top: 2px;
}

.catalog-result-condition-control {
  gap: 5px;
}

.catalog-result-condition-control span {
  color: rgba(219, 231, 255, 0.68);
  font-size: 0.57rem;
  letter-spacing: 0.1em;
}

.catalog-result-condition-select {
  min-height: 38px;
  color: var(--catalog-ink);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.105), rgba(255, 255, 255, 0.045)),
    rgba(255, 255, 255, 0.055);
  border-color: rgba(126, 211, 202, 0.28);
  border-radius: var(--catalog-radius);
  font-size: 0.76rem;
  font-weight: 820;
}

.catalog-result-price {
  max-width: 100%;
  overflow-wrap: anywhere;
  color: var(--catalog-accent);
  font-size: 1.34rem;
  font-weight: 960;
  letter-spacing: 0;
  line-height: 1.03;
  text-shadow: 0 0 22px rgba(149, 240, 175, 0.18);
}

.catalog-result-actions {
  gap: 8px;
}

.catalog-grade-price-btn,
.catalog-add-collection-btn,
.catalog-save-submit-btn,
.catalog-graded-company-choices button {
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease, box-shadow 150ms ease, opacity 150ms ease;
}

.catalog-grade-price-btn,
.catalog-add-collection-btn {
  min-height: 42px;
  border-radius: var(--catalog-radius);
  font-size: 0.72rem;
  line-height: 1.12;
  letter-spacing: 0.06em;
}

.catalog-grade-price-btn {
  color: #241104;
  background: linear-gradient(135deg, #ffe08a, #ffb84d 52%, #ff7f50);
  border: 1px solid rgba(255, 233, 176, 0.72);
  box-shadow: 0 16px 34px rgba(255, 184, 77, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.36);
  cursor: pointer;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.24);
}

.catalog-add-collection-btn {
  color: #03120e;
  background: linear-gradient(135deg, var(--catalog-accent), var(--catalog-accent-2));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 14px 28px rgba(126, 211, 202, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.catalog-grade-price-btn:active,
.catalog-add-collection-btn:active,
.catalog-save-submit-btn:active,
.catalog-graded-company-choices button:active {
  transform: scale(0.985);
}

.catalog-add-collection-btn.is-added,
.catalog-add-collection-btn:disabled {
  color: rgba(236, 255, 251, 0.68);
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.catalog-empty-panel {
  min-height: 168px;
  padding: 24px;
  color: var(--catalog-muted);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.035)),
    rgba(9, 13, 23, 0.72);
  border-color: rgba(236, 255, 251, 0.11);
  border-radius: var(--catalog-radius);
  box-shadow: var(--catalog-shadow-tight);
  backdrop-filter: blur(18px) saturate(1.12);
  -webkit-backdrop-filter: blur(18px) saturate(1.12);
}

.catalog-empty-panel strong {
  font-size: 1.02rem;
  letter-spacing: 0;
}

.catalog-empty-panel span {
  color: rgba(219, 231, 255, 0.7);
}

.catalog-save-sheet::before {
  background: rgba(1, 4, 11, 0.58);
  backdrop-filter: blur(24px) saturate(0.9) brightness(0.72);
  -webkit-backdrop-filter: blur(24px) saturate(0.9) brightness(0.72);
}

.catalog-save-sheet-panel {
  color: var(--catalog-ink);
  background:
    radial-gradient(440px 260px at 88% 0%, rgba(126, 211, 202, 0.13), transparent 72%),
    linear-gradient(180deg, rgba(19, 25, 37, 0.98), rgba(10, 14, 24, 0.98));
  border-color: rgba(236, 255, 251, 0.13);
  box-shadow: 0 -26px 76px rgba(0, 0, 0, 0.54);
}

.catalog-save-sheet-handle {
  height: 5px;
  background: rgba(126, 211, 202, 0.58);
}

.catalog-save-sheet-head span {
  color: rgba(143, 180, 255, 0.9);
}

.catalog-save-sheet-head h3 {
  letter-spacing: 0;
}

.catalog-save-sheet-head small,
.catalog-save-form label {
  color: rgba(219, 231, 255, 0.68);
}

.catalog-save-sheet-head button,
.catalog-save-form input,
.catalog-save-form select,
.catalog-graded-price-result,
.catalog-graded-company-choices button {
  color: var(--catalog-ink);
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(236, 255, 251, 0.12);
  border-radius: var(--catalog-radius);
}

.catalog-save-preview {
  background:
    radial-gradient(circle at 50% 38%, rgba(236, 255, 251, 0.12), transparent 56%),
    #040713;
  border-color: rgba(236, 255, 251, 0.13);
  border-radius: var(--catalog-radius);
}

.catalog-save-submit-btn,
.catalog-graded-company-choices button.is-active {
  color: #03120e;
  background: linear-gradient(135deg, var(--catalog-accent), var(--catalog-accent-2));
  border-color: transparent;
  box-shadow: 0 14px 32px rgba(126, 211, 202, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.28);
}

.catalog-graded-price-result strong {
  color: var(--catalog-accent);
  text-shadow: 0 0 22px rgba(149, 240, 175, 0.18);
}

.catalog-result-tabs-skeleton span,
.catalog-result-card-skeleton .catalog-result-media,
.catalog-result-card-skeleton .catalog-result-copy > span,
.catalog-result-card-skeleton strong,
.catalog-result-card-skeleton small,
.catalog-result-card-skeleton .catalog-result-meta span,
.catalog-result-card-skeleton .catalog-result-price,
.catalog-result-card-skeleton .catalog-add-collection-btn {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.055), rgba(126, 211, 202, 0.18), rgba(255, 255, 255, 0.055));
  background-size: 240% 100%;
}

@media (hover: hover) {
  .catalog-exit-btn:hover,
  .catalog-result-tabs button:hover,
  .catalog-grade-price-btn:hover,
  .catalog-add-collection-btn:hover,
  .catalog-save-sheet-head button:hover,
  .catalog-graded-company-choices button:hover {
    border-color: rgba(149, 240, 175, 0.36);
  }

  .catalog-result-card:hover {
    border-color: rgba(149, 240, 175, 0.24);
    box-shadow: var(--catalog-shadow-soft);
    transform: translateY(-2px);
  }
}

@media (max-width: 520px) {
  .catalog-search-page {
    padding-inline: 14px;
  }

  .catalog-search-head h1 {
    font-size: 2.28rem;
  }

  .catalog-search-head span {
    font-size: 0.86rem;
  }
}

@media (max-width: 430px) {
  .catalog-search-page {
    padding-top: max(58px, calc(env(safe-area-inset-top) + 32px));
  }

  .catalog-search-head {
    grid-template-columns: max-content minmax(0, 1fr);
    gap: 12px;
    margin-bottom: 14px;
  }

  .catalog-exit-btn {
    min-width: 68px;
    height: 46px;
    padding: 0 15px;
  }

  .catalog-search-field {
    min-height: 56px;
  }

  .catalog-result-tabs {
    gap: 6px;
    padding: 5px;
  }

  .catalog-result-tabs button {
    min-height: 46px;
    padding: 0 10px;
    font-size: 0.68rem;
  }

  .catalog-result-tabs button strong {
    min-width: 28px;
    height: 28px;
    padding: 0 8px;
  }

  .catalog-result-card-grid {
    gap: 10px;
  }

  .catalog-result-card {
    gap: 10px;
    padding: 10px;
  }

  .catalog-result-copy {
    gap: 6px;
  }

  .catalog-result-copy strong {
    min-height: 2.1em;
    font-size: 0.93rem;
  }

  .catalog-result-copy small {
    font-size: 0.71rem;
  }

  .catalog-result-meta span {
    min-height: 22px;
    padding: 4px 7px;
    font-size: 0.58rem;
  }

  .catalog-result-condition-select {
    min-height: 36px;
    padding-inline: 7px 24px;
    font-size: 0.66rem;
  }

  .catalog-result-price {
    font-size: 1.12rem;
  }

  .catalog-grade-price-btn,
  .catalog-add-collection-btn {
    min-height: 39px;
    padding: 0 9px;
    font-size: 0.66rem;
    letter-spacing: 0.055em;
  }
}

@media (min-width: 1180px) {
  .catalog-result-card-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .catalog-search-field,
  .catalog-result-tabs,
  .catalog-result-card,
  .catalog-empty-panel,
  .catalog-save-sheet-panel {
    background-color: #111827;
  }
}

@media (prefers-reduced-motion: reduce) {
  .catalog-exit-btn,
  .catalog-result-tabs button,
  .catalog-result-card,
  .catalog-grade-price-btn,
  .catalog-add-collection-btn,
  .catalog-save-submit-btn,
  .catalog-graded-company-choices button {
    transition: none;
  }

  .catalog-result-tabs-skeleton span,
  .catalog-result-card-skeleton .catalog-result-media,
  .catalog-result-card-skeleton .catalog-result-copy > span,
  .catalog-result-card-skeleton strong,
  .catalog-result-card-skeleton small,
  .catalog-result-card-skeleton .catalog-result-meta span,
  .catalog-result-card-skeleton .catalog-result-price,
  .catalog-result-card-skeleton .catalog-add-collection-btn {
    animation: none;
  }
}
/* MEMORY LINE: Catalog Futuristic Polish END */

/* MEMORY LINE: Catalog Results Declutter START */
.catalog-search-page {
  padding-top: max(34px, calc(env(safe-area-inset-top) + 18px));
}

.catalog-search-head {
  grid-template-columns: max-content;
  margin-bottom: 10px;
}

.catalog-search-head > div {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.catalog-search-form {
  margin-bottom: 12px;
}

.catalog-result-card[data-result-group="card"] .catalog-result-confidence-badge,
.catalog-result-card[data-result-group="card"] .catalog-result-copy > small,
.catalog-result-card[data-result-group="card"] .catalog-result-meta {
  display: none;
}

.catalog-result-card[data-result-group="card"] .catalog-result-media {
  aspect-ratio: 63 / 88;
}

.catalog-result-card[data-result-group="card"] .catalog-result-copy {
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 8px;
}

.catalog-result-card[data-result-group="card"] .catalog-result-copy strong {
  min-height: auto;
  margin-bottom: 2px;
}

.catalog-result-card[data-result-group="card"] .catalog-result-footer {
  align-self: end;
  margin-top: 0;
}

.catalog-result-card[data-result-group="card"] .catalog-result-label-row {
  min-height: 20px;
}

@media (max-width: 430px) {
  .catalog-search-page {
    padding-top: max(28px, calc(env(safe-area-inset-top) + 14px));
  }

  .catalog-search-head {
    margin-bottom: 8px;
  }

  .catalog-result-card[data-result-group="card"] .catalog-result-copy {
    gap: 7px;
  }
}
/* MEMORY LINE: Catalog Results Declutter END */

.catalog-search-assist {
  position: relative;
  z-index: 1;
  width: min(1180px, 100%);
  margin: -2px auto 14px;
  display: flex;
  align-items: stretch;
  gap: 8px;
}

.catalog-search-assist[hidden] {
  display: none;
}

.catalog-search-history {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 2px 8px;
  scrollbar-width: none;
}

.catalog-search-history::-webkit-scrollbar {
  display: none;
}

.catalog-search-history-item {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 32px;
  align-items: stretch;
  max-width: min(72vw, 280px);
  overflow: hidden;
  color: var(--catalog-ink);
  background: rgba(12, 17, 27, 0.72);
  border: 1px solid rgba(236, 255, 251, 0.14);
  border-radius: var(--catalog-radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 10px 24px rgba(0, 0, 0, 0.22);
}

.catalog-search-history-item.is-active {
  border-color: rgba(149, 240, 175, 0.58);
}

.catalog-search-history-query,
.catalog-search-history-delete,
.catalog-search-history-clear {
  min-width: 0;
  color: inherit;
  background: transparent;
  border: 0;
}

.catalog-search-history-clear {
  flex: 0 0 auto;
  min-height: 42px;
  align-self: flex-start;
  padding: 0 14px;
  color: var(--catalog-ink);
  font-size: 0.72rem;
  font-weight: 860;
  letter-spacing: 0;
  background: rgba(12, 17, 27, 0.72);
  border: 1px solid rgba(236, 255, 251, 0.14);
  border-radius: var(--catalog-radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 10px 24px rgba(0, 0, 0, 0.22);
}

.catalog-search-history-query {
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  text-align: left;
}

.catalog-search-history-query strong,
.catalog-search-history-query small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.catalog-search-history-query strong {
  font-size: 0.78rem;
  font-weight: 880;
  letter-spacing: 0;
}

.catalog-search-history-query small {
  color: var(--catalog-muted);
  font-size: 0.64rem;
  font-weight: 760;
  letter-spacing: 0;
}

.catalog-search-history-delete {
  display: grid;
  place-items: center;
  min-height: 42px;
  border-left: 1px solid rgba(236, 255, 251, 0.1);
}

.catalog-search-history-delete svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.6;
  stroke-linecap: round;
}

.catalog-search-history-query:focus-visible,
.catalog-search-history-delete:focus-visible,
.catalog-search-history-clear:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px rgba(126, 211, 202, 0.24), 0 0 0 1px rgba(126, 211, 202, 0.72) inset;
}

@media (max-width: 430px) {
  .catalog-search-assist {
    margin-bottom: 10px;
  }

  .catalog-search-history-item {
    max-width: 78vw;
  }
}

/* MEMORY LINE: Collection Item Detail Page START */
.collection-item-detail-view {
  min-height: 100dvh;
  padding: max(18px, calc(env(safe-area-inset-top) + 12px)) 16px calc(var(--app-bottom-nav-clearance) + 18px);
  color: #f7f8fb;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  background:
    radial-gradient(circle at 18% 4%, rgba(126, 211, 202, 0.16), transparent 34%),
    radial-gradient(circle at 88% 10%, rgba(255, 209, 102, 0.11), transparent 30%),
    linear-gradient(180deg, #111a29 0%, #070a10 100%);
}

.collection-item-section-head strong {
  margin: 0;
  color: #ffffff;
  letter-spacing: 0;
}

.collection-item-total-card small,
.collection-item-history-meta,
.collection-item-stat small {
  color: rgba(247, 248, 251, 0.66);
  font-size: 0.8125rem;
  font-weight: 560;
  line-height: 1.32;
}

.collection-item-detail-content {
  display: grid;
  gap: 12px;
  width: min(760px, 100%);
  margin: 0 auto;
}

.collection-item-total-card,
.collection-item-history-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025)),
    rgba(12, 17, 26, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  box-shadow: 0 22px 58px rgba(0, 0, 0, 0.24);
}

.collection-item-detail-hero {
  display: block;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.collection-item-detail-art {
  display: grid;
  place-items: center;
  min-height: clamp(240px, 42vh, 340px);
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  overflow: visible;
  box-shadow: none;
}

.collection-item-detail-art .collection-card-image {
  display: block;
  width: auto;
  height: auto;
  max-width: min(78vw, 320px);
  max-height: none;
  object-fit: contain;
  background: transparent;
  border: 0;
  box-shadow: none;
}

.collection-item-detail-art .mini-card {
  width: min(78vw, 260px);
  max-width: 100%;
  height: auto;
  aspect-ratio: 63 / 88;
  object-fit: contain;
}

.collection-item-detail-art .portfolio-slab-preview {
  width: min(54vw, 224px);
  max-height: 332px;
}

.collection-item-market-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.collection-item-market-links a {
  display: flex;
  min-width: 0;
  min-height: 74px;
  align-items: center;
  justify-content: center;
  padding: 10px;
  color: rgba(247, 248, 251, 0.9);
  text-decoration: none;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.025)),
    rgba(13, 19, 28, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 17px;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.2);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.collection-item-market-logo {
  display: grid;
  width: min(100%, 168px);
  height: 42px;
  place-items: center;
  padding: 5px 18px;
  background: rgba(255, 255, 255, 0.94);
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(8, 13, 18, 0.08);
}

.collection-item-market-logo img {
  display: block;
  width: 100%;
  max-height: 30px;
  object-fit: contain;
}

.collection-item-total-card {
  display: grid;
  gap: 8px;
  padding: 18px;
}

.collection-item-detail-summary {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.collection-item-detail-summary > span,
.collection-item-stat span {
  color: #a9e7df;
  font-size: 0.76rem;
  font-weight: 720;
  letter-spacing: 0;
  text-transform: none;
}

.collection-item-section-head span {
  display: block;
  margin-bottom: 4px;
  color: #a9e7df;
  font-size: 0.76rem;
  font-weight: 720;
  letter-spacing: 0;
  text-transform: none;
}

.collection-item-total-value {
  color: #ffffff;
  font-size: clamp(2rem, 8.8vw, 2.65rem);
  font-weight: 780;
  letter-spacing: 0;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.collection-item-metrics-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.collection-item-stat {
  min-width: 0;
  padding: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.03)),
    rgba(13, 18, 27, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 17px;
}

.collection-item-stat strong {
  display: block;
  margin-top: 7px;
  color: #ffffff;
  font-size: clamp(1.12rem, 4.7vw, 1.45rem);
  font-weight: 760;
  letter-spacing: 0;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.collection-item-stat.is-positive strong {
  color: #abf2d8;
}

.collection-item-stat.is-negative strong {
  color: #ffb1a4;
}

.collection-item-history-card {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.collection-item-section-head {
  display: flex;
  gap: 12px;
  align-items: end;
  justify-content: space-between;
}

.collection-item-section-head strong {
  font-size: 0.98rem;
  font-weight: 500;
  line-height: 1.1;
}

.collection-item-section-head small.positive {
  color: #abf2d8;
  font-size: 0.82rem;
  font-weight: 450;
  font-variant-numeric: tabular-nums;
}

.collection-item-section-head small.negative {
  color: #ffb1a4;
  font-size: 0.82rem;
  font-weight: 450;
  font-variant-numeric: tabular-nums;
}

.collection-item-chart {
  min-height: 174px;
  padding: 6px;
  background: rgba(5, 8, 13, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
}

.collection-item-chart svg {
  width: 100%;
  height: auto;
}

.collection-item-chart p {
  margin: 0;
  padding: 28px 12px;
  text-align: center;
  color: rgba(247, 248, 251, 0.62);
}

.collection-item-history-controls {
  margin-top: -2px;
}

.collection-item-history-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  font-size: 0.78rem;
  text-align: center;
}

.collection-item-chart .scanner-market-axis,
.collection-item-chart .scanner-market-date {
  font-size: 9px;
  font-weight: 500;
}

.collection-item-chart .scanner-market-svg-tooltip text {
  font-size: 8px;
  font-weight: 500;
}

.collection-item-chart .scanner-market-svg-tooltip text + text {
  font-size: 10px;
}

.collection-item-empty {
  display: grid;
  gap: 8px;
  padding: 28px;
  text-align: center;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
}

.collection-tab.is-section-detail .collection-portfolio-card {
  cursor: pointer;
}

@media (max-width: 720px) {
  .collection-item-detail-view {
    padding-inline: 12px;
  }

  .collection-item-detail-art {
    min-height: clamp(230px, 39vh, 315px);
  }

  .collection-item-detail-art .portfolio-slab-preview {
    width: min(58vw, 214px);
    max-height: 318px;
  }
}
/* MEMORY LINE: Collection Item Detail Page END */

/* MEMORY LINE: Home Daily Movers START */
.market-movers-card,
body.theme-light .market-movers-card,
body.theme-clear .market-movers-card {
  display: grid;
  gap: 8px;
  margin-top: 8px;
  padding: 14px;
  color: #f8f8f8;
  background:
    linear-gradient(135deg, rgba(44, 52, 58, 0.9), rgba(18, 20, 23, 0.98)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 14px);
  border: 1px solid rgba(135, 247, 255, 0.12);
  border-radius: 20px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.market-movers-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.market-movers-title-button,
.market-movers-see-all {
  appearance: none;
  border: 0;
  font: inherit;
}

.market-movers-title-button {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  padding: 0;
  color: #f8f8f8;
  background: transparent;
  font-size: clamp(1.42rem, 5.5vw, 2rem);
  font-weight: 950;
  line-height: 1.02;
  letter-spacing: 0;
}

.market-movers-title-button svg {
  width: 22px;
  height: 22px;
  margin-left: 6px;
  fill: #ffdc18;
}

.market-movers-see-all {
  flex: 0 0 auto;
  min-height: 28px;
  padding: 0 11px;
  color: #ffdc18;
  background: rgba(255, 220, 24, 0.08);
  border: 1px solid rgba(255, 220, 24, 0.42);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 560;
  line-height: 1;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.market-movers-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 6px;
}

.market-movers-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}

.market-movers-tabs button {
  min-height: 36px;
  padding: 0 13px;
  color: #161719;
  background: linear-gradient(135deg, #ffdf42, #fff06f);
  border: 1px solid rgba(255, 220, 24, 0.8);
  border-radius: 999px;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 950;
  box-shadow: 0 10px 22px rgba(255, 220, 24, 0.16);
}

.market-movers-tabs button.is-active {
  color: #161719;
}

.market-movers-direction {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  justify-self: stretch;
  width: 100%;
  min-width: 0;
  min-height: 36px;
  padding: 3px;
  background: rgba(8, 11, 14, 0.72);
  border: 1px solid rgba(135, 247, 255, 0.14);
  border-radius: 13px;
}

.market-movers-direction button {
  position: relative;
  display: inline-flex;
  place-items: center;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
  padding: 0 7px;
  color: rgba(248, 248, 248, 0.62);
  background: transparent;
  border: 0;
  border-radius: 10px;
  font: inherit;
  font-size: 0.68rem;
  font-weight: 950;
  line-height: 1;
  overflow: hidden;
}

.market-movers-direction button::after {
  content: "";
  position: absolute;
  right: 20%;
  bottom: 4px;
  left: 20%;
  height: 3px;
  background: transparent;
  border-radius: 999px;
  opacity: 0;
}

.market-movers-direction button.is-active {
  color: #87f7ff;
  background: transparent;
  box-shadow: none;
}

.market-movers-direction button.is-active::after {
  background: linear-gradient(90deg, #87f7ff, #9ecbff);
  opacity: 0.9;
}

.market-movers-direction svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}

.market-movers-status {
  justify-self: start;
  max-width: 100%;
  color: rgba(248, 248, 248, 0.72);
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(135, 247, 255, 0.12);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.market-movers-panel {
  display: grid;
  gap: 6px;
}

.market-movers-stage {
  min-height: 0;
}

.market-movers-loading {
  display: grid;
  place-items: center;
  gap: 7px;
  min-height: 190px;
  padding: 20px;
  text-align: center;
  background: rgba(7, 10, 13, 0.34);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 16px;
}

.market-movers-loading strong,
.market-movers-loading span {
  display: block;
}

.market-movers-loading strong {
  color: #f8f8f8;
  font-size: 1.08rem;
  font-weight: 950;
}

.market-movers-loading span {
  max-width: 30ch;
  color: rgba(248, 248, 248, 0.64);
  font-size: 0.86rem;
  line-height: 1.35;
}

.market-mover-feature {
  display: grid;
  grid-template-columns: minmax(78px, 104px) minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 0;
  padding: 9px;
  background: rgba(8, 10, 13, 0.46);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
}

.market-mover-art-row {
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
}

.market-mover-nav {
  position: absolute;
  left: -8px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 28px;
  height: 42px;
  color: rgba(248, 248, 248, 0.62);
  background: rgba(7, 10, 13, 0.76);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

.market-mover-nav.is-next {
  right: -8px;
  left: auto;
  color: #ffdc18;
}

.market-mover-nav svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.market-mover-art-stack {
  display: grid;
  width: 100%;
  place-items: center;
}

.market-mover-main-image {
  display: grid;
  place-items: center;
  width: min(100%, 98px);
  aspect-ratio: 0.716;
  justify-self: center;
  text-decoration: none;
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, 0.36));
}

.market-mover-card-image,
.market-mover-card-placeholder {
  width: 100%;
  height: 100%;
  max-height: 136px;
  object-fit: contain;
  border-radius: 8px;
}

.market-mover-card-placeholder {
  display: grid;
  place-items: center;
  color: #111214;
  background: linear-gradient(145deg, #87f7ff, #ffdc18);
  font-size: 1rem;
  font-weight: 950;
}

.market-mover-peek {
  display: none;
}

.market-mover-peek-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 8px;
}

.market-mover-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
  justify-items: start;
  text-align: left;
}

.market-mover-copy h3 {
  margin: 0;
  max-width: 100%;
  color: #f8f8f8;
  font-size: clamp(1.12rem, 5vw, 1.62rem);
  font-weight: 950;
  line-height: 1.06;
  overflow-wrap: anywhere;
}

.market-mover-copy p {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 6px;
  margin: 0;
  color: rgba(248, 248, 248, 0.52);
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1.2;
}

.market-mover-set-code {
  display: inline-grid;
  place-items: center;
  min-width: 30px;
  min-height: 18px;
  padding-inline: 4px;
  color: #081013;
  background: #87f7ff;
  border-radius: 5px;
  font-size: 0.62rem;
  font-weight: 950;
}

.market-mover-copy > strong {
  color: #f8f8f8;
  font-size: clamp(1.45rem, 6vw, 2rem);
  font-weight: 950;
  line-height: 1;
}

.market-mover-change {
  color: rgba(248, 248, 248, 0.56);
  font-size: 0.9rem;
  font-weight: 950;
}

.market-mover-change.positive,
.market-mover-list-item small.positive {
  color: #8ee8bd;
}

.market-mover-change.negative,
.market-mover-list-item small.negative {
  color: #ff876f;
}

.market-mover-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 5px;
}

.market-mover-badges span {
  min-height: 22px;
  padding: 3px 7px;
  color: rgba(248, 248, 248, 0.58);
  border: 1px solid rgba(248, 248, 248, 0.22);
  border-radius: 999px;
  font-size: 0.64rem;
  font-weight: 950;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.market-movers-list {
  display: grid;
  gap: 8px;
}

.market-movers-list[hidden] {
  display: none;
}

.market-mover-list-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 62px;
  padding: 8px;
  color: #f8f8f8;
  text-align: left;
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 13px;
}

.market-mover-list-image {
  width: 42px;
  aspect-ratio: 0.716;
  object-fit: contain;
  border-radius: 6px;
}

.market-mover-list-item span,
.market-mover-list-item em,
.market-mover-list-item strong,
.market-mover-list-item small {
  display: block;
  min-width: 0;
}

.market-mover-list-item span strong {
  overflow: hidden;
  color: #f8f8f8;
  font-size: 0.86rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.market-mover-list-item span small,
.market-mover-list-item em small {
  margin-top: 2px;
  color: rgba(248, 248, 248, 0.56);
  font-size: 0.72rem;
  font-style: normal;
}

.market-mover-list-item em {
  text-align: right;
  font-style: normal;
}

.market-mover-list-item em strong {
  color: #f8f8f8;
  font-size: 0.86rem;
}

@media (max-width: 480px) {
  .market-movers-card,
  body.theme-light .market-movers-card,
  body.theme-clear .market-movers-card {
    padding: 12px;
    border-radius: 18px;
  }

  .market-movers-toolbar {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .market-movers-direction {
    justify-self: stretch;
    min-width: 0;
  }

  .market-mover-feature {
    grid-template-columns: minmax(72px, 90px) minmax(0, 1fr);
    gap: 8px;
    padding: 8px;
  }

  .market-mover-main-image {
    width: min(100%, 86px);
  }

  .market-mover-list-item {
    grid-template-columns: 40px minmax(0, 1fr);
  }

  .market-mover-list-item em {
    grid-column: 2;
    text-align: left;
  }
}

/* MEMORY LINE: Home TCG Profiles START */
.tcg-profile-card {
  container-type: inline-size;
  display: grid;
  gap: 10px;
  padding: 14px;
  color: #f8f8f8;
  background:
    radial-gradient(circle at 16% 0%, rgba(135, 247, 255, 0.1), transparent 34%),
    linear-gradient(135deg, rgba(18, 25, 30, 0.92), rgba(7, 10, 14, 0.98));
  border: 1px solid rgba(135, 247, 255, 0.1);
  border-radius: 20px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.tcg-profile-head {
  display: flex;
  align-items: end;
  justify-content: flex-start;
}

.tcg-profile-head h2 {
  margin: 0;
  color: #f8f8f8;
  font-size: clamp(1.04rem, 4vw, 1.24rem);
  font-weight: 560;
  letter-spacing: -0.01em;
}

.tcg-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.tcg-profile-tile {
  position: relative;
  display: grid;
  grid-template-rows: minmax(28px, 1fr) auto;
  gap: 7px;
  min-height: 84px;
  padding: 13px 10px 10px;
  overflow: hidden;
  align-content: center;
  justify-items: center;
  text-align: center;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.036), rgba(255, 255, 255, 0.01)),
    rgba(2, 5, 8, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.065);
  border-radius: 15px;
  opacity: 0.9;
}

.tcg-profile-tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.08), transparent 52%);
  border-radius: 999px;
  opacity: 0.42;
  pointer-events: none;
}

.tcg-profile-tile.is-live {
  opacity: 1;
  filter: none;
  cursor: pointer;
  background:
    radial-gradient(circle at 50% 16%, rgba(255, 220, 24, 0.1), transparent 46%),
    linear-gradient(145deg, rgba(135, 247, 255, 0.12), rgba(255, 220, 24, 0.045)),
    rgba(7, 10, 13, 0.78);
  border-color: rgba(135, 247, 255, 0.32);
}

.tcg-profile-tile.is-selected {
  border-color: rgba(255, 220, 24, 0.54);
  box-shadow: inset 0 0 0 1px rgba(255, 220, 24, 0.26);
}

.tcg-profile-tile:focus-visible {
  outline: 2px solid rgba(255, 220, 24, 0.78);
  outline-offset: 3px;
}

.tcg-profile-tile[data-tcg-profile="digimon"],
.tcg-profile-tile[data-tcg-profile="yugioh"] {
  opacity: 0.52;
}

.tcg-profile-tile.is-live::before {
  background:
    linear-gradient(90deg, transparent 5%, rgba(101, 197, 187, 0.72), rgba(126, 164, 255, 0.5), transparent 95%);
  inset: auto 14px 8px;
  height: 2px;
  opacity: 0.9;
}

.tcg-profile-logo-img {
  position: relative;
  z-index: 1;
  display: block;
  align-self: center;
  width: min(100%, 158px);
  max-width: 88%;
  height: 42px;
  object-fit: contain;
}

.tcg-profile-tile[data-tcg-profile="pokemon"] .tcg-profile-logo-img {
  height: 48px;
  max-width: 92%;
}

.tcg-profile-tile em {
  position: relative;
  z-index: 1;
  display: inline-grid;
  place-items: center;
  min-height: 20px;
  padding: 3px 8px;
  color: rgba(246, 181, 255, 0.82);
  background: rgba(255, 49, 255, 0.065);
  border: 1px solid rgba(255, 49, 255, 0.24);
  border-radius: 999px;
  font-size: 0.52rem;
  font-style: normal;
  font-weight: 620;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.tcg-profile-tile.is-live em {
  color: #06110f;
  background: #65c5bb;
  border-color: #65c5bb;
}

@container (min-width: 620px) {
  .tcg-profile-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 360px) {
  .tcg-profile-card {
    padding: 12px;
  }

  .tcg-profile-tile {
    min-height: 78px;
    padding-inline: 8px;
  }

  .tcg-profile-logo-img {
    height: 30px;
  }
}
/* MEMORY LINE: Home TCG Profiles END */

body.is-market-movers-full .dashboard-header {
  display: none;
}

body.is-market-movers-full {
  background: #0b0c0e;
}

body.is-market-movers-full .collector-app {
  background:
    linear-gradient(180deg, #101215 0%, #0b0c0e 42%, #090a0c 100%);
}

.market-movers-full-view {
  display: grid;
  align-content: start;
  align-items: start;
  gap: 10px;
  color: #f8f8f8;
}

.market-movers-full-view[hidden] {
  display: none;
}

.market-movers-full-head {
  position: sticky;
  top: 0;
  z-index: 8;
  display: grid;
  grid-template-columns: 44px;
  align-items: center;
  gap: 8px;
  min-height: 54px;
  padding: 0 0 8px;
  background: rgba(13, 14, 16, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(16px);
}

.market-movers-full-back {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  color: #ffdc18;
  background: transparent;
  border: 0;
  border-radius: 14px;
}

.market-movers-full-back svg {
  width: 34px;
  height: 34px;
}

.market-movers-full-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-self: start;
  gap: 4px;
  height: 48px;
  min-height: 48px;
  padding: 4px;
  background: rgba(5, 7, 9, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
}

.market-movers-full-tabs button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 0;
  padding: 0 10px;
  color: rgba(248, 248, 248, 0.68);
  background: transparent;
  border: 0;
  border-radius: 12px;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 950;
}

.market-movers-full-tabs button.is-active {
  color: #111214;
  background: #87f7ff;
  box-shadow: 0 10px 20px rgba(135, 247, 255, 0.14);
}

.market-movers-full-tabs svg {
  width: 18px;
  height: 18px;
}

.market-movers-full-ranges {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-self: start;
  gap: 6px;
  height: 42px;
  min-height: 42px;
  padding: 4px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.075);
  border-radius: 14px;
}

.market-movers-full-ranges button {
  display: grid;
  place-items: center;
  min-width: 0;
  padding: 0 10px;
  color: rgba(248, 248, 248, 0.6);
  background: rgba(7, 9, 11, 0.42);
  border: 1px solid transparent;
  border-radius: 10px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 950;
}

.market-movers-full-ranges button.is-active {
  color: #ffdc18;
  background: rgba(255, 220, 24, 0.12);
  border-color: rgba(255, 220, 24, 0.5);
  box-shadow: inset 0 0 0 1px rgba(255, 220, 24, 0.08);
}

.market-movers-full-status {
  margin: 0;
  padding: 7px 10px;
  background: rgba(255, 255, 255, 0.065);
  border: 1px solid rgba(255, 255, 255, 0.075);
  border-radius: 999px;
}

.market-movers-full-status {
  justify-self: start;
  color: rgba(248, 248, 248, 0.66);
  font-size: 0.74rem;
  font-weight: 900;
}

.market-movers-full-status[hidden] {
  display: none;
}

.market-movers-rank-list {
  display: grid;
  gap: 0;
  padding-bottom: 14px;
}

.market-movers-full-notice {
  display: grid;
  gap: 5px;
  margin: 2px 0 8px;
  padding: 10px 12px;
  color: rgba(248, 248, 248, 0.78);
  background: rgba(135, 247, 255, 0.08);
  border: 1px solid rgba(135, 247, 255, 0.18);
  border-radius: 8px;
}

.market-movers-full-notice strong {
  color: #f8f8f8;
  font-size: 0.82rem;
  font-weight: 800;
}

.market-movers-full-notice span {
  font-size: 0.74rem;
  line-height: 1.35;
}

.market-movers-rank-row {
  display: grid;
  grid-template-columns: 30px 68px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 106px;
  padding: 11px 0;
  color: #f8f8f8;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.market-movers-rank-number {
  color: #f8f8f8;
  font-size: clamp(1.24rem, 5.6vw, 1.62rem);
  font-weight: 650;
  line-height: 1;
  text-align: center;
}

.market-movers-rank-image-wrap {
  display: grid;
  place-items: center;
  width: 68px;
  aspect-ratio: 0.716;
  text-decoration: none;
}

.market-movers-rank-image,
.market-movers-rank-image.market-mover-card-placeholder {
  width: 100%;
  height: 100%;
  max-height: 96px;
  object-fit: contain;
  border-radius: 7px;
}

.market-movers-rank-copy {
  display: grid;
  min-width: 0;
  gap: 5px;
}

.market-movers-rank-copy h3 {
  margin: 0;
  overflow: hidden;
  color: #f8f8f8;
  font-size: clamp(1.12rem, 5.4vw, 1.55rem);
  font-weight: 950;
  line-height: 1.06;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.market-movers-rank-copy p {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0;
  overflow: hidden;
  color: rgba(248, 248, 248, 0.5);
  font-size: 0.83rem;
  font-weight: 900;
  line-height: 1.15;
}

.market-movers-rank-metrics {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.market-movers-rank-metrics > strong {
  color: #f8f8f8;
  font-size: clamp(1.18rem, 5.8vw, 1.55rem);
  font-weight: 950;
  line-height: 1;
}

.market-movers-rank-change {
  display: inline-flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 6px;
  min-width: 0;
  color: rgba(248, 248, 248, 0.82);
  font-weight: 950;
  text-align: right;
}

.market-movers-rank-change strong,
.market-movers-rank-change em {
  overflow: hidden;
  max-width: 100%;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.market-movers-rank-change strong {
  font-size: 0.88rem;
}

.market-movers-rank-change em {
  font-size: 0.9rem;
  font-style: normal;
}

.market-movers-rank-change.positive em,
.market-movers-rank-change.positive strong {
  color: #96e58d;
}

.market-movers-rank-change.negative em,
.market-movers-rank-change.negative strong {
  color: #ff876f;
}

.market-movers-full-empty {
  display: grid;
  place-items: center;
  gap: 8px;
  min-height: 260px;
  padding: 26px;
  color: rgba(248, 248, 248, 0.58);
  text-align: center;
}

.market-movers-full-empty strong {
  color: #f8f8f8;
  font-size: 1.25rem;
  font-weight: 950;
}

@media (max-width: 390px) {
  .market-movers-rank-row {
    grid-template-columns: 26px 58px minmax(0, 1fr);
    gap: 8px;
    min-height: 98px;
  }

  .market-movers-rank-image-wrap {
    width: 58px;
  }

  .market-movers-rank-copy h3 {
    font-size: 1.02rem;
  }

  .market-movers-rank-metrics {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }

  .market-movers-rank-change strong,
  .market-movers-rank-change em {
    font-size: 0.82rem;
  }
}
/* MEMORY LINE: Home Daily Movers END */

/* MEMORY LINE: APPLE TYPOGRAPHY SYSTEM START */
input,
button,
select,
textarea,
.scanner-sheet-candidate-option,
.scanner-sheet-lookup-field input,
.shared-trade-view {
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
}

#portfolioHeroValue,
.portfolio-pulse-copy > strong,
.collection-tab.is-section-detail .collection-portfolio-hero div > strong,
.value-hub strong,
.portfolio-graph-head strong,
.collection-stat-row strong,
.stat-card strong,
.price-pills strong,
.value-row strong,
.collector-app .value-row strong,
.portfolio-card-market strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-price-row strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-footer strong,
.market-mover-copy > strong,
.market-movers-rank-metrics > strong,
.market-movers-rank-change strong,
.scanner-sheet-candidate-price,
.scanner-sheet-result strong,
.scanner-job-price,
.sold-title-row strong,
.market-result strong {
  font-weight: 520;
  letter-spacing: -0.02em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

#portfolioHeroValue,
.portfolio-pulse-copy > strong {
  font-size: clamp(1.7rem, 7vw, 2.25rem);
}

.portfolio-pulse-copy h2,
.hero-copy h2,
.section-row h2 {
  font-size: clamp(1.05rem, 4.2vw, 1.35rem);
  font-weight: 520;
  letter-spacing: -0.01em;
}

.portfolio-pulse-copy > span {
  font-size: clamp(0.78rem, 3vw, 0.92rem);
  font-weight: 500;
  letter-spacing: -0.01em;
}

.eyebrow,
.portfolio-currency-pill,
.portfolio-currency-pill span {
  font-weight: 520;
}

.eyebrow {
  font-size: 0.68rem;
}

.portfolio-mode-tabs button {
  font-size: clamp(0.82rem, 3vw, 0.98rem);
  font-weight: 520;
}

.portfolio-currency-pill {
  font-size: 0.78rem;
}

.portfolio-range-tabs button,
.range-tabs button {
  font-weight: 500;
}

.portfolio-pulse-footer span,
.portfolio-pulse-footer small,
.portfolio-pulse-card .graph-label,
#portfolioGraphSummary {
  font-weight: 450;
}

.portfolio-pulse-footer strong {
  font-size: 1rem;
  font-weight: 520;
}

.portfolio-card-market strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-price-row strong,
.market-mover-copy > strong,
.market-movers-rank-metrics > strong,
.scanner-sheet-candidate-price,
.scanner-sheet-result strong,
.sold-title-row strong,
.market-result strong {
  font-size: 1rem;
}

.collection-stat-row strong,
.stat-card strong,
.price-pills strong {
  font-size: clamp(0.8125rem, 3.2vw, 0.9375rem);
}

.collection-tab-head h2,
.shared-trade-header h2,
.vendor-hero-card h2,
.app-menu-panel h2 {
  font-size: 1.25rem;
  font-weight: 520;
  letter-spacing: -0.01em;
}

.card-topline h3,
.portfolio-card-copy h3,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy h3,
.market-mover-copy h3,
.market-movers-rank-copy h3,
.scanner-sheet-head h3,
.sold-title-row h4,
.catalog-result-copy strong {
  font-size: 0.9375rem;
  font-weight: 460;
  letter-spacing: -0.01em;
}

.card-topline p,
.portfolio-card-copy p,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-copy p,
.market-mover-copy p,
.market-movers-rank-copy p,
.collection-tab .card-meta,
.collection-tab .card-notes,
.scanner-sheet-head span,
.scanner-sheet-result p,
.catalog-result-copy small,
.vendor-hero-card span,
.shared-trade-header span {
  font-size: 0.8125rem;
  font-weight: 400;
  opacity: 0.68;
}

.bottom-nav a span,
.bottom-nav .scan-tab span {
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
}

input::placeholder,
textarea::placeholder {
  font-size: 0.9375rem;
  font-weight: 400;
}

.scanner-manual-search-placeholder,
.scanner-search-placeholder-query {
  font-size: 0.9375rem;
  font-weight: 400;
}

.home-action-strip a,
.home-action-strip button,
.save-inventory-btn,
.scanner-sheet-add-btn,
.scanner-sheet-confirm-btn,
.catalog-add-collection-btn,
.catalog-grade-price-btn,
.collection-back-btn,
.market-movers-see-all,
.market-movers-toolbar button,
.market-movers-full-tabs button,
.market-movers-full-ranges button {
  font-size: 0.875rem;
  font-weight: 450;
}

.card-actions a {
  font-size: 0.72rem;
  font-weight: 450;
  letter-spacing: 0.01em;
}

.market-mover-change,
.market-movers-rank-change em,
.portfolio-card-market em,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market em,
.portfolio-card-market.positive em,
.portfolio-card-market.negative em,
.positive small,
.negative small,
.scanner-sheet-candidate-option small {
  font-size: 0.72rem;
  font-weight: 400;
}

.collection-trade-text-icon,
.collection-trade-hub-count,
.collection-action-button strong,
.vault-card-badge-row span,
.vault-card-edit-toggle,
.vault-card-edit-actions button,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory button,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-inventory button + button,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market small,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-qty,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-sell,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-paid {
  font-weight: 450;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market strong,
.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-price-row strong {
  font-size: 0.86rem;
  font-weight: 450;
  letter-spacing: -0.01em;
}

.collection-tab.is-section-detail .collection-portfolio-card .portfolio-card-market em {
  font-size: 0.62rem;
  font-weight: 400;
}

.trade-link-panel {
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
}

.trade-link-head strong {
  font-size: 1.1rem;
  font-weight: 520;
  letter-spacing: -0.01em;
  line-height: 1.08;
}

.trade-toggle-row strong,
.trade-offer-suggestions strong {
  font-size: 0.9rem;
  font-weight: 520;
  letter-spacing: -0.01em;
}

.trade-link-head small,
.trade-toggle-row small {
  font-size: 0.78rem;
  font-weight: 400;
  line-height: 1.36;
}

.trade-note-field span {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.06em;
}

.trade-note-field textarea,
.trade-note-field input {
  font-size: 0.84rem;
  font-weight: 400;
  line-height: 1.35;
}

.trade-link-head button,
.trade-link-actions button {
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: -0.005em;
}

.trade-link-output {
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.35;
}

/* Home borderless portfolio surface START */
.portfolio-pulse-card,
body.theme-light .portfolio-pulse-card,
body.theme-clear .portfolio-pulse-card {
  overflow: visible;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.portfolio-pulse-card::before,
body.theme-clear .portfolio-pulse-card::before {
  content: none;
  display: none;
}
/* Home borderless portfolio surface END */
/* MEMORY LINE: APPLE TYPOGRAPHY SYSTEM END */
