/* Isolated TradingView-inspired dark theme. Load after the existing styles.
   Existing markup, responsive grids, interactions, and data stay in place. */
:root {
  color-scheme: dark;
  --page: #0a0a0a;
  --page-deep: #0a0a0a;
  --bar: #0f0f0f;
  --bar-dark: #1a1a1a;
  --card: #0f0f0f;
  --card-hover: #242424;
  --line: #303030;
  --text: #f5f5f5;
  --muted: #a6a6a6;
  --aqua: #2962ff;
  --blue: #2962ff;
  --green: #089981;
  --green-dark: #26bda5;
  --red: #ff6370;
  --ink: #f5f5f5;
  --font: -apple-system, BlinkMacSystemFont, "Trebuchet MS", Roboto, Ubuntu, sans-serif;
  --body: var(--font);
  --surface: #0f0f0f;
  --surface-alt: #1a1a1a;
  --hover: #2e2e2e;
  --selected: #202c48;
  --border-strong: #4a4a4a;
  --accent-hover: #4778ff;
  --accent-text: #8aafff;
  --chart-grid: #252525;
  --chart-label: #a6a6a6;
  --chart-price: #5790ff;
  --chart-point-outline: #0f0f0f;
  --chart-median: #858585;
  --chart-crosshair: #b2b5be;
  --chart-volume-up: #08998180;
  --chart-volume-down: #f2364580;
  --chart-area-top: #2962ff36;
  --chart-area-bottom: #2962ff00;
}

html,
body,
body.account-site {
  background: var(--page);
  color: var(--text);
  font-family: var(--body);
}
body {
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
body :is(h1, h2, h3, .logo, .q-name, .item-name, .saved-item-name, .price-primary) {
  text-shadow: none;
  font-weight: 600;
}
body :is(button, input, select, textarea) {
  font-family: var(--body);
}
body :is(button, a, input, select, summary):focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}
body :is(input, select, textarea) {
  accent-color: var(--accent-text);
}
body :is(input, textarea)::placeholder {
  color: var(--muted);
  opacity: 1;
}
body .skip-link,
body .noscript-note {
  background: var(--surface);
  color: var(--text);
  border-color: var(--accent-text);
}

/* Navigation and global chrome. */
body .topbar {
  height: 60px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  box-shadow: none;
}
body .topbar-inner {
  height: 59px;
}
body .logo {
  padding: 6px 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  font-family: Arial, sans-serif;
  font-size: 23px;
  letter-spacing: -0.055em;
  white-space: nowrap;
}
body .logo b {
  color: #6694ff;
  font-weight: 700;
  font-style: normal;
}
body .logo span {
  color: var(--text);
  font-weight: 700;
}
body .data-status {
  color: var(--muted);
  text-shadow: none;
}
body .status-dot {
  background: var(--green);
  box-shadow: none;
}
body .data-status.is-offline .status-dot {
  background: var(--red);
  box-shadow: none;
}
body .desktop-nav {
  gap: 4px;
}
body .desktop-nav a {
  padding: 9px 16px;
  min-height: 38px;
  border: 0;
  border-radius: 20px;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
}
body .desktop-nav a:hover {
  background: var(--hover);
  box-shadow: none;
}
body .desktop-nav a[aria-current="page"] {
  background: var(--hover);
  color: var(--text);
  box-shadow: none;
}
body .account-trigger,
body .account-trigger.is-authenticated {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface-alt);
  color: var(--text);
  font-weight: 500;
  box-shadow: none;
  text-shadow: none;
  border-color: transparent;
}
body .account-trigger:hover {
  background: var(--hover);
  color: var(--text);
}
body .account-avatar,
body.account-site .account-avatar.large {
  border: 0;
  border-radius: 50%;
  background: var(--selected);
  color: var(--accent-text);
  box-shadow: none;
  font-weight: 600;
}
body .alpha-banner {
  background: var(--surface-alt);
  border-color: var(--line);
  color: var(--muted);
  box-shadow: none;
}
body .alpha-badge {
  background: var(--selected);
  color: var(--accent-text);
  border-color: transparent;
}
body .alpha-banner-link:hover {
  background: var(--hover);
}
body .discord-support {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 4px 20px #00000033;
  text-shadow: none;
}
body .discord-support:hover {
  background: var(--hover);
  border-color: var(--border-strong);
}
body .discord-support img {
  filter: brightness(0) saturate(100%) invert(37%) sepia(81%) saturate(4982%) hue-rotate(220deg);
}
body .discord-support-label {
  background: #1e222d;
  border-color: #1e222d;
  font-weight: 500;
}
body .site-footer {
  padding: 16px 0;
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  color: var(--muted);
  box-shadow: none;
}
body .site-footer a {
  color: var(--muted);
}
body .site-footer a:hover {
  color: var(--accent-text);
}

/* Search and Daily Quest retain their existing positions and dimensions. */
#item-search {
  background: var(--page);
  border-bottom: 1px solid var(--line);
  box-shadow: none;
}
#item-search::before,
#item-search .weather-glints {
  display: none;
}
#item-search .landing-inner {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  transform: none;
  transition: none;
  padding: 24px 20px 24px 0;
}
#search-title {
  color: var(--text);
  font-weight: 700;
  text-shadow: none;
  letter-spacing: -0.03em;
  margin-bottom: 28px;
  font-size: clamp(36px, 3.8vw, 46px);
}
#search-title svg {
  stroke: var(--text);
  width: 32px;
  height: 32px;
}
#item-search .search-bar,
body .market-search {
  border: 1px solid transparent;
  border-radius: 28px;
  background: var(--hover);
  box-shadow: none;
}
#item-search .search-bar:focus-within,
body .market-search:focus-within {
  border-color: var(--accent-text);
  box-shadow: 0 0 0 2px #2962ff1a;
}
#item-search input,
body .market-search input {
  color: var(--text);
  background: transparent;
}
#item-search input::placeholder {
  color: var(--muted);
}
#item-search .search-icon,
body .market-search svg {
  stroke: var(--muted);
}
#item-search .kbd-hint {
  color: var(--muted);
  border-color: var(--line);
  background: var(--surface-alt);
}
#item-search .search-go {
  height: 40px;
  margin: 0 8px;
  padding: 0 14px;
  border: 0;
  border-radius: 22px;
  background: #f5f5f5;
  color: #131722;
  font-weight: 600;
  box-shadow: none;
  text-shadow: none;
}
#item-search .search-go:hover:not(:disabled) {
  background: #d9dce3;
}
#item-search .search-go:disabled {
  background: #383838;
  color: #b3b3b3;
  box-shadow: none;
}
#item-search .autocomplete,
body .autocomplete {
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 8px 32px #00000066;
}
#item-search .autocomplete-item,
body .autocomplete-item {
  background: var(--surface);
  color: var(--text);
  border-color: var(--line);
}
#item-search .autocomplete-item:hover,
#item-search .autocomplete-item.active,
body .autocomplete-item:hover,
body .autocomplete-item.active {
  background: var(--hover);
}
#item-search :is(.ac-meta, .ac-price small, .autocomplete-empty) {
  color: var(--muted);
}
#item-search .landing-links :is(a, button) {
  border: 1px solid transparent;
  border-radius: 22px;
  background: var(--surface-alt);
  color: var(--text);
  font-size: 12px;
  font-weight: 500;
  box-shadow: none;
  min-height: 38px;
  padding: 8px 14px;
  flex-direction: row;
  gap: 7px;
}
#item-search .landing-links :is(a, button):hover {
  background: var(--hover);
  border-color: var(--border-strong);
}
#item-search .landing-links :is(a, button):active {
  transform: none;
  box-shadow: none;
}
#item-search .landing-links svg {
  stroke: var(--muted);
  width: 16px;
  height: 16px;
}
#daily-quest {
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: none;
}
#daily-quest .daily-quest-header {
  border-bottom: 1px solid var(--line);
  background: #202020;
  box-shadow: none;
  color: var(--text);
  border-radius: 13px 13px 0 0;
}
#daily-quest .daily-quest-header h2 {
  font-size: 20px;
  font-weight: 700;
}
#daily-quest .daily-quest-reset {
  color: var(--muted);
}
#daily-quest .daily-quest-reset strong {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
#daily-quest .daily-quest-panel {
  background: var(--surface);
  padding: 6px 12px;
  border-radius: 0 0 13px 13px;
}
#daily-quest .daily-quest-item {
  background: transparent;
  color: var(--text);
  border: 0;
  box-shadow: none;
  border-radius: 8px;
}
#daily-quest .daily-quest-item:hover {
  background: var(--hover);
  border-color: var(--border-strong);
}
#daily-quest :is(.daily-quest-item-copy strong, .daily-quest-quantity strong) {
  color: var(--text);
  font-weight: 600;
  text-shadow: none;
}
#daily-quest :is(.daily-quest-item-copy small, .daily-quest-quantity small, .daily-quest-arrow) {
  color: var(--muted);
}
#daily-quest .daily-quest-message {
  background: var(--surface);
  color: var(--muted);
}

/* Market tables, cards, and section hierarchy. */
body :is(.section-bar, .panel-title, .notice-bar) {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  box-shadow: none;
}
body .section-bar h2,
body .market-heading h1 {
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.025em;
}
body .panel-title {
  font-size: 16px;
  font-weight: 600;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 12px 12px 0 0;
}
body :is(.section-bar > span, .item-nav > span, .section-action) {
  color: var(--muted);
}
body .section-action {
  font-weight: 500;
}
body .section-action:hover {
  background: var(--hover);
  color: var(--accent-text);
}
body .market-overview {
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  box-shadow: none;
  border-bottom: 1px solid var(--line);
}
body .market-overview div {
  border-color: var(--line);
}
body .market-overview span {
  color: var(--muted);
}
body .home-view .market-overview span {
  font-size: 12px;
  text-transform: none;
  letter-spacing: 0;
}
body .market-overview strong {
  color: var(--text);
  font-weight: 600;
}
body .quote-head {
  background: transparent;
  color: var(--muted);
  border: 0;
  font-weight: 500;
  border-bottom: 1px solid var(--line);
}
body :is(.quote-row, .item-card, .item-hero, .listing-card, .account-identity, .category-card) {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  box-shadow: none;
}
body :is(.quote-row, .item-card, .listing-card, .category-card):hover {
  background: var(--hover);
  border-color: var(--line);
  transform: none;
}
body .quote-head button:hover {
  color: var(--accent-text);
}
body .quote-row {
  min-height: 72px;
  border-width: 0 0 1px;
  border-radius: 0;
  background: transparent;
}
body .category-card {
  gap: 16px;
  align-items: flex-start;
  position: relative;
  text-align: left;
  padding: 20px;
  border-radius: 14px;
}
body .category-card strong {
  font-size: 17px;
  font-weight: 600;
}
body .category-icon svg {
  stroke: var(--muted);
}
body .tick,
body .category-icon.tick,
#daily-quest .tick {
  border: 0;
  border-radius: 50%;
  background: var(--hover);
  color: var(--muted);
  box-shadow: none;
  text-shadow: none;
}
body
  :is(
    .q-shouts,
    .q-price small,
    .activity-time,
    .item-cat,
    .item-price small,
    .item-hero-meta,
    .listing-time,
    .listing-meta,
    .item-price-caption,
    .item-stack-price,
    .accuracy-note,
    .empty-state
  ) {
  color: var(--muted);
}
body :is(.q-price, .item-price, .item-hero-price, .listing-price, .stat-value, .ac-price) {
  color: var(--text);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
body .item-hero-main h1 {
  font-weight: 700;
  letter-spacing: -0.02em;
  font-size: 28px;
}
body .item-hero-meta b {
  color: var(--text);
  font-weight: 600;
}
body .listing-quantity {
  color: var(--muted);
}
body .price-display .price-primary {
  font-weight: 600;
}
body .price-display small.price-secondary,
body .chart-readout .price-display .price-secondary {
  color: var(--muted);
}
body :is(.trend.up, .listing-tag.buy) {
  background: #102a25;
  color: var(--green-dark);
  border-color: #244a40;
}
body :is(.trend.down, .listing-tag.sell) {
  background: #30191f;
  color: var(--red);
  border-color: #603039;
}
body .trend.flat {
  color: var(--muted);
  background: var(--hover);
}
body :is(.skeleton-row, .skeleton-card, .skeleton-chart),
#daily-quest .skeleton-card {
  background: #1a1a1a;
  border-color: var(--line);
}
body .skeleton-row::after,
body .skeleton-card::after,
body .skeleton-chart::after {
  background: linear-gradient(90deg, transparent, #ffffff0d, transparent);
}

/* Inputs, buttons, chart timeframes, and evidence controls. */
body
  :is(
    .market-controls,
    .tool-panel,
    .listing-toolbar,
    .market-info,
    .chart-panel,
    .listings-panel
  ) {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: none;
}
body
  :is(
    .market-filter-row label,
    .calculator-body label,
    .listing-toolbar label,
    .market-filter-disclosure > summary,
    .calc-result span,
    .calc-result small,
    .item-info-body,
    .info-properties
  ) {
  color: var(--muted);
}
body
  :is(
    .market-filter-row select,
    .listing-toolbar select,
    .listing-toolbar input,
    .calculator-body input
  ) {
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text);
  box-shadow: none;
}
body #market-reset {
  color: var(--accent-text);
}
body :is(.back-btn, .load-btn, .mini-btn, .fav-btn, .dialog-close, .flip-button) {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-weight: 500;
  box-shadow: none;
  text-shadow: none;
  filter: none;
}
body :is(.back-btn, .load-btn, .mini-btn, .fav-btn, .dialog-close, .flip-button):hover {
  background: var(--hover);
  border-color: var(--border-strong);
}
body .fav-btn.is-fav {
  background: var(--selected);
  color: var(--accent-text);
}
body .seg {
  gap: 4px;
}
body .seg button {
  border: 1px solid transparent;
  border-radius: 4px;
  background: transparent;
  color: #c6c6cc;
  font-weight: 500;
}
body .seg button:hover {
  background: var(--hover);
  color: var(--text);
}
body .seg button.is-active {
  background: var(--hover);
  border-color: transparent;
  color: var(--text);
}
body .stat-card {
  background: var(--surface);
  border-color: var(--line);
}
body :is(.stat-label, .stat-sub) {
  color: var(--muted);
}
body .stat-label {
  font-weight: 500;
}
body .stat-value.pos {
  color: var(--green-dark);
}
body .stat-value.neg {
  color: var(--red);
}
body :is(.chart-box, .chart-canvas) {
  background: var(--surface);
}
body .chart-explorer {
  border-color: var(--line);
  background: transparent;
  color: var(--muted);
}
body .chart-explorer input {
  accent-color: var(--accent-text);
}
body .chart-readout {
  color: var(--text);
  margin: 6px 0 0;
  padding: 10px 12px;
  border-radius: 6px;
  background: var(--surface-alt);
}
body .chart-readout > span {
  color: var(--muted);
}
body .chart-legend {
  color: var(--muted);
}
body .lg-key i {
  background: var(--chart-price);
}
body .lg-key.vol i {
  background: #08998166;
}
body .chart-empty {
  color: var(--muted);
}
body .try-link {
  color: var(--accent-text);
}
body .info-type {
  background: var(--hover);
  color: var(--muted);
}
body .item-info-body a {
  color: var(--accent-text);
}
body .calc-result {
  background: var(--surface-alt);
  border-color: var(--line);
  color: var(--text);
}
body .calc-result .price-primary,
body .calc-result .price-amount {
  color: var(--text);
}
body .listing-feed {
  background: var(--surface-alt);
}
body .listing-msg {
  background: var(--surface-alt);
  color: var(--text);
  border-left: 2px solid var(--border-strong);
}
body .legal-page {
  background: transparent;
  border-color: var(--line);
  color: var(--text);
  box-shadow: none;
}
body .legal-page > .back-btn {
  color: var(--text);
}
body .legal-page :is(h1, h2, p, li) {
  color: var(--text);
}
body .legal-page a {
  color: var(--accent-text);
}
body .seo-catalogue {
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  box-shadow: none;
}

/* Account, watchlist, alerts, and private management share the same controls. */
body
  :is(
    .account-panel,
    .account-guest,
    .permission-summary,
    .account-dialog,
    .flip-panel,
    .world-card
  ) {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  box-shadow: none;
}
body
  :is(
    .page-heading h1,
    .flip-heading,
    .flip-heading h1,
    .collection-meta,
    .collection-note,
    .saved-item-name,
    .alert-target-line strong,
    .expand-label,
    .management-label,
    .management-back,
    .management-session,
    .management-eyebrow
  ) {
  color: var(--text);
  text-shadow: none;
}
body.account-site :is(h1, h2, h3) {
  font-weight: 700;
  text-shadow: none;
}
body.account-site
  :is(.account-form label, .item-search-field > label, .form-field > label, .field-unit) {
  color: var(--text);
  font-weight: 500;
}
body.account-site .account-consent {
  color: var(--muted) !important;
}
body.account-site :is(input:not([type="checkbox"]), select),
body .flip-filters :is(input:not([type="checkbox"]), select),
body.world-copy-page input {
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  box-shadow: none;
}
body.account-site input:focus {
  border-color: var(--accent-text);
  outline: 2px solid #2962ff26;
  box-shadow: none;
}
body.account-site input[readonly] {
  background: var(--surface-alt);
}
body.account-site input[aria-invalid="true"] {
  border-color: var(--red);
  outline-color: #f2364533;
}
body.account-site
  :is(
    .account-form small,
    .field-help,
    .account-intro,
    .account-fineprint,
    .alert-activity,
    .profile-details dt,
    .saved-item-name small,
    .listing-price > small,
    .listing-price > span,
    .alert-target-line,
    .collection-note,
    .expand-label
  ) {
  color: var(--muted);
}
body.account-site .account-nav {
  padding: 6px;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: none;
}
body.account-site .account-nav a,
body.account-site .account-tabs a {
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  font-weight: 500;
  box-shadow: none;
  filter: none;
}
body.account-site .account-nav a:hover,
body.account-site .account-tabs a:hover {
  background: var(--hover);
}
body.account-site .account-nav a[aria-current="page"],
body.account-site .account-tabs a.is-active {
  background: var(--selected);
  color: var(--accent-text);
  box-shadow: none;
}
body.account-site .account-tabs {
  padding: 4px;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-alt);
}
body.account-site :is(.account-submit, .secondary-button, .password-toggle),
body.account-site .account-submit.secondary,
body .undo-message button {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  font-weight: 500;
  box-shadow: none;
}
body.account-site :is(.secondary-button, .password-toggle):hover,
body.account-site .account-submit.secondary:hover {
  background: var(--hover);
  border-color: var(--border-strong);
}
body.account-site .account-submit,
body.account-site #alert-new,
body .flip-primary,
body .undo-message button {
  background: var(--blue);
  border-color: var(--accent-text);
  color: white;
}
body.account-site .account-submit:hover,
body.account-site #alert-new:hover,
body .flip-primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: white;
}
body.account-site :is(.account-submit, .secondary-button):active,
body .flip-button:active {
  transform: none;
  box-shadow: none;
}
body.account-site
  :is(
    .account-link-button,
    .account-consent a,
    .account-footer a,
    .watchlist-shortcut,
    .market-link
  ),
body.account-site #account-logout,
body.account-site #alerts-refresh {
  color: var(--accent-text);
}
body.account-site
  :is(
    .profile-heading,
    .profile-details > div,
    .saved-row-actions,
    .alert-summary-end,
    .alert-controls,
    .management-session,
    .management-label
  ),
body .discord-panel #discord-options {
  border-color: var(--line);
  box-shadow: none;
}
body.account-site .profile-heading {
  background: var(--surface);
}
body :is(.alert-controls, .account-head, .account-tabs) {
  background: var(--surface-alt);
  color: var(--text);
  border-color: var(--line);
  box-shadow: none;
}
body.account-site .listing-price > strong,
body.collection-site .listing-price > .price-display,
body .alert-target-line > .price-display,
body .alert-price strong {
  color: var(--text);
  font-weight: 600;
}
body :is(.remove-saved, .delete-alert) {
  color: var(--red);
}
body :is(.remove-saved, .delete-alert):hover {
  color: #f7525f;
}
body :is(.plan-badge, .verified-label, .status-badge, .access-chip.verified) {
  color: var(--green-dark);
}
body.collection-site .status-badge {
  background: #102a25;
  color: var(--green-dark);
  border-color: #244a40;
}
body.collection-site .status-badge.paused {
  background: #30281b;
  color: #e9c36b;
  border-color: #54472b;
}
body .empty-alerts,
body.collection-site .empty-alerts {
  background: var(--surface);
  color: var(--muted);
  border: 1px solid var(--line);
  box-shadow: none;
}
body.account-site :is(#account-loading, .account-loading, #alerts-loading, #saved-alerts-title),
body .discord-panel #discord-options summary {
  color: var(--muted);
}
body #alert-items {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
}
body #alert-items [role="option"]:hover,
body #alert-items [aria-selected="true"] {
  background: var(--selected);
}
body.account-site .danger-panel {
  background: #1e1418;
  border-color: #52303a;
  color: var(--text);
}
body.account-site .danger-panel label {
  color: var(--text);
}
body.account-site .account-submit.danger {
  background: #bc2440;
  border-color: #bc2440;
  color: white;
}
body.account-site .account-submit.danger:hover {
  background: #d12a46;
}
body.account-site .account-error {
  box-shadow: none;
}
body.account-site .success-message {
  background: #102a25;
  color: var(--green-dark);
  box-shadow: none;
}
body .verification-icon {
  color: var(--accent-text);
  border-color: var(--line);
  background: var(--selected);
}
body .account-dialog::backdrop {
  background: #000000a6;
}
body .toast {
  color: white;
  background: #1e222d;
  border: 1px solid #1e222d;
  box-shadow: 0 4px 20px #00000066;
}

/* Flip Finder keeps its existing filter and buy/sell evidence layout. */
body
  :is(
    .flip-filters label,
    .flip-results-bar,
    .flip-loading,
    .flip-pagination,
    .flip-footer,
    .flip-item-link h3,
    .flip-source-title b
  ) {
  color: var(--text);
}
body :is(.flip-offer-label, .flip-card-head, .flip-source, .flip-card-foot) {
  background: var(--surface-alt);
  border-color: var(--line);
  color: var(--muted);
  box-shadow: none;
}
body
  :is(
    .flip-quantity,
    .flip-gain small,
    .flip-gain > span,
    .flip-source-title,
    .flip-source-meta,
    .flip-empty p,
    .flip-method p
  ) {
  color: var(--muted);
}
body .flip-gain strong {
  color: var(--green-dark);
  font-weight: 600;
}
body .flip-source .price-primary {
  color: var(--text);
  font-weight: 600;
}
body .flip-source .price-secondary {
  color: var(--muted);
}
body
  :is(
    .flip-world .flip-text-button,
    .flip-card-foot a,
    .flip-source-actions a,
    .flip-empty-symbol,
    .flip-trade-arrow
  ) {
  color: var(--accent-text);
}
body .flip-gain {
  border-color: #244a40;
}
body .flip-heading h1 {
  font-weight: 700;
}

/* Management tables and the standalone world-copy handoff. */
body.management-site .account-panel a:not(.secondary-button):not(.account-submit) {
  color: var(--accent-text);
}
body.management-site
  :is(label, .management-attention strong, .management-stat strong, .management-stat.pro strong) {
  color: var(--text);
}
body.management-site
  :is(
    .management-note,
    .management-updated,
    #management-loading,
    .management-facts dt,
    .management-table-wrap th,
    .management-table-wrap td small,
    .management-stat small,
    .management-event-top time
  ) {
  color: var(--muted);
}
body.management-site :is(.management-stat, .management-stat.pro, .management-dialog) {
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  box-shadow: none;
}
body.management-site .management-stat:hover {
  background: var(--hover);
  transform: none;
}
body.management-site
  :is(.management-close, .management-expiry-options button, textarea, #recovery-codes) {
  background: var(--surface-alt);
  border: 1px solid var(--line);
  color: var(--text);
}
body.management-site
  :is(
    .management-attention,
    .management-table-wrap th,
    .management-table-wrap td,
    .management-detail-section,
    .management-event
  ) {
  border-color: var(--line);
}
body.management-site .management-table-wrap tbody tr:hover {
  background: var(--hover);
}
body.management-site .management-table-wrap tr.selected {
  background: var(--selected);
  box-shadow: inset 3px 0 var(--blue);
}
body.management-site :is(.management-user-link, .management-event-change) {
  color: var(--accent-text);
}
body.management-site .management-badge {
  background: var(--selected);
  color: var(--accent-text);
  border-color: #343e58;
}
body.management-site .management-badge.pro {
  background: #102a25;
  color: var(--green-dark);
  border-color: #244a40;
}
body.management-site .management-badge.suspended {
  background: #30191f;
  color: var(--red);
  border-color: #603039;
}
body.management-site .management-badge.unverified {
  background: #30281b;
  color: #e9c36b;
  border-color: #54472b;
}
body.management-site .management-dialog::backdrop {
  background: #000000a6;
}
body.world-copy-page {
  background: var(--page);
}
body.world-copy-page :is(.brand, .back-link) {
  color: var(--accent-text);
}
body.world-copy-page :is(label, #copy-status) {
  color: var(--muted);
}
body.world-copy-page button {
  border: 1px solid var(--blue);
  border-radius: 6px;
  background: var(--blue);
  color: white;
  font-family: var(--body);
  font-weight: 600;
  box-shadow: none;
}
body.world-copy-page button:hover {
  background: var(--accent-hover);
}
body.world-copy-page button:active {
  transform: none;
  box-shadow: none;
}

@media (max-width: 767px) {
  body .flip-gain {
    background: #102a25;
  }
}
@media (max-width: 700px) {
  body .topbar-inner {
    gap: 10px;
  }
  body .mobile-nav {
    background: var(--surface);
    border-top: 1px solid var(--line);
    box-shadow: none;
  }
  body .mobile-nav :is(a, button) {
    color: var(--muted);
    font-weight: 500;
  }
  body .mobile-nav .is-active,
  body .mobile-nav [aria-current="page"] {
    background: var(--selected);
    color: var(--accent-text);
    box-shadow: inset 0 2px var(--blue);
  }
  body .seg button {
    min-height: 44px;
  }
}
@media (min-width: 701px) {
  body :is(.back-btn, .load-btn, .mini-btn) {
    min-height: 36px;
    padding-block: 7px;
  }
  body .seg button {
    min-height: 34px;
    padding: 6px 10px;
  }
}

/* Form labels and values follow the same compact type rhythm. */
body .collection-tools label,
body .flip-filters label,
body .flip-filters .flip-checkbox {
  font-weight: 500;
}
body select,
body.account-site select,
body .flip-filters select {
  font-weight: 400;
}

/* Dark market workspace: open headings, discovery tiles, compact toolbars. */
body .section-bar {
  padding: 12px 0;
  margin-bottom: 16px;
  border: 0;
  background: transparent;
}
body .market-heading h1,
body .page-heading h1,
body .flip-heading h1 {
  font-size: 34px;
  letter-spacing: -0.035em;
}
body .market-heading {
  margin-block: 20px 24px;
}
#item-search .landing-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}
#item-search .landing-links a:first-child {
  border-color: var(--border-strong);
  background: transparent;
}
#daily-quest .daily-quest-items {
  gap: 0;
}
#daily-quest .daily-quest-item + .daily-quest-item {
  border-top: 1px solid var(--line);
  border-radius: 0;
}
body .home-view .market-overview div {
  padding: 20px 24px;
}
body .home-view .market-overview div:first-child {
  padding-left: 0;
}
body .home-view .market-overview strong {
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.03em;
}
body .category-icon.tick {
  width: 48px;
  height: 48px;
  flex-basis: 48px;
}
body .category-icon img {
  width: 32px;
  height: 32px;
}
body .category-arrow {
  display: block;
  position: absolute;
  right: 20px;
  bottom: 20px;
  color: var(--muted);
  font-size: 18px;
}
body .category-card:hover {
  border-color: var(--border-strong);
}
body .item-card {
  padding: 16px;
  border-radius: 12px;
}
body .item-stack {
  border: 0;
  background: transparent;
  box-shadow: none;
}
body .trend {
  font-variant-numeric: tabular-nums;
  font-weight: 500;
}
body .quote-row .trend {
  background: transparent;
  padding-inline: 0;
}
body .market-controls {
  padding: 20px;
  border-radius: 14px;
}
body
  :is(
    .market-filter-row select,
    .listing-toolbar select,
    .listing-toolbar input,
    .calculator-body input
  ) {
  background: var(--surface-alt);
  border-color: var(--line);
  font-size: 14px;
}
body :is(.chart-panel, .market-info, .tool-panel, .listings-panel, .item-hero) {
  border-radius: 12px;
}
body .item-hero {
  padding: 22px 18px;
}
body .item-hero-price {
  font-size: 34px;
  letter-spacing: -0.035em;
}
body .item-hero-price .trend {
  letter-spacing: 0;
}
body .stat-value {
  font-size: 24px;
  font-weight: 500;
}
body .chart-title {
  padding: 10px 14px;
}
body :is(.account-error, .field-error) {
  color: var(--red);
  background: #30191f;
  border-color: #603039;
}
body .listing-feed {
  border-radius: 0 0 12px 12px;
}
body .notice-bar svg {
  stroke: var(--muted);
}
@media (min-width: 701px) {
  body .market-filter-row select {
    height: 40px;
  }
}
@media (max-width: 700px) {
  #item-search .landing-inner {
    padding: 8px 0 20px;
  }
  #search-title {
    margin-bottom: 24px;
    font-size: 32px;
  }
  body .section-bar h2 {
    font-size: 22px;
  }
  body .market-heading h1,
  body .page-heading h1,
  body .flip-heading h1 {
    font-size: 28px;
  }
  body .category-card {
    min-height: 136px;
    padding: 16px;
    gap: 14px;
  }
  body .category-card strong {
    font-size: 15px;
    padding-right: 14px;
  }
  body .category-arrow {
    right: 14px;
    bottom: 16px;
  }
  body .home-view .market-overview div {
    padding: 16px 10px;
  }
  body .home-view .market-overview strong {
    font-size: clamp(14px, 4.4vw, 22px);
  }
  body .home-view .market-overview span {
    font-size: 11px;
  }
  body .market-controls {
    padding: 14px;
  }
  body .item-hero-main h1 {
    font-size: 24px;
  }
  body .item-hero-price {
    font-size: 30px;
  }
}

/* Standalone pages and feedback states share the dark surface palette. */
body .legal-page article {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: none;
}
body .legal-page .legal-kicker {
  color: var(--muted);
  font-weight: 500;
  text-transform: none;
}
body.account-site #alerts-status {
  color: #e9c36b;
  background: #30281b;
  border: 1px solid #54472b;
}
body.account-site .account-error button {
  background: #30191f;
  color: var(--red);
  border-color: #603039;
}
#item-search input:focus-visible,
body .market-search input:focus-visible {
  outline: none;
}

/* Observed reference: neutral materials, plain controls, image-led opening.
   The requested panel lift uses grayscale edges and shadows only. */
:root {
  --panel-face: linear-gradient(180deg, #1d1d1d, #151515);
  --panel-edge: #3a3a3a;
  --panel-depth: inset 0 1px #ffffff0d, 0 2px 0 #050505, 0 10px 24px #0000004d;
}
body
  :is(
    .category-card,
    .item-card,
    .item-hero,
    .market-controls,
    .market-info,
    .chart-panel,
    .tool-panel,
    .listings-panel,
    .account-panel,
    .account-guest,
    .permission-summary,
    .flip-panel,
    .seo-catalogue,
    .world-card
  ) {
  border-color: var(--panel-edge);
  background: var(--panel-face);
  box-shadow: var(--panel-depth);
}
body .topbar {
  background: #0f0f0f;
}
body .category-icon.tick {
  background: #292929;
  border: 0;
  box-shadow: none;
}
body :is(.category-card, .item-card):hover {
  background: #232323;
  border-color: #555;
}
body .panel-title {
  background: #1d1d1d;
  border-bottom-color: var(--line);
  box-shadow: none;
}
#item-search {
  padding-block: 62px 72px;
  background: #0a0a0a;
  border: 0;
}
#item-search::before {
  content: "";
  display: block;
  position: absolute;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background: url("/_releases/10938ce4266214b76a0641de0a229d0298b782f9/static/market-horizon.png") center 64% / cover no-repeat;
  filter: saturate(0.4) brightness(0.8);
}
#item-search::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(180deg, #0a0a0a33, transparent 55%, #0a0a0a),
    linear-gradient(90deg, #00000080, #00000026 65%, #00000033);
}
#item-search .landing-inner {
  padding: 26px 24px 26px 0;
}
#search-title {
  margin-bottom: 28px;
  line-height: 1.16;
  letter-spacing: -0.035em;
}
#search-title svg {
  width: 30px;
  height: 30px;
}
#item-search .search-bar {
  height: 52px;
  background: #2e2e2e;
}
#item-search .search-go {
  height: 36px;
}
#item-search .landing-links {
  gap: 8px;
  margin-top: 20px;
}
#item-search .landing-links :is(a, button) {
  min-height: 40px;
  padding: 9px 14px;
  background: #292929;
  border-color: transparent;
  font-size: 13px;
}
#item-search .landing-links :is(a, button):hover {
  background: #3a3a3a;
  border-color: transparent;
}
#item-search .landing-links a:first-child {
  background: #f5f5f5;
  color: #111;
  font-weight: 600;
}
#item-search .landing-links a:first-child:hover {
  background: #dedede;
}
#daily-quest {
  border: 1px solid #454545;
  border-radius: 16px;
  background: var(--panel-face);
  box-shadow:
    inset 0 1px #ffffff14,
    0 3px 0 #050505,
    0 16px 32px #00000066;
}
#daily-quest .daily-quest-header {
  background: linear-gradient(180deg, #282828, #222);
  border-bottom: 1px solid #383838;
  border-radius: 15px 15px 0 0;
  box-shadow: inset 0 1px #ffffff14;
}
#daily-quest .daily-quest-panel {
  padding: 12px;
  background: transparent;
}
#daily-quest .daily-quest-items {
  gap: 8px;
}
#daily-quest .daily-quest-item,
#daily-quest .daily-quest-item + .daily-quest-item {
  border: 1px solid #383838;
  border-radius: 10px;
  background: #242424;
  box-shadow:
    inset 0 1px #ffffff08,
    0 2px 0 #0a0a0a;
}
#daily-quest .daily-quest-item:hover {
  background: #303030;
  border-color: #555;
}
#daily-quest .tick {
  background: #181818;
  border: 0;
  box-shadow: none;
}
@media (prefers-reduced-motion: no-preference) and (hover: hover) and (pointer: fine) {
  body :is(.category-card, .item-card),
  #daily-quest .daily-quest-item {
    transition:
      transform 140ms ease-out,
      border-color 140ms ease-out;
  }
  body :is(.category-card, .item-card):hover,
  #daily-quest .daily-quest-item:hover {
    transform: translateY(-2px);
  }
  body :is(.category-card, .item-card):active,
  #daily-quest .daily-quest-item:active {
    transform: translateY(0);
  }
}
@media (max-width: 700px) {
  #item-search {
    padding-block: 36px 44px;
  }
  #item-search::before {
    background-position: 30% center;
  }
  #item-search .landing-inner {
    padding: 6px 0 16px;
  }
  #search-title {
    font-size: 34px;
  }
}
@media (forced-colors: active) {
  body .logo b {
    color: LinkText;
  }
}
