/* START ALPHA CHANGE INNBC-SWAP-002 -- responsive INNBCswap visual design */
:root {
  color-scheme: dark;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #edf2f7;
  background: #101827;

  --background: #101827;
  --panel: #152033;
  --muted: #b8c6d9;
  --accent: #70d8ce;
  --border: #2b3a50;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  min-width: 280px;
  min-height: 100vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(
      ellipse at 85% 12%,
      rgb(112 216 206 / 7%),
      transparent 42%
    ),
    var(--background);
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: default;
  opacity: 0.5;
}

input:disabled {
  opacity: 1;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

img {
  display: block;
  object-fit: contain;
}

.container {
  width: min(1160px, calc(100% - 48px));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 10;
  padding: 12px 18px;
  color: #10202a;
  background: var(--accent);
  border-radius: 8px;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  border-bottom: 1px solid rgb(184 198 217 / 10%);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  padding-block: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #edf2f7;
  font-size: 1.25rem;
  font-weight: 750;
  letter-spacing: -0.04em;
}

.brand:hover {
  text-decoration: none;
}

.brand img {
  width: 28px;
  height: 28px;
}

.brand-accent {
  color: var(--accent);
}

.ecosystem-links {
  display: flex;
  gap: 24px;
  margin-left: auto;
}

.ecosystem-links a {
  color: var(--muted);
  font-size: 0.82rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 11px 17px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 650;
}

.button-secondary {
  color: #edf2f7;
  background: #1c2b42;
  border-color: var(--border);
}

.button-primary {
  color: #10202a;
  background: var(--accent);
}

main {
  flex: 1;
}

.workspace {
  width: min(100%, 530px);
  margin: 48px auto 56px;
}

.intro {
  margin-bottom: 30px;
  text-align: center;
}

.eyebrow {
  margin: 0 0 9px;
  color: var(--accent);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  line-height: 1.6;
}

h1,
h2,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 2.7rem);
  font-weight: 750;
  letter-spacing: -0.055em;
  line-height: 1.15;
}

.intro-description {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.7;
}

.app-card {
  background:
    linear-gradient(
      145deg,
      rgb(112 216 206 / 3%),
      transparent 45%
    ),
    var(--panel);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: 0 22px 65px rgb(0 0 0 / 18%);
}

.tabs {
  display: flex;
  gap: 6px;
  padding: 8px;
  border-bottom: 1px solid var(--border);
}

.tab {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 13px;
  font-weight: 650;
  transition:
    color 160ms ease,
    background-color 160ms ease;
}

.tab:hover {
  color: #edf2f7;
  background: rgb(184 198 217 / 5%);
}

.tab[aria-selected="true"] {
  color: var(--accent);
  background: rgb(112 216 206 / 9%);
  border-color: rgb(112 216 206 / 16%);
}

.tab-badge {
  padding: 2px 6px;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 5px;
  font-size: 0.6rem;
  font-weight: 500;
}

.panel {
  padding: 24px;
  border-radius: 0 0 22px 22px;
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 22px;
}

.panel-heading .eyebrow {
  margin-bottom: 4px;
  font-size: 0.58rem;
}

h2 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 650;
  letter-spacing: -0.035em;
}

.status-badge {
  flex-shrink: 0;
  padding: 5px 8px;
  color: var(--muted);
  background: rgb(184 198 217 / 4%);
  border: 1px solid var(--border);
  border-radius: 7px;
  font-size: 0.62rem;
}

/* START ALPHA CHANGE INNBC-SWAP-148E -- place network logos outside the bridge amount boxes */
/* START ALPHA CHANGE INNBC-SWAP-149A -- bring network logos inward and closer to their label */
.asset-network-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin-bottom: 8px;
  padding-inline-end: 2px; /* move text + logo to the right */
  color: var(--muted);
  font-size: 0.72rem;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-149A -- bring network logos inward and closer to their label */

.network-logo {
  display: inline-flex;
}

.network-logo img {
  width: 20px;
  height: 20px;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-148E -- place network logos outside the bridge amount boxes */

.asset-box {
  min-width: 0;
  padding: 17px;
  background: #101a2a;
  border: 1px solid var(--border);
  border-radius: 14px;
}

.asset-box:focus-within {
  border-color: var(--accent);
}

.box-topline,
.box-bottomline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
}

.box-topline {
  font-size: 0.76rem;
}

.network {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #edf2f7;
  font-size: 0.73rem;
}

.network img {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.amount-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 15px 0 13px;
}

.amount-line input,
.amount-placeholder {
  min-width: 0;
  color: #edf2f7;
  font-size: clamp(1.65rem, 5vw, 2rem);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.04em;
  line-height: 1.25;
}

.amount-line input {
  width: 100%;
  padding: 2px 0;
  background: transparent;
  border: 0;
  border-radius: 3px;
}

.amount-line input::placeholder {
  color: #91a3ba;
  opacity: 1;
}

.token {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  color: #edf2f7;
  font-size: 1rem;
  font-weight: 650;
}

.token img {
  width: 28px;
  height: 28px;
  border-radius: 50%;
}

.box-bottomline,
.token-note {
  font-size: 0.68rem;
  line-height: 1.6;
}

.box-bottomline > :last-child {
  text-align: right;
}

.token-note {
  margin: 0;
  color: var(--muted);
}

.direction-row {
  display: flex;
  justify-content: center;
  margin: -6px 0;
  position: relative;
  z-index: 1;
}

.direction-button,
.direction-static {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  color: var(--accent);
  background: #1c2b42;
  border: 4px solid var(--panel);
  border-radius: 12px;
}

.direction-button:hover {
  background: #2b4058;
}

.direction-static {
  color: var(--muted);
  font-size: 1.2rem;
}

.field-note {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.7;
}

.transfer-details {
  display: grid;
  gap: 10px;
  margin: 21px 0;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  font-size: 0.75rem;
}

.transfer-details > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.transfer-details dt {
  color: var(--muted);
}

.transfer-details dd {
  margin: 0;
  font-variant-numeric: tabular-nums;
}

.action-button {
  width: 100%;
  min-height: 49px;
  font-size: 0.92rem;
}

.route-note {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 0.68rem;
  line-height: 1.7;
  text-align: center;
}

.preview-notice {
  max-width: 390px;
  margin: 18px auto 0;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.7;
  text-align: center;
}

/* START ALPHA CHANGE INNBC-SWAP-005 -- shared footer layout and social icons */
.site-footer {
  border-top: 1px solid rgb(184 198 217 / 10%);
}

.footer-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
  padding-block: 28px;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.7;
}

.footer-inner p {
  margin: 0;
}

.footer-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.social-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.social-links a:hover {
  background: #1c2b42;
}

.social-links img {
  display: block;
  width: 24px;
  height: 24px;
  object-fit: contain;
  filter: brightness(0) invert(1);
  opacity: 0.85;
}

.social-links a:hover img {
  opacity: 1;
}

.footer-network {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-005 -- shared footer layout and social icons */

@media (max-width: 680px) {
  .container {
    width: calc(100% - 32px);
  }

  .header-inner {
    flex-wrap: wrap;
    gap: 16px;
    padding-block: 17px;
  }

  .header-inner > .button {
    margin-left: auto;
  }

  .ecosystem-links {
    order: 3;
    width: 100%;
    justify-content: center;
    margin-left: 0;
  }

  .workspace {
    margin-top: 34px;
  }

  /* START ALPHA CHANGE INNBC-SWAP-006 -- retain footer alignment on mobile */
  .footer-inner {
    align-items: flex-start;
  }
  /* FINISH ALPHA CHANGE INNBC-SWAP-006 -- retain footer alignment on mobile */
}

@media (max-width: 380px) {
  .panel {
    padding: 16px;
  }

  .panel-heading {
    flex-wrap: wrap;
  }

  .asset-box {
    padding: 13px;
  }

  .network {
    font-size: 0.66rem;
  }

  .brand {
    font-size: 1.1rem;
  }

  .header-inner > .button {
    padding-inline: 10px;
    font-size: 0.75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}

/* START ALPHA CHANGE INNBC-SWAP-017 -- wallet controls and balance presentation */
.header-inner {
  flex-wrap: wrap;
}

.wallet-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 100%;
}

/* START ALPHA CHANGE INNBC-SWAP-025 -- rounded wallet control and popup */
.wallet-picker {
  position: relative;
  width: 130px;
  max-width: 100%;
}

.wallet-select {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-height: 44px;
  padding: 8px 10px;
  color: #edf2f7;
  background: #1c2b42;
  border: 1px solid var(--border);
  border-radius: 10px;
  font: inherit;
  font-size: 0.78rem;
  text-align: left;
}

#wallet-picker-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wallet-picker-arrow {
  flex-shrink: 0;
  color: var(--muted);
}

.wallet-select[aria-expanded="true"] {
  border-color: var(--accent);
}

.wallet-picker-options {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 20;
  width: min(220px, calc(100vw - 48px));
  max-height: min(280px, 60vh);
  overflow-y: auto;
  padding: 6px;
  background: #1c2b42;
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgb(0 0 0 / 30%);
}

/* START ALPHA CHANGE INNBC-SWAP-028 -- match wallet options to Bridge and Swap tab highlights */
.wallet-picker-option {
  display: block;
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  font: inherit;
  font-size: 0.78rem;
  text-align: left;
  overflow-wrap: anywhere;
}

.wallet-picker-option:not([aria-pressed="true"]):hover:not(:disabled),
.wallet-picker-option:not([aria-pressed="true"]):focus-visible {
  color: #edf2f7;
  background: rgb(184 198 217 / 5%);
}

.wallet-picker-option:focus-visible {
  outline-offset: -3px;
}

.wallet-picker-option[aria-pressed="true"] {
  color: var(--accent);
  background: rgb(112 216 206 / 9%);
  border-color: rgb(112 216 206 / 16%);
}
/* FINISH ALPHA CHANGE INNBC-SWAP-028 -- match wallet options to Bridge and Swap tab highlights */
/* FINISH ALPHA CHANGE INNBC-SWAP-025 -- rounded wallet control and popup */

/* START ALPHA CHANGE INNBC-SWAP-148F -- reuse the wallet popup styling for the destination token */
.token-picker {
  width: auto;
  flex-shrink: 0;
}

.token-select {
  min-height: 44px;
  padding: 6px 10px;
  background: transparent;
  border-radius: 999px;
}

.token-picker-options {
  right: 0;
  left: auto;
  width: 160px;
  max-width: calc(100vw - 64px);
}

.token-picker-option {
  display: flex;
  align-items: center;
  gap: 8px;
}

.token-picker-option img {
  width: 24px;
  height: 24px;
  border-radius: 50%;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-148F -- reuse the wallet popup styling for the destination token */

/* START ALPHA CHANGE INNBC-SWAP-150C -- slippage controls and precise fee display */
.slippage-picker .wallet-select {
  white-space: nowrap;
}

.slippage-custom {
  display: flex;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 8px;
  margin: -6px 0 18px;
  padding: 12px;
  background: #101a2a;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.slippage-custom label {
  display: grid;
  flex: 1 1 120px;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  font-size: 0.72rem;
}

.slippage-custom input {
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  color: #edf2f7;
  background: #1c2b42;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.slippage-custom .button {
  min-height: 40px;
  padding: 8px 12px;
  font-size: 0.75rem;
}

.slippage-custom-error {
  flex-basis: 100%;
  margin: 0;
  color: #ffb8b8;
  font-size: 0.72rem;
}

.swap-details dd {
  min-width: 0;
  text-align: right;
  overflow-wrap: anywhere;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-150C -- slippage controls and precise fee display */

/* START ALPHA CHANGE INNBC-SWAP-151H -- swap quotation and transaction presentation */
.swap-quote-summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 16px 0 8px;
  color: var(--muted);
  font-size: 0.72rem;
}

.swap-quote-summary p {
  margin: 0;
}

.swap-quote-summary .button {
  min-height: 34px;
  margin-left: auto;
  padding: 6px 10px;
  font-size: 0.7rem;
}

#swap-impact[data-high="true"] {
  color: #ffb8b8;
}

.swap-options {
  margin: 18px 0;
  color: var(--muted);
  font-size: 0.75rem;
}

.swap-options summary {
  cursor: pointer;
}

.swap-options label {
  display: grid;
  gap: 6px;
  margin-top: 12px;
}

.swap-options select,
.swap-recovery input {
  width: 100%;
  min-width: 0;
  padding: 10px;
  color: #edf2f7;
  background: #101a2a;
  border: 1px solid var(--border);
  border-radius: 8px;
  font: inherit;
}

.swap-tracking {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 0.75rem;
}

.swap-tracking > p:first-child {
  margin-top: 0;
}

.swap-tracking a {
  overflow-wrap: anywhere;
}

.swap-tracking .button {
  min-height: 36px;
  margin-top: 10px;
  padding: 7px 10px;
  font-size: 0.7rem;
}

.swap-recovery {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.swap-recovery input {
  flex: 1 1 220px;
}

.swap-recovery .button {
  margin-top: 0;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-151H -- swap quotation and transaction presentation */

.wallet-panel {
  margin-bottom: 14px;
  padding: 16px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--muted);
  font-size: 0.74rem;
}

.wallet-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

.wallet-toolbar + .wallet-toolbar {
  margin-top: 12px;
}

.wallet-toolbar .button {
  font-size: 0.74rem;
}

.text-button {
  min-height: 36px;
  padding: 6px 0;
  color: var(--accent);
  background: transparent;
  border: 0;
  font-size: 0.74rem;
}

.text-button:hover:not(:disabled) {
  text-decoration: underline;
}

.wallet-balances {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.wallet-balances dt {
  font-size: 0.63rem;
  line-height: 1.6;
}

.wallet-balances dd {
  margin: 5px 0 0;
  color: #edf2f7;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.balance-status {
  margin: 12px 0 0;
  font-size: 0.68rem;
  line-height: 1.7;
}

.balance-status:empty {
  margin: 0;
}

.wallet-feedback {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.7;
}

.wallet-feedback:empty {
  margin: 0;
}

.wallet-feedback[data-tone="error"] {
  color: #ffb4b4;
}

@media (max-width: 680px) {
  .header-inner > .wallet-controls {
    margin-left: auto;
  }
}

@media (max-width: 380px) {
  .wallet-balances {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

/* START ALPHA CHANGE INNBC-SWAP-023 -- align wallet network icon and text */
.wallet-network-label {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.wallet-network-label img {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  object-fit: contain;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-023 -- align wallet network icon and text */
/* FINISH ALPHA CHANGE INNBC-SWAP-017 -- wallet controls and balance presentation */
/* FINISH ALPHA CHANGE INNBC-SWAP-002 -- responsive INNBCswap visual design */

/* START ALPHA CHANGE INNBC-SWAP-117 -- bridge progress and claim cards */
/* START ALPHA CHANGE INNBC-SWAP-142AB -- style each history as one box */
.bridge-history,
.bridge-claims {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgb(0 0 0 / 8%);
}

.history-header,
.history-navigation {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.history-header h3,
.history-header p,
.history-details p,
.claim-status {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.6;
}

.history-header h3 {
  font-weight: 600;
}

.history-details {
  display: grid;
  gap: 8px;
  margin: 14px 0;
}

.history-navigation {
  margin-top: 14px;
}

.claim-status {
  margin-top: 14px;
  overflow-wrap: anywhere;
}

#claim-amount:empty,
#claims-status:empty {
  display: none;
}
/* FINISH ALPHA CHANGE INNBC-SWAP-142AB -- style each history as one box */

#bridge-status,
#bridge-storage-status {
  margin-top: 14px;
}

#bridge-status:empty,
#bridge-storage-status:empty {
  margin: 0;
}

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

@media (max-width: 380px) {
  .wallet-balances {
    grid-template-columns: 1fr;
  }
}
/* FINISH ALPHA CHANGE INNBC-SWAP-117 -- bridge progress and claim cards */