:root {
  color-scheme: dark;
  --bg: #07111f;
  --bg-soft: #0d1a2d;
  --card: #101d33;
  --card-2: #0b1526;
  --line: #243753;
  --line-strong: #39527c;
  --text: #edf5ff;
  --muted: #9fb1cd;
  --blue: #6d8dff;
  --blue-2: #99b0ff;
  --green: #38d88d;
  --red: #ff687a;
  --yellow: #ffc857;
  --shadow: 0 24px 80px rgb(0 0 0 / 0.35);
  --radius: 28px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top right, rgb(84 116 255 / 0.22), transparent 34rem),
    radial-gradient(circle at 15% 20%, rgb(56 216 141 / 0.10), transparent 28rem),
    linear-gradient(180deg, #07111f, #050914 78%);
  color: var(--text);
}

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

button,
input,
select {
  font: inherit;
}

code {
  color: var(--blue-2);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  justify-content: space-between;
  padding: 1rem clamp(1rem, 4vw, 3rem);
  border-bottom: 1px solid rgb(255 255 255 / 0.08);
  background: rgb(7 17 31 / 0.86);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  min-width: max-content;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--blue), var(--green));
  color: #04111f;
  font-weight: 900;
  box-shadow: 0 0 28px rgb(109 141 255 / 0.32);
}

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

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

.nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
  justify-content: center;
}

.nav a {
  padding: 0.65rem 0.8rem;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.92rem;
}

.nav a:hover {
  color: var(--text);
  background: rgb(255 255 255 / 0.06);
}

.section {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 4.5rem 0 0;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(340px, 0.75fr);
  align-items: center;
  gap: 2rem;
  min-height: 620px;
  padding-top: 2.5rem;
}

.eyebrow {
  margin: 0 0 0.8rem;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 1.2rem;
  font-size: clamp(2.6rem, 6vw, 5.75rem);
  line-height: 0.96;
  letter-spacing: -0.07em;
}

h2 {
  margin-bottom: 0.8rem;
  font-size: clamp(1.8rem, 3vw, 2.7rem);
  line-height: 1;
  letter-spacing: -0.045em;
}

h3 {
  margin-bottom: 0.8rem;
  font-size: 1.15rem;
}

.hero-text,
.section-heading p,
.muted {
  color: var(--muted);
  line-height: 1.75;
}

.hero-actions,
.button-row {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.85rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.75rem 1.05rem;
  color: var(--text);
  background: rgb(255 255 255 / 0.04);
  cursor: pointer;
  transition: 160ms ease;
}

.button:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: rgb(255 255 255 / 0.08);
}

.button-primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--blue), #8ca3ff);
  color: #061120;
  font-weight: 850;
}

.button-secondary {
  background: rgb(109 141 255 / 0.13);
  color: var(--blue-2);
}

.button-full {
  width: 100%;
  margin-top: 1.1rem;
}

.grid-two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.2rem;
}

.card,
.hero-panel {
  border: 1px solid rgb(255 255 255 / 0.10);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgb(255 255 255 / 0.06), transparent),
    var(--card);
  box-shadow: var(--shadow);
}

.card {
  padding: clamp(1.2rem, 3vw, 2rem);
}

.compact {
  box-shadow: none;
}

.hero-panel {
  padding: 1.4rem;
}

.status-grid,
.wallet-card,
.rpc-grid,
.safety-grid,
.quote-meta {
  display: grid;
  gap: 0.9rem;
}

.status-grid,
.wallet-card,
.rpc-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.status-grid > div,
.wallet-card > div,
.rpc-grid > div,
.quote-meta > div {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  background: var(--card-2);
}

.metric-label,
.quote-meta span,
.rpc-grid span {
  display: block;
  margin-bottom: 0.32rem;
  color: var(--muted);
  font-size: 0.78rem;
}

.status-grid strong,
.wallet-card strong,
.rpc-grid strong,
.quote-meta strong {
  word-break: break-word;
}

.notice {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  color: var(--muted);
  background: rgb(255 255 255 / 0.035);
  line-height: 1.55;
}

.notice-safe {
  border-color: rgb(56 216 141 / 0.25);
  background: rgb(56 216 141 / 0.07);
}

.card-heading,
.section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.2rem;
}

.section-heading {
  display: block;
  max-width: 780px;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: max-content;
  border-radius: 999px;
  padding: 0.45rem 0.7rem;
  background: rgb(56 216 141 / 0.12);
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 800;
}

.pill-muted {
  background: rgb(255 255 255 / 0.07);
  color: var(--muted);
}

.pill-warning {
  background: rgb(255 200 87 / 0.12);
  color: var(--yellow);
}

.swap-form,
.mini-form {
  display: grid;
  gap: 1rem;
}

.swap-form label,
.mini-form label {
  display: grid;
  gap: 0.5rem;
  color: var(--muted);
}

.input-row {
  display: grid;
  grid-template-columns: 1fr 9rem;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 1.35rem;
  background: var(--card-2);
}

.input-row input,
.input-row select,
.mini-form input,
.mini-form select {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.input-row input {
  min-width: 0;
  padding: 1.05rem;
  font-size: 1.35rem;
  font-weight: 800;
}

.input-row select {
  border-left: 1px solid var(--line);
  padding: 0 0.85rem;
  color: var(--blue-2);
  font-weight: 800;
}

.flip-button {
  justify-self: center;
  width: 2.7rem;
  height: 2.7rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  color: var(--text);
  background: rgb(109 141 255 / 0.15);
  cursor: pointer;
}

.quote-meta {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.result-box {
  margin-top: 1rem;
  min-height: 4rem;
  padding: 1rem;
  border: 1px dashed var(--line-strong);
  border-radius: 1.2rem;
  color: var(--muted);
  background: rgb(7 17 31 / 0.55);
  white-space: pre-wrap;
}

.result-box.small {
  min-height: 0;
  font-size: 0.9rem;
}

.orderbook-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1.05fr;
  gap: 1.2rem;
}

.table-like {
  display: grid;
  gap: 0.55rem;
}

.order-row {
  display: grid;
  grid-template-columns: 1fr 1fr 0.8fr;
  gap: 0.65rem;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--card-2);
  font-size: 0.92rem;
}

.order-row span {
  color: var(--muted);
}

.price-green {
  color: var(--green);
}

.price-red {
  color: var(--red);
}

.mini-form {
  grid-template-columns: 1fr;
}

.mini-form input,
.mini-form select {
  padding: 0.85rem 1rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--card-2);
}

.route-list,
.timeline,
.checklist {
  display: grid;
  gap: 0.85rem;
}

.route {
  width: 100%;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  color: var(--text);
  text-align: left;
  background: var(--card-2);
  cursor: pointer;
}

.route span {
  display: block;
  margin-top: 0.35rem;
  color: var(--muted);
  line-height: 1.55;
}

.route.active {
  border-color: var(--blue);
  background: rgb(109 141 255 / 0.14);
}

.timeline-item {
  display: grid;
  grid-template-columns: 2rem 1fr;
  gap: 0.8rem;
  align-items: start;
}

.timeline-number {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  color: #07111f;
  background: var(--blue);
  font-weight: 900;
}

.console-output {
  overflow: auto;
  max-height: 330px;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  color: #c8d6ff;
  background: #030712;
  font-size: 0.83rem;
  line-height: 1.55;
}

.checklist {
  margin: 0;
  padding: 0;
  list-style: none;
}

.checklist li {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  color: var(--muted);
  line-height: 1.55;
}

.check {
  flex: 0 0 auto;
  width: 0.95rem;
  height: 0.95rem;
  margin-top: 0.27rem;
  border-radius: 999px;
  background: var(--yellow);
}

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

.safety-grid ul {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--muted);
  line-height: 1.8;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  width: min(1180px, calc(100% - 2rem));
  margin: 4rem auto 0;
  padding: 2rem 0;
  border-top: 1px solid rgb(255 255 255 / 0.09);
  color: var(--muted);
}

@media (max-width: 980px) {
  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
  }

  .hero,
  .grid-two,
  .orderbook-grid,
  .safety-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }
}

@media (max-width: 640px) {
  .section {
    width: min(100% - 1rem, 1180px);
    padding-top: 2.5rem;
  }

  .card,
  .hero-panel {
    border-radius: 1.25rem;
    padding: 1rem;
  }

  .nav {
    justify-content: flex-start;
  }

  .input-row,
  .quote-meta,
  .status-grid,
  .wallet-card,
  .rpc-grid {
    grid-template-columns: 1fr;
  }

  .footer {
    flex-direction: column;
  }
}

/* === 20260622-ui-polish-relay-history START === */

/*
  TracTrader frontend-only UI polish.
  Scope:
  - relay/history/detail/export readability
  - mobile form layout
  - safer JSON wrapping
  - no RPC/backend/nginx behavior changes
*/

#intentFilterForm,
#intentDetailForm {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 0.75rem;
  align-items: end;
}

#intentFilterForm label,
#intentDetailForm label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

#intentFilterForm input,
#intentFilterForm select,
#intentDetailForm input {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

#intentFilterForm .button,
#intentDetailForm .button,
#downloadIntentHistoryJson,
#copyIntentHistoryJson {
  white-space: normal;
}

#intentStatusOutput,
#intentRelayOutput,
#intentHistoryOutput,
#intentHistoryExportOutput,
#intentDetailOutput,
#tapDmtStatusOutput,
#tapDmtWalletOutput,
#releaseStatusOutput {
  max-height: 24rem;
  overflow: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
}

#intentStatusOutput,
#intentRelayOutput {
  max-height: 18rem;
}

#intentHistoryExportOutput,
#intentDetailOutput {
  max-height: 20rem;
}

.intent-history-export-note {
  margin-top: 0.75rem;
  margin-bottom: 0.5rem;
  max-width: 72rem;
  line-height: 1.45;
}

.intent-history-export-note code {
  white-space: nowrap;
}

#downloadIntentHistoryJson,
#copyIntentHistoryJson {
  margin-top: 0.35rem;
}

@media (max-width: 720px) {
  #intentFilterForm,
  #intentDetailForm {
    grid-template-columns: 1fr;
  }

  #intentStatusOutput,
  #intentRelayOutput,
  #intentHistoryOutput,
  #intentHistoryExportOutput,
  #intentDetailOutput,
  #tapDmtStatusOutput,
  #tapDmtWalletOutput,
  #releaseStatusOutput {
    max-height: 18rem;
  }
}

@media (max-width: 480px) {
  body {
    overflow-x: hidden;
  }

  #intentFilterForm .button,
  #intentDetailForm .button,
  #downloadIntentHistoryJson,
  #copyIntentHistoryJson {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .console-output {
    font-size: 0.82rem;
  }
}

/* === 20260622-ui-polish-relay-history END === */

/* === 20260622-intent-workspace-guide START === */

/*
  TracTrader frontend-only intent workspace guide.
  Scope:
  - clearer Preview relay / history scanning
  - clickable section chips
  - section headings for status, history, detail, and export
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

#intentWorkspaceGuide {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 0.75rem;
  margin: 1rem 0 1.1rem;
}

.intent-workspace-chip {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  padding: 0.85rem;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 1rem;
  text-decoration: none;
  color: inherit;
  background: rgba(15, 23, 42, 0.24);
}

.intent-workspace-chip:hover,
.intent-workspace-chip:focus {
  transform: translateY(-1px);
  border-color: rgba(148, 163, 184, 0.55);
  outline: none;
}

.intent-workspace-chip-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.38);
  font-weight: 700;
}

.intent-workspace-chip span:last-child {
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
  min-width: 0;
}

.intent-workspace-chip strong {
  font-size: 0.95rem;
  line-height: 1.15;
}

.intent-workspace-chip small {
  opacity: 0.78;
  line-height: 1.2;
}

.intent-workspace-heading {
  margin: 1.15rem 0 0.65rem;
  padding-top: 0.9rem;
  border-top: 1px solid rgba(148, 163, 184, 0.22);
}

.intent-workspace-heading h4 {
  margin: 0 0 0.3rem;
  font-size: 1rem;
}

.intent-workspace-heading p {
  margin: 0;
  opacity: 0.82;
  line-height: 1.45;
}

#intentStatusOutput:target,
#intentHistoryOutput:target,
#intentDetailOutput:target,
#intentHistoryExportOutput:target {
  outline: 2px solid rgba(148, 163, 184, 0.7);
  outline-offset: 4px;
}

@media (max-width: 540px) {
  #intentWorkspaceGuide {
    grid-template-columns: 1fr;
  }

  .intent-workspace-chip {
    padding: 0.75rem;
  }
}

/* === 20260622-intent-workspace-guide END === */

/* === 20260623-intent-workspace-safety-strip START === */

/*
  TracTrader frontend-only safety strip.
  Scope:
  - clearer preview-mode safety labels
  - beginner testing flow help text
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

#intentWorkspaceSafetyStrip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(155px, 1fr));
  gap: 0.75rem;
  margin: 0.6rem 0 1rem;
}

.intent-safety-pill {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  min-width: 0;
  padding: 0.82rem;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 0.95rem;
  background: rgba(15, 23, 42, 0.18);
}

.intent-safety-pill-label {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.72;
}

.intent-safety-pill strong {
  font-size: 0.98rem;
  line-height: 1.2;
}

.intent-safety-pill small {
  opacity: 0.78;
  line-height: 1.3;
}

#intentWorkspaceQuickStart {
  margin: 0.75rem 0 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 1rem;
  background: rgba(15, 23, 42, 0.14);
}

#intentWorkspaceQuickStart summary {
  cursor: pointer;
  font-weight: 700;
}

#intentWorkspaceQuickStart ol {
  margin: 0.75rem 0 0.65rem;
  padding-left: 1.25rem;
}

#intentWorkspaceQuickStart li {
  margin: 0.35rem 0;
  line-height: 1.42;
}

#intentWorkspaceQuickStart p {
  margin: 0.65rem 0 0;
  opacity: 0.82;
  line-height: 1.45;
}

@media (max-width: 540px) {
  #intentWorkspaceSafetyStrip {
    grid-template-columns: 1fr;
  }

  .intent-safety-pill {
    padding: 0.75rem;
  }

  #intentWorkspaceQuickStart {
    padding: 0.8rem;
  }
}

/* === 20260623-intent-workspace-safety-strip END === */

/* === 20260623-intent-workspace-output-guide START === */

/*
  TracTrader frontend-only output guide.
  Scope:
  - beginner help for reading preview JSON/output boxes
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

#intentWorkspaceOutputGuide {
  margin: 0.75rem 0 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 1rem;
  background: rgba(15, 23, 42, 0.14);
}

#intentWorkspaceOutputGuide summary {
  cursor: pointer;
  font-weight: 700;
}

.intent-output-guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 0.75rem;
  margin-top: 0.85rem;
}

.intent-output-guide-card {
  min-width: 0;
  padding: 0.8rem;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 0.9rem;
  background: rgba(15, 23, 42, 0.18);
}

.intent-output-guide-card strong {
  display: block;
  margin-bottom: 0.35rem;
  line-height: 1.2;
}

.intent-output-guide-card p {
  margin: 0;
  line-height: 1.42;
  opacity: 0.82;
}

.intent-output-guide-card code {
  white-space: nowrap;
}

.intent-output-guide-warning {
  margin: 0.85rem 0 0;
  line-height: 1.45;
  opacity: 0.86;
}

@media (max-width: 540px) {
  #intentWorkspaceOutputGuide {
    padding: 0.8rem;
  }

  .intent-output-guide-grid {
    grid-template-columns: 1fr;
  }

  .intent-output-guide-card code {
    white-space: normal;
    overflow-wrap: anywhere;
  }
}

/* === 20260623-intent-workspace-output-guide END === */

/* === 20260623-intent-console-captions START === */

/*
  TracTrader frontend-only console captions.
  Scope:
  - beginner-friendly labels above JSON/output boxes
  - improves accessibility with aria-describedby links
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

.intent-console-caption {
  margin: 0.75rem 0 0.35rem;
  line-height: 1.42;
  opacity: 0.84;
}

.intent-console-caption strong {
  opacity: 1;
}

.intent-console-caption + .console-output {
  margin-top: 0.25rem;
}

@media (max-width: 540px) {
  .intent-console-caption {
    font-size: 0.92rem;
  }
}

/* === 20260623-intent-console-captions END === */

/* === 20260623-intent-console-copy-buttons START === */

/*
  TracTrader frontend-only console copy buttons.
  Scope:
  - copy visible public-safe output boxes
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

.intent-console-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  margin: 0.25rem 0 0.4rem;
}

.intent-console-copy-button {
  min-width: 0;
}

.intent-console-copy-status {
  font-size: 0.9rem;
  opacity: 0.78;
  line-height: 1.3;
}

@media (max-width: 540px) {
  .intent-console-actions {
    align-items: stretch;
  }

  .intent-console-copy-button {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .intent-console-copy-status {
    width: 100%;
  }
}

/* === 20260623-intent-console-copy-buttons END === */

/* === 20260623-intent-console-download-buttons START === */

/*
  TracTrader frontend-only console download buttons.
  Scope:
  - download visible public-safe output boxes
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

.intent-console-download-button {
  min-width: 0;
}

.intent-console-copy-button,
.intent-console-download-button {
  white-space: normal;
}

@media (max-width: 540px) {
  .intent-console-copy-button,
  .intent-console-download-button {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
}

/* === 20260623-intent-console-download-buttons END === */

/* === 20260623-intent-console-collapse-buttons START === */

/*
  TracTrader frontend-only console collapse buttons.
  Scope:
  - collapse or expand visible public-safe output boxes
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

.intent-console-toggle-button {
  min-width: 0;
  white-space: normal;
}

.console-output.intent-console-output-hidden {
  display: none;
}

.intent-console-collapsed-note {
  margin: 0.35rem 0 0.7rem;
  font-size: 0.9rem;
  opacity: 0.78;
  line-height: 1.35;
}

@media (max-width: 540px) {
  .intent-console-toggle-button {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
}

/* === 20260623-intent-console-collapse-buttons END === */

/* === 20260623-intent-console-bulk-controls START === */

/*
  TracTrader frontend-only console bulk controls.
  Scope:
  - collapse or expand all visible public-safe output boxes
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

#intentConsoleBulkActions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  align-items: center;
  margin: 0.75rem 0 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 1rem;
  background: rgba(15, 23, 42, 0.14);
}

.intent-console-bulk-copy {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.intent-console-bulk-copy span {
  opacity: 0.8;
  line-height: 1.35;
}

.intent-console-bulk-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  justify-content: flex-end;
}

.intent-console-bulk-button {
  white-space: normal;
}

.intent-console-bulk-status {
  grid-column: 1 / -1;
  min-height: 1.2em;
  font-size: 0.9rem;
  opacity: 0.78;
  line-height: 1.3;
}

@media (max-width: 720px) {
  #intentConsoleBulkActions {
    grid-template-columns: 1fr;
  }

  .intent-console-bulk-buttons {
    justify-content: stretch;
  }

  .intent-console-bulk-button {
    flex: 1 1 12rem;
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 540px) {
  .intent-console-bulk-button {
    width: 100%;
    flex-basis: 100%;
  }
}

/* === 20260623-intent-console-bulk-controls END === */

/* === 20260623-intent-console-output-bundle START === */

/*
  TracTrader frontend-only output bundle controls.
  Scope:
  - copy/download current browser output boxes as one public-safe support bundle
  - no backend, RPC, nginx, settlement, transfer, or broadcast changes
*/

.intent-console-bundle-button {
  white-space: normal;
}

@media (max-width: 540px) {
  .intent-console-bundle-button {
    width: 100%;
    flex-basis: 100%;
    justify-content: center;
    text-align: center;
  }
}

/* === 20260623-intent-console-output-bundle END === */

/* === 20260626-output-bundle-privacy-note START === */

/*
  TracTrader frontend-only output bundle privacy note.
  This explains browser-visible bundle contents.
  It does not change backend, RPC, settlement, transfer, or broadcast behavior.
*/

#intentConsoleBundlePrivacyNote,
#intentConsoleBundleContentsGuide {
  grid-column: 1 / -1;
}

.intent-console-bundle-note {
  margin: 0.25rem 0 0;
  padding-top: 0.7rem;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  line-height: 1.45;
  opacity: 0.84;
}

.intent-console-bundle-note strong {
  opacity: 1;
}

.intent-console-bundle-contents-guide {
  margin: 0.35rem 0 0;
  padding: 0.7rem 0.8rem;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 0.85rem;
  background: rgba(15, 23, 42, 0.12);
}

.intent-console-bundle-contents-guide summary {
  cursor: pointer;
  font-weight: 700;
}

.intent-console-bundle-contents-guide ul {
  margin: 0.65rem 0 0.45rem;
  padding-left: 1.25rem;
}

.intent-console-bundle-contents-guide li {
  margin: 0.25rem 0;
  line-height: 1.35;
}

.intent-console-bundle-contents-guide p {
  margin: 0.55rem 0 0;
  opacity: 0.82;
  line-height: 1.4;
}

@media (max-width: 540px) {
  .intent-console-bundle-note,
  .intent-console-bundle-contents-guide {
    font-size: 0.92rem;
  }

  .intent-console-bundle-contents-guide {
    padding: 0.65rem;
  }
}

/* === 20260626-output-bundle-privacy-note END === */

/* === 20260626-trac-wallet-r1-readiness START === */

/*
  TracTrader frontend-only TRAC Wallet API and R1 readiness panel.
  Wallet methods are detected by property inspection only.
  No wallet method, transfer, signing or broadcast action is called.
*/

.trac-readiness-section {
  scroll-margin-top: 1rem;
}

.trac-readiness-header {
  margin-bottom: 1rem;
}

.trac-readiness-header h2 {
  margin-bottom: 0.45rem;
}

.trac-readiness-header p:last-child {
  max-width: 72rem;
  margin-bottom: 0;
  line-height: 1.5;
  opacity: 0.82;
}

.trac-readiness-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.trac-readiness-card {
  min-width: 0;
}

.trac-readiness-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.9rem;
  margin-bottom: 0.9rem;
}

.trac-readiness-card-header h3 {
  margin: 0 0 0.3rem;
}

.trac-readiness-card-header p {
  margin: 0;
  line-height: 1.4;
  opacity: 0.8;
}

.trac-wallet-capability-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.trac-wallet-capability {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.7rem;
  min-width: 0;
  padding: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 0.85rem;
  background: rgba(15, 23, 42, 0.14);
}

.trac-wallet-capability > div {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.trac-wallet-capability small {
  line-height: 1.3;
  overflow-wrap: anywhere;
  opacity: 0.76;
}

.trac-readiness-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-height: 1.8rem;
  padding: 0.25rem 0.55rem;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 999px;
  font-size: 0.78rem;
  line-height: 1.2;
  text-align: center;
}

.trac-readiness-pill.is-safe {
  border-color: rgba(74, 222, 128, 0.45);
  background: rgba(22, 101, 52, 0.16);
}

.trac-readiness-pill.is-ready {
  border-color: rgba(56, 189, 248, 0.48);
  background: rgba(3, 105, 161, 0.16);
}

.trac-readiness-pill.is-review {
  border-color: rgba(250, 204, 21, 0.4);
  background: rgba(133, 77, 14, 0.14);
}

.trac-readiness-pill.is-gated {
  border-color: rgba(248, 113, 113, 0.42);
  background: rgba(127, 29, 29, 0.14);
}

.trac-readiness-pill.is-unavailable {
  opacity: 0.72;
}

.trac-readiness-safety-note {
  margin: 0.85rem 0 0.6rem;
  line-height: 1.45;
  opacity: 0.82;
}

#tracWalletApiOutput {
  max-height: 24rem;
  overflow: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.trac-r1-checklist {
  display: grid;
  gap: 0.65rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.trac-r1-checklist li {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.8rem;
  padding: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 0.85rem;
  background: rgba(15, 23, 42, 0.12);
}

.trac-r1-checklist li > div {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.trac-r1-checklist small {
  line-height: 1.35;
  opacity: 0.78;
}

@media (max-width: 900px) {
  .trac-readiness-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .trac-readiness-card-header {
    flex-direction: column;
  }

  #scanTracWalletApi {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .trac-wallet-capability-grid {
    grid-template-columns: 1fr;
  }

  .trac-wallet-capability,
  .trac-r1-checklist li {
    flex-direction: column;
  }

  .trac-readiness-pill {
    align-self: flex-start;
  }
}

/* === 20260626-trac-wallet-r1-readiness END === */
