/* SUNDEX transaction system p28 — compact material split, built around the task. */
body.sundex-transaction-system {
  --tx-bg: #020407;
  --tx-panel: #070b10;
  --tx-panel-raised: #0b1017;
  --tx-field: #060a0f;
  --tx-ink: #f2f5f9;
  --tx-text: #d6dee8;
  --tx-muted: #98a4b3;
  --tx-dim: #6f7b8b;
  --tx-line: rgba(197, 211, 229, 0.11);
  --tx-line-strong: rgba(197, 211, 229, 0.2);
  --tx-metal: #bacbe0;
  --tx-danger: #d99aa5;
  --tx-ease: cubic-bezier(0.22, 1, 0.36, 1);
  background: var(--tx-bg) !important;
}

body.sundex-transaction-system .platform-main {
  padding: 28px 24px 64px !important;
  background: var(--tx-bg) !important;
  scrollbar-gutter: stable;
}

/* The page is deliberately smaller than the viewport: a task, not a hero. */
body.sundex-transaction-system .stx-shell {
  position: relative;
  isolation: isolate;
  display: grid !important;
  width: min(1120px, 100%) !important;
  max-width: 1120px !important;
  min-height: 520px !important;
  margin: 0 auto !important;
  padding: 0 !important;
  grid-template-columns: minmax(400px, 2fr) minmax(620px, 3fr);
  grid-template-rows: max-content max-content max-content;
  grid-template-areas:
    ". head"
    ". progress"
    ". stage";
  column-gap: 20px;
  align-content: start;
  align-items: start;
  overflow: visible !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* One material plane, no card-inside-card. */
body.sundex-transaction-system .stx-context {
  grid-area: auto;
  position: absolute;
  top: 0;
  left: 0;
  width: calc((100% - 20px) * 0.4);
  height: 520px;
  min-width: 0;
  min-height: 520px;
  overflow: hidden;
  border: 1px solid var(--tx-line);
  border-radius: 28px;
  color: var(--tx-text);
  background: #05080c;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28), inset 0 1px rgba(255, 255, 255, 0.035);
}

body.sundex-transaction-system .stx-context::before {
  content: "";
  position: absolute;
  inset: -22% -45% 35% -25%;
  border-radius: 50%;
  background:
    repeating-radial-gradient(ellipse at 70% 72%, transparent 0 20px, rgba(177, 201, 230, 0.032) 21px 22px),
    radial-gradient(ellipse at 68% 68%, rgba(80, 108, 143, 0.13), transparent 58%);
  transform: rotate(-10deg);
}

body.sundex-transaction-system .stx-context::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 28%, rgba(2, 4, 7, 0.18) 48%, rgba(2, 4, 7, 0.92) 78%);
}

body.sundex-transaction-system .stx-material-object {
  position: absolute;
  inset: 0;
  height: auto;
  overflow: hidden;
  border: 0;
  border-radius: inherit;
  background:
    linear-gradient(124deg, rgba(255, 255, 255, 0.025), transparent 28% 76%, rgba(165, 192, 224, 0.035)),
    repeating-linear-gradient(116deg, transparent 0 27px, rgba(185, 207, 234, 0.022) 28px 29px),
    linear-gradient(145deg, #0b1119, #05080d 62%, #020406);
  box-shadow: none;
  transform: none;
}

body.sundex-transaction-system .stx-material-object::after {
  content: "";
  position: absolute;
  top: 44%;
  right: -8%;
  width: 88%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(183, 207, 236, 0.42), transparent);
  box-shadow: 0 0 20px rgba(124, 164, 213, 0.16);
  transform: rotate(-7deg);
}

body.sundex-transaction-system .stx-material-brand {
  position: absolute;
  top: 25px;
  left: 27px;
  color: rgba(238, 244, 251, 0.78);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.13em;
}

body.sundex-transaction-system .stx-material-object i {
  display: none;
}

body.sundex-transaction-system .stx-material-object b {
  position: absolute;
  top: 26px;
  right: 27px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(198, 218, 242, 0.8);
  box-shadow: 0 0 14px rgba(151, 190, 237, 0.45);
}

body.sundex-transaction-system .stx-context-copy {
  position: absolute;
  z-index: 1;
  right: 30px;
  bottom: 31px;
  left: 30px;
}

body.sundex-transaction-system .stx-context-label {
  display: block;
  margin: 0 0 11px;
  color: var(--tx-metal);
  font-size: 12px;
  font-weight: 560;
}

body.sundex-transaction-system .stx-context-title {
  max-width: 11ch;
  margin: 0;
  color: var(--tx-ink);
  font-size: 40px;
  font-weight: 620;
  line-height: 1.01;
  letter-spacing: -0.038em;
  text-wrap: balance;
}

body.sundex-transaction-system .stx-context-body {
  max-width: 33ch;
  margin: 18px 0 0;
  color: var(--tx-muted);
  font-size: 13px;
  line-height: 1.55;
  text-wrap: pretty;
}

body.sundex-transaction-system .stx-context-rows {
  display: none !important;
}

/* One quiet working surface on the right. */
body.sundex-transaction-system .stx-ticket-frame {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: -1;
  width: calc((100% - 20px) * 0.6);
  min-height: 0;
  pointer-events: none;
  border: 1px solid var(--tx-line-strong);
  border-radius: 28px;
  background: linear-gradient(145deg, #080d14, #05080c 72%);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.32), inset 0 1px rgba(255, 255, 255, 0.035);
  clip-path: none;
}

body.sundex-transaction-system .stx-head {
  grid-area: head;
  display: flex !important;
  min-width: 0;
  min-height: 72px;
  align-items: center !important;
  gap: 14px !important;
  margin: 0 !important;
  padding: 20px 28px 10px !important;
}

body.sundex-transaction-system .stx-head > div {
  min-width: 0;
  flex-wrap: nowrap !important;
  gap: 10px !important;
}

body.sundex-transaction-system .stx-funding-shell .stx-head > div > div:first-child {
  display: none !important;
}

body.sundex-transaction-system .stx-head h1 {
  color: var(--tx-ink) !important;
  font-size: 21px !important;
  font-weight: 620 !important;
  line-height: 1.15;
  letter-spacing: -0.025em;
}

body.sundex-transaction-system .stx-head > button {
  width: 40px !important;
  height: 40px !important;
  flex: 0 0 40px;
  padding: 0 !important;
  border: 1px solid var(--tx-line) !important;
  border-radius: 12px !important;
  color: var(--tx-text) !important;
  background: rgba(213, 225, 240, 0.035) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.035) !important;
}

body.sundex-transaction-system .stx-step-meta {
  margin-left: 2px;
  color: var(--tx-muted);
  font-size: 12px;
  font-weight: 460;
  white-space: nowrap;
}

body.sundex-transaction-system .stx-progress,
body.sundex-transaction-system .stx-head + div:has(> .stx-progress) {
  grid-area: progress;
}

body.sundex-transaction-system .stx-head + div:has(> .stx-progress) {
  margin: 0 !important;
  padding: 0 28px 13px !important;
}

body.sundex-transaction-system .stx-progress {
  display: flex !important;
  width: 100%;
  min-width: 0;
  flex-direction: row !important;
  align-items: flex-start !important;
  gap: 8px !important;
  margin: 0 !important;
  padding: 0 28px 13px !important;
}

body.sundex-transaction-system div:has(> .stx-progress) > .stx-progress {
  padding: 0 !important;
}

body.sundex-transaction-system .stx-progress > div {
  display: flex !important;
  min-width: 0;
  min-height: 30px !important;
  flex: 1 1 0 !important;
  flex-direction: column !important;
  align-items: flex-start !important;
  gap: 6px !important;
}

body.sundex-transaction-system .stx-progress > div > div:first-child {
  width: 100% !important;
  height: 2px !important;
  flex: none !important;
  overflow: hidden;
  border-radius: 99px !important;
  background: #151b23 !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-progress > div > div:first-child > div {
  display: block !important;
  height: 100% !important;
  border-radius: inherit;
  background: var(--tx-metal) !important;
}

body.sundex-transaction-system .stx-progress > div::after {
  display: none !important;
}

body.sundex-transaction-system .stx-progress > div > span {
  max-width: 100%;
  overflow: hidden;
  color: var(--tx-dim) !important;
  font-size: 10px !important;
  font-weight: 510 !important;
  letter-spacing: 0 !important;
  text-overflow: ellipsis;
  text-transform: none !important;
  white-space: nowrap;
}

body.sundex-transaction-system .stx-progress > div.stx-is-current > span {
  color: var(--tx-text) !important;
  font-weight: 600 !important;
}

body.sundex-transaction-system .stx-progress > div.stx-is-complete > span {
  color: rgba(186, 203, 224, 0.68) !important;
}

body.sundex-transaction-system .stx-stage {
  grid-area: stage;
  min-width: 0;
  min-height: 0;
  margin: 0 !important;
  overflow: visible !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-stage > div {
  width: 100% !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 13px 28px 30px !important;
}

body.sundex-transaction-system .buy-sell-intro,
body.sundex-transaction-system .stx-stage .text-center {
  margin: 0 0 22px !important;
  text-align: left !important;
}

body.sundex-transaction-system .buy-sell-intro > small,
body.sundex-transaction-system .buy-sell-option-copy > small {
  display: none !important;
}

body.sundex-transaction-system .buy-sell-intro h2,
body.sundex-transaction-system .stx-stage h2 {
  margin: 0;
  color: var(--tx-ink) !important;
  font-size: 22px !important;
  font-weight: 610 !important;
  line-height: 1.18;
  letter-spacing: -0.025em;
}

body.sundex-transaction-system .buy-sell-intro p,
body.sundex-transaction-system .stx-stage h2 + p {
  margin-top: 7px !important;
  color: var(--tx-muted) !important;
  font-size: 13px !important;
  line-height: 1.5;
}

/* Funding method and coin rows are compact controls, not presentation cards. */
body.sundex-transaction-system .buy-sell-options {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px !important;
}

body.sundex-transaction-system .buy-sell-intro {
  grid-column: 1 / -1;
}

body.sundex-transaction-system .buy-sell-option,
body.sundex-transaction-system .stx-stage button.group {
  min-width: 0;
  min-height: 82px !important;
  gap: 13px !important;
  padding: 15px 16px !important;
  border: 1px solid var(--tx-line) !important;
  border-radius: 17px !important;
  color: var(--tx-text) !important;
  background: var(--tx-panel-raised) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.028) !important;
  transition: border-color 180ms var(--tx-ease), background-color 180ms var(--tx-ease), transform 180ms var(--tx-ease) !important;
}

body.sundex-transaction-system .buy-sell-option.signature-ring {
  border-color: rgba(194, 214, 239, 0.43) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.035) !important;
}

body.sundex-transaction-system .buy-sell-icon,
body.sundex-transaction-system .stx-stage button.group > .w-14 {
  width: 40px !important;
  height: 40px !important;
  flex: 0 0 40px;
  border: 0 !important;
  border-radius: 12px !important;
  color: var(--tx-metal) !important;
  background: rgba(184, 203, 224, 0.055) !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .buy-sell-option-copy strong,
body.sundex-transaction-system .stx-stage button.group p.font-bold {
  color: var(--tx-ink) !important;
  font-size: 14px !important;
  font-weight: 610 !important;
}

body.sundex-transaction-system .buy-sell-option-copy p,
body.sundex-transaction-system .stx-stage button.group p.text-muted-foreground {
  color: var(--tx-muted) !important;
  font-size: 12px !important;
  line-height: 1.4;
}

body.sundex-transaction-system .buy-sell-arrow {
  margin-left: auto;
  color: var(--tx-dim) !important;
}

body.sundex-transaction-system .stx-order-form {
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-order-form label,
body.sundex-transaction-system .stx-stage label {
  color: var(--tx-text) !important;
  font-size: 12px !important;
  font-weight: 560 !important;
}

body.sundex-transaction-system .stx-order-form > div:has(> label) > div > button,
body.sundex-transaction-system .stx-stage input,
body.sundex-transaction-system .stx-stage select {
  min-height: 54px !important;
  border: 1px solid var(--tx-line) !important;
  border-radius: 14px !important;
  color: var(--tx-ink) !important;
  background: var(--tx-field) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.025) !important;
}

body.sundex-transaction-system .stx-stage input::placeholder {
  color: #9ca8b7 !important;
  opacity: 1;
}

/* Deposit amount: remove the nested card and restore normal control scale. */
body.sundex-transaction-system .stx-funding-shell .stx-stage .space-y-5 > .flex.items-center.justify-center:has(> img) {
  justify-content: flex-start !important;
  padding: 4px 0 2px !important;
}

body.sundex-transaction-system .stx-funding-shell .stx-stage .space-y-5 > .bg-card {
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-funding-shell .stx-stage .space-y-5 > .bg-card input {
  height: 64px !important;
  min-height: 64px !important;
  padding: 0 18px !important;
  border: 1px solid var(--tx-line-strong) !important;
  border-radius: 15px !important;
  background: var(--tx-field) !important;
  color: var(--tx-ink) !important;
  font-size: 30px !important;
  font-weight: 560 !important;
  line-height: 1 !important;
  text-align: left !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.025) !important;
}

body.sundex-transaction-system .stx-funding-shell .stx-stage .space-y-5 > .bg-card p {
  margin-top: 10px !important;
  color: var(--tx-muted) !important;
  text-align: left !important;
}

body.sundex-transaction-system .stx-funding-shell .stx-stage .bg-destructive\/5 {
  padding: 3px 2px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-funding-shell .stx-stage .bg-destructive\/5 p,
body.sundex-transaction-system .stx-funding-shell .stx-stage .bg-destructive\/5 svg {
  color: var(--tx-danger) !important;
}

body.sundex-transaction-system .stx-quick-assets {
  display: flex !important;
  min-height: 40px;
  align-items: center;
  gap: 7px !important;
}

body.sundex-transaction-system .stx-quick-label {
  margin-right: 4px;
  color: var(--tx-dim);
  font-size: 11px;
}

body.sundex-transaction-system .stx-quick-assets > button {
  min-width: 58px;
  min-height: 40px !important;
  justify-content: center;
  border: 1px solid var(--tx-line) !important;
  border-radius: 12px !important;
  background: var(--tx-panel-raised) !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-quick-assets > button[aria-pressed="true"] {
  border-color: rgba(194, 214, 239, 0.46) !important;
}

body.sundex-transaction-system .stx-quick-overflow {
  display: none !important;
}

/* Dark material CTA: same vocabulary as the header controls. */
body.sundex-transaction-system .stx-stage button.w-full.rounded-full,
body.sundex-transaction-system .stx-stage button.w-full.py-3,
body.sundex-transaction-system .stx-order-form > button:last-of-type,
body.sundex-transaction-system .stx-swap-ticket > button:not(.stx-quick-assets button) {
  min-height: 52px !important;
  border: 1px solid transparent !important;
  border-radius: 15px !important;
  color: var(--tx-ink) !important;
  background:
    linear-gradient(180deg, #0d131b, #070b10) padding-box,
    linear-gradient(130deg, #aebdce, #313b47 36%, #77879a 70%, #c4d1df) border-box !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.055), 0 10px 26px rgba(0, 0, 0, 0.22) !important;
  font-size: 14px !important;
  font-weight: 620 !important;
}

body.sundex-transaction-system button:disabled {
  border-color: var(--tx-line) !important;
  color: rgba(214, 222, 232, 0.38) !important;
  background: #0b1017 !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.02) !important;
  opacity: 1 !important;
}

body.sundex-product-surface.sundex-transaction-system .stx-stage button:disabled {
  justify-content: center !important;
  padding: 0 18px !important;
  border-color: var(--tx-line) !important;
  color: rgba(214, 222, 232, 0.38) !important;
  background: #0b1017 !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.02) !important;
}

body.sundex-transaction-system .stx-disabled-reason {
  margin: -1px 0 0;
  color: var(--tx-dim);
  font-size: 11px;
  line-height: 1.4;
  text-align: center;
}

body.sundex-transaction-system :where(button, a):focus-visible {
  outline: 2px solid rgba(219, 231, 246, 0.82) !important;
  outline-offset: 3px !important;
}

body.sundex-transaction-system.sundex-funding-flow .stx-stage :where(input, select, textarea):focus-visible,
body.sundex-transaction-system.stx-buy-sell-route .stx-stage :where(input, select, textarea):focus-visible {
  outline: 2px solid transparent !important;
  outline-offset: 0 !important;
  border-color: rgba(194, 214, 239, 0.34) !important;
  box-shadow: 0 0 0 2px rgba(160, 185, 216, 0.08), inset 0 1px rgba(255, 255, 255, 0.025) !important;
}

/* Swap uses the same compact split without an additional page card. */
body.stx-swap-route .stx-swap-main {
  width: min(1120px, 100%);
  margin-inline: auto;
}

body.stx-swap-route .sundex-swap-page-head {
  width: min(760px, calc(100% - 360px));
  margin: 0 0 10px auto;
}

body.stx-swap-route .stx-swap-layout {
  display: grid !important;
  min-height: 520px;
  grid-template-columns: minmax(400px, 2fr) minmax(620px, 3fr);
  align-items: stretch !important;
  justify-content: stretch !important;
  gap: 20px;
  padding: 0 !important;
}

body.stx-swap-route .stx-swap-layout > .stx-context {
  position: relative;
  top: auto;
  left: auto;
  grid-area: auto;
  grid-column: 1;
  grid-row: 1;
  width: auto;
  height: auto;
  min-height: 520px;
}

body.stx-swap-route .stx-swap-ticket {
  grid-column: 2;
  grid-row: 1;
  align-self: stretch;
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 28px !important;
  border: 1px solid var(--tx-line-strong) !important;
  border-radius: 28px !important;
  background: linear-gradient(145deg, #080d14, #05080c 72%) !important;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.32), inset 0 1px rgba(255, 255, 255, 0.035) !important;
  clip-path: none !important;
}

body.stx-swap-route .stx-swap-ticket > .rounded-2xl {
  padding: 18px !important;
  border: 1px solid var(--tx-line) !important;
  border-radius: 18px !important;
  background: var(--tx-field) !important;
  box-shadow: none !important;
}

body.stx-swap-route .stx-swap-ticket .uppercase {
  font-size: 12px !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
}

/* Transaction dialogs use one stable shell so steps never jump on change. */
.stx-dialog {
  width: min(680px, calc(100vw - 32px)) !important;
  max-width: 680px !important;
  height: min(620px, calc(100dvh - 32px)) !important;
  min-height: 0 !important;
  max-height: calc(100dvh - 32px) !important;
  padding: 0 !important;
  border: 1px solid var(--tx-line-strong) !important;
  border-radius: 24px !important;
  color: var(--tx-text) !important;
  background: #070b10 !important;
  box-shadow: 0 36px 100px rgba(0, 0, 0, 0.58), inset 0 1px rgba(255, 255, 255, 0.035) !important;
  overflow: hidden !important;
  transform: translate(-50%, -50%) !important;
  transform-origin: 50% 46% !important;
  will-change: transform, opacity;
}

.stx-dialog[data-state="open"] {
  animation: stx-dialog-enter 220ms cubic-bezier(0.22, 1, 0.36, 1) both !important;
}

.stx-dialog[data-state="closed"] {
  animation: stx-dialog-exit 150ms cubic-bezier(0.4, 0, 1, 1) both !important;
}

.stx-dialog:focus,
.stx-dialog:focus-visible {
  outline: none !important;
}

@keyframes stx-dialog-enter {
  from {
    opacity: 0;
    transform: translate(-50%, calc(-50% + 10px)) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

@keyframes stx-dialog-exit {
  from {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
  to {
    opacity: 0;
    transform: translate(-50%, calc(-50% + 6px)) scale(0.99);
  }
}

.stx-dialog > .stx-dialog-header {
  flex: 0 0 auto !important;
  padding: 18px 22px 8px !important;
}

.stx-dialog > .stx-dialog-content {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.stx-dialog > .stx-dialog-content > div {
  animation: stx-dialog-step-enter 180ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes stx-dialog-step-enter {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.stx-verification-dialog .stx-dialog-header > div:first-child {
  margin-bottom: 14px !important;
}

.stx-verification-dialog .stx-progress {
  gap: 8px !important;
}

.stx-verification-info .stx-dialog-content > div {
  height: 100% !important;
  min-height: 0 !important;
  padding: 22px 26px 20px !important;
}

.stx-verification-info .stx-dialog-content > div > div:first-child {
  justify-content: center !important;
}

.stx-verification-info .stx-dialog-content > div > div:first-child > div:first-child {
  width: 82px !important;
  height: 82px !important;
  margin-bottom: 18px !important;
}

.stx-verification-info .stx-dialog-content > div > div:first-child > div:first-child > div {
  border-radius: 22px !important;
}

.stx-verification-info .stx-dialog-content h3 {
  margin-bottom: 10px !important;
  font-size: 23px !important;
  line-height: 1.2 !important;
}

.stx-verification-info .stx-dialog-content h3 ~ p {
  max-width: 500px !important;
  margin-bottom: 10px !important;
  font-size: 13px !important;
  line-height: 1.55 !important;
}

.stx-verification-info .stx-dialog-content > div > div:last-child {
  padding-top: 14px !important;
}

.stx-verification-info .stx-dialog-content > div > div:last-child > button:first-child {
  height: 50px !important;
  border-radius: 14px !important;
}

.stx-verification-info .stx-dialog-content > div > div:last-child > button:last-child {
  height: 36px !important;
}

.stx-verification-coin .stx-dialog-content > div {
  display: flex !important;
  height: 100% !important;
  min-height: 0 !important;
  flex-direction: column !important;
  padding: 24px 26px !important;
}

.stx-verification-coin .stx-dialog-content > div > button:last-of-type {
  margin-top: auto !important;
}

@media (max-width: 700px) {
  .stx-dialog {
    width: calc(100vw - 16px) !important;
    height: min(620px, calc(100dvh - 16px)) !important;
    max-height: calc(100dvh - 16px) !important;
    border-radius: 20px !important;
  }

  .stx-dialog > .stx-dialog-header {
    padding: 16px 16px 8px !important;
  }

  .stx-verification-info .stx-dialog-content > div,
  .stx-verification-coin .stx-dialog-content > div {
    padding: 18px 16px !important;
  }
}

@media (hover: hover) and (pointer: fine) {
  body.sundex-transaction-system .buy-sell-option:hover,
  body.sundex-transaction-system .stx-stage button.group:hover {
    border-color: rgba(197, 211, 229, 0.22) !important;
    background: #0d131b !important;
    transform: translateY(-1px);
  }

  body.sundex-transaction-system .stx-stage button:not(:disabled):hover,
  body.sundex-transaction-system .stx-head > button:hover {
    filter: brightness(1.08);
  }
}

body.sundex-transaction-system button:active,
body.sundex-transaction-system a:active {
  transform: scale(0.985);
}

@media (max-width: 1100px) {
  body.sundex-transaction-system .platform-main {
    padding: 20px 16px 44px !important;
  }

  body.sundex-transaction-system .stx-shell,
  body.stx-swap-route .stx-swap-layout {
    width: min(720px, 100%) !important;
    min-height: 0 !important;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: max-content max-content max-content;
    grid-template-areas: "head" "progress" "stage";
    gap: 0;
  }

  body.sundex-transaction-system .stx-context {
    display: none !important;
  }

  body.sundex-transaction-system .stx-ticket-frame {
    right: 0;
    left: 0;
    width: auto;
    min-height: 0;
    border-radius: 24px;
  }

  body.stx-swap-route .sundex-swap-page-head {
    width: min(720px, 100%);
    margin: 0 auto 10px;
  }

  body.stx-swap-route .stx-swap-layout {
    display: block !important;
    min-height: 0 !important;
  }

  body.stx-swap-route .stx-swap-ticket {
    padding: 26px !important;
    border-radius: 24px !important;
  }
}

@media (max-width: 620px) {
  body.sundex-transaction-system .platform-main {
    padding: 10px 8px 28px !important;
  }

  body.sundex-transaction-system .stx-ticket-frame {
    border-radius: 20px;
  }

  body.sundex-transaction-system .stx-head {
    min-height: 62px;
    padding: 15px 16px 8px !important;
  }

  body.sundex-transaction-system .stx-head h1 {
    font-size: 19px !important;
  }

  body.sundex-transaction-system .stx-step-meta {
    margin-left: auto;
    font-size: 11px;
  }

  body.sundex-transaction-system .stx-head + div:has(> .stx-progress) {
    padding: 0 16px 10px !important;
  }

  body.sundex-transaction-system .stx-progress {
    padding: 0 16px 10px !important;
  }

  body.sundex-transaction-system div:has(> .stx-progress) > .stx-progress {
    padding: 0 !important;
  }

  body.sundex-transaction-system .stx-progress > div > span {
    font-size: 9px !important;
  }

  body.sundex-transaction-system .stx-stage > div {
    padding: 12px 16px 26px !important;
  }

  body.sundex-transaction-system .buy-sell-options {
    grid-template-columns: minmax(0, 1fr);
  }

  body.sundex-transaction-system .stx-quick-label {
    width: 100%;
  }

  body.sundex-transaction-system .stx-order-form > button:last-of-type,
  body.sundex-transaction-system .stx-stage button.w-full.rounded-full,
  body.sundex-transaction-system .stx-stage button.w-full.py-3,
  body.stx-swap-route .stx-swap-ticket > button {
    position: sticky;
    z-index: 5;
    bottom: max(10px, env(safe-area-inset-bottom));
  }

  body.stx-swap-route .stx-swap-ticket {
    padding: 20px 16px 88px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.sundex-transaction-system *,
  body.sundex-transaction-system *::before,
  body.sundex-transaction-system *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* SUNDEX transaction system p30 — exact full-screen processing ticket. */
body.sundex-transaction-system {
  --tx30-bg: #010307;
  --tx30-surface: #050a11;
  --tx30-surface-2: #090f18;
  --tx30-field: rgba(8, 13, 22, 0.88);
  --tx30-line: rgba(172, 194, 223, 0.2);
  --tx30-line-soft: rgba(172, 194, 223, 0.11);
  --tx30-ink: #f2f4f8;
  --tx30-muted: #98a4b8;
  --tx30-blue: #b9d2f4;
  width: 100%;
  min-height: 100dvh;
  overflow: hidden !important;
  background: var(--tx30-bg) !important;
}

body.sundex-transaction-system [role="banner"],
body.sundex-transaction-system > header,
body.sundex-transaction-system .platform-header,
body.sundex-transaction-system button[aria-label*="support" i] {
  display: none !important;
}

body.sundex-transaction-system .platform-main,
body.sundex-transaction-system main.platform-main {
  position: relative !important;
  width: 100% !important;
  height: 100dvh !important;
  min-height: 680px !important;
  overflow: hidden !important;
  padding: 0 !important;
  background:
    radial-gradient(circle at 72% 8%, rgba(45, 65, 92, 0.12), transparent 28%),
    #010307 !important;
}

body.sundex-transaction-system .stx-shell {
  position: relative !important;
  isolation: isolate;
  display: grid !important;
  width: 100% !important;
  max-width: none !important;
  height: 100dvh !important;
  min-height: 680px !important;
  margin: 0 !important;
  padding: 0 !important;
  grid-template-columns: 43% 57% !important;
  grid-template-rows: 146px minmax(0, 1fr) !important;
  grid-template-areas:
    "context head"
    "context stage" !important;
  gap: 0 !important;
  align-content: stretch !important;
  align-items: stretch !important;
  overflow: hidden !important;
  background: transparent !important;
}

body.sundex-transaction-system .stx-context {
  grid-area: context !important;
  position: relative !important;
  inset: auto !important;
  z-index: 2;
  display: block !important;
  width: auto !important;
  min-width: 0 !important;
  height: 100dvh !important;
  min-height: 680px !important;
  overflow: hidden !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: #03070c !important;
  box-shadow: inset -1px 0 rgba(179, 199, 226, 0.09) !important;
}

body.sundex-transaction-system .stx-context::before {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(1, 4, 8, 0.04) 0%, rgba(1, 4, 8, 0.12) 42%, rgba(1, 3, 7, 0.88) 84%, #010307 100%),
    linear-gradient(90deg, transparent 64%, rgba(1, 3, 7, 0.5));
  pointer-events: none;
}

body.sundex-transaction-system .stx-context::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  background: linear-gradient(145deg, rgba(138, 176, 225, 0.05), transparent 42%);
  pointer-events: none;
}

body.sundex-transaction-system .stx-context-media {
  position: absolute;
  inset: 0;
  background-image: url('/assets/sundex-processing-metal-ag-p32.jpg');
  background-position: 50% center;
  background-size: cover;
  filter: saturate(0.58) contrast(1.08) brightness(0.64);
  transform: scale(1.012);
}

body.sundex-transaction-system .stx-context-brand {
  position: absolute;
  z-index: 3;
  top: 38px;
  left: 46px;
  color: var(--tx30-ink) !important;
  font-size: clamp(24px, 2vw, 32px);
  font-weight: 620;
  line-height: 1;
  letter-spacing: 0.02em;
  text-decoration: none !important;
}

body.sundex-transaction-system .stx-context-copy {
  position: absolute !important;
  z-index: 3;
  right: clamp(32px, 4vw, 72px) !important;
  bottom: clamp(36px, 4.2vh, 64px) !important;
  left: 46px !important;
  max-width: 500px;
}

body.sundex-transaction-system .stx-context-label {
  display: block;
  margin: 0 0 18px !important;
  color: #a8b5ca !important;
  font-size: 12px !important;
  font-weight: 620 !important;
  line-height: 1.2;
  letter-spacing: 0.12em;
}

body.sundex-transaction-system .stx-context-asset {
  display: flex;
  min-height: 50px;
  align-items: center;
  gap: 14px;
}

body.sundex-transaction-system .stx-context-coin {
  position: relative;
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(197, 215, 240, 0.22);
  border-radius: 50%;
  background: linear-gradient(145deg, rgba(190, 211, 239, 0.28), rgba(55, 70, 90, 0.2));
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.15);
}

body.sundex-transaction-system .stx-context-coin img {
  display: none;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

body.sundex-transaction-system .stx-context-coin i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #c7d8ee;
  box-shadow: 0 0 16px rgba(166, 201, 245, 0.55);
}

body.sundex-transaction-system .stx-context-coin.stx-has-asset img { display: block; }
body.sundex-transaction-system .stx-context-coin.stx-has-asset i { display: none; }

body.sundex-transaction-system .stx-context-title {
  max-width: none !important;
  margin: 0 !important;
  color: var(--tx30-ink) !important;
  font-size: clamp(36px, 3vw, 54px) !important;
  font-weight: 600 !important;
  line-height: 0.96 !important;
  letter-spacing: -0.045em !important;
}

body.sundex-transaction-system .stx-context-body {
  max-width: 38ch !important;
  margin: 14px 0 18px !important;
  color: var(--tx30-muted) !important;
  font-size: 15px !important;
  line-height: 1.5 !important;
}

body.sundex-transaction-system .stx-context-rows {
  display: grid !important;
  margin: 0 !important;
  border-top: 1px solid rgba(178, 198, 224, 0.2);
}

body.sundex-transaction-system .stx-context-rows > div {
  display: flex;
  min-height: 40px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid rgba(178, 198, 224, 0.13);
}

body.sundex-transaction-system .stx-context-rows dt,
body.sundex-transaction-system .stx-context-rows dd {
  margin: 0;
  color: var(--tx30-muted);
  font-size: 13px;
  font-weight: 450;
}

body.sundex-transaction-system .stx-context-rows dd {
  color: #c4ccda;
  text-align: right;
}

body.sundex-transaction-system .stx-context-note {
  margin: clamp(20px, 3vh, 38px) 0 0;
  color: #778397;
  font-size: 13px;
  line-height: 1.4;
}

body.sundex-transaction-system .stx-ticket-frame {
  position: absolute !important;
  z-index: 0 !important;
  top: 28px !important;
  right: 36px !important;
  bottom: 28px !important;
  left: calc(43% + 36px) !important;
  width: auto !important;
  min-height: 0 !important;
  overflow: hidden;
  border: 0 !important;
  border-radius: 16px 0 0 16px !important;
  background: linear-gradient(135deg, rgba(139, 164, 196, 0.42), #c1d8fa 49%, rgba(88, 116, 151, 0.72)) !important;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.44), 0 0 40px rgba(80, 116, 165, 0.06) !important;
  clip-path: polygon(0 0, calc(100% - 74px) 0, 100% 34px, 100% calc(100% - 42px), calc(100% - 40px) 100%, 0 100%) !important;
}

body.sundex-transaction-system .stx-ticket-frame::before {
  content: "";
  position: absolute;
  inset: 2px;
  background:
    radial-gradient(circle at 82% 8%, rgba(77, 107, 149, 0.1), transparent 30%),
    linear-gradient(145deg, rgba(7, 12, 20, 0.99), rgba(2, 6, 12, 0.995) 76%);
  clip-path: polygon(0 0, calc(100% - 73px) 0, 100% 33px, 100% calc(100% - 41px), calc(100% - 39px) 100%, 0 100%);
}

body.sundex-transaction-system .stx-ticket-frame::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 20px;
  width: 130px;
  height: 1px;
  background: linear-gradient(90deg, transparent, #c5dcfb 64%, transparent);
  box-shadow: 0 0 14px rgba(153, 194, 247, 0.36);
}

body.sundex-transaction-system .stx-head {
  grid-area: head !important;
  position: relative !important;
  z-index: 2 !important;
  display: flex !important;
  min-width: 0;
  min-height: 0 !important;
  align-items: flex-start !important;
  margin: 28px 36px 0 !important;
  padding: 34px clamp(34px, 4vw, 58px) 8px !important;
}

body.sundex-transaction-system .stx-shell > .stx-head > button,
body.sundex-transaction-system .stx-sell-inner > .stx-head > button,
body.stx-swap-route .sundex-swap-back {
  display: none !important;
}

body.sundex-transaction-system .stx-title-group,
body.sundex-transaction-system .stx-head > div {
  display: flex !important;
  min-width: 0;
  flex: 1;
  flex-direction: column !important;
  align-items: flex-start !important;
  gap: 3px !important;
}

body.sundex-transaction-system .stx-funding-shell .stx-title-group > div:first-child {
  display: none !important;
}

body.sundex-transaction-system .stx-sell-inner .stx-title-group > div:first-child {
  display: none !important;
}

body.sundex-transaction-system .stx-head h1 {
  margin: 0 !important;
  color: var(--tx30-ink) !important;
  font-size: clamp(29px, 2.3vw, 38px) !important;
  font-weight: 540 !important;
  line-height: 1.06 !important;
  letter-spacing: -0.035em !important;
}

body.sundex-transaction-system .stx-step-meta {
  margin: 5px 0 0 !important;
  color: var(--tx30-muted) !important;
  font-size: 15px !important;
  font-weight: 450 !important;
  line-height: 1.2;
}

body.sundex-transaction-system .stx-head > .stx-mode-switch {
  display: grid !important;
  width: clamp(220px, 22vw, 300px);
  height: 56px;
  flex: 0 0 auto !important;
  flex-direction: initial !important;
  align-items: stretch !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px !important;
  margin: 4px 0 0 22px;
  padding: 5px;
  border: 1px solid var(--tx30-line-soft);
  border-radius: 13px;
  background: rgba(2, 6, 12, 0.58);
}

body.sundex-transaction-system .stx-mode-option {
  min-height: 0 !important;
  border: 0 !important;
  border-radius: 9px !important;
  color: var(--tx30-muted) !important;
  background: transparent !important;
  font-size: 16px !important;
  font-weight: 500 !important;
  transition: color 160ms ease, background-color 160ms ease, box-shadow 160ms ease !important;
}

body.sundex-transaction-system .stx-mode-option.is-active {
  color: var(--tx30-ink) !important;
  background: linear-gradient(145deg, rgba(50, 61, 77, 0.86), rgba(24, 31, 42, 0.86)) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.08), 0 8px 22px rgba(0, 0, 0, 0.18);
}

body.sundex-transaction-system .stx-shell > .stx-progress,
body.sundex-transaction-system .stx-shell > .sfx-progress,
body.sundex-transaction-system .stx-shell > div:has(> .stx-progress),
body.sundex-transaction-system .stx-progress-wrap {
  display: none !important;
}

body.sundex-transaction-system .stx-shell > .stx-sell-flow {
  position: relative !important;
  z-index: 2;
  display: block !important;
  min-width: 0 !important;
  min-height: 0 !important;
  grid-column: 2 !important;
  grid-row: 1 / 3 !important;
}

body.sundex-transaction-system .stx-sell-inner {
  display: grid !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  grid-template-rows: 146px minmax(0, 1fr) !important;
}

body.sundex-transaction-system .stx-sell-inner > .stx-head {
  grid-area: auto !important;
  grid-row: 1 !important;
}

body.sundex-transaction-system .stx-sell-inner > .stx-stage {
  grid-area: auto !important;
  grid-row: 2 !important;
}

body.sundex-transaction-system .stx-stage {
  grid-area: stage !important;
  position: relative !important;
  z-index: 2 !important;
  min-width: 0 !important;
  min-height: 0 !important;
  margin: 0 36px 28px !important;
  padding: 2px clamp(34px, 4vw, 58px) 30px !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  scrollbar-width: thin;
  scrollbar-color: rgba(179, 200, 229, 0.22) transparent;
}

body.sundex-transaction-system .stx-stage > div,
body.sundex-transaction-system .stx-stage > div > div {
  width: 100% !important;
  max-width: none !important;
}

body.sundex-transaction-system .buy-sell-intro,
body.sundex-transaction-system .stx-stage .text-center.mb-2 {
  margin: 0 0 28px !important;
  text-align: left !important;
}

body.sundex-transaction-system .buy-sell-intro h2,
body.sundex-transaction-system .stx-stage .text-center.mb-2 h2,
body.sundex-transaction-system .stx-stage h2 {
  margin: 0 0 8px !important;
  color: var(--tx30-ink) !important;
  font-size: clamp(21px, 1.6vw, 27px) !important;
  font-weight: 530 !important;
  line-height: 1.15 !important;
  letter-spacing: -0.025em !important;
}

body.sundex-transaction-system .buy-sell-intro p,
body.sundex-transaction-system .stx-stage .text-center.mb-2 p {
  margin: 0 !important;
  color: var(--tx30-muted) !important;
  font-size: 15px !important;
  line-height: 1.45 !important;
}

body.sundex-transaction-system .buy-sell-options,
body.sundex-transaction-system .stx-stage-menu .space-y-4 {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  gap: 14px !important;
}

body.sundex-transaction-system .buy-sell-option,
body.sundex-transaction-system .stx-stage-menu button.group {
  min-height: 82px !important;
  padding: 18px 20px !important;
  border: 1px solid var(--tx30-line) !important;
  border-radius: 12px !important;
  color: var(--tx30-ink) !important;
  background: linear-gradient(135deg, rgba(10, 16, 25, 0.94), rgba(5, 10, 17, 0.82)) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.025) !important;
  transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease !important;
}

body.sundex-transaction-system .buy-sell-option strong,
body.sundex-transaction-system .stx-stage-menu button.group .font-bold {
  color: var(--tx30-ink) !important;
  font-size: 17px !important;
  font-weight: 560 !important;
}

body.sundex-transaction-system .buy-sell-option p,
body.sundex-transaction-system .stx-stage-menu button.group p {
  color: var(--tx30-muted) !important;
  font-size: 13px !important;
}

body.sundex-transaction-system .stx-order-form {
  display: grid !important;
  gap: 20px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-order-form label,
body.sundex-transaction-system .stx-stage label,
body.stx-swap-route .stx-swap-ticket > div > div:first-child > span,
body.stx-swap-route .stx-swap-ticket > div > span:first-child {
  display: block !important;
  margin: 0 0 9px !important;
  color: #d9e0ea !important;
  font-size: 16px !important;
  font-weight: 460 !important;
  line-height: 1.25 !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
}

body.sundex-transaction-system .stx-order-form > div:has(> label) button,
body.sundex-transaction-system .stx-order-form > div:has(> label) input,
body.sundex-transaction-system .stx-stage input,
body.sundex-transaction-system .stx-stage select {
  width: 100% !important;
  min-height: 70px !important;
  padding: 0 20px !important;
  border: 1px solid var(--tx30-line) !important;
  border-radius: 12px !important;
  color: var(--tx30-ink) !important;
  background: linear-gradient(145deg, rgba(7, 12, 20, 0.96), rgba(9, 15, 25, 0.86)) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.025) !important;
  font-size: 18px !important;
  transition: border-color 160ms ease, box-shadow 160ms ease !important;
}

body.sundex-transaction-system .stx-order-form > div:has(> input) input,
body.sundex-transaction-system .stx-stage-amount input[type="number"] {
  font-variant-numeric: tabular-nums;
  font-size: clamp(26px, 2.4vw, 40px) !important;
  font-weight: 480 !important;
  letter-spacing: -0.035em;
  text-align: right;
}

body.sundex-transaction-system .stx-stage input:focus,
body.sundex-transaction-system .stx-stage button:focus-visible,
body.stx-swap-route .stx-swap-ticket input:focus {
  outline: none !important;
  border-color: rgba(195, 216, 244, 0.72) !important;
  box-shadow: 0 0 0 3px rgba(151, 184, 226, 0.1) !important;
}

body.sundex-transaction-system .stx-stage input[placeholder*="Search" i] {
  padding-left: 48px !important;
  font-size: 15px !important;
  text-align: left !important;
}

body.sundex-transaction-system .stx-quick-assets {
  display: none !important;
}

body.sundex-transaction-system .stx-order-form > div:has(.lucide-arrow-down-up) {
  position: relative;
  height: 1px;
  margin: 1px 0;
  background: linear-gradient(90deg, var(--tx30-line-soft), transparent 42% 58%, var(--tx30-line-soft));
}

body.sundex-transaction-system .stx-order-form > div:has(.lucide-arrow-down-up) > div {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 48px !important;
  height: 48px !important;
  border: 1px solid var(--tx30-line) !important;
  border-radius: 50% !important;
  background: #050a11 !important;
  transform: translate(-50%, -50%);
}

body.sundex-transaction-system .stx-order-form > button:last-of-type,
body.sundex-transaction-system .stx-stage button.w-full.rounded-full,
body.sundex-transaction-system .stx-stage button.w-full.py-3,
body.stx-swap-route .stx-swap-ticket > button {
  width: 100% !important;
  min-height: 66px !important;
  border: 1px solid rgba(213, 229, 250, 0.8) !important;
  border-radius: 10px !important;
  color: #06101d !important;
  background: linear-gradient(135deg, #c8dbf5 0%, #a8c7f2 48%, #bdd5f6 100%) !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.72), 0 12px 28px rgba(49, 91, 147, 0.16) !important;
  font-size: 17px !important;
  font-weight: 580 !important;
  transition: filter 160ms ease, transform 160ms ease !important;
}

body.sundex-transaction-system .stx-order-form > button:disabled,
body.sundex-transaction-system .stx-stage button.w-full:disabled,
body.stx-swap-route .stx-swap-ticket > button:disabled {
  opacity: 0.48 !important;
  filter: saturate(0.35) !important;
}

body.sundex-transaction-system .stx-disabled-reason {
  margin: -8px 0 0 !important;
  color: #7f8a9d !important;
  font-size: 12px !important;
  line-height: 1.35 !important;
  text-align: center !important;
}

body.sundex-transaction-system .stx-stage-coins > div,
body.sundex-transaction-system .stx-stage-coins .space-y-3,
body.sundex-transaction-system .stx-stage-coins .grid {
  gap: 10px !important;
}

body.sundex-transaction-system .stx-stage-coins button:has(img) {
  min-height: 62px !important;
  border: 1px solid var(--tx30-line-soft) !important;
  border-radius: 11px !important;
  background: rgba(7, 12, 20, 0.8) !important;
  box-shadow: none !important;
}

body.sundex-transaction-system .stx-stage .rounded-2xl.border.border-border.bg-card:not(.stx-order-form),
body.sundex-transaction-system .stx-stage .rounded-xl.border.border-border.bg-card {
  border: 1px solid var(--tx30-line-soft) !important;
  border-radius: 12px !important;
  background: rgba(7, 12, 20, 0.76) !important;
  box-shadow: none !important;
}

/* Swap uses the same shell without moving the application controls. */
body.stx-swap-route .stx-swap-main {
  position: relative !important;
  display: block !important;
}

body.stx-swap-route .stx-swap-layout {
  position: static !important;
  display: block !important;
  width: auto !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
}

body.stx-swap-route .stx-swap-layout > .stx-context {
  position: absolute !important;
  inset: 0 auto 0 0 !important;
  width: 43% !important;
}

body.stx-swap-route .stx-swap-layout > .stx-ticket-frame {
  left: calc(43% + 36px) !important;
}

body.stx-swap-route .sundex-swap-page-head {
  position: absolute !important;
  z-index: 2;
  top: 28px;
  right: 36px;
  left: calc(43% + 36px);
  width: auto !important;
  min-height: 118px !important;
  margin: 0 !important;
}

body.stx-swap-route .sundex-swap-page-head .sundex-swap-title {
  order: 0;
}

body.stx-swap-route .sundex-swap-page-head .stx-step-meta {
  display: block;
  position: absolute;
  top: 74px;
  left: clamp(34px, 4vw, 58px);
}

body.stx-swap-route .stx-swap-ticket {
  position: absolute !important;
  z-index: 2;
  top: 146px;
  right: 36px;
  bottom: 28px;
  left: calc(43% + 36px);
  width: auto !important;
  max-width: none !important;
  overflow-y: auto;
  margin: 0 !important;
  padding: 2px clamp(34px, 4vw, 58px) 30px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.stx-swap-route .stx-swap-ticket > div.rounded-2xl {
  padding: 18px 20px !important;
  border: 1px solid var(--tx30-line) !important;
  border-radius: 12px !important;
  background: linear-gradient(145deg, rgba(7, 12, 20, 0.96), rgba(9, 15, 25, 0.86)) !important;
  box-shadow: none !important;
}

body.stx-swap-route .stx-swap-ticket input {
  color: var(--tx30-ink) !important;
  background: transparent !important;
  font-size: clamp(26px, 2.3vw, 38px) !important;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

body.stx-swap-route .sundex-swap-reverse {
  width: 48px !important;
  height: 48px !important;
  border: 1px solid var(--tx30-line) !important;
  border-radius: 50% !important;
  background: #050a11 !important;
}

@media (hover: hover) and (pointer: fine) {
  body.sundex-transaction-system .buy-sell-option:hover,
  body.sundex-transaction-system .stx-stage-menu button.group:hover,
  body.sundex-transaction-system .stx-stage-coins button:has(img):hover {
    border-color: rgba(190, 214, 246, 0.42) !important;
    background: rgba(12, 20, 31, 0.94) !important;
    transform: translateY(-1px);
  }

  body.sundex-transaction-system .stx-context-brand:hover { color: #fff !important; }
  body.sundex-transaction-system .stx-mode-option:hover { color: var(--tx30-ink) !important; }
}

@media (max-height: 780px) and (min-width: 1001px) {
  body.sundex-transaction-system .stx-context-copy { bottom: 28px !important; }
  body.sundex-transaction-system .stx-context-label { margin-bottom: 12px !important; }
  body.sundex-transaction-system .stx-context-title { font-size: 38px !important; }
  body.sundex-transaction-system .stx-context-body { margin: 10px 0 12px !important; font-size: 13px !important; }
  body.sundex-transaction-system .stx-context-rows > div { min-height: 33px; }
  body.sundex-transaction-system .stx-context-note { margin-top: 16px; }
  body.sundex-transaction-system .stx-head { padding-top: 26px !important; }
  body.sundex-transaction-system .stx-stage { padding-bottom: 20px !important; }
  body.sundex-transaction-system .stx-order-form { gap: 15px !important; }
  body.sundex-transaction-system .stx-order-form > div:has(> label) button,
  body.sundex-transaction-system .stx-order-form > div:has(> label) input { min-height: 60px !important; }
}

@media (max-width: 1000px) {
  body.sundex-transaction-system { overflow: auto !important; }
  body.sundex-transaction-system .platform-main,
  body.sundex-transaction-system main.platform-main { height: auto !important; min-height: 100dvh !important; overflow: visible !important; }

  body.sundex-transaction-system .stx-shell {
    height: auto !important;
    min-height: 100dvh !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: 132px minmax(0, 1fr) !important;
    grid-template-areas: "head" "stage" !important;
  }

  body.sundex-transaction-system .stx-context { display: none !important; }

  body.sundex-transaction-system .stx-shell > .stx-sell-flow {
    grid-column: 1 !important;
  }

  body.sundex-transaction-system .stx-sell-inner {
    grid-template-rows: 132px minmax(0, 1fr) !important;
  }

  body.sundex-transaction-system .stx-ticket-frame,
  body.stx-swap-route .stx-swap-layout > .stx-ticket-frame {
    top: 18px !important;
    right: 18px !important;
    bottom: 18px !important;
    left: 18px !important;
  }

  body.sundex-transaction-system .stx-head {
    margin: 18px 18px 0 !important;
    padding: 28px 34px 6px !important;
  }

  body.sundex-transaction-system .stx-stage {
    margin: 0 18px 18px !important;
    padding: 2px 34px 30px !important;
  }

  body.stx-swap-route .sundex-swap-page-head {
    top: 18px;
    right: 18px;
    left: 18px;
    padding: 28px 34px 6px !important;
  }

  body.stx-swap-route .sundex-swap-page-head .stx-step-meta { top: 67px; left: 34px; }
  body.stx-swap-route .stx-swap-ticket { top: 132px; right: 18px; bottom: 18px; left: 18px; padding: 2px 34px 30px !important; }
}

@media (max-width: 640px) {
  body.sundex-transaction-system .stx-shell { grid-template-rows: 154px minmax(0, 1fr) !important; }
  body.sundex-transaction-system .stx-sell-inner { grid-template-rows: 154px minmax(0, 1fr) !important; }

  body.sundex-transaction-system .stx-ticket-frame,
  body.stx-swap-route .stx-swap-layout > .stx-ticket-frame {
    inset: 8px !important;
    border-radius: 16px !important;
    clip-path: none !important;
  }

  body.sundex-transaction-system .stx-head {
    margin: 8px 8px 0 !important;
    padding: 24px 20px 6px !important;
    flex-wrap: wrap;
  }

  body.sundex-transaction-system .stx-head h1 { font-size: 27px !important; }
  body.sundex-transaction-system .stx-step-meta { font-size: 13px !important; }

  body.sundex-transaction-system .stx-mode-switch {
    width: 100%;
    height: 44px;
    margin: 12px 0 0;
  }

  body.sundex-transaction-system .stx-stage {
    margin: 0 8px 8px !important;
    padding: 8px 20px 80px !important;
  }

  body.sundex-transaction-system .stx-order-form > button:last-of-type,
  body.sundex-transaction-system .stx-stage button.w-full.rounded-full,
  body.sundex-transaction-system .stx-stage button.w-full.py-3,
  body.stx-swap-route .stx-swap-ticket > button {
    position: sticky;
    z-index: 4;
    bottom: max(12px, env(safe-area-inset-bottom));
  }

  body.stx-swap-route .sundex-swap-page-head { top: 8px; right: 8px; left: 8px; padding: 24px 20px 6px !important; }
  body.stx-swap-route .sundex-swap-page-head .stx-step-meta { top: 61px; left: 20px; }
  body.stx-swap-route .stx-swap-ticket { top: 122px; right: 8px; bottom: 8px; left: 8px; padding: 8px 20px 80px !important; }
}
