/* Bencho by Lorenzo Cabra. See bencho-license.txt. */
/* Asset Swap */
.swp {
  position: relative;
  font-family: var(--font-ui);
  color: var(--fill-on, var(--ink));
  overflow: hidden;
  border-radius: var(--swp-r);
}

.swp-card {
  position: absolute;
  left: 0;
  right: 0;
  height: 116px;
  z-index: 1;
  overflow: hidden;
  border-radius: var(--swp-r);
  background: var(--fill-slab, var(--card));
}

.swp-card[data-lifted] { z-index: 3;
}

[data-stroke="on"] .swp-card { box-shadow: inset 0 0 0 1px var(--pane-edge);
}

.swp-label {
  position: absolute;
  top: 16px;
  left: 16px;
  font-size: 13px;
  font-weight: 400;
  color: color-mix(in srgb, var(--fill-on, #17181a) 52%, var(--fill-slab, #ffffff));
  letter-spacing: 0em;
}

.swp-amount {
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 30px;
  margin-bottom: 2px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.swp-coin {
  position: absolute;
  right: 16px;
  bottom: 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 30px;
  padding: 0 12px 0 4px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fill-on, #17181a) 6%, transparent);
  font-size: 13px;
  font-weight: 500;
  
  border: 0;
  margin: 0;
  color: inherit;
  font-family: inherit;
  cursor: pointer;
  transition: background 160ms ease, scale 160ms ease;
  -webkit-tap-highlight-color: transparent;
  letter-spacing: 0em;
}

.swp-coin:hover { background: color-mix(in srgb, var(--fill-on, #17181a) 12%, transparent);
}

[data-fill="dark"] .swp-coin { background: color-mix(in srgb, var(--fill-on, #17181a) 12%, transparent);
}

[data-fill="dark"] .swp-coin:hover { background: color-mix(in srgb, var(--fill-on, #17181a) 20%, transparent);
}

.swp-coin:active { scale: 0.96;
}

.swp-coin:focus-visible { outline: 2px solid var(--pick); outline-offset: 2px;
}

.swp-logo { display: block; flex: none;
}

/* Label Input */
.lbi {
  position: relative;
  font-family: var(--font-ui);
  display: grid;
  place-items: center;
  
  padding-top: 12px;
}

.lbi-box {
  position: relative;
  background: transparent;
  cursor: text;
}

.lbi-ring {
  position: absolute;
  inset: 0;
  overflow: visible;
  pointer-events: none;
}

.lbi-ring path {
  fill: none;
  stroke: color-mix(in srgb, var(--fill-on, #17181a) 32%, var(--fill-slab, #ffffff));
  stroke-width: 1;
  stroke-linecap: butt;
  transition: stroke 220ms ease, stroke-width 220ms ease;
}

.lbi[data-focus="true"] .lbi-ring path {
  stroke: var(--ink);
  stroke-width: 1.5;
}

.lbi[data-filled="true"]:not([data-focus="true"]) .lbi-ring path {
  stroke: color-mix(in srgb, var(--fill-on, #17181a) 32%, var(--fill-slab, #ffffff));
}

.lbi-gap {
  stroke-dasharray: 1 2;
  stroke-dashoffset: 0;
  transition: stroke 220ms ease, stroke-width 220ms ease,
    stroke-dashoffset 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

.lbi[data-up="true"] .lbi-gap { stroke-dashoffset: -1;
}

.lbi-label {
  position: absolute;
  left: var(--lbi-x);
  top: 50%;
  font-size: 16px;
  line-height: 1;
  letter-spacing: -0.01em;
  white-space: pre;
  color: var(--ink-4);
  transform-origin: left center;
  transform: translateY(-50%);
  transition: transform 420ms cubic-bezier(0.22, 1, 0.36, 1), color 220ms ease;
  cursor: text;
  -webkit-user-select: none;
  user-select: none;
}

.lbi[data-up="true"] .lbi-label {
  transform: translateY(-50%) translateY(-26px) scale(0.78);
  color: var(--ink-3);
}

.lbi[data-focus="true"] .lbi-label { color: var(--fill-on, var(--ink));
}

.lbi-label span { display: inline-block;
}

.lbi[data-focus="true"] .lbi-label span {
  animation: lbi-hop 460ms cubic-bezier(0.3, 0.7, 0.3, 1) both;
  animation-delay: calc(var(--i) * 24ms);
}

.lbi-field {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0 0 0 var(--lbi-x);
  border: 0;
  border-radius: inherit;
  background: transparent;
  font: inherit;
  font-size: 16px;
  letter-spacing: -0.01em;
  color: var(--fill-on, var(--ink));
  outline: none;
}

/* Action Node */
.nod-card {
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  
  width: 272px;
  padding: 20px;
  
  border-radius: var(--nod-r, 20px);
  background: var(--fill-slab, var(--card));
  color: var(--fill-on, var(--ink));
  
  transition: translate 220ms cubic-bezier(0.24, 1.34, 0.38, 1);
}

.nod-card[data-on] { translate: 0 -1px;
}

.nod-top {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nod-mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  
  border-radius: var(--nod-mark-r, 14px);
  background: rgba(var(--ink-rgb), var(--wash));
  color: var(--fill-on, var(--ink));
}

.nod-name {
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

/* Toast Stack */
.tst-toast {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 12px 0 16px;
  border-radius: var(--tst-r);
  background: var(--fill-slab, #ffffff);
  transform-origin: 50% 0;
  transition: background-color 220ms ease, box-shadow 220ms ease;
}

[data-stroke="on"] .tst-toast { box-shadow: 0 0 0 1px var(--pane-edge);
}

.tst-toast > * { transition: opacity 220ms ease;
}

.tst-toast[data-kind="success"] .tst-icon { color: #1f9d55;
}

.tst-toast[data-kind="error"] .tst-icon { color: #e5484d;
}

.tst-toast[data-kind="warning"] .tst-icon { color: #e09a12;
}

.tst-toast[data-kind="info"] .tst-icon { color: var(--tst-mute);
}

.tst-act {
  flex: none;
  height: 28px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: var(--tst-wash);
  color: inherit;
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: scale 160ms cubic-bezier(0.22, 1, 0.36, 1);
  letter-spacing: 0em;
}

.tst-act:active { scale: 0.96;
}

/* Activity Stack */
.acs-card {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 62px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px 0 12px;
  border-radius: var(--acs-r);
  background: color-mix(in srgb, var(--fill-on, #17181a) calc(var(--k, 0) * 9%), var(--fill-slab, #ffffff));
  transform-origin: 50% 0;
  will-change: transform;
  transition: transform var(--acs-ms) cubic-bezier(0.22, 1, 0.36, 1), opacity calc(var(--acs-ms) * 0.7) ease, background-color var(--acs-ms) ease;
}

[data-stroke="on"] .acs-card { box-shadow: 0 0 0 1px var(--pane-edge);
}

.acs-card > * { transition: opacity 220ms ease;
}

.acs-card:not([data-top]) > * { opacity: 0;
}

.acs-card[data-top] { cursor: grab; touch-action: pan-y;
}

.acs-card[data-top]:active { cursor: grabbing;
}

.acs-card:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--signal, #2231dd);
}

.acs-icon {
  flex: none;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: color-mix(in srgb, var(--fill-on, #17181a) 7%, transparent);
  overflow: hidden;
}

.acs-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px;
}

.acs-text b { font-size: 14px; font-weight: 500; line-height: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -0.01em;
}

.acs-text span { font-size: 12px; line-height: 16px; color: var(--acs-mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: 0em;
}

/* FAQ Accordion */
.fqa {
  display: flex;
  align-items: flex-start;
  font-family: var(--font-ui);
  color: var(--fill-on, var(--ink));
  --fqa-soft: color-mix(in srgb, var(--fill-on, #17181a) 72%, var(--fill-slab, #ffffff));
  --fqa-mute: color-mix(in srgb, var(--fill-on, #17181a) 52%, var(--fill-slab, #ffffff));
  --fqa-line: color-mix(in srgb, var(--fill-on, #17181a) 12%, transparent);
}

.fqa-list { width: 100%;
}

.fqa-item + .fqa-item { border-top: 1px solid var(--fqa-line);
}

.fqa-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  height: 52px;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  text-align: left;
  cursor: pointer;
}

.fqa-q > span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.fqa-q:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--signal, #2231dd); border-radius: 6px;
}

.fqa-mark {
  flex: none;
  color: var(--fqa-mute);
  transition: rotate 220ms cubic-bezier(0.22, 1, 0.36, 1), color 160ms ease;
}

.fqa-q:hover .fqa-mark { color: var(--fill-on, var(--ink));
}

.fqa-list[data-icon="Plus"] .fqa-item[data-open] .fqa-mark { rotate: 135deg;
}

.fqa-list[data-icon="Chevron"] .fqa-item[data-open] .fqa-mark { rotate: 180deg;
}

.fqa-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

.fqa-item[data-open] .fqa-a { grid-template-rows: 1fr;
}

.fqa-a > div { min-height: 0; overflow: hidden;
}

.fqa-a p {
  margin: 0;
  padding: 0 24px 16px 0;
  font-size: 14px;
  line-height: 20px;
  color: var(--fqa-soft);
  letter-spacing: -0.01em;
}

@keyframes lbi-hop {
  0% { transform: translateY(0); }
  38% { transform: translateY(-3px); }
  100% { transform: translateY(0); }}
