:root {
  --ink: #1d201d;
  --muted: #6d716b;
  --paper: #f4f2ed;
  --card: #fffdf8;
  --line: #dcd8ce;
  --green: #245b45;
  --green-soft: #e3eee7;
  --gold: #ba853c;
  --shadow: 0 18px 50px rgba(45, 42, 34, .08);
}

/* NewAge Metals treatment for the private operational workspaces. */
.listing-page,
.catalogue-page,
.newage-page {
  --ink: #f5f2ed;
  --muted: #aaa7ae;
  --paper: #09090c;
  --card: #171619;
  --line: rgba(209,179,122,.24);
  --green: #d1b37a;
  --green-soft: rgba(209,179,122,.13);
  --gold: #d1b37a;
  --shadow: 0 20px 58px rgba(0,0,0,.36);
  min-height: 100vh;
  background:
    radial-gradient(circle at 17% 4%, rgba(163,87,46,.23), transparent 30rem),
    radial-gradient(circle at 90% 75%, rgba(209,179,122,.07), transparent 35rem),
    var(--paper);
}

[hidden] { display: none !important; }
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: Inter, ui-sans-serif, system-ui, -apple-system, sans-serif; }
.topbar { height: 72px; padding: 0 max(28px, calc((100vw - 1420px)/2)); display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); background: rgba(244,242,237,.92); }
.brand { display: flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; font-size: 18px; letter-spacing: -.4px; }
.brand b { color: var(--green); }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; color: #fff; background: var(--green); border-radius: 50%; font: 700 18px Georgia, serif; }
.brand-logo { width: 40px; height: 40px; flex: 0 0 40px; border: 1px solid rgba(209,179,122,.45); border-radius: 11px; object-fit: cover; box-shadow: 0 0 22px rgba(209,179,122,.22); }
.status { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 13px; }
.connection-warning { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin: 0 0 18px; padding: 15px 18px; border: 1px solid #e7c987; border-radius: 10px; background: #fff8e7; }
.connection-warning div { display: grid; gap: 3px; }
.connection-warning span { color: var(--muted); font-size: 12px; }
.connection-warning .button-link { flex: 0 0 auto; }
.topnav { display: flex; gap: 5px; padding: 4px; overflow-x: auto; border: 1px solid var(--line); border-radius: 9px; background: rgba(255,255,255,.48); }
.topnav a { padding: 7px 11px; border-radius: 6px; color: var(--muted); text-decoration: none; white-space: nowrap; font-size: 12px; font-weight: 700; }
.topnav a.current { color: #fff; background: var(--green); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #70a47e; box-shadow: 0 0 0 4px var(--green-soft); }
main { max-width: 1420px; margin: 0 auto; padding: 58px 28px 80px; }
.intro { display: flex; justify-content: space-between; align-items: end; margin-bottom: 38px; }
.eyebrow { margin: 0 0 9px; color: var(--green); text-transform: uppercase; letter-spacing: 1.6px; font-size: 11px; font-weight: 750; }
h1 { max-width: 720px; margin: 0; font: 500 clamp(43px, 5vw, 71px)/.98 Georgia, serif; letter-spacing: -2.7px; }
.lede { max-width: 610px; margin: 21px 0 0; color: var(--muted); font-size: 16px; line-height: 1.55; }
.stepper { display: flex; gap: 24px; padding-bottom: 5px; }
.stepper span { display: grid; place-items: center; width: 34px; height: 34px; position: relative; border: 1px solid var(--line); border-radius: 50%; color: #92958f; font-size: 12px; }
.stepper span:not(:last-child)::after { content: ""; position: absolute; left: 34px; width: 24px; border-top: 1px solid var(--line); }
.stepper em { position: absolute; top: 43px; font-style: normal; font-size: 10px; }
.stepper .complete { color: white; background: var(--green); border-color: var(--green); }
.stepper .active { color: var(--green); border: 2px solid var(--green); font-weight: 700; }
.workspace { display: grid; grid-template-columns: minmax(380px, .72fr) 40px minmax(620px, 1.28fr); align-items: start; }
.card { border: 1px solid var(--line); border-radius: 14px; background: var(--card); box-shadow: var(--shadow); overflow: hidden; }
.card-heading { min-height: 90px; padding: 22px 25px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
h2 { margin: 0; font: 500 25px Georgia, serif; }
.pill { padding: 7px 10px; border-radius: 99px; font-size: 11px; font-weight: 750; }
.shopify { background: #e9f2e4; color: #3c672c; }
.ebay { background: #edf0f8; color: #315389; }
.master { background: #f3e9d6; color: #75521d; }
.loading { padding: 40px 25px; color: var(--muted); }
.product-picker { padding: 18px 25px; border-bottom: 1px solid var(--line); }
.product-picker label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .8px; }
.product-picker select { width: 100%; min-height: 40px; padding: 0 10px; border: 1px solid var(--line); border-radius: 7px; background: #fff; color: var(--ink); font: inherit; }
.search-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin-bottom: 15px; }
.search-row input { min-width: 0; padding: 0 10px; border: 1px solid var(--line); border-radius: 7px; font: inherit; }
.search-row button { min-width: 78px; padding: 10px 12px; }
.flow-arrow { display: grid; place-items: center; margin-top: 170px; color: var(--gold); font-size: 26px; }
.product-body { padding: 25px; }
.source-image { width: 100%; aspect-ratio: 1.4; object-fit: cover; border-radius: 9px; background: #eee; }
.source h3, .listing h3 { margin: 19px 0 8px; font: 500 23px/1.2 Georgia, serif; }
.sku { color: var(--muted); font: 12px ui-monospace, SFMono-Regular, monospace; }
.source-grid { display: grid; grid-template-columns: 1fr 1fr; margin-top: 25px; border: 1px solid var(--line); border-radius: 8px; }
.source-grid div { padding: 13px; border-bottom: 1px solid var(--line); }
.source-grid div:nth-child(odd) { border-right: 1px solid var(--line); }
.source-grid div:nth-last-child(-n+2) { border-bottom: none; }
.label { display: block; margin-bottom: 5px; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .8px; }
.listing { padding: 25px; }
.listing-top { display: grid; grid-template-columns: 210px 1fr; gap: 24px; }
.listing-image { width: 100%; aspect-ratio: 1; border-radius: 8px; object-fit: cover; }
.price { margin: 15px 0 4px; font: 600 30px Georgia, serif; }
.meta { color: var(--muted); font-size: 13px; }
.aspects { margin-top: 28px; border-top: 1px solid var(--line); }
.aspect { display: grid; grid-template-columns: 145px 1fr; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.aspect span:first-child { color: var(--muted); }
.notice { margin-top: 20px; padding: 14px 16px; border-radius: 8px; font-size: 13px; line-height: 1.45; }
.notice.good { color: #20553e; background: var(--green-soft); }
.notice.warn { color: #76511f; background: #f7ead5; }
.notice span { display: block; margin-top: 5px; }
.worksheet-banner { display: flex; justify-content: space-between; align-items: center; padding: 17px 25px; background: #f1f4ef; border-bottom: 1px solid var(--line); }
.worksheet-banner strong { display: block; font-size: 14px; }
#save-status { color: var(--green); font-size: 12px; }
.profile-settings { padding: 0 25px; border-bottom: 1px solid var(--line); background: #faf7ef; }
.profile-settings summary { padding: 15px 0; color: var(--green); cursor: pointer; font-size: 13px; font-weight: 750; }
.profile-help { margin: -3px 0 15px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.profile-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
.profile-actions { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 16px 0 20px; color: var(--muted); font-size: 11px; }
.small-button { min-width: 130px; padding: 10px 14px; }
.form-section { padding: 25px; border-bottom: 1px solid var(--line); }
.form-section:last-child { border-bottom: 0; }
.section-title { display: flex; gap: 12px; align-items: start; margin-bottom: 20px; }
.section-title > span { display: grid; place-items: center; width: 28px; height: 28px; flex: 0 0 28px; border-radius: 50%; color: white; background: var(--green); font-size: 10px; }
.section-title h3 { margin: 0; font: 500 21px Georgia, serif; }
.section-title p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
.worksheet label > span { display: flex; justify-content: space-between; margin-bottom: 7px; color: var(--muted); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .55px; }
.worksheet label em { color: var(--green); font-style: normal; }
.worksheet input, .worksheet textarea, .worksheet select { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 7px; background: #fff; color: var(--ink); font: inherit; }
.worksheet input:focus, .worksheet textarea:focus, .worksheet select:focus { outline: 2px solid rgba(36,91,69,.18); border-color: var(--green); }
.worksheet input:disabled { background: #f2f0eb; color: var(--muted); }
.worksheet small { display: block; margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.35; }
.three-fields { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 13px; margin-top: 15px; }
.policy-grid { display: grid; gap: 13px; }
.image-help { margin: -5px 0 16px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.image-grid { display: grid; gap: 10px; }
.image-row { display: grid; grid-template-columns: 74px 1fr; gap: 12px; align-items: center; }
.image-preview { display: grid; place-items: center; width: 74px; aspect-ratio: 1; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: #f2f0eb; color: var(--muted); font-size: 12px; }
.image-preview img { width: 100%; height: 100%; object-fit: cover; }
.mapping-table { border: 1px solid var(--line); border-radius: 9px; overflow: hidden; }
.mapping-row { display: grid; grid-template-columns: minmax(155px,.8fr) 30px minmax(170px,1fr) 44px; gap: 9px; align-items: center; padding: 11px 13px; border-bottom: 1px solid var(--line); }
.mapping-row:last-child { border-bottom: 0; }
.mapping-source small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mapping-line { color: var(--gold); text-align: center; }
.source-badge { display: inline-block; padding: 4px 7px; border-radius: 99px; background: #eee; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .6px; }
.source-badge.profile { color: #725017; background: #f5e7c8; }
.source-badge.derived { color: #315389; background: #e6ebf5; }
.source-badge.override { color: #713b65; background: #f1e2ee; }
.reset-link { min-width: 0; padding: 5px; color: var(--green); background: transparent; font-size: 10px; }
.validation-section { background: #faf9f6; }
.validation-section .notice { margin-top: 0; }
.empty-image { display: grid; place-items: center; color: var(--muted); }
.actions { margin-top: 22px; padding: 18px 20px; display: flex; justify-content: space-between; align-items: start; gap: 24px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,253,248,.7); }
.actions strong, .actions span { display: block; }
.actions div > span { margin-top: 4px; color: var(--muted); font-size: 12px; }
.publish-copy { flex: 1; min-width: 0; }
.publish-actions { display: grid; gap: 9px; }
.publish-panel { margin-top: 14px; padding: 13px 15px; border-radius: 8px; font-size: 12px; line-height: 1.45; }
.publish-panel.blocked { color: #76511f; background: #f7ead5; }
.publish-panel.ready { color: #20553e; background: var(--green-soft); }
.publish-panel label { display: block; margin-top: 12px; }
.publish-panel code { display: inline-block; margin: 7px 0; padding: 5px 7px; border-radius: 5px; color: var(--ink); background: rgba(255,255,255,.7); font-size: 11px; }
.publish-panel input { width: min(100%, 470px); padding: 9px 10px; border: 1px solid var(--line); border-radius: 6px; font: inherit; }
button { min-width: 190px; padding: 14px 18px; border: none; border-radius: 8px; color: white; background: var(--green); font-weight: 700; }
button:disabled { opacity: .43; cursor: not-allowed; }
button span { display: inline; margin-left: 14px; }

/* Listing worksheet: vertical navigation and dark precious-metals chrome. */
.listing-page .listing-sidebar {
  position: fixed;
  z-index: 20;
  inset: 0 auto 0 0;
  width: 236px;
  height: 100vh;
  padding: 28px 18px 22px;
  display: flex;
  align-items: stretch;
  justify-content: flex-start;
  flex-direction: column;
  gap: 28px;
  border-right: 1px solid var(--line);
  border-bottom: 0;
  background: linear-gradient(180deg, rgba(33,31,34,.98), rgba(9,9,12,.98));
  box-shadow: 18px 0 50px rgba(0,0,0,.2);
}
.listing-page .brand { color: var(--ink); font-weight: 700; }
.listing-page .brand b { color: var(--gold); }
.listing-page .brand-mark {
  position: relative;
  width: 40px;
  height: 40px;
  overflow: visible;
  color: #09090c;
  background: linear-gradient(145deg, #ffe584, var(--gold) 60%, #a3572e);
  box-shadow: 0 0 20px rgba(209,179,122,.22);
  font-size: 22px;
}
.listing-page .brand-mark::before {
  content: "♛";
  position: absolute;
  top: -15px;
  color: #e2c684;
  font: 15px Georgia, serif;
  text-shadow: 0 0 8px rgba(209,179,122,.55);
}
.listing-page .topnav {
  width: 100%;
  padding: 5px;
  display: grid;
  gap: 5px;
  overflow: visible;
  border-color: rgba(209,179,122,.16);
  background: rgba(255,255,255,.025);
}
.listing-page .topnav a {
  padding: 12px 13px;
  color: var(--muted);
  border: 1px solid transparent;
  text-align: left;
  transition: color .18s ease, border-color .18s ease, background .18s ease;
}
.listing-page .topnav a:hover { color: var(--ink); border-color: rgba(209,179,122,.22); background: rgba(209,179,122,.06); }
.listing-page .topnav a.current {
  color: #0b0a0c;
  border-color: #f1d28c;
  background: linear-gradient(135deg, #f4da9b, var(--gold));
  box-shadow: 0 0 22px rgba(209,179,122,.2);
}
.listing-page .status {
  margin-top: auto;
  padding: 13px 11px;
  align-items: flex-start;
  border-top: 1px solid var(--line);
  line-height: 1.4;
}
.listing-page .status .dot { margin-top: 4px; background: var(--gold); box-shadow: 0 0 0 4px rgba(209,179,122,.12); }
.listing-page main { max-width: 1580px; margin: 0 auto 0 236px; padding: 50px 32px 80px; }
.listing-page h1,
.listing-page h2,
.listing-page .source h3,
.listing-page .listing h3 { color: var(--ink); }
.listing-page h1 {
  background: linear-gradient(105deg, #fff 8%, #e6d3aa 48%, #c4935c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.listing-page .eyebrow { color: var(--gold); }
.listing-page .card,
.listing-page .actions {
  border-color: var(--line);
  background: linear-gradient(145deg, rgba(33,31,34,.98), rgba(17,16,19,.98));
  box-shadow: var(--shadow);
}
.listing-page .card-heading,
.listing-page .product-picker,
.listing-page .source-grid,
.listing-page .source-grid div,
.listing-page .worksheet-banner,
.listing-page .profile-settings,
.listing-page .form-section,
.listing-page .aspects,
.listing-page .aspect,
.listing-page .mapping-table,
.listing-page .mapping-row { border-color: var(--line); }
.listing-page .product-picker select,
.listing-page .search-row input,
.listing-page .worksheet input,
.listing-page .worksheet textarea,
.listing-page .worksheet select,
.listing-page .publish-panel input,
.listing-page .costing-tool input {
  color: var(--ink);
  border-color: rgba(209,179,122,.3);
  background: #211f22;
  color-scheme: dark;
}
.listing-page .product-picker select:focus,
.listing-page .search-row input:focus,
.listing-page .worksheet input:focus,
.listing-page .worksheet textarea:focus,
.listing-page .worksheet select:focus,
.listing-page .costing-tool input:focus {
  outline: 2px solid rgba(209,179,122,.18);
  border-color: var(--gold);
}
.listing-page .worksheet input:disabled { color: #817d84; background: #141316; }
.listing-page .worksheet-banner { background: rgba(209,179,122,.07); }
.listing-page .profile-settings { background: rgba(9,9,12,.42); }
.listing-page .validation-section { background: rgba(9,9,12,.25); }
.listing-page .source-image,
.listing-page .image-preview { background: #0d0d10; }
.listing-page .shopify { color: #96dc7c; background: rgba(94,170,74,.15); }
.listing-page .ebay { color: #9dbbff; background: rgba(66,105,190,.18); }
.listing-page .source-badge { background: rgba(255,255,255,.09); }
.listing-page .source-badge.profile { color: #e7c982; background: rgba(209,179,122,.12); }
.listing-page .source-badge.derived { color: #a7c0f3; background: rgba(76,108,174,.18); }
.listing-page .source-badge.override { color: #e4a9d8; background: rgba(174,76,151,.16); }
.listing-page .notice.good,
.listing-page .publish-panel.ready { color: #8dffac; background: rgba(58,198,91,.11); }
.listing-page .notice.warn,
.listing-page .publish-panel.blocked { color: #ffd29a; background: rgba(197,111,51,.13); }
.listing-page button,
.listing-page .button-link {
  color: #0b0a0c;
  background: linear-gradient(135deg, #eed18a, var(--gold));
  box-shadow: 0 8px 22px rgba(0,0,0,.22);
}
.listing-page .reset-link { color: var(--gold); background: transparent; box-shadow: none; }
.listing-page .flow-arrow { color: var(--gold); text-shadow: 0 0 13px rgba(209,179,122,.42); }
.source-column { display: grid; gap: 18px; min-width: 0; }

/* Always-visible eBay state with a deliberate two-step reconnect control. */
.listing-page .connection-warning {
  min-height: 78px;
  padding: 16px 18px;
  border-width: 1px;
  border-radius: 13px;
  background: rgba(17,16,19,.92);
  box-shadow: 0 14px 36px rgba(0,0,0,.26);
}
.connection-copy,
.connection-controls { display: flex; align-items: center; gap: 12px; }
.connection-copy > div { display: grid; gap: 4px; }
.connection-light { width: 13px; height: 13px; flex: 0 0 13px; border-radius: 50%; }
.connection-controls { flex: 0 0 auto; }
.listing-page .connection-lock,
.listing-page .connection-action { min-width: 128px; padding: 11px 15px; text-align: center; }
.listing-page .connection-lock { color: #ebcf8c; border: 1px solid rgba(209,179,122,.45); background: rgba(209,179,122,.07); box-shadow: none; }
.listing-page .connection-action { text-decoration: none; font-size: 13px; font-weight: 800; }
.listing-page .connection-action[aria-disabled="true"] { cursor: not-allowed; filter: saturate(.72); }
.listing-page .connection-action.armed { transform: translateY(-1px); filter: brightness(1.14); }
.connection-checking { border-color: rgba(209,179,122,.45); }
.connection-checking .connection-light { background: var(--gold); box-shadow: 0 0 16px var(--gold); }
.connection-connected { border-color: rgba(63,255,112,.62); box-shadow: 0 0 24px rgba(58,255,105,.13), 0 14px 36px rgba(0,0,0,.26) !important; }
.connection-connected .connection-light { background: #46ff79; box-shadow: 0 0 17px #46ff79; }
.listing-page .connection-connected .connection-action { color: #06170b; background: #46ff79; box-shadow: 0 0 20px rgba(70,255,121,.42); }
.connection-disconnected { border-color: rgba(255,57,57,.7); box-shadow: 0 0 24px rgba(255,45,45,.14), 0 14px 36px rgba(0,0,0,.26) !important; }
.connection-disconnected .connection-light { background: #ff3939; box-shadow: 0 0 17px #ff3939; }
.listing-page .connection-disconnected .connection-action { color: #fff; background: #e72828; box-shadow: 0 0 20px rgba(255,48,48,.42); }
@keyframes lock-nudge { 0%,100% { transform: translateX(0); } 30% { transform: translateX(-4px); } 70% { transform: translateX(4px); } }
.lock-nudge { animation: lock-nudge .28s ease-in-out 2; }

/* Full private costing worksheet beneath the Shopify source card. */
.costing-heading { min-height: 76px; }
.costing-lock { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid rgba(209,179,122,.38); border-radius: 50%; background: rgba(209,179,122,.08); }
.costing-body { padding: 24px; }
.costing-product { margin: 0 0 25px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.costing-section-title { margin: 0 0 12px; color: var(--muted); font-size: 13px; font-weight: 800; }
.costing-main-entries,
.costing-results,
.expense-list { overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.025); }
.costing-main-entries { margin-bottom: 25px; }
.costing-main-entries > label,
.costing-sale-price,
.costing-results > div,
.expense-row { min-height: 58px; padding: 12px 16px; border-bottom: 1px solid rgba(209,179,122,.15); }
.costing-main-entries > label,
.costing-sale-price { display: grid; grid-template-columns: minmax(0,1fr) minmax(118px,145px); gap: 14px; align-items: center; }
.costing-main-entries > :last-child,
.costing-results > :last-child,
.expense-list > :last-child { border-bottom: 0; }
.costing-main-entries label > span:first-child,
.costing-sale-price span,
.costing-results span,
.expense-row > span:nth-child(2) { color: var(--ink); font-size: 13px; font-weight: 700; }
.costing-sale-price strong { color: var(--gold); font-size: 18px; text-align: right; }
.money-input,
.percent-input { position: relative; display: block; min-width: 0; }
.money-input b,
.percent-input b { position: absolute; z-index: 1; top: 50%; transform: translateY(-50%); color: var(--gold); font-size: 12px; }
.money-input b { left: 11px; }
.percent-input b { right: 11px; }
.listing-page .money-input input { width: 100%; padding: 10px 10px 10px 26px; text-align: right; }
.listing-page .percent-input input { width: 100%; padding: 10px 27px 10px 10px; text-align: right; }
.quantity-control { display: grid; grid-template-columns: 38px minmax(45px,1fr) 38px; overflow: hidden; border: 1px solid rgba(209,179,122,.3); border-radius: 9px; background: #211f22; }
.listing-page .quantity-control button { min-width: 0; width: 38px; padding: 8px 0; border-radius: 0; color: var(--ink); background: rgba(255,255,255,.06); box-shadow: none; font-size: 18px; }
.listing-page .quantity-control input { width: 100%; min-width: 0; padding: 8px 2px; border: 0; border-right: 1px solid rgba(209,179,122,.22); border-left: 1px solid rgba(209,179,122,.22); border-radius: 0; text-align: center; }
.costing-results { margin-bottom: 25px; }
.costing-results > div { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.costing-results strong { flex: 0 0 auto; color: var(--ink); font-size: 14px; text-align: right; }
.costing-results .costing-lot-profit { background: rgba(209,179,122,.07); }
.costing-profit.positive strong,
.costing-profit-ex.positive strong,
.costing-lot-profit.positive strong { color: #62f68b; }
.costing-profit.negative strong,
.costing-profit-ex.negative strong,
.costing-lot-profit.negative strong { color: #ff6666; }
.costing-title-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 2px; }
.costing-title-row .costing-section-title { margin-bottom: 12px; }
.gst-toggle { display: flex; align-items: center; gap: 6px; margin: 0 2px 12px 0; color: var(--muted); font-size: 10px; font-weight: 750; }
.listing-page .gst-toggle input,
.listing-page .expense-row > input { width: 17px; height: 17px; padding: 0; accent-color: #35d969; }
.expense-list { margin-bottom: 14px; }
.expense-row { display: grid; grid-template-columns: 18px minmax(0,1fr) minmax(95px,120px); gap: 11px; align-items: center; }
.expense-row .money-input,
.expense-row .percent-input { width: 100%; }
.costing-note { margin: 14px 2px 0; color: var(--muted); font-size: 10px; line-height: 1.5; }

@media (max-width: 1250px) {
  .listing-page .workspace { grid-template-columns: 1fr; gap: 20px; }
  .listing-page .flow-arrow { display: none; }
}

/* Coin Vault master workspace */
.vault-main { max-width: 1540px; }
.vault-intro { display: flex; justify-content: space-between; align-items: end; gap: 40px; margin-bottom: 36px; }
.vault-intro .lede { margin: 0 0 5px; }
.vault-shell { display: grid; grid-template-columns: minmax(300px, .72fr) minmax(680px, 1.8fr); gap: 22px; align-items: start; }
.vault-list-panel { position: sticky; top: 18px; max-height: calc(100vh - 36px); }
.vault-search { padding: 17px 20px; border-bottom: 1px solid var(--line); }
.vault-search label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 10px; font-weight: 750; text-transform: uppercase; letter-spacing: .7px; }
.vault-search input { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 7px; font: inherit; }
.vault-filter-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 13px; }
.vault-filter-grid label { margin: 0; }
.vault-filter-grid select { width: 100%; min-height: 40px; margin-top: 7px; padding: 0 10px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); background: #fff; font: inherit; }
.vault-filter-count { margin: 11px 0 0; color: var(--muted); font-size: 10px; }
.vault-items { max-height: calc(100vh - 250px); overflow: auto; }
.vault-item { display: grid; grid-template-columns: 38px 1fr auto; gap: 11px; align-items: center; width: 100%; min-width: 0; padding: 14px 16px; border-bottom: 1px solid var(--line); border-radius: 0; color: var(--ink); background: transparent; text-align: left; }
.vault-item:hover, .vault-item.selected { background: var(--green-soft); }
.vault-item-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; color: #fff; background: var(--green); font: 700 11px Georgia, serif; }
.vault-item-copy { min-width: 0; }
.vault-item-copy strong, .vault-item-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vault-item-copy strong { font: 500 14px/1.25 Georgia, serif; }
.vault-item-copy small { margin-top: 4px; color: var(--muted); font-size: 9px; }
.vault-empty { padding: 28px 20px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.state-pill { display: inline-flex; align-items: center; width: max-content; padding: 5px 7px; border-radius: 99px; color: #5d615b; background: #eceae5; font-size: 8px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; }
.state-live, .state-available, .state-ready { color: #20553e; background: var(--green-soft); }
.state-ended, .state-archived, .state-unavailable { color: #6c6559; background: #ebe7de; }
.state-failed, .state-sold-out { color: #7a3434; background: #f5dfdc; }
.vault-detail { min-height: 620px; }
.vault-detail-heading { display: flex; justify-content: space-between; gap: 24px; padding: 28px 30px; border-bottom: 1px solid var(--line); }
.vault-detail-heading h2 { max-width: 760px; font-size: 31px; }
.vault-sku { margin: 9px 0 0; color: var(--muted); font: 11px ui-monospace, SFMono-Regular, monospace; }
.vault-state-stack { display: flex; gap: 7px; align-items: start; flex-wrap: wrap; justify-content: end; }
.vault-summary-grid { display: grid; grid-template-columns: repeat(4,1fr); border-bottom: 1px solid var(--line); background: #faf9f6; }
.vault-summary-grid div { padding: 17px 20px; border-right: 1px solid var(--line); }
.vault-summary-grid div:last-child { border-right: 0; }
.vault-summary-grid span, .vault-summary-grid strong { display: block; }
.vault-summary-grid span { margin-bottom: 6px; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .7px; }
.vault-summary-grid strong { font: 500 21px Georgia, serif; }
.vault-section { padding: 27px 30px; border-bottom: 1px solid var(--line); }
.vault-section-title { display: flex; justify-content: space-between; gap: 24px; align-items: start; margin-bottom: 19px; }
.vault-section-title h3 { margin: 0; font: 500 22px Georgia, serif; }
.vault-section-title p:not(.eyebrow) { margin: 6px 0 0; color: var(--muted); font-size: 11px; }
.save-message { color: var(--muted); font-size: 10px; }
.vault-fields { display: grid; gap: 14px; }
.two-fields { grid-template-columns: 1fr 1fr; }
.vault-fields label > span, .vault-image-fields label > span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .65px; }
.vault-fields input, .vault-image-fields input, .vault-image-fields select { width: 100%; padding: 10px 11px; border: 1px solid var(--line); border-radius: 7px; background: #fff; font: inherit; }
.vault-form-actions { display: flex; justify-content: end; margin-top: 14px; }
.vault-images { display: grid; gap: 12px; }
.vault-image-card { display: grid; grid-template-columns: 30px 128px 1fr; gap: 15px; align-items: center; padding: 13px; border: 1px solid var(--line); border-radius: 10px; background: #faf9f6; cursor: grab; }
.vault-image-card:active { cursor: grabbing; }
.vault-image-number { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 50%; color: #fff; background: var(--green); font-size: 10px; }
.vault-image-preview { width: 128px; aspect-ratio: 1; overflow: hidden; border-radius: 8px; background: #e9e6de; }
.vault-image-preview img { width: 100%; height: 100%; object-fit: cover; }
.vault-image-fields { display: grid; grid-template-columns: 180px 1fr; gap: 11px; }
.vault-image-actions { grid-column: 1 / -1; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.gallery-choice { display: flex; align-items: center; gap: 7px; margin-right: auto; color: var(--green); font-size: 11px; font-weight: 750; }
.gallery-choice input { width: auto; }
.quiet-button { min-width: 72px; padding: 8px 10px; border: 1px solid var(--line); color: var(--green); background: #fff; font-size: 10px; }
.vault-image-actions .small-button { min-width: 105px; padding: 9px 11px; font-size: 10px; }
.image-storage-state { padding: 5px 8px; border-radius: 999px; color: #4c514c; background: #e9e6de; font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .45px; }
.recognition-approve { background: #1f5c43; }
.recognition-approve:disabled { color: #68736d; background: #dfe7e2; }
.image-review-section { background: #fcfbf8; }
.image-candidates { display: grid; gap: 14px; }
.image-candidate-card { display: grid; grid-template-columns: minmax(300px, .95fr) minmax(260px, 1fr); gap: 18px; padding: 15px; border: 1px solid var(--line); border-radius: 11px; background: #fff; }
.candidate-comparison { display: grid; grid-template-columns: 1fr 28px 1fr; gap: 8px; align-items: center; }
.candidate-comparison figure { min-width: 0; margin: 0; }
.candidate-comparison figcaption { margin-bottom: 7px; color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .55px; }
.candidate-comparison img, .candidate-unavailable { display: grid; place-items: center; width: 100%; aspect-ratio: 1; border-radius: 8px; background: #ece9e2; object-fit: cover; }
.candidate-unavailable { padding: 12px; color: var(--muted); font-size: 10px; line-height: 1.4; text-align: center; }
.candidate-versus { color: var(--muted); font: italic 13px Georgia, serif; text-align: center; }
.candidate-detail { align-self: center; min-width: 0; }
.candidate-detail strong, .candidate-detail small { display: block; }
.candidate-detail strong { font: 500 17px Georgia, serif; }
.candidate-detail small { margin-top: 6px; overflow: hidden; color: var(--muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.candidate-decision-state { margin: 14px 0; color: var(--green); font-size: 11px; font-weight: 750; }
.candidate-actions { display: flex; gap: 7px; flex-wrap: wrap; }
.candidate-actions .small-button, .candidate-actions .quiet-button { min-width: 100px; padding: 9px 10px; font-size: 10px; }
.candidate-flag { background: #876b2f; }
.channel-list { display: grid; gap: 8px; }
.channel-row { display: grid; grid-template-columns: 80px 100px 1fr 1fr; gap: 12px; align-items: center; padding: 11px 12px; border: 1px solid var(--line); border-radius: 8px; font-size: 11px; }
.channel-row small { color: var(--muted); font-family: ui-monospace, SFMono-Regular, monospace; }
.vault-muted { color: var(--muted); font-size: 12px; }
.vault-identities { display: flex; gap: 13px; flex-wrap: wrap; padding: 18px 30px; color: var(--muted); font-size: 9px; }
.vault-identities code { color: #4c514c; }

/* Master Catalogue: the same left rail and dark metals system as Listing Worksheet. */
.catalogue-page .listing-sidebar {
  position: fixed;
  z-index: 20;
  inset: 0 auto 0 0;
  width: 236px;
  height: 100vh;
  padding: 28px 18px 22px;
  display: flex;
  align-items: stretch;
  justify-content: flex-start;
  flex-direction: column;
  gap: 28px;
  border-right: 1px solid var(--line);
  border-bottom: 0;
  background: linear-gradient(180deg, rgba(33,31,34,.98), rgba(9,9,12,.98));
  box-shadow: 18px 0 50px rgba(0,0,0,.2);
}
.catalogue-page .brand { color: var(--ink); font-weight: 700; }
.catalogue-page .brand b { color: var(--gold); }
.catalogue-page .topnav {
  width: 100%;
  padding: 5px;
  display: grid;
  gap: 5px;
  overflow: visible;
  border-color: rgba(209,179,122,.16);
  background: rgba(255,255,255,.025);
}
.catalogue-page .topnav a {
  padding: 12px 13px;
  color: var(--muted);
  border: 1px solid transparent;
  text-align: left;
  transition: color .18s ease, border-color .18s ease, background .18s ease;
}
.catalogue-page .topnav a:hover { color: var(--ink); border-color: rgba(209,179,122,.22); background: rgba(209,179,122,.06); }
.catalogue-page .topnav a.current {
  color: #0b0a0c;
  border-color: #f1d28c;
  background: linear-gradient(135deg, #f4da9b, var(--gold));
  box-shadow: 0 0 22px rgba(209,179,122,.2);
}
.catalogue-page .status {
  margin-top: auto;
  padding: 13px 11px;
  align-items: flex-start;
  border-top: 1px solid var(--line);
  line-height: 1.4;
}
.catalogue-page .status .dot { margin-top: 4px; background: var(--gold); box-shadow: 0 0 0 4px rgba(209,179,122,.12); }
.catalogue-page .vault-main { max-width: 1640px; margin: 0 auto 0 236px; padding: 50px 32px 80px; }
.catalogue-page h1 {
  background: linear-gradient(105deg, #fff 8%, #e6d3aa 48%, #c4935c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.catalogue-page h2,
.catalogue-page h3 { color: var(--ink); }
.catalogue-page .eyebrow { color: var(--gold); }
.catalogue-page .card {
  border-color: var(--line);
  background: linear-gradient(145deg, rgba(33,31,34,.98), rgba(17,16,19,.98));
  box-shadow: var(--shadow);
}
.catalogue-page .card-heading,
.catalogue-page .vault-search,
.catalogue-page .vault-item,
.catalogue-page .vault-detail-heading,
.catalogue-page .vault-summary-grid,
.catalogue-page .vault-summary-grid div,
.catalogue-page .vault-section { border-color: var(--line); }
.catalogue-page .vault-search input,
.catalogue-page .vault-filter-grid select,
.catalogue-page .vault-fields input,
.catalogue-page .vault-image-fields input,
.catalogue-page .vault-image-fields select {
  color: var(--ink);
  border-color: rgba(209,179,122,.3);
  background: #211f22;
  color-scheme: dark;
}
.catalogue-page .vault-search input:focus,
.catalogue-page .vault-filter-grid select:focus,
.catalogue-page .vault-fields input:focus,
.catalogue-page .vault-image-fields input:focus,
.catalogue-page .vault-image-fields select:focus {
  outline: 2px solid rgba(209,179,122,.18);
  border-color: var(--gold);
}
.catalogue-page .vault-list-panel { top: 20px; max-height: calc(100vh - 40px); }
.catalogue-page .vault-items { max-height: calc(100vh - 372px); }
.catalogue-page .vault-item:hover,
.catalogue-page .vault-item.selected { background: rgba(209,179,122,.11); }
.catalogue-page .vault-item.selected { box-shadow: inset 3px 0 var(--gold); }
.catalogue-page .vault-item-mark {
  color: #0b0a0c;
  background: linear-gradient(145deg, #f4da9b, var(--gold));
  box-shadow: 0 0 15px rgba(209,179,122,.15);
}
.catalogue-page .master { color: #f1d28c; background: rgba(209,179,122,.13); }
.catalogue-page .state-pill { color: #c2bec5; background: rgba(255,255,255,.08); }
.catalogue-page .state-live,
.catalogue-page .state-available,
.catalogue-page .state-ready { color: #80f1a0; background: rgba(58,198,91,.12); }
.catalogue-page .state-failed,
.catalogue-page .state-sold-out { color: #ff8b8b; background: rgba(221,62,62,.13); }
.catalogue-page .vault-summary-grid,
.catalogue-page .vault-image-card,
.catalogue-page .image-review-section { background: rgba(255,255,255,.025); }
.catalogue-page .image-candidate-card { border-color: var(--line); background: rgba(9,9,12,.45); }
.catalogue-page .vault-image-preview,
.catalogue-page .candidate-comparison img,
.catalogue-page .candidate-unavailable { background: #0d0d10; }
.catalogue-page .quiet-button {
  color: var(--gold);
  border-color: rgba(209,179,122,.35);
  background: rgba(209,179,122,.06);
}
.catalogue-page .small-button,
.catalogue-page .button-link {
  color: #0b0a0c;
  background: linear-gradient(135deg, #eed18a, var(--gold));
  box-shadow: 0 8px 22px rgba(0,0,0,.22);
}
.catalogue-page .recognition-approve { color: #06170b; background: #55dc7c; }
.catalogue-page .image-storage-state { color: #d2ced5; background: rgba(255,255,255,.08); }
.catalogue-page .vault-identities code { color: #d9bd83; }

/* Segregated business portal — Fenix storefront palette. */
.portal-body {
  --ink: #ffffff;
  --muted: #bec3d0;
  --paper: #121212;
  --card: #242833;
  --line: rgba(241,148,42,.32);
  --green: #f1942a;
  --green-soft: rgba(241,148,42,.14);
  --gold: #f1942a;
  --shadow: 0 20px 55px rgba(0,0,0,.34);
  min-height: 100vh;
  background:
    radial-gradient(circle at 9% 3%, rgba(51,79,180,.3), transparent 34rem),
    radial-gradient(circle at 92% 86%, rgba(241,148,42,.12), transparent 30rem),
    var(--paper);
}
.portal-body .portal-topbar {
  border-bottom-color: rgba(241,148,42,.3);
  background: rgba(36,40,51,.94);
  box-shadow: 0 9px 30px rgba(0,0,0,.22);
  backdrop-filter: blur(16px);
}
.portal-body .portal-sidebar {
  position: fixed;
  z-index: 20;
  inset: 0 auto 0 0;
  width: 236px;
  height: 100vh;
  padding: 27px 18px 22px;
  display: flex;
  align-items: stretch;
  justify-content: flex-start;
  flex-direction: column;
  gap: 27px;
  border-right: 1px solid rgba(241,148,42,.3);
  border-bottom: 0;
  box-shadow: 17px 0 42px rgba(0,0,0,.25);
}
.portal-brand { display: block; padding: 5px 8px 8px; }
.portal-brand img { display: block; width: 100%; height: auto; }
.portal-body .portal-nav {
  width: 100%;
  padding: 5px;
  display: grid;
  gap: 5px;
  overflow: visible;
  border-color: rgba(241,148,42,.16);
  background: rgba(255,255,255,.025);
}
.portal-body .portal-nav a {
  padding: 12px 13px;
  color: var(--muted);
  border: 1px solid transparent;
  text-align: left;
}
.portal-body .portal-nav a:hover {
  color: #fff;
  border-color: rgba(241,148,42,.32);
  background: rgba(241,148,42,.08);
}
.portal-body .portal-nav a.current {
  color: #121212;
  border-color: #ffbc65;
  background: linear-gradient(135deg,#ffb24a,#f1942a);
  box-shadow: 0 0 22px rgba(241,148,42,.18);
}
.portal-body .portal-sidebar .status {
  margin-top: auto;
  padding: 13px 11px;
  align-items: flex-start;
  border-top: 1px solid rgba(241,148,42,.24);
  line-height: 1.4;
}
.portal-body .brand-mark {
  color: #121212;
  background: linear-gradient(145deg,#ffb34f,#f1942a 62%,#c36900);
  box-shadow: 0 0 22px rgba(241,148,42,.28);
}
.portal-body .brand b,
.portal-body .eyebrow { color: #f1942a; }
.portal-body .status .dot {
  background: #f1942a;
  box-shadow: 0 0 0 4px rgba(241,148,42,.14), 0 0 17px rgba(241,148,42,.52);
}
.portal-main { width: min(1240px,calc(100% - 292px)); max-width: 1240px; margin-left: max(264px,calc((100vw - 1240px + 236px)/2)); padding-top: 50px; }
.portal-auth { display: grid; grid-template-columns: 1.15fr .85fr; min-height: 570px; }
.portal-auth-copy {
  position: relative;
  display: grid;
  place-items: center;
  padding: 68px 58px;
  background:
    linear-gradient(145deg,rgba(51,79,180,.94),rgba(36,40,51,.96)),
    #242833;
}
.fenix-portal-logo {
  display: block;
  width: min(100%,680px);
  height: auto;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,.2));
}
.portal-auth-copy .fenix-workspace-label {
  position: absolute;
  right: 24px;
  bottom: 20px;
  margin: 0;
  color: rgba(255,255,255,.72);
  text-align: right;
}
.portal-auth-copy h1 { font-size: clamp(45px,6vw,76px); }
.portal-form { display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 55px 48px; background: rgba(18,18,18,.58); }
.portal-form label > span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 10px; font-weight: 750; text-transform: uppercase; letter-spacing: .7px; }
.portal-form input { width: 100%; padding: 12px; border: 1px solid var(--line); border-radius: 7px; color: #fff; background: rgba(255,255,255,.06); font: inherit; }
.portal-form input:focus { border-color: #f1942a; outline: 3px solid rgba(241,148,42,.14); }
.portal-form button { width: 100%; color: #121212; background: linear-gradient(135deg,#ffb24a,#f1942a); box-shadow: 0 10px 25px rgba(241,148,42,.17); }
.portal-form-copy,.portal-message { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.portal-message { min-height: 18px; color: #ff9d95; }
.workspace-invite-form { display: grid; gap: 15px; padding: 24px; }
.workspace-invite-form label > span,.invite-result label > span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .65px; }
.workspace-invite-form input,.workspace-invite-form textarea { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 7px; font: inherit; }
.invite-result { display: grid; gap: 10px; padding-top: 6px; }
.invite-result textarea { resize: none; font-size: 11px; }
.portal-intro { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 28px; }
.portal-user { display: flex; align-items: center; gap: 14px; color: var(--muted); font-size: 12px; }
.portal-assurance { display: grid; grid-template-columns: auto 1fr; gap: 17px; align-items: center; padding: 17px 20px; border: 1px solid rgba(241,148,42,.35); border-radius: 10px; color: #ffd5a5; background: var(--green-soft); font-size: 12px; }
.portal-counts { display: grid; grid-template-columns: repeat(5,1fr); margin: 20px 0; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; background: var(--card); }
.portal-counts div { padding: 19px; border-right: 1px solid var(--line); }
.portal-counts div:last-child { border-right: 0; }
.portal-counts span,.portal-counts strong { display: block; }
.portal-counts span { color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .6px; }
.portal-counts strong { margin-top: 7px; font: 500 25px Georgia,serif; }
.portal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.portal-section .card-heading { min-height: 105px; }
.portal-list-row { display: grid; grid-template-columns: 1fr auto; gap: 7px 16px; padding: 17px 22px; border-bottom: 1px solid var(--line); }
.portal-list-row:last-child { border-bottom: 0; }
.portal-list-row strong,.portal-list-row span { display: block; }
.portal-list-row div > span { margin-top: 4px; color: var(--muted); font-size: 10px; }
.portal-list-row small { grid-column: 1 / -1; color: var(--muted); font-size: 10px; }
.portal-state { align-self: start; padding: 5px 8px; border-radius: 99px; color: #d5d8e1; background: rgba(255,255,255,.08); font-size: 8px; font-weight: 800; text-transform: uppercase; }
.portal-state.connected { color: #121212; background: #f1942a; }
.portal-boundaries { display: grid; grid-template-columns: .65fr 1.35fr; gap: 45px; margin-top: 20px; padding: 28px 30px; }
.portal-boundary-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.portal-boundary-grid div { padding: 11px 12px; border: 1px solid var(--line); border-radius: 7px; background: rgba(255,255,255,.035); }
.portal-boundary-grid span,.portal-boundary-grid strong { display: block; }
.portal-boundary-grid span { color: var(--muted); font-size: 9px; text-transform: uppercase; }
.portal-boundary-grid strong { margin-top: 4px; font-size: 11px; text-transform: capitalize; }
.community-entry { display: flex; gap: 16px; align-items: center; margin-top: 20px; padding: 18px 21px; color: inherit; text-decoration: none; }
.community-entry:hover { border-color: #f1942a; box-shadow: 0 8px 28px rgba(241,148,42,.12); }
.community-entry-mark { display: grid; place-items: center; width: 43px; height: 43px; flex: 0 0 auto; border-radius: 50%; color: #121212; background: var(--green); font-size: 20px; }
.community-entry small,.community-entry strong,.community-entry em { display: block; }
.community-entry small { color: var(--green); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .7px; }
.community-entry strong { margin-top: 3px; font: 500 19px Georgia,serif; }
.community-entry em { margin-top: 4px; color: var(--muted); font-size: 11px; font-style: normal; }

/* Shared, authenticated store community */
.community-body { min-height: 100vh; background: #eef1ed; }
.community-main { width: min(940px,calc(100% - 32px)); margin: 0 auto; padding: 42px 0 65px; }
.community-heading { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 23px; }
.community-heading h1 { font-size: clamp(38px,6vw,65px); }
.community-heading .lede { margin-top: 9px; font-size: 13px; }
.community-assurance { margin-bottom: 18px; }
.community-card { overflow: hidden; }
.community-messages { height: min(58vh,610px); min-height: 390px; padding: 24px; overflow-y: auto; overscroll-behavior: contain; background: linear-gradient(180deg,#f9faf7,#f0f2ed); }
.community-empty { display: grid; place-items: center; min-height: 100%; margin: 0; color: var(--muted); font-size: 13px; text-align: center; }
.community-message { width: min(78%,660px); margin: 0 0 14px; padding: 13px 15px; border: 1px solid var(--line); border-radius: 5px 14px 14px; background: white; box-shadow: 0 3px 12px rgba(36,55,45,.04); }
.community-message.own { margin-left: auto; border-color: #bfd5c6; border-radius: 14px 5px 14px 14px; background: var(--green-soft); }
.community-message-head { display: flex; justify-content: space-between; align-items: start; gap: 18px; margin-bottom: 8px; }
.community-message-identity strong,.community-message-identity small { display: block; }
.community-message-identity strong { font-size: 11px; }
.community-message-identity small { margin-top: 2px; color: var(--muted); font-size: 9px; }
.community-message time { color: var(--muted); font-size: 9px; white-space: nowrap; }
.community-message-body { margin: 0; font-size: 14px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; }
.community-composer { padding: 17px 20px 19px; border-top: 1px solid var(--line); background: white; }
.community-composer > label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .7px; }
.community-composer textarea { width: 100%; min-height: 76px; resize: vertical; padding: 12px 13px; border: 1px solid var(--line); border-radius: 8px; font: inherit; line-height: 1.45; }
.community-composer textarea:focus { border-color: #6a947e; outline: 3px solid rgba(74,127,99,.12); }
.community-compose-actions { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; margin-top: 10px; }
.community-compose-actions span { color: var(--muted); font-size: 10px; }
.community-compose-actions #message-status { text-align: right; }
.community-refresh-note { margin: 11px 2px 0; color: var(--muted); font-size: 10px; text-align: center; }
.community-login-needed { display: grid; place-items: center; min-height: 100%; text-align: center; }
.community-login-needed strong { font: 500 23px Georgia,serif; }
.community-login-needed p { margin: 8px 0 18px; color: var(--muted); font-size: 12px; }
.dot.offline { background: #b24a43; box-shadow: 0 0 0 4px rgba(178,74,67,.12); }

@media (max-width: 780px) {
  .portal-body .portal-sidebar {
    position: sticky;
    inset: 0;
    width: 100%;
    height: auto;
    padding: 11px 12px 10px;
    gap: 9px;
    border-right: 0;
    border-bottom: 1px solid rgba(241,148,42,.3);
  }
  .portal-brand { width: 142px; padding: 0 4px; }
  .portal-body .portal-nav {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .portal-body .portal-nav::-webkit-scrollbar { display: none; }
  .portal-body .portal-nav a { flex: 0 0 auto; padding: 9px 11px; text-align: center; }
  .portal-body .portal-sidebar .status { display: none; }
  .portal-main { padding: 26px 16px 60px; }
  .portal-main { width: 100%; margin-left: 0; }
  .portal-auth { grid-template-columns: 1fr; }
  .portal-auth-copy { padding: 38px 28px; }
  .fenix-portal-logo { width: min(92%,560px); }
  .portal-auth-copy .fenix-workspace-label { right: 17px; bottom: 14px; font-size: 8px; letter-spacing: 1px; }
  .portal-form { padding: 38px 28px; }
  .portal-intro,.portal-user { align-items: start; }
  .portal-intro { flex-direction: column; }
  .portal-counts { grid-template-columns: 1fr 1fr; }
  .portal-counts div { border-bottom: 1px solid var(--line); }
  .portal-grid,.portal-boundaries { grid-template-columns: 1fr; }
  .portal-boundary-grid { grid-template-columns: 1fr; }
  .community-main { width: min(100% - 20px,940px); padding: 25px 0 40px; }
  .community-heading { align-items: stretch; flex-direction: column; margin-bottom: 16px; }
  .community-heading button { display: none; }
  .community-assurance { grid-template-columns: 1fr; gap: 7px; padding: 13px 15px; }
  .community-messages { height: 260px; min-height: 260px; padding: 13px 10px; }
  .community-message { width: 91%; }
  .community-composer { padding: 13px 12px max(15px,env(safe-area-inset-bottom)); }
  .community-compose-actions { grid-template-columns: 1fr auto; }
  .community-compose-actions #message-status { grid-column: 1 / -1; grid-row: 2; text-align: left; }
}

/* Provider-independent master listing editor */
.master-main { max-width: 1580px; }
.master-intro { display: grid; grid-template-columns: 1.2fr .8fr; gap: 60px; align-items: end; margin-bottom: 36px; }
.master-intro-copy { max-width: 610px; justify-self: end; }
.master-intro-copy > p { margin: 0 0 16px; color: var(--muted); font-size: 15px; line-height: 1.55; }
.safe-banner { display: flex; gap: 9px; align-items: center; padding: 11px 13px; border: 1px solid #c9dece; border-radius: 8px; color: #20553e; background: var(--green-soft); font-size: 11px; }
.safe-banner strong { white-space: nowrap; }
.master-shell { display: grid; grid-template-columns: minmax(300px,.62fr) minmax(760px,1.8fr); gap: 22px; align-items: start; }
.master-drafts { position: sticky; top: 18px; }
.master-drafts .card-heading { gap: 14px; }
.master-drafts .small-button { min-width: 105px; padding: 9px 11px; font-size: 10px; }
.master-import-note { display: grid; gap: 5px; padding: 17px 20px; border-top: 1px solid var(--line); color: var(--muted); background: #faf9f6; font-size: 10px; line-height: 1.45; }
.master-import-note strong { color: var(--ink); }
.master-editor { overflow: hidden; }
.master-editor-head { display: flex; justify-content: space-between; gap: 24px; align-items: center; padding: 27px 30px; border-bottom: 1px solid var(--line); background: #faf9f6; }
.master-editor-head h2 { font-size: 30px; }
.master-editor-head > div > p:last-child { margin: 7px 0 0; color: var(--muted); font-size: 11px; }
.master-save-cluster { display: flex; align-items: center; gap: 13px; }
.master-save-cluster span { max-width: 250px; color: var(--muted); font-size: 10px; text-align: right; }
.master-save-cluster button { min-width: 160px; padding: 11px 15px; }
.master-form-section { padding: 29px 30px; border-bottom: 1px solid var(--line); }
.master-section-heading { display: flex; justify-content: space-between; gap: 35px; margin-bottom: 22px; }
.master-section-heading > div { display: grid; grid-template-columns: 30px 1fr; column-gap: 10px; }
.master-section-heading > div > span { grid-row: 1 / 3; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: #fff; background: var(--green); font-size: 9px; }
.master-section-heading .eyebrow { margin-bottom: 3px; }
.master-section-heading h3 { margin: 0; font: 500 23px Georgia,serif; }
.master-section-heading > p { max-width: 360px; margin: 0; color: var(--muted); font-size: 11px; line-height: 1.45; text-align: right; }
.master-fields { display: grid; gap: 14px; }
.master-core-grid { grid-template-columns: 1.25fr .75fr 1fr; }
.coin-facts-grid { grid-template-columns: repeat(5,1fr); }
.master-inventory-grid { grid-template-columns: 1fr 1fr; }
.master-fields .span-2 { grid-column: span 2; }
.master-fields .span-3 { grid-column: span 3; }
.master-fields label > span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .65px; }
.master-fields input, .master-fields textarea { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 7px; color: var(--ink); background: #fff; font: inherit; }
.master-fields textarea { resize: vertical; line-height: 1.5; }
.master-fields input:focus, .master-fields textarea:focus { outline: 2px solid rgba(36,91,69,.18); border-color: var(--green); }
.master-fields small { display: block; margin-top: 6px; color: var(--muted); font-size: 9px; line-height: 1.4; }
.channel-target-section { background: #faf9f6; }
.channel-targets { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.channel-target { padding: 17px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); }
.channel-target-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.channel-target-top label { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 750; }
.channel-target-top input { width: 17px; height: 17px; accent-color: var(--green); }
.capability-copy { display: grid; gap: 5px; min-height: 68px; margin: 17px 0; color: var(--muted); font-size: 10px; line-height: 1.45; }
.capability-copy strong { color: var(--ink); font-size: 12px; }
.channel-target button { width: 100%; min-width: 0; padding: 10px 12px; font-size: 10px; }
.master-readiness { display: flex; justify-content: space-between; gap: 30px; align-items: center; padding: 25px 30px; background: #f0eee8; }
.master-readiness h3 { margin: 0; font: 500 22px Georgia,serif; }
.master-readiness p:last-child { max-width: 590px; margin: 6px 0 0; color: var(--muted); font-size: 10px; line-height: 1.45; }
.master-identity-grid { display: grid; gap: 4px; min-width: 310px; color: var(--muted); font-size: 8px; }
.master-identity-grid span { display: flex; justify-content: space-between; gap: 10px; }
.master-identity-grid code { overflow: hidden; color: var(--ink); text-overflow: ellipsis; }
.master-identity-grid a { margin-top: 5px; color: var(--green); font-size: 10px; font-weight: 750; text-align: right; text-decoration: none; }

/* Shared product barcodes, inventory workflows and physical Show/POS */
.barcode-main { max-width: 1420px; padding-top: 48px; }
.barcode-intro { display: flex; justify-content: space-between; align-items: end; gap: 45px; margin-bottom: 34px; }
.barcode-intro h1 { font-size: clamp(41px, 4.4vw, 64px); }
.barcode-intro-copy { max-width: 610px; }
.barcode-intro-copy > p { margin: 0 0 17px; color: var(--muted); font-size: 15px; line-height: 1.55; }
.barcode-metrics { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 13px 16px; border: 1px solid #cbdacf; border-radius: 9px; color: var(--green); background: var(--green-soft); font-size: 11px; }
.barcode-metrics strong { font-size: 13px; }
.barcode-workspace { display: grid; grid-template-columns: minmax(310px, .72fr) minmax(560px, 1.28fr); gap: 24px; align-items: start; }
.barcode-controls { position: sticky; top: 16px; }
.barcode-heading { min-height: 82px; }
.barcode-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 16px; border-bottom: 1px solid var(--line); }
.barcode-modes button { display: grid; gap: 3px; padding: 13px; border: 1px solid var(--line); border-radius: 9px; color: var(--ink); background: #faf9f6; text-align: left; cursor: pointer; }
.barcode-modes button:nth-child(3) { grid-column: 1 / -1; }
.barcode-modes button strong { font-size: 12px; }
.barcode-modes button span { color: var(--muted); font-size: 9px; }
.barcode-modes button.active { border-color: var(--green); color: white; background: var(--green); box-shadow: 0 7px 20px rgba(36,91,69,.16); }
.barcode-modes button.active span { color: rgba(255,255,255,.76); }
.scan-form { padding: 20px; }
.scan-form > label span, .inventory-action label span, .alternate-barcodes > strong, .reference-search > span { display: block; margin-bottom: 7px; color: var(--muted); font-size: 10px; font-weight: 750; letter-spacing: .3px; text-transform: uppercase; }
.scan-input-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.scan-input-row input { min-width: 0; padding: 15px; border: 2px solid var(--green); border-radius: 9px; background: white; font: 700 15px ui-monospace,SFMono-Regular,Menlo,monospace; text-transform: uppercase; }
.scan-input-row button, .inventory-action button, .pos-complete { min-width: 90px; padding: 13px 17px; border: 0; border-radius: 8px; color: white; background: var(--green); font-weight: 750; cursor: pointer; }
.scan-form > p { margin: 10px 0 0; color: var(--muted); font-size: 10px; line-height: 1.4; }
.scan-form .scan-message { min-height: 30px; color: var(--green); font-weight: 700; }
.scan-form .scan-message.error { color: #a63d35; }
.camera-button { width: 100%; margin-top: 9px; padding: 10px; border: 1px solid var(--line); border-radius: 8px; color: var(--green); background: transparent; font-weight: 700; }
.camera-panel { padding: 0 20px 20px; }
.camera-panel video { display: block; width: 100%; max-height: 260px; margin-bottom: 8px; border-radius: 9px; background: #111; object-fit: cover; }
.barcode-stage { display: grid; gap: 24px; }
.barcode-product { min-height: 410px; }
.barcode-empty { display: grid; place-items: center; min-height: 410px; padding: 45px; color: var(--muted); text-align: center; }
.barcode-empty h2 { margin: 10px 0 0; color: var(--ink); }
.barcode-empty p { max-width: 430px; line-height: 1.55; }
.barcode-empty-mark { display: grid; place-items: center; width: 70px; height: 70px; border: 1px solid var(--line); border-radius: 50%; color: var(--green); background: var(--green-soft); font-size: 32px; }
.product-result-head { display: grid; grid-template-columns: 108px 1fr auto; gap: 19px; align-items: center; padding: 23px 25px; border-bottom: 1px solid var(--line); }
.product-result-head h2 { line-height: 1.15; }
.product-result-image { display: grid; place-items: center; width: 108px; height: 108px; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #eee; }
.product-result-image img { width: 100%; height: 100%; object-fit: cover; }
.product-image-fallback { color: var(--green); font: 700 44px Georgia,serif; }
.product-vault-link { align-self: start; text-decoration: none; }
.product-stock-grid { display: grid; grid-template-columns: repeat(4,1fr); border-bottom: 1px solid var(--line); }
.product-stock-grid div { display: grid; gap: 5px; padding: 15px 19px; border-right: 1px solid var(--line); }
.product-stock-grid div:nth-child(4) { border-right: 0; }
.product-stock-grid .wide { grid-column: 1 / -1; border-top: 1px solid var(--line); border-right: 0; }
.product-stock-grid span { color: var(--muted); font-size: 9px; text-transform: uppercase; }
.product-stock-grid strong { font-size: 17px; }
.product-barcode-block { display: grid; grid-template-columns: minmax(250px,.85fr) 1.15fr; gap: 22px; padding: 22px 25px; }
.primary-barcode { text-align: center; }
.primary-barcode img { display: block; width: 100%; max-height: 88px; object-fit: contain; }
.primary-barcode code { font-size: 9px; }
.alternate-barcodes p { min-height: 24px; margin: 0 0 10px; color: var(--muted); font-size: 10px; }
.alternate-barcodes code { display: inline-block; margin: 0 5px 5px 0; padding: 4px 6px; border-radius: 4px; color: var(--ink); background: #f0eee8; }
.alternate-barcodes form { display: grid; grid-template-columns: 1fr 90px auto; gap: 6px; }
.alternate-barcodes input, .alternate-barcodes select, .inventory-action input { min-width: 0; padding: 10px; border: 1px solid var(--line); border-radius: 7px; background: white; }
.inventory-action { display: grid; grid-template-columns: minmax(190px,1fr) auto; gap: 11px; align-items: end; padding: 22px 25px; border-top: 1px solid var(--line); background: #faf9f6; }
.inventory-action small { grid-column: 1 / -1; color: var(--muted); font-size: 10px; }
.pos-panel { overflow: visible; }
.pos-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 21px 25px; border-bottom: 1px solid var(--line); }
.pos-order-actions { display: flex; gap: 7px; }
.pos-order-empty { display: grid; gap: 4px; padding: 35px 25px; color: var(--muted); text-align: center; }
.pos-order-empty strong { color: var(--green); font: 500 24px Georgia,serif; }
.pos-order-meta, .pos-total { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 13px 20px; color: var(--muted); background: #f3f1eb; font-size: 10px; }
.pos-order-meta strong { color: var(--ink); }
.pos-lines { display: grid; }
.pos-line { display: grid; grid-template-columns: 48px 1fr 72px 90px; gap: 12px; align-items: center; padding: 12px 20px; border-top: 1px solid var(--line); }
.pos-line:first-child { border-top: 0; }
.pos-line-image { display: grid; place-items: center; width: 48px; height: 48px; overflow: hidden; border-radius: 7px; color: var(--green); background: var(--green-soft); font: 700 18px Georgia,serif; }
.pos-line-image img { width: 100%; height: 100%; object-fit: cover; }
.pos-line > div:nth-child(2) { display: grid; gap: 4px; }
.pos-line small { color: var(--muted); font-size: 9px; }
.pos-line label { display: grid; gap: 3px; color: var(--muted); font-size: 8px; text-transform: uppercase; }
.pos-line input { width: 66px; padding: 8px; border: 1px solid var(--line); border-radius: 6px; }
.pos-no-lines { padding: 25px; color: var(--muted); text-align: center; }
.pos-total { padding: 17px 20px; border-top: 1px solid var(--line); color: var(--ink); font-size: 14px; }
.pos-total strong { font-size: 24px; }
.pos-complete { width: calc(100% - 40px); margin: 0 20px 20px; }
.pos-complete:disabled { opacity: .45; cursor: not-allowed; }
.reference-section { margin-top: 34px; padding: 27px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); box-shadow: var(--shadow); }
.reference-heading { display: flex; align-items: end; justify-content: space-between; gap: 25px; }
.reference-heading p:last-child { margin: 7px 0 0; color: var(--muted); font-size: 11px; }
.reference-actions { display: flex; gap: 8px; }
.reference-search { display: block; margin: 23px 0 14px; }
.reference-search input { width: 100%; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: white; }
.reference-preview { max-height: 620px; overflow: auto; border: 1px solid var(--line); border-radius: 9px; }
.reference-preview > p { padding: 28px; color: var(--muted); text-align: center; }
.reference-group { position: sticky; top: 0; z-index: 1; padding: 11px 14px; border-top: 1px solid #b7c8bd; color: white; background: var(--green); font: 700 12px ui-sans-serif,system-ui,sans-serif; letter-spacing: .8px; }
.reference-group:first-child { border-top: 0; }
.reference-row { display: grid; grid-template-columns: 54px 70px minmax(220px,1fr) 115px 74px 230px 74px; gap: 9px; align-items: center; min-height: 70px; padding: 7px 12px; border-top: 1px solid var(--line); font-size: 10px; }
.reference-row small { display: block; margin-top: 3px; color: var(--muted); font-size: 8px; }
.ref-thumb img { width: 58px; height: 54px; border-radius: 5px; object-fit: cover; }
.ref-barcode img { display: block; width: 220px; height: 54px; object-fit: contain; }
.ref-price { font-weight: 750; text-align: right; }
.print-book { display: none; }
.sources-main { max-width: 1160px; margin: 0 auto; padding: 58px 30px 80px; }
.sources-intro { display: grid; grid-template-columns: 1.05fr .95fr; gap: 70px; align-items: end; margin-bottom: 32px; }
.sources-intro h1 { margin: 8px 0 0; }
.sources-intro > p { margin: 0 0 8px; color: var(--muted); line-height: 1.7; }
.source-panel { overflow: hidden; }
.source-panel-head { display: flex; justify-content: space-between; gap: 25px; align-items: start; padding: 27px; border-bottom: 1px solid var(--line); }
.source-panel-head h2 { margin: 5px 0; }
.source-panel-head p:last-child { margin: 0; color: var(--muted); font-size: 12px; }
.source-state { padding: 7px 11px; border-radius: 999px; color: #745c19; background: #fbf1cf; font-size: 10px; font-weight: 750; text-transform: uppercase; letter-spacing: .5px; }
.source-state.connected { color: #175b3f; background: #dff2e8; }
.source-policy { display: grid; grid-template-columns: repeat(3,1fr); border-bottom: 1px solid var(--line); }
.source-policy div { min-height: 90px; padding: 20px 23px; border-right: 1px solid var(--line); }
.source-policy div:last-child { border-right: 0; }
.source-policy strong, .source-policy span { display: block; }
.source-policy strong { margin-bottom: 7px; font-size: 11px; }
.source-policy span { color: var(--muted); font-size: 10px; line-height: 1.55; }
.source-metrics { display: grid; grid-template-columns: repeat(4,1fr); border-bottom: 1px solid var(--line); }
.source-metrics div { padding: 20px 23px; border-right: 1px solid var(--line); }
.source-metrics div:last-child { border-right: 0; }
.source-metrics span, .source-metrics strong { display: block; }
.source-metrics span { margin-bottom: 5px; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .6px; }
.source-metrics strong { font-size: 22px; }
.source-progress { padding: 17px 23px; background: #f8faf8; }
.source-progress div { display: flex; justify-content: space-between; gap: 20px; padding: 7px 0; font-size: 10px; }
.source-progress span { color: var(--muted); text-align: right; }
.source-actions { display: flex; gap: 9px; align-items: center; padding: 21px 23px 8px; }
.button-link { display: inline-flex; align-items: center; min-height: 39px; padding: 0 16px; border-radius: 8px; color: white; background: var(--green); font-size: 11px; font-weight: 750; text-decoration: none; }
.source-panel > .scan-message { min-height: 35px; margin: 0; padding: 7px 23px 20px; }

/* Hands-free recognition image review */
.review-body { background: #eef1ed; }
.review-main { max-width: 1500px; padding-top: 20px; padding-bottom: 32px; }
.review-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 14px; }
.review-heading .eyebrow { margin-bottom: 4px; }
.review-heading h1 { max-width: none; font-size: clamp(30px,3vw,42px); line-height: 1; letter-spacing: -1.5px; }
.review-heading h1 br { display: none; }
.review-controls { display: flex; gap: 10px; padding-bottom: 5px; }
.review-controls button { min-width: 165px; }
.voice-dot { background: #9b9e98; box-shadow: 0 0 0 4px #e3e4e1; }
.voice-dot.listening { background: #2e9b58; box-shadow: 0 0 0 5px rgba(46,155,88,.18); animation: voice-pulse 1.7s infinite; }
.voice-dot.paused { background: #d59a36; box-shadow: 0 0 0 5px rgba(213,154,54,.17); }
@keyframes voice-pulse { 50% { box-shadow: 0 0 0 10px rgba(46,155,88,.06); } }
.review-status-strip { display: grid; grid-template-columns: repeat(3,150px) 1fr; align-items: stretch; margin-bottom: 14px; overflow: hidden; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,253,248,.82); }
.review-status-strip div { padding: 13px 17px; border-right: 1px solid var(--line); }
.review-status-strip span, .review-status-strip strong { display: block; }
.review-status-strip span { color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .7px; }
.review-status-strip strong { margin-top: 2px; font: 500 23px Georgia,serif; }
.review-status-strip p { align-self: center; margin: 0; padding: 13px 19px; color: var(--muted); font-size: 13px; text-align: right; }
.review-status-strip p[data-tone="good"] { color: #216140; }
.review-status-strip p[data-tone="error"] { color: #9a332f; }
.review-status-strip p[data-tone="warn"] { color: #8b5d18; }
.review-status-strip p[data-tone="heard"] { color: #315389; }
.review-status-strip.review-status-four { grid-template-columns: repeat(4,132px) 1fr; }
.review-card { min-height: 440px; }
.review-product-heading { display: flex; justify-content: space-between; align-items: start; gap: 20px; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.review-product-heading .eyebrow { margin-bottom: 5px; }
.review-product-heading h2 { max-width: 1100px; font-size: clamp(20px,2vw,29px); line-height: 1.12; }
.review-product-heading p:not(.eyebrow) { margin: 7px 0 0; color: var(--muted); font: 12px ui-monospace,SFMono-Regular,monospace; }
.review-image-count { flex: 0 0 auto; padding: 8px 11px; border-radius: 99px; color: var(--green); background: var(--green-soft); font-size: 11px; font-weight: 750; }
.review-pair { display: grid; grid-template-columns: minmax(0,1fr) 46px minmax(0,1fr); gap: 12px; align-items: center; padding: 10px 14px 14px; }
.review-pair figure { min-width: 0; margin: 0; }
.review-pair figcaption { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 9px; }
.review-pair figcaption strong { font: 500 18px Georgia,serif; }
.review-pair figcaption span { color: var(--green); font-size: 11px; font-weight: 750; text-transform: uppercase; letter-spacing: .65px; }
.review-image { display: grid; place-items: center; height: clamp(240px,calc(100vh - 475px),590px); min-height: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 11px; background: #e8e7e2; }
.review-image img { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: scale-down; }
.review-single { display: grid; grid-template-columns: minmax(300px,560px) 230px; gap: 14px; align-items: stretch; justify-content: center; padding: 12px 14px 14px; }
.review-candidate { min-width: 0; margin: 0; }
.review-candidate figcaption { display: flex; justify-content: space-between; gap: 20px; align-items: center; margin-bottom: 8px; }
.review-candidate figcaption strong { font: 500 18px Georgia,serif; }
.review-candidate figcaption span { color: var(--green); font-size: 11px; font-weight: 750; text-transform: uppercase; letter-spacing: .65px; }
.review-image.review-image-large { width: 100%; height: clamp(280px,calc(100vh - 470px),520px); margin-inline: auto; }
.review-locked { display: flex; min-height: 300px; padding: 24px 20px; border: 1px solid var(--line); border-radius: 11px; background: #f4f2ed; flex-direction: column; justify-content: center; text-align: center; }
.review-locked.has-selection { justify-content: flex-start; background: var(--green-soft); }
.review-locked > strong { margin-top: 12px; font: 500 19px Georgia,serif; }
.review-locked > p:not(.eyebrow) { margin: 9px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.review-step-number { display: grid; place-items: center; width: 58px; height: 58px; margin: 0 auto 12px; border-radius: 50%; color: white; background: var(--green); font: 500 25px Georgia,serif; }
.review-locked-thumb { height: 190px; overflow: hidden; border: 1px solid rgba(23,63,49,.2); border-radius: 9px; background: #e8e7e2; }
.review-locked-thumb img { width: 100%; height: 100%; object-fit: contain; }
.review-pair-divider { display: grid; place-items: center; }
.review-pair-divider span { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; color: white; background: var(--green); font-size: 22px; }
.review-command-panel { margin-top: 10px; padding: 11px 16px max(13px,env(safe-area-inset-bottom)); border: 1px solid var(--line); border-radius: 13px; background: rgba(244,242,237,.97); box-shadow: 0 10px 30px rgba(35,48,40,.08); }
.review-command-panel > p:first-child { margin: 0 0 10px; color: var(--muted); font-size: 12px; }
.review-actions { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 10px; }
.review-actions.review-product-actions { grid-template-columns: repeat(3,minmax(0,1fr)); }
.review-actions button { min-width: 0; min-height: 54px; padding: 11px 15px; font-size: 17px; }
.review-yes { background: #197044; }
.review-one { background: #3f6684; }
.review-more { color: #173f31; background: #b9d9cd; }
.review-swap { color: #34250f; background: #e4b766; }
.review-no { background: #a8433d; }
.review-actions .review-skip { color: var(--ink); background: white; }
.review-undo { width: 100%; min-height: 36px; margin-top: 7px; padding: 8px 14px; }
.review-safety { max-width: 1050px; margin: 9px auto 0; color: var(--muted); font-size: 10px; line-height: 1.45; text-align: center; }
.review-finished { display: grid; place-items: center; min-height: 438px; padding: 30px; text-align: center; }
.review-finished > span { display: grid; place-items: center; width: 62px; height: 62px; margin-bottom: 14px; border-radius: 50%; color: white; background: var(--green); font-size: 28px; }
.review-finished p { max-width: 520px; margin: 10px 0 22px; color: var(--muted); }

/* Product photography queue */
.photos-needed-main { max-width: 1260px; padding-top: 42px; padding-bottom: 70px; }
.photos-needed-heading { display: flex; justify-content: space-between; align-items: end; gap: 30px; margin-bottom: 24px; }
.photos-needed-heading p:last-child { max-width: 650px; margin: 10px 0 0; color: var(--muted); line-height: 1.55; }
.photos-needed-total { flex: 0 0 auto; padding: 17px 22px; border-radius: 11px; color: var(--green); background: var(--green-soft); text-align: center; }
.photos-needed-total strong, .photos-needed-total span { display: block; }
.photos-needed-total strong { font: 500 30px Georgia,serif; }
.photos-needed-total span { margin-top: 3px; font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .7px; }
.photos-needed-list { overflow: hidden; }
.photos-needed-row { display: grid; grid-template-columns: 96px minmax(0,1fr) auto; gap: 18px; align-items: center; padding: 14px 18px; border-top: 1px solid var(--line); }
.photos-needed-row:first-child { border-top: 0; }
.photos-needed-thumb { width: 96px; height: 96px; overflow: hidden; border-radius: 9px; background: #e8e7e2; }
.photos-needed-thumb img { width: 100%; height: 100%; object-fit: contain; }
.photos-needed-row h2 { font-size: 19px; line-height: 1.2; }
.photos-needed-row p { margin: 7px 0 0; color: var(--muted); font: 11px ui-monospace,SFMono-Regular,monospace; }
.photos-needed-badge { padding: 7px 10px; border-radius: 99px; color: #8b3e39; background: #f5dfdc; font-size: 10px; font-weight: 750; text-transform: uppercase; letter-spacing: .55px; }

@media (max-width: 860px) {
  .topbar { height: auto; min-height: 72px; padding: 12px 18px; flex-wrap: wrap; gap: 10px; }
  .topnav { order: 3; width: 100%; }
  .topnav a { flex: 0 0 auto; text-align: center; }
  .intro { display: block; }
  .stepper { margin: 35px 0 20px; }
  .workspace { grid-template-columns: 1fr; gap: 18px; }
  .flow-arrow { display: none; }
  .listing-top { grid-template-columns: 130px 1fr; }
  .three-fields { grid-template-columns: 1fr; }
  .profile-fields { grid-template-columns: 1fr; }
  .profile-actions { align-items: stretch; flex-direction: column; }
  .image-row { grid-template-columns: 56px 1fr; }
  .image-preview { width: 56px; }
  .mapping-row { grid-template-columns: 1fr 22px 1fr; }
  .mapping-row > :last-child { display: none; }
  .actions { align-items: stretch; gap: 16px; flex-direction: column; }
  .publish-actions { width: 100%; }
  .publish-actions button { width: 100%; }
  .vault-main { padding: 38px 16px 60px; }
  .vault-intro { display: block; }
  .vault-intro .lede { margin-top: 20px; }
  .vault-shell { grid-template-columns: 1fr; }
  .vault-list-panel { position: static; max-height: none; }
  .vault-items { max-height: 360px; }
  .vault-detail-heading { display: block; padding: 23px 20px; }
  .vault-state-stack { justify-content: start; margin-top: 15px; }
  .vault-summary-grid { grid-template-columns: 1fr 1fr; }
  .vault-summary-grid div:nth-child(2) { border-right: 0; }
  .vault-summary-grid div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .vault-section { padding: 23px 20px; }
  .vault-section-title { display: block; }
  .save-message { display: block; margin-top: 8px; }
  .two-fields { grid-template-columns: 1fr; }
  .vault-image-card { grid-template-columns: 28px 82px 1fr; align-items: start; }
  .vault-image-preview { width: 82px; }
  .vault-image-fields { grid-column: 1 / -1; grid-template-columns: 1fr; }
  .vault-image-actions { grid-column: 1; }
  .gallery-choice { width: 100%; margin-bottom: 4px; }
  .image-candidate-card { grid-template-columns: 1fr; }
  .candidate-actions button { flex: 1 1 120px; }
  .channel-row { grid-template-columns: 72px 90px 1fr; }
  .channel-row small { grid-column: 1 / -1; }
  .master-main { padding: 38px 14px 60px; }
  .master-intro { display: block; }
  .master-intro-copy { margin-top: 22px; }
  .safe-banner { align-items: start; flex-direction: column; }
  .master-shell { grid-template-columns: 1fr; }
  .master-drafts { position: static; }
  .master-editor-head { display: block; padding: 23px 19px; }
  .master-save-cluster { align-items: stretch; flex-direction: column; margin-top: 17px; }
  .master-save-cluster span { max-width: none; text-align: left; }
  .master-save-cluster button { width: 100%; }
  .master-form-section { padding: 24px 19px; }
  .master-section-heading { display: block; }
  .master-section-heading > p { max-width: none; margin: 11px 0 0 40px; text-align: left; }
  .master-core-grid, .coin-facts-grid, .master-inventory-grid { grid-template-columns: 1fr; }
  .master-fields .span-2, .master-fields .span-3 { grid-column: 1; }
  .channel-targets { grid-template-columns: 1fr; }
  .master-readiness { display: block; padding: 23px 19px; }
  .master-identity-grid { min-width: 0; margin-top: 17px; }
  .barcode-main { padding: 36px 14px 60px; }
  .barcode-intro { display: block; }
  .barcode-intro-copy { margin-top: 21px; }
  .barcode-metrics { align-items: start; flex-direction: column; }
  .barcode-workspace { grid-template-columns: 1fr; }
  .barcode-controls { position: static; }
  .product-result-head { grid-template-columns: 76px 1fr; padding: 19px; }
  .product-result-image { width: 76px; height: 76px; }
  .product-vault-link { grid-column: 1 / -1; text-align: center; }
  .product-stock-grid { grid-template-columns: 1fr 1fr; }
  .product-stock-grid div:nth-child(2) { border-right: 0; }
  .product-stock-grid div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .product-stock-grid div:nth-child(4) { border-right: 0; }
  .product-barcode-block { grid-template-columns: 1fr; padding: 19px; }
  .alternate-barcodes form { grid-template-columns: 1fr 86px; }
  .alternate-barcodes form button { grid-column: 1 / -1; }
  .inventory-action { grid-template-columns: 1fr; padding: 19px; }
  .inventory-action small { grid-column: 1; }
  .pos-line { grid-template-columns: 42px 1fr 64px; padding: 11px 13px; }
  .pos-line > strong:last-child { grid-column: 2 / -1; text-align: right; }
  .reference-heading { align-items: stretch; flex-direction: column; }
  .reference-actions button { flex: 1; }
  .reference-preview { max-height: 520px; }
  .reference-row { grid-template-columns: 42px 48px minmax(145px,1fr) 58px; }
  .ref-grade, .ref-barcode, .ref-denomination { display: none; }
  .ref-thumb img { width: 48px; height: 46px; }
  .sources-main { padding: 38px 14px 60px; }
  .sources-intro { display: block; }
  .sources-intro > p { margin-top: 20px; }
  .source-panel-head { display: block; padding: 22px 19px; }
  .source-state { display: inline-block; margin-top: 13px; }
  .source-policy { grid-template-columns: 1fr; }
  .source-policy div { min-height: 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .source-policy div:last-child { border-bottom: 0; }
  .source-metrics { grid-template-columns: 1fr 1fr; }
  .source-metrics div:nth-child(2) { border-right: 0; }
  .source-metrics div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .source-actions { align-items: stretch; flex-direction: column; }
  .source-actions button, .button-link { justify-content: center; width: 100%; }
  .review-main { padding: 25px 10px 35px; }
  .review-topbar .status { margin-left: auto; }
  .review-heading { display: block; margin-bottom: 18px; }
  .review-heading h1 { font-size: 39px; }
  .review-controls { display: grid; grid-template-columns: 1fr 1fr; margin-top: 18px; }
  .review-controls button { min-width: 0; }
  .review-status-strip { grid-template-columns: repeat(3,1fr); }
  .review-status-strip.review-status-four { grid-template-columns: 1fr 1fr; }
  .review-status-strip div { padding: 10px; text-align: center; }
  .review-status-strip div:nth-child(3) { border-right: 0; }
  .review-status-strip.review-status-four div:nth-child(2n) { border-right: 0; }
  .review-status-strip.review-status-four div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .review-status-strip p { grid-column: 1 / -1; padding: 10px 12px; border-top: 1px solid var(--line); text-align: center; }
  .review-product-heading { display: block; padding: 16px; }
  .review-image-count { display: inline-block; margin-top: 11px; }
  .review-pair { grid-template-columns: 1fr 1fr; gap: 8px; padding: 10px; }
  .review-pair-divider { display: none; }
  .review-pair figcaption { display: block; min-height: 43px; margin-bottom: 6px; }
  .review-pair figcaption strong, .review-pair figcaption span { display: block; }
  .review-pair figcaption strong { font-size: 15px; }
  .review-pair figcaption span { margin-top: 3px; font-size: 8px; }
  .review-image { height: min(45vh,420px); min-height: 210px; }
  .review-single { grid-template-columns: 1fr; padding: 10px; }
  .review-image.review-image-large { width: min(100%,520px); height: min(48vh,460px); min-height: 250px; }
  .review-locked { min-height: 0; padding: 14px; }
  .review-locked.has-selection { display: grid; grid-template-columns: 90px 1fr; gap: 5px 14px; align-items: center; text-align: left; }
  .review-locked.has-selection .eyebrow { grid-column: 1 / -1; }
  .review-locked-thumb { grid-row: 2 / span 2; width: 90px; height: 90px; }
  .review-locked > strong { margin-top: 0; }
  .review-locked > p:not(.eyebrow) { margin-top: 2px; }
  .review-command-panel { margin: 8px -10px 0; border-right: 0; border-left: 0; }
  .review-command-panel > p:first-child { text-align: center; }
  .review-actions { grid-template-columns: 1fr 1fr; }
  .review-actions.review-product-actions { grid-template-columns: 1fr 1fr; }
  .review-actions button { min-height: 60px; }
  .voice-session .review-heading { display: none; }
  .voice-session .review-main { padding-top: 10px; }
  .voice-session .review-status-strip { margin-bottom: 8px; }
  .photos-needed-main { padding: 28px 12px 50px; }
  .photos-needed-heading { display: block; }
  .photos-needed-total { display: inline-block; margin-top: 16px; }
  .photos-needed-row { grid-template-columns: 72px minmax(0,1fr); gap: 12px; padding: 12px; }
  .photos-needed-thumb { width: 72px; height: 72px; }
  .photos-needed-badge { grid-column: 1 / -1; text-align: center; }
}

@media (max-width: 860px) {
  :is(.listing-page, .catalogue-page) .listing-sidebar {
    position: relative;
    inset: auto;
    width: auto;
    height: auto;
    padding: 15px 16px 12px;
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 11px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 10px 30px rgba(0,0,0,.2);
  }
  :is(.listing-page, .catalogue-page) .topnav {
    order: 3;
    width: 100%;
    display: flex;
    overflow-x: auto;
  }
  :is(.listing-page, .catalogue-page) .topnav a { padding: 9px 11px; text-align: center; }
  :is(.listing-page, .catalogue-page) .status { margin: 0 0 0 auto; padding: 7px 0 7px 10px; border-top: 0; }
  :is(.listing-page, .catalogue-page) main { margin-left: 0; padding: 36px 14px 60px; }
  .catalogue-page .vault-main { margin-left: 0; padding: 36px 14px 60px; }
  .listing-page .connection-warning { align-items: stretch; flex-direction: column; }
  .connection-controls { width: 100%; }
  .listing-page .connection-lock,
  .listing-page .connection-action { flex: 1; min-width: 0; }
}

@media (max-width: 460px) {
  :is(.listing-page, .catalogue-page) .status { width: 100%; margin-left: 0; }
  .vault-filter-grid { grid-template-columns: 1fr; }
  .connection-controls { align-items: stretch; flex-direction: column; }
  .costing-fields { grid-template-columns: 1fr; }
  .costing-fields .span-two { grid-column: 1; }
}

/* Shared NewAge chrome for every private operational room. Store Portal stays
   deliberately neutral so each business can receive its own branding. */
.newage-page {
  color: var(--ink);
}
body.newage-page.review-body,
body.newage-page.community-body {
  background:
    radial-gradient(circle at 17% 4%, rgba(163,87,46,.23), transparent 30rem),
    radial-gradient(circle at 90% 75%, rgba(209,179,122,.07), transparent 35rem),
    var(--paper);
}
.newage-page .listing-sidebar {
  position: fixed;
  z-index: 20;
  inset: 0 auto 0 0;
  width: 236px;
  height: 100vh;
  padding: 28px 18px 22px;
  display: flex;
  align-items: stretch;
  justify-content: flex-start;
  flex-direction: column;
  gap: 28px;
  border-right: 1px solid var(--line);
  border-bottom: 0;
  background: linear-gradient(180deg, rgba(33,31,34,.98), rgba(9,9,12,.98));
  box-shadow: 18px 0 50px rgba(0,0,0,.2);
  backdrop-filter: none;
}
.newage-page .brand {
  min-width: 0;
  color: var(--ink);
  font-weight: 700;
}
.newage-page .brand span { min-width: 0; white-space: nowrap; }
.newage-page .brand b { color: var(--gold); }
.newage-page .topnav {
  width: 100%;
  padding: 5px;
  display: grid;
  gap: 5px;
  overflow-y: auto;
  overflow-x: hidden;
  border-color: rgba(209,179,122,.16);
  background: rgba(255,255,255,.025);
}
.newage-page .topnav a {
  padding: 12px 13px;
  color: var(--muted);
  border: 1px solid transparent;
  text-align: left;
  transition: color .18s ease, border-color .18s ease, background .18s ease;
}
.newage-page .topnav a:hover {
  color: var(--ink);
  border-color: rgba(209,179,122,.22);
  background: rgba(209,179,122,.06);
}
.newage-page .topnav a.current {
  color: #0b0a0c;
  border-color: #f1d28c;
  background: linear-gradient(135deg, #f4da9b, var(--gold));
  box-shadow: 0 0 22px rgba(209,179,122,.2);
}
.newage-page .status {
  margin-top: auto;
  padding: 13px 11px;
  align-items: flex-start;
  border-top: 1px solid var(--line);
  line-height: 1.4;
}
.newage-page .status .dot {
  margin-top: 4px;
  background: var(--gold);
  box-shadow: 0 0 0 4px rgba(209,179,122,.12);
}
.newage-page > main {
  margin-left: 236px;
  margin-right: auto;
}
body.newage-page:not(.live-body) h1 {
  background: linear-gradient(105deg, #fff 8%, #e6d3aa 48%, #c4935c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
body.newage-page:not(.live-body) h2,
body.newage-page:not(.live-body) h3,
body.newage-page:not(.live-body) strong { color: var(--ink); }
body.newage-page:not(.live-body) .eyebrow { color: var(--gold); }
body.newage-page:not(.live-body) .card {
  border-color: var(--line);
  background: linear-gradient(145deg, rgba(33,31,34,.98), rgba(17,16,19,.98));
  box-shadow: var(--shadow);
}
body.newage-page:not(.live-body) :is(input:not([type="checkbox"]):not([type="radio"]), textarea, select) {
  color: var(--ink);
  border-color: rgba(209,179,122,.32);
  background: #201f22;
  color-scheme: dark;
}
body.newage-page:not(.live-body) :is(input, textarea, select):focus {
  outline: 2px solid rgba(209,179,122,.2);
  border-color: var(--gold);
}
body.newage-page:not(.live-body) :is(.worksheet-banner, .profile-settings, .validation-section, .actions,
  .master-editor-head, .master-form-section, .master-readiness, .source-panel-head,
  .source-policy, .source-actions, .review-status-strip, .review-command-panel,
  .community-composer, .portal-assurance) {
  border-color: var(--line);
  background: rgba(255,255,255,.025);
}
body.newage-page:not(.live-body) :is(.master-item, .vault-item, .photos-needed-row, .community-message,
  .alternate-row, .pos-line, .reference-row) { border-color: var(--line); }
body.newage-page:not(.live-body) :is(.master-item:hover, .master-item.selected, .photos-needed-row:hover) {
  background: rgba(209,179,122,.09);
}
body.newage-page:not(.live-body) .photos-needed-thumb,
body.newage-page:not(.live-body) .review-image,
body.newage-page:not(.live-body) .review-locked,
body.newage-page:not(.live-body) .product-result-image { background: #0d0d10; }
body.newage-page:not(.live-body) .photos-needed-badge {
  color: #ffb1aa;
  background: rgba(184,61,52,.18);
}
body.newage-page:not(.live-body) .safe-banner,
body.newage-page:not(.live-body) .source-policy div,
body.newage-page:not(.live-body) .source-metrics div,
body.newage-page:not(.live-body) .barcode-metrics,
body.newage-page:not(.live-body) .photos-needed-total {
  border-color: var(--line);
  background: rgba(209,179,122,.09);
}
body.newage-page:not(.live-body) .quiet-button {
  color: var(--ink) !important;
  border: 1px solid rgba(209,179,122,.34) !important;
  background: rgba(255,255,255,.04) !important;
}
body.newage-page:not(.live-body) :is(.master-import-note, .channel-target-section,
  .source-progress, .inventory-action, .pos-order-meta, .pos-total) {
  border-color: var(--line);
  background: rgba(255,255,255,.025);
}
body.newage-page:not(.live-body) .community-messages {
  background: linear-gradient(180deg, #111114, #0d0d10);
}
body.newage-page:not(.live-body) .community-message {
  color: var(--ink);
  border-color: var(--line);
  background: #201f22;
  box-shadow: 0 4px 16px rgba(0,0,0,.2);
}
body.newage-page:not(.live-body) .community-message.own {
  border-color: rgba(209,179,122,.38);
  background: rgba(209,179,122,.12);
}
body.newage-page:not(.live-body) .barcode-modes button {
  color: var(--ink);
  border-color: var(--line);
  background: rgba(255,255,255,.035);
}
body.newage-page:not(.live-body) .barcode-modes button.active {
  color: #0b0a0c;
  border-color: #f1d28c;
  background: linear-gradient(135deg, #f4da9b, var(--gold));
}
.newage-page.live-body > main {
  width: auto;
  max-width: 1540px;
  padding-right: 32px;
  padding-left: 32px;
}
@media (max-width: 860px) {
  .newage-page .listing-sidebar {
    position: relative;
    inset: auto;
    width: auto;
    height: auto;
    padding: 15px 16px 12px;
    flex-direction: row;
    align-items: center;
    flex-wrap: wrap;
    gap: 11px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 10px 30px rgba(0,0,0,.2);
  }
  .newage-page .topnav {
    order: 3;
    width: 100%;
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
  }
  .newage-page .topnav a { padding: 9px 11px; text-align: center; }
  .newage-page .status {
    margin: 0 0 0 auto;
    padding: 7px 0 7px 10px;
    border-top: 0;
  }
  .newage-page > main,
  .newage-page.live-body > main {
    width: auto;
    margin-left: 0;
    padding-right: 14px;
    padding-left: 14px;
  }
}

@media (max-width: 460px) {
  .newage-page .status { width: 100%; margin-left: 0; }
}

/* One app-level doorway followed by one flat, permission-aware workspace. */
.login-body {
  --ink: #f5f2ed;
  --muted: #aaa7ae;
  --paper: #09090c;
  --card: #171619;
  --line: rgba(209,179,122,.27);
  --green: #d1b37a;
  --gold: #d1b37a;
  min-height: 100vh;
  background:
    radial-gradient(circle at 16% 8%, rgba(163,87,46,.26), transparent 31rem),
    radial-gradient(circle at 88% 82%, rgba(209,179,122,.09), transparent 34rem),
    #09090c;
}
.login-shell {
  width: min(1060px,calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  padding: clamp(28px,7vh,80px) 0 30px;
  display: grid;
  align-content: center;
}
.login-card {
  display: grid;
  grid-template-columns: 1.12fr .88fr;
  min-height: 590px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(145deg,rgba(33,31,34,.98),rgba(17,16,19,.98));
  box-shadow: 0 30px 90px rgba(0,0,0,.48);
}
.login-brand-panel {
  padding: clamp(44px,7vw,82px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-right: 1px solid var(--line);
  background:
    linear-gradient(145deg,rgba(209,179,122,.08),transparent 55%),
    rgba(255,255,255,.018);
}
.login-logo {
  width: 92px;
  height: 92px;
  margin-bottom: 34px;
  border: 1px solid rgba(209,179,122,.52);
  border-radius: 22px;
  object-fit: cover;
  box-shadow: 0 0 42px rgba(209,179,122,.18);
}
.login-brand-panel h1 {
  margin: 0;
  font: 500 clamp(46px,6vw,72px)/.98 Georgia,serif;
  letter-spacing: -2.5px;
  background: linear-gradient(105deg,#fff 8%,#e6d3aa 48%,#c4935c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.login-brand-panel > p:last-child { max-width: 540px; margin: 27px 0 0; color: var(--muted); line-height: 1.65; }
.login-body .portal-form { background: rgba(7,7,9,.38); }
.login-body .portal-form input { color: var(--ink); border-color: var(--line); background: #201f22; color-scheme: dark; }
.login-body .portal-form input:focus { border-color: var(--gold); outline: 3px solid rgba(209,179,122,.13); }
.login-body .portal-form button { color: #0b0a0c; background: linear-gradient(135deg,#f4da9b,var(--gold)); }
.login-body .eyebrow { color: var(--gold); }
.login-footnote { margin: 18px 0 0; color: #77747c; font-size: 11px; text-align: center; }

.newage-page .topnav { flex: 1 1 auto; min-height: 0; }
.workspace-account {
  margin-top: auto;
  padding: 13px 11px;
  display: grid;
  gap: 3px;
  border-top: 1px solid var(--line);
}
.workspace-account span { overflow: hidden; color: var(--ink); font-size: 11px; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.workspace-account small { overflow: hidden; color: var(--muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.workspace-account button {
  margin-top: 8px;
  padding: 7px 9px;
  color: var(--muted);
  border: 1px solid rgba(209,179,122,.24);
  border-radius: 7px;
  background: rgba(255,255,255,.025);
  font: inherit;
  font-size: 10px;
  font-weight: 700;
  cursor: pointer;
}
.newage-page .workspace-account + .status { margin-top: 0; }
.workspace-home-main { width: auto; max-width: 1420px; margin-left: 236px; }
.workspace-home-main .portal-assurance { margin-bottom: 20px; }

.newage-page.fenix-workspace {
  --gold: #f1942a;
  --green: #f1942a;
  --green-soft: rgba(241,148,42,.14);
  --line: rgba(241,148,42,.28);
  background:
    radial-gradient(circle at 9% 3%,rgba(51,79,180,.25),transparent 34rem),
    radial-gradient(circle at 92% 86%,rgba(241,148,42,.1),transparent 30rem),
    #121212;
}
.newage-page.fenix-workspace .listing-sidebar { background: linear-gradient(180deg,#242833,#121212); }
.newage-page.fenix-workspace .topnav a.current { border-color: #ffbc65; background: linear-gradient(135deg,#ffb24a,#f1942a); }
.workspace-fenix-brand { display: block !important; padding: 3px 7px 8px; }
.workspace-fenix-brand img { display: block; width: 100%; height: auto; }

@media (max-width: 860px) {
  .workspace-account { margin: 0 0 0 auto; border-top: 0; padding: 2px 4px; }
  .workspace-account span,.workspace-account small { display: none; }
  .workspace-account button { margin: 0; }
  .newage-page .workspace-account + .status { margin-left: 0; }
  .workspace-home-main { width: auto; margin-left: 0; }
  .workspace-fenix-brand { width: 142px; padding: 0 4px; }
}

@media (max-width: 720px) {
  .login-card { grid-template-columns: 1fr; }
  .login-brand-panel { padding: 38px 28px; border-right: 0; border-bottom: 1px solid var(--line); }
  .login-logo { width: 68px; height: 68px; margin-bottom: 24px; border-radius: 17px; }
  .login-brand-panel h1 { font-size: 44px; }
  .login-brand-panel > p:last-child { margin-top: 18px; font-size: 13px; }
  .login-body .portal-form { padding: 38px 28px; }
}

/* Entry surfaces only. Authority, [hidden] and module content stay unchanged. */
.core-entry-page .login-shell { width: min(1080px, calc(100% - 48px)); padding-block: 40px; }
.core-entry-page .login-card { min-height: 560px; border-radius: 24px; }
.core-entry-page .login-brand-panel { padding: clamp(32px, 4.5vw, 64px); }
.core-entry-page .login-logo { width: 76px; height: 76px; margin-bottom: 32px; border-radius: 18px; box-shadow: 0 8px 30px rgba(0,0,0,.3); }
.core-entry-page .login-brand-panel h1 { font-size: clamp(38px, 4.4vw, 60px); line-height: 1.08; letter-spacing: -1.8px; }
.core-entry-page .login-brand-panel > p:last-child { max-width: 38ch; font-size: 14px; line-height: 1.75; }
.core-entry-page .login-form { min-width: 0; padding: clamp(28px, 4vw, 52px); gap: 22px; }
.core-entry-page .login-form h2 { font-size: 30px; line-height: 1.2; }
.core-entry-page .login-form input { min-height: 48px; padding: 12px 14px; border-radius: 10px; font-size: 16px; }
.core-entry-page .login-form button { min-height: 48px; border-radius: 10px; box-shadow: 0 6px 20px rgba(209,179,122,.1); }
.core-entry-page .login-form > a { align-self: flex-start; padding-block: 8px; color: var(--muted); font-size: 13px; text-underline-offset: 4px; }
.core-entry-page .login-form > a:hover { color: var(--ink); }
.core-entry-page .login-footnote { max-width: 68ch; margin: 22px auto 0; color: var(--muted); line-height: 1.6; }
.core-entry-page :is(a,button):focus-visible,
.core-account-page :is(a,button):focus-visible { outline: 2px solid var(--gold); outline-offset: 5px; }

.core-home-page .workspace-home-main { padding: 48px clamp(20px, 3vw, 48px) 64px; }
.core-home-page .portal-intro { align-items: center; gap: 24px; margin-bottom: 28px; }
.core-home-page .portal-intro > div { min-width: 0; }
.core-home-page .portal-intro h1 { font-size: clamp(34px, 3.8vw, 54px); line-height: 1.1; letter-spacing: -1.5px; overflow-wrap: anywhere; }
.core-home-page .portal-user { max-width: 28ch; line-height: 1.6; overflow-wrap: anywhere; }
.core-home-page .portal-assurance { grid-template-columns: 1fr; gap: 6px; padding: 18px 22px; border-color: var(--line); border-radius: 14px; background: rgba(209,179,122,.045); color: var(--muted); line-height: 1.65; }
.core-home-page .portal-assurance strong { color: var(--gold); font-weight: 600; }
.core-home-page .portal-counts { gap: 12px; margin: 24px 0; overflow: visible; border: 0; background: transparent; }
.core-home-page .portal-counts > div { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
.core-home-page .portal-counts span { min-height: 2.8em; font-size: 10px; line-height: 1.4; letter-spacing: .7px; }
.core-home-page .portal-counts strong { margin-top: 8px; color: var(--gold); font: 500 32px/1.1 Georgia, serif; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.core-home-page .portal-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.core-home-page :is(.portal-section,.portal-boundaries) { border-radius: 16px; box-shadow: 0 8px 28px rgba(0,0,0,.12); }
.core-home-page .card-heading { min-height: 96px; padding: 24px; }
.core-home-page .card-heading h2 { font-size: 26px; line-height: 1.2; }
.core-home-page .portal-list-row { padding: 20px 24px; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 12px; align-items: start; }
.core-home-page .portal-list-row strong { font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.core-home-page .portal-list-row :is(small,div > span) { font-size: 12px; line-height: 1.55; }
.core-home-page .portal-state { max-width: 16ch; white-space: normal; text-align: center; overflow-wrap: anywhere; }
.core-home-page .portal-state.connected { color: var(--paper); background: var(--gold); }
.core-home-page .portal-boundaries { grid-template-columns: 1fr; gap: 20px; margin-top: 24px; padding: 24px; background: rgba(255,255,255,.015); }
.core-home-page .portal-boundaries h2 { font-size: 23px; line-height: 1.3; }
.core-home-page .portal-boundary-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.core-home-page .portal-boundary-grid > div { padding: 12px 0; border: 0; border-radius: 0; background: transparent; }
.core-home-page .portal-boundary-grid span { font-size: 10px; line-height: 1.5; }
.core-home-page .portal-boundary-grid strong { font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }

.core-account-page { padding: clamp(24px, 8vh, 80px) 24px; }
.core-account-page .core-account-panel { width: 100%; max-width: 720px; margin: 0 auto; padding: clamp(24px, 5vw, 48px); border: 1px solid var(--line); border-radius: 24px; background: linear-gradient(145deg,rgba(209,179,122,.06),transparent 60%),var(--card); box-shadow: var(--shadow); }
.core-account-page h1 { font-size: clamp(34px, 5vw, 48px); letter-spacing: -1.4px; line-height: 1.12; }
.core-account-page p { color: var(--muted); font-size: 14px; line-height: 1.7; overflow-wrap: anywhere; }
.core-account-page #username { color: var(--ink); font-weight: 600; }
.core-account-page nav { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,220px),1fr)); gap: 14px; margin: 28px 0; }
.core-account-page nav a { display: flex; align-items: center; min-height: 86px; padding: 22px; border: 1px solid var(--line); border-radius: 14px; color: var(--gold); background: rgba(209,179,122,.055); font-size: 17px; font-weight: 600; text-decoration: none; }
.core-account-page nav a:hover { border-color: var(--gold); background: var(--green-soft); }
.core-account-page p a { color: var(--muted); text-underline-offset: 4px; }
.core-account-page #logout { min-height: 44px; padding: 10px 18px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: transparent; box-shadow: none; }
.core-account-page #account-message { max-width: 720px; margin: 20px auto; }

@media (max-width: 1100px) {
  .core-home-page .portal-counts { grid-template-columns: repeat(3, minmax(0,1fr)); }
  .core-home-page .portal-intro { align-items: flex-start; flex-direction: column; gap: 14px; }
}
@media (max-width: 860px) {
  .core-home-page .workspace-home-main { padding-top: 28px; }
  .core-home-page .portal-boundary-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 720px) {
  .core-entry-page .login-shell { width: calc(100% - 32px); padding-block: 24px; }
  .core-entry-page .login-brand-panel { padding: 30px 24px; }
  .core-entry-page .login-logo { width: 56px; height: 56px; margin-bottom: 22px; border-radius: 14px; }
  .core-entry-page .login-brand-panel h1 { font-size: clamp(32px, 7vw, 44px); letter-spacing: -1px; }
  .core-entry-page .login-form { padding: 30px 24px; }
  .core-home-page .portal-grid { grid-template-columns: minmax(0,1fr); }
  .core-home-page .portal-counts { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .core-home-page .portal-counts > div { padding: 16px; }
  .core-home-page .portal-list-row { padding: 18px; }
  .core-account-page { padding: 24px 16px; }
}

/* Noticeboard: explicit shared text, not a private-data dashboard. */
.noticeboard-page main > p { color: var(--muted); line-height: 1.6; }
.noticeboard-page .notice-toolbar { display: flex; align-items: end; flex-wrap: wrap; gap: 16px; margin: 20px 0; }
.noticeboard-page label { display: block; color: var(--muted); font-size: 13px; line-height: 1.6; }
.noticeboard-page :is(input:not([type=checkbox]),select,textarea) { display: block; width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink); background: var(--paper); font: inherit; font-size: 16px; }
.noticeboard-page :is(input,select,textarea,button):focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.noticeboard-page button { min-height: 44px; border-radius: 10px; }
.noticeboard-page #notice-new,.noticeboard-page #notice-save { color: #09090c; }
.noticeboard-page #notice-form { padding: clamp(20px,3vw,32px); margin: 24px 0; }
.noticeboard-page fieldset { display: grid; gap: 16px; border: 0; margin: 20px 0; padding: 0; min-width: 0; }
.noticeboard-page .notice-posts { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,320px),1fr)); gap: 20px; }
.noticeboard-page .notice-post { padding: 24px; min-width: 0; overflow-wrap: anywhere; }
.noticeboard-page .notice-post p { color: var(--muted); font-size: 13px; line-height: 1.65; white-space: pre-wrap; }
.noticeboard-page .notice-post h2 { font-size: 26px; line-height: 1.25; }
.noticeboard-page .notice-post > p:first-child { color: var(--gold); font-size: 11px; letter-spacing: .7px; }
.noticeboard-page #notice-cancel,.noticeboard-page .notice-post button { background: transparent; color: var(--ink); border: 1px solid var(--line); box-shadow: none; }
.noticeboard-page #notice-message { min-height: 1.5em; }
.noticeboard-page .notice-post .notice-badge { display: inline-block; padding: 5px 10px; border: 1px solid var(--line); border-radius: 999px; }
.noticeboard-page .notice-post .notice-state-active { color: var(--gold); }
.noticeboard-page .notice-post :is(.notice-state-expired,.notice-state-withdrawn) { color: var(--muted); }
.noticeboard-page #notice-value-help { color: var(--muted); font-size: 13px; margin: 0; }
@media(max-width:720px) { .noticeboard-page .notice-toolbar > label { width: 100%; } }

/* Shared research tools: browser counterparts to the CoinVault tool rooms. */
.tool-page { color-scheme: dark; }
.tool-main { width: auto; max-width: 1510px; margin-left: 236px; padding: 46px 34px 80px; }
.tool-intro { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 26px; }
.tool-intro h1 { background: linear-gradient(105deg,#fff 8%,#e6d3aa 50%,#c4935c 100%); background-clip: text; -webkit-background-clip: text; color: transparent; }
.tool-connection,.tool-lock { display: inline-flex; align-items: center; justify-content: center; padding: 9px 13px; border: 1px solid #ae3d3d; border-radius: 999px; color: #ff7e7e; background: rgba(172,47,47,.11); font-size: 10px; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; }
.tool-connection.connected { color: #76f19b; border-color: #39a85d; background: rgba(47,168,87,.12); box-shadow: 0 0 22px rgba(47,168,87,.12); }
.tool-lock { color: var(--gold); border-color: var(--line); background: var(--green-soft); }
.tool-grid { display: grid; grid-template-columns: minmax(350px,.82fr) minmax(510px,1.18fr); gap: 24px; align-items: start; }
.tool-panel,.tool-result,.market-board { border-color: var(--line); background: linear-gradient(145deg,rgba(35,33,36,.98),rgba(16,15,18,.98)); }
.tool-panel-head { min-height: 92px; padding: 22px 25px; display: flex; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line); }
.tool-panel-head .eyebrow { margin-bottom: 5px; }
.tool-methods { display: grid; grid-template-columns: repeat(2,1fr); gap: 7px; padding: 17px 21px 0; }
.tool-methods.three { grid-template-columns: repeat(3,1fr); padding: 0; }
.tool-methods button { min-width: 0; padding: 12px 9px; color: var(--muted); border: 1px solid var(--line); background: rgba(255,255,255,.025); cursor: pointer; }
.tool-methods button.active { color: #0b0a0c; border-color: #f2d48c; background: linear-gradient(135deg,#f4da9b,var(--gold)); box-shadow: 0 0 22px rgba(209,179,122,.14); }
.tool-form { display: grid; gap: 17px; padding: 21px; }
.tool-form label,.gsr-lab label { display: grid; gap: 7px; }
.tool-form label > span,.gsr-lab label > span { color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; }
.tool-form input,.tool-form select,.gsr-lab input { width: 100%; min-width: 0; padding: 13px 14px; color: var(--ink); border: 1px solid rgba(209,179,122,.28); border-radius: 9px; background: #211f22; font: inherit; }
.tool-form input:focus,.tool-form select:focus,.gsr-lab input:focus { outline: 2px solid rgba(209,179,122,.16); border-color: var(--gold); }
.tool-form > button[type="submit"] { width: 100%; color: #0b0a0c; background: linear-gradient(135deg,#f4da9b,var(--gold)); cursor: pointer; text-transform: uppercase; letter-spacing: .5px; }
.tool-form-pair { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; }
.secondary-tool-button,.icon-tool-button { min-width: 0; padding: 11px 13px; color: var(--gold); border: 1px solid var(--line); background: rgba(209,179,122,.06); cursor: pointer; }
.icon-tool-button { width: 42px; height: 42px; padding: 0; border-radius: 50%; font-size: 24px; }
.tool-message { min-height: 18px; margin: -3px 0 0; color: var(--muted); font-size: 11px; line-height: 1.45; }
.tool-message[data-tone="good"] { color: #76f19b; }
.tool-message[data-tone="error"] { color: #ff8888; }
.tool-empty { min-height: 430px; padding: 45px; display: grid; place-items: center; align-content: center; text-align: center; }
.tool-empty > span { display: grid; place-items: center; width: 72px; height: 72px; border: 1px solid var(--line); border-radius: 50%; color: var(--gold); background: var(--green-soft); font-size: 34px; }
.tool-empty h2 { margin-top: 18px; }
.tool-empty p { max-width: 440px; color: var(--muted); line-height: 1.55; }
.tool-camera { padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: #0b0a0c; }
.tool-camera video { width: 100%; max-height: 280px; border-radius: 8px; object-fit: cover; }
.tool-camera p { color: var(--muted); font-size: 10px; }

.pcgs-page { --gold:#ffd100; --green:#ffd100; --green-soft:rgba(255,209,0,.12); --line:rgba(255,209,0,.25); background: radial-gradient(circle at 85% 4%,rgba(0,53,148,.52),transparent 36rem),radial-gradient(circle at 15% 82%,rgba(255,209,0,.08),transparent 35rem),#050b18; }
.pcgs-page .listing-sidebar { background: linear-gradient(180deg,#003594,#001b4e 60%,#050b18); }
.pcgs-page .topnav a.current,.pcgs-page .tool-methods button.active,.pcgs-page .tool-form > button[type="submit"] { color:#061129; border-color:#ffe45c; background:linear-gradient(135deg,#ffe45c,#ffd100); }
.pcgs-result-head { display:grid; grid-template-columns:150px 1fr; gap:22px; align-items:center; padding:24px; border-bottom:1px solid var(--line); }
.pcgs-result-head > img,.pcgs-result-mark { width:150px; height:150px; border-radius:13px; object-fit:contain; background:#0a1327; }
.pcgs-result-mark { display:grid; place-items:center; color:#ffd100; font-weight:900; }
.pcgs-result-head p:last-child { color:var(--muted); }
.pcgs-result-grid { display:grid; grid-template-columns:repeat(3,1fr); }
.pcgs-result-grid div { min-height:75px; padding:16px 18px; border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.pcgs-result-grid div:nth-child(3n) { border-right:0; }
.pcgs-result-grid span,.pcgs-result-grid strong { display:block; }
.pcgs-result-grid span { margin-bottom:6px; color:var(--muted); font-size:9px; text-transform:uppercase; letter-spacing:.6px; }
.pcgs-result-grid strong { font-size:13px; }
.pcgs-notes,.tool-result-actions { padding:21px 24px; border-top:1px solid var(--line); }
.pcgs-notes p:last-child { color:var(--muted); font-size:12px; line-height:1.6; }

.market-board { margin-bottom:24px; }
.market-cards { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; padding:20px 24px 12px; }
.market-card { min-width:0; padding:19px 15px; display:grid; gap:4px; color:var(--ink); border:1px solid var(--line); background:linear-gradient(145deg,#dedfe4,#9ea5ad); cursor:pointer; }
.market-card:nth-child(2) { color:#18130a; background:linear-gradient(145deg,#ffe16a,#c9850a); }
.market-card:nth-child(3) { color:#172026; background:linear-gradient(145deg,#d8e9ec,#91abb1); }
.market-card.active { border-color:#fff1bd; box-shadow:0 0 24px rgba(229,198,135,.2); transform:translateY(-2px); }
.market-card span { font-size:12px; font-weight:800; }
.market-card strong { font-size:23px; }
.market-card small { font-size:9px; text-transform:uppercase; }
.market-card em { margin-top:5px; font-size:10px; font-style:normal; opacity:.76; }
.market-updated { margin:0; padding:4px 24px 20px; color:var(--muted); font-size:10px; }
.metal-calculator-form { gap:12px; }
.metal-calculator-form > .tool-methods.three { margin-bottom:2px; }
.metal-control-block { display:grid; gap:12px; padding:16px; border:1px solid rgba(171,89,52,.52); border-radius:13px; background:linear-gradient(145deg,rgba(25,23,26,.94),rgba(13,12,15,.96)); }
.metal-control-block .tool-methods { padding:0; }
.metal-control-title { margin:0; color:var(--muted); font-size:9px; font-weight:800; letter-spacing:1px; text-transform:uppercase; }
.metal-control-help { margin:0; color:var(--muted); font-size:10px; line-height:1.5; }
.metal-preset-strip { display:flex; gap:8px; padding:2px 1px 8px; overflow-x:auto; overscroll-behavior-inline:contain; scrollbar-color:rgba(236,207,145,.72) rgba(255,255,255,.04); scrollbar-width:thin; scroll-snap-type:x proximity; }
.metal-preset-strip::-webkit-scrollbar { height:7px; }
.metal-preset-strip::-webkit-scrollbar-track { border-radius:99px; background:rgba(255,255,255,.04); }
.metal-preset-strip::-webkit-scrollbar-thumb { border-radius:99px; background:linear-gradient(90deg,#b67a39,#f1d691); box-shadow:0 0 9px rgba(240,208,143,.36); }
.metal-preset-strip button { flex:0 0 auto; min-width:78px; min-height:44px; padding:10px 13px; scroll-snap-align:start; color:#d7d5d9; border:1px solid rgba(255,255,255,.13); border-radius:10px; background:linear-gradient(180deg,#44434a,#1c1c22); box-shadow:inset 0 1px rgba(255,255,255,.12); cursor:pointer; font-weight:750; }
.metal-preset-strip button.active { color:#171108; border-color:#f0cf85; background:linear-gradient(145deg,#f1d796,#ad7538); box-shadow:0 0 15px rgba(236,205,137,.24),inset 0 1px rgba(255,255,255,.35); }
.metal-input-with-suffix { position:relative; display:block; }
.metal-input-with-suffix input { padding-right:52px; }
.metal-input-with-suffix b { position:absolute; top:50%; right:16px; transform:translateY(-50%); color:var(--ink); font-size:13px; pointer-events:none; }
.metal-quantity-control { display:grid; grid-template-columns:48px minmax(80px,1fr) 48px; gap:8px; }
.metal-quantity-control button { min-width:0; padding:0; color:var(--gold); border:1px solid var(--line); background:rgba(209,179,122,.07); cursor:pointer; font-size:23px; }
.metal-quantity-control input { text-align:center; }
.metals-result { overflow:visible; }
.metal-calculation { padding:30px; }
.metal-calculation > strong { display:block; font:600 clamp(42px,6vw,72px)/1 Georgia,serif; color:#ebd198; }
.metal-calculation > span { display:block; margin-top:10px; color:var(--muted); }
.metal-calculation > p:last-child { color:var(--muted); font-size:11px; line-height:1.5; }
.metal-result-grid { display:grid; grid-template-columns:repeat(2,1fr); margin:27px 0 20px; border:1px solid var(--line); border-radius:10px; overflow:hidden; }
.metal-result-grid div { padding:16px; border-right:1px solid var(--line); border-bottom:1px solid var(--line); }
.metal-result-grid div:nth-child(2n) { border-right:0; }
.metal-result-grid div:nth-last-child(-n+2) { border-bottom:0; }
.metal-result-grid span,.metal-result-grid b { display:block; }
.metal-result-grid span { margin-bottom:5px; color:var(--muted); font-size:9px; text-transform:uppercase; }
.gsr-lab { display:grid; gap:17px; padding:27px; border-top:1px solid var(--line); background:rgba(209,179,122,.035); }
.gsr-lab .tool-methods { padding:0; }
.gsr-result { margin:0; padding:15px; color:var(--muted); border:1px solid var(--line); border-radius:9px; font-size:12px; line-height:1.55; }
.gsr-result strong { color:var(--ink); }

@media (max-width: 980px) {
  .tool-grid { grid-template-columns:1fr; }
  .pcgs-result-grid { grid-template-columns:repeat(2,1fr); }
  .pcgs-result-grid div:nth-child(3n) { border-right:1px solid var(--line); }
  .pcgs-result-grid div:nth-child(2n) { border-right:0; }
}
@media (max-width: 860px) {
  .tool-main { margin-left:0; padding:30px 18px 65px; }
  .tool-intro { align-items:flex-start; flex-direction:column; }
  .market-cards { gap:8px; padding-inline:15px; }
  .market-card { padding:15px 9px; }
  .market-card strong { font-size:17px; }
}
@media (max-width: 540px) {
  .tool-form-pair,.pcgs-result-head { grid-template-columns:1fr; }
  .tool-methods.three { grid-template-columns:1fr; }
  .metals-page .tool-methods.three { grid-template-columns:repeat(3,1fr); }
  .metal-control-block { padding:13px; }
  .metal-preset-strip button { min-width:74px; }
  .market-card strong { font-size:14px; }
  .pcgs-result-head > img,.pcgs-result-mark { width:112px; height:112px; }
  .pcgs-result-grid { grid-template-columns:1fr; }
  .pcgs-result-grid div { border-right:0 !important; }
}

@page { size: A4 portrait; margin: 11mm 9mm 12mm; }
@media print {
  body { background: white; color: black; }
  .no-print { display: none !important; }
  .print-book { display: block; font-family: Arial,Helvetica,sans-serif; }
  .print-book-title { padding-bottom: 5mm; border-bottom: 1px solid #111; }
  .print-book-title h1 { margin: 0; font: 700 19pt Arial,Helvetica,sans-serif; letter-spacing: 0; }
  .print-book-title p { margin: 2mm 0 0; font-size: 7pt; }
  .print-book .reference-group { position: static; margin: 5mm 0 0; padding: 2.2mm 2.5mm; break-after: avoid; color: white !important; background: #245b45 !important; print-color-adjust: exact; -webkit-print-color-adjust: exact; font-size: 9pt; }
  .print-book .reference-row { grid-template-columns: 10mm 13mm minmax(42mm,1fr) 22mm 15mm 43mm 15mm; gap: 1.5mm; min-height: 16mm; padding: 1.4mm 1mm; break-inside: avoid; border-top: .2mm solid #bbb; font-size: 6.7pt; }
  .print-book .reference-row small { font-size: 5.5pt; }
  .print-book .ref-thumb img { width: 13mm; height: 13mm; border-radius: 0; }
  .print-book .ref-barcode img { width: 42mm; height: 13mm; }
}
:root .listing-sidebar .topnav:not([data-authority-ready]) { visibility: hidden; }
