:root {
  --bg: #0a0a0a;
  --panel: #141414;
  --panel-border: rgba(255, 255, 255, 0.08);
  --text: #e5e5e5;
  --muted: #bbbbbb;
  --accent: #e5e5e5;
  --accent-soft: rgba(255, 255, 255, 0.08);
  --button-primary-bg: rgba(255, 255, 255, 0.12);
  --button-primary-bg-hover: rgba(255, 255, 255, 0.18);
  --danger: #ef4444;
  --success: #22c55e;
  --warning: #eab308;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  --card-bg: #1a1a1a;
  --card-border: rgba(255, 255, 255, 0.06);
  --input-bg: #111111;
  --input-border: rgba(255, 255, 255, 0.1);
}

[data-theme="light"] {
  --bg: #f5f5f5;
  --panel: #ffffff;
  --panel-border: rgba(0, 0, 0, 0.08);
  --text: #1a1a1a;
  --muted: #666666;
  --accent: #1a1a1a;
  --accent-soft: rgba(0, 0, 0, 0.06);
  --button-primary-bg: rgba(0, 0, 0, 0.07);
  --button-primary-bg-hover: rgba(0, 0, 0, 0.12);
  --danger: #dc2626;
  --success: #16a34a;
  --warning: #ca8a04;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
  --card-bg: #ffffff;
  --card-border: rgba(0, 0, 0, 0.06);
  --input-bg: #f8f8f8;
  --input-border: rgba(0, 0, 0, 0.1);
}

/* Light theme overrides for hardcoded dark-only values */
[data-theme="light"] .header-panel,
[data-theme="light"] .nav-panel,
[data-theme="light"] .workspace-panel {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .nav-panel {
  background: rgba(0, 0, 0, 0.02);
  border-color: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .workspace-panel {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .nav-panel .tab-button {
  color: rgba(0, 0, 0, 0.5);
}

[data-theme="light"] .nav-panel .tab-button:hover {
  color: #1a1a1a;
  background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .tab-button.is-active {
  color: #1a1a1a;
  background: rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .tab-button.is-disabled {
  color: rgba(0, 0, 0, 0.3);
  opacity: 0.5;
}

[data-theme="light"] .wallet-button,
[data-theme="light"] .primary-button {
  color: #1a1a1a;
  background: rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.1);
  backdrop-filter: none;
}

[data-theme="light"] .wallet-button:hover,
[data-theme="light"] .primary-button:hover {
  background: rgba(0, 0, 0, 0.1);
  border-color: rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .secondary-button {
  color: #1a1a1a;
  border-color: rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .secondary-button:hover {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .icon-button {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.08);
  color: #666;
}

[data-theme="light"] .icon-button:hover {
  background: rgba(0, 0, 0, 0.06);
  border-color: rgba(0, 0, 0, 0.12);
  color: #1a1a1a;
}

[data-theme="light"] .address-display {
  background: rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.06);
  color: #444;
}

[data-theme="light"] .copy-tooltip {
  background: rgba(0, 0, 0, 0.8);
  border-color: transparent;
  color: #fff;
}

[data-theme="light"] .toggle-slider {
  background: rgba(0, 0, 0, 0.12);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
}

[data-theme="light"] .toggle-slider::before {
  background: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .footer-commit {
  background: rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.08);
  color: #1a1a1a;
}

[data-theme="light"] .app-disclaimer {
  color: rgba(0, 0, 0, 0.4);
}

[data-theme="light"] .panel-message.is-error {
  background: rgba(220, 38, 38, 0.08);
  border-color: rgba(220, 38, 38, 0.2);
  color: #dc2626;
}

[data-theme="light"] .panel-message.is-success {
  background: rgba(22, 163, 74, 0.08);
  border-color: rgba(22, 163, 74, 0.2);
  color: #16a34a;
}

[data-theme="light"] .panel-message.is-warning {
  background: rgba(202, 138, 4, 0.08);
  border-color: rgba(202, 138, 4, 0.2);
  color: #ca8a04;
}

[data-theme="light"] .modal-backdrop,
[data-theme="light"] .wallet-modal-backdrop {
  background: rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .modal-card,
[data-theme="light"] .wallet-modal-card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .wallet-list-item:hover {
  background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .wallet-list-arrow {
  color: rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .wallet-list-icon {
  background: rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .status-card,
[data-theme="light"] .tx-card {
  background: #ffffff;
  border-color: rgba(0, 0, 0, 0.06);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: 'Barlow', 'IBM Plex Sans', 'Segoe UI', sans-serif;
  font-size: 14px;
  background: var(--bg);
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
}

.app-shell {
  max-width: 1240px;
  margin: 0 auto;
  padding: 22px 18px 32px;
}

.header-panel,
.nav-panel,
.workspace-panel {
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.header-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
}

.nav-panel {
  display: flex;
  gap: 6px;
  margin-top: 14px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.06);
}

.workspace-panel {
  margin-top: 20px;
  padding: 24px;
  border-color: rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
}

.app-disclaimer {
  margin-top: 22px;
  padding: 0 4px;
  color: rgba(255, 255, 255, 0.5);
  font-family: 'Barlow', sans-serif;
  font-size: 0.68rem;
  font-weight: 300;
  line-height: 1.55;
  text-align: center;
}

.app-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 12px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.75rem;
}

.footer-label {
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.65rem;
}

.footer-commit {
  padding: 0.2rem 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.wallet-box {
  display: flex;
  align-items: center;
  gap: 8px;
}

.copy-button-wrap {
  position: relative;
  display: inline-flex;
}

.brand {
  font-family: 'Instrument Serif', serif;
  font-size: 1.75rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.brand-link {
  display: inline-block;
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  transition: color 200ms ease;
}

.brand-link:hover,
.brand-link:focus-visible {
  color: #ffffff;
}

.brand-tagline {
  margin-top: 4px;
  color: var(--muted);
  font-family: 'Barlow', sans-serif;
  font-size: 0.75rem;
  font-weight: 300;
  line-height: 1.3;
}

.network-select,
.field input,
.field select {
  width: 100%;
  padding: 0.65rem 0.7rem;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  color: var(--text);
  background: var(--card-bg);
}

.network-select,
.field input:not([type='range']),
.address-display {
  min-height: 42px;
}

.network-select {
  width: 132px;
  min-height: 36px;
}

.subtle-text,
.panel-caption,
.balance-meta {
  color: var(--muted);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.wallet-status {
  max-width: 140px;
  color: var(--muted);
  font-size: 0.85rem;
  text-align: right;
  line-height: 1.4;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.icon-button svg {
  width: 14px;
  height: 14px;
}

.icon-button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
}

.copy-tooltip {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 10;
  padding: 0.35rem 0.6rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  font-size: 0.75rem;
  line-height: 1;
  white-space: nowrap;
  box-shadow: var(--shadow);
}

.wallet-button,
.primary-button,
.secondary-button,
.tab-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid transparent;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  text-decoration: none;
  transition:
    background-color 120ms ease,
    border-color 120ms ease;
}

.btn-icon {
  flex-shrink: 0;
  width: 14px;
  height: 14px;
}

.wallet-button,
.primary-button {
  padding: 0.65rem 1rem;
  border-radius: 999px;
  color: #e5e5e5;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  min-height: 36px;
  font-weight: 400;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.wallet-action-button {
  justify-content: center;
}

.secondary-button {
  padding: 0.65rem 1rem;
  border-radius: 999px;
  color: var(--text);
  background: transparent;
  border-color: rgba(255, 255, 255, 0.1);
  transition: background 0.2s ease, border-color 0.2s ease;
}

.wallet-button:disabled,
.primary-button:disabled,
.secondary-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.tab-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0.6rem 0.85rem;
  border-radius: 10px;
  color: var(--muted);
  background: transparent;
  border-color: transparent;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-panel .tab-button {
  border-radius: 999px;
  padding: 0 16px 0 12px;
  min-height: 36px;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 400;
  font-size: 0.875rem;
  background: transparent;
  border: 1px solid transparent;
}

.nav-panel .tab-button .btn-icon {
  width: 16px;
  height: 16px;
}

.profile-indicator {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.profile-indicator.red {
  background: var(--danger);
}

.profile-indicator.green {
  background: var(--success);
}

.profile-indicator.yellow {
  background: var(--warning);
  animation: profile-pulse 1.5s ease-in-out infinite;
}

@keyframes profile-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.tab-button.is-active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.1);
}

.tab-button.is-disabled {
  color: rgba(255, 255, 255, 0.45);
  background: transparent;
  border-color: transparent;
  cursor: not-allowed;
  opacity: 0.5;
}

.wallet-button:hover,
.primary-button:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
}

.secondary-button:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
}

.tab-button:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.panel {
  padding: 18px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

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

.panel-header h2 {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-family: 'Space Grotesk', 'IBM Plex Sans', sans-serif;
  font-size: 1rem;
}

.panel-header h2 .btn-icon {
  width: 18px;
  height: 18px;
  color: var(--muted);
}

.panel-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.title-with-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.48rem;
  border-radius: 999px;
  font-size: 0.72rem;
  line-height: 1;
  white-space: nowrap;
}

.status-badge.is-paused {
  color: #8e4b5f;
  background: rgba(239, 68, 68, 0.12);
}

.panel-lead {
  margin: 12px 0 0;
  max-width: 62ch;
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.9rem;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
}

.loan-action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-left: auto;
}

.loan-action-button.is-repay {
  border-color: rgb(108 154 122 / 35%);
  background: rgb(126 173 140 / 16%);
  color: rgb(45 94 59);
}

.loan-action-button.is-liquidate {
  border-color: rgb(185 118 118 / 34%);
  background: rgb(201 129 129 / 16%);
  color: rgb(126 52 52);
}

.loan-action-button.is-repay:hover:not(:disabled),
.loan-action-button.is-repay:focus-visible:not(:disabled) {
  background: rgb(126 173 140 / 24%);
}

.loan-action-button.is-liquidate:hover:not(:disabled),
.loan-action-button.is-liquidate:focus-visible:not(:disabled) {
  background: rgb(201 129 129 / 24%);
}

.pagination-row {
  align-items: center;
  justify-content: space-between;
}

.registration-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
}

.registration-banner-copy {
  min-width: 0;
}

.registration-detail {
  margin-top: 4px;
  font-size: 0.82rem;
  line-height: 1.45;
}

.registration-transaction {
  margin-top: 10px;
}

.registration-signature {
  display: inline-block;
  margin-left: 8px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.78rem;
  word-break: break-all;
}

.panel-message {
  margin: 14px 0;
  padding: 14px 18px;
  border: 1px solid transparent;
  border-radius: 5px;
}

.panel-message + .panel-message {
  margin-top: -8px;
}

.dismissible-message {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.panel-message.is-error {
  color: var(--danger);
  background: rgba(239, 68, 68, 0.1);
  border-color: rgba(239, 68, 68, 0.25);
}

.panel-message.is-success {
  color: var(--success);
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.25);
}

.panel-message.is-warning {
  color: var(--warning);
  background: rgba(234, 179, 8, 0.1);
  border-color: rgba(234, 179, 8, 0.25);
}

.panel-message-subtle {
  margin-top: 6px;
  font-size: 0.88rem;
  opacity: 0.8;
}

.transaction-notice {
  margin-top: 14px;
  padding: 12px 18px;
  border: 1px solid var(--card-border);
  background: var(--card-bg);
}

.transaction-notice-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.transaction-notice-meta {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
}

.transaction-notice-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.transaction-notice-label {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}

.transaction-notice-signature {
  overflow-wrap: anywhere;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.82rem;
  line-height: 1.45;
}

.transaction-notice-link {
  color: #2b63b8;
  text-decoration: none;
  cursor: pointer;
}

.transaction-notice-link:hover,
.transaction-notice-link:focus-visible {
  color: #4a7ecb;
}

.transaction-notice-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.3rem;
  height: 1.3rem;
  margin-top: 0.1rem;
  border-radius: 999px;
  flex: 0 0 auto;
  font-size: 0.9rem;
  line-height: 1;
}

.transaction-notice-icon.is-pending {
  color: var(--muted);
  background: rgb(23 22 20 / 6%);
}

.transaction-notice-icon.is-success {
  color: rgb(36 102 58);
  background: rgb(129 186 146 / 18%);
}

.transaction-notice-icon.is-error {
  color: rgb(142 58 58);
  background: rgb(213 142 142 / 18%);
}

.transaction-spinner {
  width: 0.78rem;
  height: 0.78rem;
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-top-color: rgba(255, 255, 255, 0.6);
  border-radius: 999px;
  animation: transaction-spin 0.9s linear infinite;
}

.transaction-notice-close {
  padding: 0;
  border: 0;
  color: #8f8a81;
  font-size: 1rem;
  line-height: 1;
  background: transparent;
  cursor: pointer;
}

.transaction-notice-close:hover,
.transaction-notice-close:focus-visible {
  color: var(--text);
}

.transaction-notice-trace {
  margin-top: 12px;
  padding: 10px 12px;
  color: rgb(126 52 52);
  background: rgb(201 129 129 / 10%);
  overflow: auto;
}

.transaction-notice-trace pre {
  margin: 0;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.76rem;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

@keyframes transaction-spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.launch-config-detail {
  color: var(--muted);
  font-size: 0.9rem;
}

.launch-config-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.4rem;
  height: 1.4rem;
  border-radius: 999px;
  font-size: 0.9rem;
  line-height: 1;
}

.launch-config-status.is-active {
  color: rgb(36 102 58);
  background: rgb(129 186 146 / 18%);
}

.launch-config-status.is-paused {
  color: rgb(142 58 58);
  background: rgb(213 142 142 / 18%);
}

.launch-config-note {
  margin-top: 12px;
}

.address-inline {
  overflow-wrap: anywhere;
}

.debug-address-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.debug-address-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.debug-address-label {
  color: var(--muted);
  font-size: 0.8rem;
}

.debug-address-value {
  overflow-wrap: anywhere;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.8rem;
}

.empty-state.compact {
  margin-top: 8px;
  padding: 10px 12px;
}

.message-close {
  padding: 0;
  border: 0;
  color: currentcolor;
  font-size: 1rem;
  line-height: 1;
  background: transparent;
  cursor: pointer;
}

.balance-list {
  margin-top: 18px;
}

.vault-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.launch-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.profile-account-section {
  margin-top: 18px;
}

.profile-account-row {
  align-items: flex-start;
}

.profile-account-value {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.address-value-with-link {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

.explorer-link-button {
  text-decoration: none;
}



.vault-card {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--card-border);
  color: var(--text);
  text-decoration: none;
  background: var(--card-bg);
}

.vault-card:hover {
  background: #1f1f1f;
}

.vault-card-header {
  min-width: 0;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.84rem;
  line-height: 1.45;
}

.loan-card-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.pool-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pool-card-title {
  display: inline-block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.token-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.token-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.loan-card-header .vault-card-address {
  display: inline-block;
  min-width: 0;
}

.loan-card-created-at {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 400;
  text-align: right;
  white-space: nowrap;
  flex-shrink: 0;
}

.vault-card-address {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vault-card-meta,
.vault-card-meta-row {
  min-width: 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.vault-card-header strong,
.vault-card-meta,
.vault-card-meta-row,
.middle-ellipsis {
  display: block;
  min-width: 0;
}

.vault-card-meta-row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  align-items: center;
  column-gap: 12px;
}

.vault-card-address-value {
  display: flex;
  justify-content: flex-end;
  min-width: 0;
  text-align: right;
}

.middle-ellipsis {
  display: flex;
  align-items: baseline;
  min-width: 0;
  max-width: 100%;
  white-space: nowrap;
}

.middle-ellipsis-head {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.middle-ellipsis-tail {
  flex: 0 0 auto;
  white-space: nowrap;
}

.vault-card-divider {
  height: 1px;
  margin: 2px 0 4px;
  background: var(--panel-border);
}

.vault-card-grid,
.vault-detail-grid {
  display: grid;
  gap: 10px;
  align-items: start;
}

.vault-card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 24px;
  color: var(--text);
  font-size: 0.82rem;
}

.vault-card-metric {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: baseline;
  column-gap: 12px;
  min-width: 0;
}

.vault-card-metric-label {
  min-width: 0;
  color: var(--muted);
}

.vault-card-metric-value {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.vault-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 18px;
}

.balance-row,
.status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.balance-row {
  padding: 14px 0;
  border-top: 1px solid var(--card-border);
}

.balance-label,
.balance-value {
  font-weight: 600;
}

.balance-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.balance-send-button {
  min-height: 32px;
  padding: 0.45rem 0.8rem;
}

.empty-state,
.status-card,
.tx-card {
  margin-top: 18px;
  padding: 14px;
  border-radius: 8px;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
}

.loan-ticks-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.status-card {
  display: grid;
  gap: 12px;
}

.tx-card {
  display: grid;
  gap: 8px;
}

.tx-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tx-label,
.address-field-label,
.field span {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
}

.tx-signature,
.address-display,
.address-value {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.82rem;
  line-height: 1.45;
  word-break: break-all;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: rgba(0, 0, 0, 0.65);
}

.modal-shell {
  position: fixed;
  inset: 0;
  z-index: 21;
  display: grid;
  place-items: center;
  padding: 18px;
}

.modal-card {
  width: min(100%, 520px);
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--panel-border);
  border-radius: 5px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.bundle-confirm-body {
  display: grid;
  gap: 10px;
}

.bundle-confirm-summary {
  display: grid;
  gap: 6px;
}

.profile-tools-section {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--panel-border);
}

.position-section {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--panel-border);
}

.launch-form-section {
  margin-top: 24px;
  padding-top: 0;
  border-top: 0;
}

.preset-section-title {
  margin: 0 0 14px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.preset-group {
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  background: var(--card-bg);
}

.preset-group > .preset-section-title {
  margin-top: 0;
}

.preset-group + .preset-group {
  margin-top: 14px;
}

.preset-group > .address-field-list {
  margin-top: 0;
}

.preset-group > .preset-fields {
  margin-top: 0;
}

.preset-mint-field {
  display: flex;
  align-items: center;
  gap: 8px;
}

.preset-mint-field > span:first-child {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.preset-key-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.preset-mint-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.preset-mint-actions > .secondary-button {
  flex: 1;
  min-width: 0;
}

.preset-icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.preset-icon-button > svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.preset-key-icon {
  width: 16px;
  height: 16px;
}

.preset-key-icon.is-present {
  color: var(--success);
}

.preset-key-icon.is-missing {
  color: var(--muted);
}

.preset-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.preset-fields > li {
  flex: 1 1 240px;
  min-width: 0;
  max-width: 100%;
}

.preset-field-spacer {
  display: none;
}

@media (min-width: 560px) {
  .preset-field-spacer {
    display: block;
  }
}

.position-paginator {
  display: flex;
  gap: 10px;
  margin-top: 18px;
  padding-bottom: 4px;
  overflow-x: auto;
}

.position-pill {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--panel-border);
  color: var(--muted);
  background: var(--card-bg);
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color 160ms ease,
    border-color 160ms ease,
    color 160ms ease;
}

.position-pill:hover,
.position-pill:focus-visible {
  border-color: rgba(255, 255, 255, 0.12);
  background: #1f1f1f;
  color: var(--text);
}

.position-pill.is-active {
  color: var(--text);
  background: var(--accent-soft);
}

.position-form-card {
  display: grid;
  gap: 14px;
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--card-border);
  background: var(--card-bg);
}

.position-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.position-form-column {
  display: grid;
  align-content: start;
  align-items: start;
  grid-auto-rows: min-content;
  gap: 14px;
  min-width: 0;
}

.position-subtabs {
  display: flex;
  gap: 10px;
  padding-bottom: 4px;
  overflow-x: auto;
}

.position-subtab {
  flex: 0 0 auto;
  padding: 0.55rem 0.8rem;
  border: 1px solid var(--panel-border);
  color: var(--muted);
  background: var(--card-bg);
  cursor: pointer;
}

.position-subtab.is-active {
  color: var(--text);
  background: var(--accent-soft);
}

.range-field input[type='range'] {
  display: block;
  width: 100%;
  height: 18px;
  padding: 0;
  border: 0;
  appearance: none;
  background: transparent;
  box-sizing: border-box;
}

.range-field input[type='range']::-webkit-slider-runnable-track {
  width: 100%;
  height: 4px;
  border: 0;
  background: var(--accent-soft);
}

.range-field input[type='range']::-webkit-slider-thumb {
  width: 14px;
  height: 14px;
  margin-top: -5px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  appearance: none;
  background: var(--card-bg);
  box-shadow: 0 1px 2px rgb(23 22 20 / 14%);
  cursor: pointer;
}

.range-field input[type='range']::-moz-range-track {
  width: 100%;
  height: 4px;
  border: 0;
  background: var(--accent-soft);
}

.range-field input[type='range']::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  background: var(--card-bg);
  box-shadow: 0 1px 2px rgb(23 22 20 / 14%);
  cursor: pointer;
}

.range-field input[type='range']::-moz-range-progress {
  height: 4px;
  background: var(--accent);
}

.range-field input[type='range']:disabled::-webkit-slider-thumb,
.range-field input[type='range']:disabled::-moz-range-thumb {
  cursor: not-allowed;
  opacity: 0.6;
}

.slider-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 18px;
  color: var(--muted);
  font-size: 0.78rem;
}

.profile-tools,
.protocol-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.configuration-main {
  min-width: 0;
}

.configuration-main > .status-card:first-child,
.configuration-main > .empty-state:first-child {
  margin-top: 0;
}

.configuration-sidebar {
  align-self: start;
}

.address-field-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  align-items: start;
}

.configuration-main .address-field-list {
  margin-top: 0;
}

.address-field-list.two-columns {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.address-field {
  display: grid;
  align-content: start;
  gap: 6px;
}

.address-field-label {
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.address-display {
  padding: 0.65rem 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
}

.mints-actions-cell,
.queue-actions-cell {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  white-space: nowrap;
}

.address-display-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  width: 100%;
}

.address-display-inline > span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.address-display-inline > a,
.address-display-inline > .icon-button {
  margin-left: auto;
  flex-shrink: 0;
}

.field {
  display: grid;
  align-content: start;
  align-items: start;
  gap: 6px;
}

.field > span,
.address-field-label {
  min-height: 16px;
  line-height: 1.2;
}

.configuration-main .address-field {
  position: relative;
  min-height: 42px;
}

.configuration-main .address-field-label {
  position: absolute;
  top: 8px;
  right: 10px;
  min-height: 0;
  color: var(--muted);
  font-size: 0.45rem;
  line-height: 1;
  text-align: right;
}

.configuration-main .address-display {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 42px;
}

.configuration-sidebar .address-display {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.configuration-sidebar .address-display > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.launch-config-section {
  margin-top: 18px;
}

.launch-config-root > .panel-header {
  margin-bottom: 0;
}

.launch-config-section .panel-header {
  margin-bottom: 12px;
}

.launch-config-section .address-field-list {
  margin-top: 0;
}

.launch-config-section .address-display {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
}

.field input:not([type='range']) {
  margin: 0;
  line-height: 1.2;
}

.field input[type='range'] {
  margin: 0;
}

.readonly-input {
  cursor: not-allowed;
  color: var(--muted);
  background: #1a1a1a !important;
}

.network-select:focus,
.field input:focus {
  outline: 2px solid rgba(255, 255, 255, 0.1);
  outline-offset: 1px;
}

@media (width <= 720px) {
  .app-shell {
    padding: 18px 14px 28px;
  }

  .header-panel,
  .header-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .wallet-status {
    max-width: none;
    text-align: left;
  }

  .network-select {
    width: 100%;
  }

  .balance-row,
  .status-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .vault-card-grid,
  .vault-detail-grid,
  .loan-ticks-list,
  .position-form-grid,
  .address-field-list.two-columns,
  .profile-tools,
  .protocol-grid {
    grid-template-columns: 1fr;
  }

  /* Nav panel: labels disappear on narrow screens so 6 icon pills fit in
     one row without overflowing. The SVG icon is visible-only content; text
     nodes are hidden via font-size 0 so accessible name is preserved via the
     label text inside the link — screen readers still announce it. */
  .nav-panel {
    gap: 6px;
    padding: 10px 12px;
    justify-content: space-between;
    flex-wrap: nowrap;
  }

  .nav-panel .tab-button {
    flex: 1 1 0;
    gap: 0;
    padding: 0;
    min-width: 0;
    font-size: 0;
    justify-content: center;
  }

  .nav-panel .tab-button .btn-icon {
    width: 18px;
    height: 18px;
  }
}

@media (width <= 1024px) {
  .vault-list {
    grid-template-columns: 1fr;
  }
}

.setting-hint {
  font-size: 0.75rem;
  margin-top: 8px;
}

.inline-link {
  background: none;
  border: none;
  padding: 0;
  color: var(--accent);
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
  font-family: monospace;
  font-size: 0.75rem;
  word-break: break-all;
  text-align: left;
}

.bundle-wallets-table-wrap {
  overflow-x: auto;
}

.bundle-wallets-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.7rem;
}

.bundle-wallets-table th,
.bundle-wallets-table td {
  padding: 4px 6px;
  text-align: left;
  border-bottom: 1px solid var(--panel-border);
}

.bundle-wallets-table th {
  font-weight: 600;
  color: var(--muted);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

/* Three-column layout (Address, Receive, Status+Action). table-layout:fixed
   makes column widths fully predictable regardless of content, so status
   label changes never reflow neighbouring cells. Address column takes half
   the table width (since base58 keys are long), while Receive and the
   Status+Action column each take a quarter. */
.alts-table {
  table-layout: fixed;
}

.alts-table th,
.alts-table td {
  white-space: nowrap;
}

.alts-table th:first-child,
.alts-table td:first-child {
  width: 50%;
}

.alts-table th:nth-child(2),
.alts-table td:nth-child(2),
.alts-table th:last-child,
.alts-table td:last-child {
  width: 25%;
}

.alts-table th:first-child,
.alts-table td:first-child,
.alts-table th:nth-child(2),
.alts-table td:nth-child(2) {
  text-align: left;
}

/* Last column holds the action button and the status label side-by-side and
   is right-aligned so both cell content and the column header hug the table's
   right edge. */
.alts-table th:last-child,
.alts-table td:last-child {
  text-align: right;
}

.alts-action-cell-inner {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-end;
}

.alts-status-label {
  color: var(--muted);
}

.check-passed-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 12px 0;
  padding: 12px 16px;
  background: rgba(34, 197, 94, 0.1);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: 4px;
  text-align: center;
}

.check-passed-banner svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.readiness-issue {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.readiness-issue-text {
  flex: 1;
}

.copy-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--text);
  color: var(--panel);
  padding: 8px 16px;
  border-radius: 4px;
  font-size: 0.8rem;
  z-index: 10000;
  box-shadow: 0 4px 12px rgb(0 0 0 / 15%);
  animation: copy-toast-fade 0.2s ease-out;
}

@keyframes copy-toast-fade {
  from { opacity: 0; transform: translate(-50%, 8px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

.address-copy-btn {
  background: none;
  border: none;
  padding: 0;
  color: var(--accent);
  text-decoration: underline;
  cursor: pointer;
  font: inherit;
  font-family: monospace;
}

.address-copy-btn:hover {
  opacity: 0.7;
}

.bundle-wallets-table .bundle-row-funded td {
  background: rgba(34, 197, 94, 0.08);
}

.bundle-wallets-table .bundle-row-low td {
  background: rgba(239, 68, 68, 0.08);
}

.bundle-wallets-table .address-cell {
  font-family: monospace;
  font-size: 0.7rem;
  white-space: nowrap;
}

.address-cell-inner {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.address-explorer-link {
  display: inline-flex;
  align-items: center;
  color: var(--muted);
  opacity: 0.7;
}

.address-explorer-link:hover {
  opacity: 1;
}

.address-explorer-link svg {
  width: 12px;
  height: 12px;
}

.runtime-alt-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.runtime-alt-row input {
  flex: 1;
  min-width: 0;
}

.runtime-alt-row button {
  flex-shrink: 0;
}

.toggle-switch {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 22px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15);
  border-radius: 11px;
  cursor: pointer;
  transition: background 0.2s;
}

.toggle-slider::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 2px;
  width: 18px;
  height: 18px;
  background: #ffffff;
  border-radius: 50%;
  transition: transform 0.2s;
}

.toggle-switch input:checked + .toggle-slider {
  background: var(--success);
}

.toggle-switch input:checked + .toggle-slider::before {
  transform: translateX(18px);
}

/* ==========================================================================
   WALLET SELECT MODAL
   ========================================================================== */

.wallet-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: none;
  cursor: default;
}

.wallet-modal-backdrop + .modal-shell {
  z-index: 101;
}

.wallet-modal-card {
  width: min(100%, 400px);
  padding: 0;
  border-radius: 16px;
  background: #1a1a1a;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.wallet-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.wallet-modal-title {
  font-family: 'Barlow', sans-serif;
  font-size: 1.1rem;
  font-weight: 500;
  color: #e5e5e5;
  margin: 0;
}

.wallet-list {
  list-style: none;
  margin: 0;
  padding: 8px;
}

.wallet-list li {
  margin: 0;
}

.wallet-list-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px 16px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: #e5e5e5;
  font: inherit;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 0.2s ease;
}

.wallet-list-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.wallet-list-item:active {
  background: rgba(255, 255, 255, 0.1);
}

.wallet-list-item:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.wallet-list-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: contain;
  background: rgba(255, 255, 255, 0.05);
  flex-shrink: 0;
}

.wallet-list-name {
  flex: 1;
  text-align: left;
  font-weight: 400;
}

.wallet-list-arrow {
  width: 16px;
  height: 16px;
  color: rgba(255, 255, 255, 0.5);
  flex-shrink: 0;
}

.wallet-empty {
  padding: 32px 24px;
  text-align: center;
}

.wallet-empty-text {
  color: #e5e5e5;
  font-size: 0.95rem;
  margin: 0 0 12px;
}

.wallet-empty-hint {
  color: #888;
  font-size: 0.85rem;
  line-height: 1.6;
  margin: 0;
}

.wallet-empty-link {
  color: #e5e5e5;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.wallet-empty-link:hover {
  color: #fff;
}

.wallet-modal-error {
  padding: 12px 24px 16px;
  font-size: 0.82rem;
  color: #f87171;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* ==========================================================================
   MOONO LANDING PAGE
   Full-screen cinematic landing — index route only.
   All classes prefixed .ml-* to avoid collision with app styles.
   ========================================================================== */

/* --- Liquid Glass Utilities --- */

.liquid-glass {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.liquid-glass-strong {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* --- Landing Root --- */

.moono-landing {
  width: 100%;
  color: #ffffff;
  font-family: 'Barlow', -apple-system, sans-serif;
  background: #0a0a0a;
}

/* --- Shared Section --- */

.ml-section {
  position: relative;
  padding: 100px 0;
}

.ml-section-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.ml-section-header {
  text-align: center;
  margin-bottom: 64px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.ml-section-header.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-section-tag {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 20px;
}

.ml-section-title {
  font-family: 'PPMondwest', serif;
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 400;
  letter-spacing: -2px;
  line-height: 1;
  margin: 0 0 20px;
  color: #ffffff;
}

.ml-section-sub {
  font-weight: 300;
  font-size: 1.05rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.8);
  max-width: 600px;
  margin: 0 auto;
}

/* --- Shared Button --- */

.ml-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Barlow', sans-serif;
  font-size: 0.9rem;
  font-weight: 400;
  color: #ffffff;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  text-decoration: none;
  transition: background 0.3s ease, transform 0.15s ease;
}

.ml-btn:hover {
  transform: translateY(-1px);
}

.ml-cta-primary {
  padding: 14px 28px;
  border-radius: 999px;
}

.ml-cta-primary:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: scale(1.03);
}

.ml-cta-secondary {
  padding: 14px 20px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: transparent;
}

.ml-cta-secondary:hover {
  background: rgba(255, 255, 255, 0.06);
}

.ml-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}


/* --- Hero Section --- */

.ml-hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.ml-hero-video-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.ml-hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: right;
  display: block;
}

.ml-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.3) 0%,
    rgba(0, 0, 0, 0.05) 40%,
    rgba(0, 0, 0, 0.4) 100%
  );
  pointer-events: none;
}

/* --- Navigation --- */

.ml-nav {
  position: relative;
  z-index: 10;
  padding: 24px 32px;
  opacity: 0;
  transform: translateY(-12px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.ml-nav.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.ml-nav-logo {
  font-family: 'Instrument Serif', serif;
  font-size: 1.75rem;
  color: #ffffff;
  letter-spacing: -0.02em;
  line-height: 1;
}

.ml-nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
}

.ml-nav-link {
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 400;
  transition: color 0.25s ease;
}

.ml-nav-link:hover {
  color: #ffffff;
}

.ml-nav-cta {
  padding: 10px 24px;
  border-radius: 999px;
  font-size: 0.85rem;
}

.ml-nav-cta:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: scale(1.03);
}

/* --- Hero Content --- */

.ml-hero-content {
  position: relative;
  z-index: 10;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 96px 32px 48px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.ml-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 0.8rem;
  width: fit-content;
  margin-bottom: 32px;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.7s ease 0.2s, transform 0.7s ease 0.2s;
}

.ml-hero-badge.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-hero-badge-tag {
  background: rgba(255, 255, 255, 0.15);
  padding: 2px 10px;
  border-radius: 999px;
  font-weight: 400;
  font-size: 0.75rem;
  color: #ffffff;
}

.ml-hero-badge-text {
  color: rgba(255, 255, 255, 0.8);
}

.ml-hero-headline {
  font-family: 'PPMondwest', serif;
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 400;
  line-height: 0.85;
  letter-spacing: -4px;
  margin: 0 0 32px;
  color: #ffffff;
}

.blur-text {
  display: inline;
}

.blur-word {
  display: inline-block;
  opacity: 0;
  will-change: filter, opacity, transform;
}

.ml-hero-sub {
  font-weight: 300;
  font-size: 1.05rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.85);
  max-width: 540px;
  margin: 0 0 36px;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s ease 0.6s, transform 0.8s ease 0.6s;
}

.ml-hero-sub.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-hero-cta-group {
  display: flex;
  align-items: center;
  gap: 20px;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s ease 0.8s, transform 0.8s ease 0.8s;
}

.ml-hero-cta-group.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Stats Bar --- */

.ml-stats-bar {
  position: relative;
  z-index: 10;
  display: flex;
  justify-content: center;
  gap: 48px;
  padding: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s ease 1s, transform 0.8s ease 1s;
}

.ml-stats-bar.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.ml-stat-value {
  font-family: 'Instrument Serif', serif;
  font-size: 1.15rem;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.ml-stat-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.6);
}

/* --- How It Works Section --- */

.ml-how {
  background: #0a0a0a;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ml-steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.ml-step-card {
  padding: 32px 24px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease, border-color 0.3s ease;
}

.ml-step-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-step-card:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.ml-step-number {
  display: block;
  font-family: 'Instrument Serif', serif;
  font-size: 2rem;
  color: rgba(255, 255, 255, 0.15);
  margin-bottom: 16px;
  line-height: 1;
}

.ml-step-title {
  font-family: 'Barlow', sans-serif;
  font-size: 1.1rem;
  font-weight: 400;
  color: #ffffff;
  margin: 0 0 12px;
}

.ml-step-desc {
  font-weight: 300;
  font-size: 0.88rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.75);
  margin: 0;
}

/* --- Features Section --- */

.ml-features {
  background: #0d0d0d;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.ml-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.ml-feature-card {
  padding: 32px 24px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.025);
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease, border-color 0.3s ease;
}

.ml-feature-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-feature-card:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.ml-feature-icon-wrap {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  margin-bottom: 20px;
  color: rgba(255, 255, 255, 0.6);
}

.ml-feature-icon-wrap .btn-icon {
  width: 20px;
  height: 20px;
}

.ml-feature-title {
  font-family: 'Barlow', sans-serif;
  font-size: 1.05rem;
  font-weight: 400;
  color: #ffffff;
  margin: 0 0 10px;
}

.ml-feature-desc {
  font-weight: 300;
  font-size: 0.88rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.75);
  margin: 0;
}

/* --- Final CTA Section --- */

.ml-final-cta {
  background: #0a0a0a;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 120px 0;
}

.ml-cta-block {
  text-align: center;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.ml-cta-block.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ml-cta-headline {
  font-family: 'PPMondwest', serif;
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 400;
  letter-spacing: -2px;
  line-height: 1;
  margin: 0 0 20px;
  color: #ffffff;
}

.ml-cta-sub {
  font-weight: 300;
  font-size: 1.05rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.8);
  max-width: 480px;
  margin: 0 auto 36px;
}

.ml-cta-buttons {
  display: flex;
  justify-content: center;
  gap: 16px;
}

/* --- Footer --- */

.ml-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 48px 32px 24px;
  background: #0a0a0a;
}

.ml-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.ml-footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.ml-footer-brand-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ml-footer-brand {
  font-family: 'Instrument Serif', serif;
  font-size: 1.5rem;
  color: #e5e5e5;
}

.ml-footer-desc {
  font-size: 0.85rem;
  font-weight: 300;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.6);
  max-width: 280px;
  margin: 0;
}

.ml-footer-links-col {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.ml-footer-heading {
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
}

.ml-footer-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ml-footer-link {
  font-size: 0.85rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: color 0.2s ease;
}

.ml-footer-link:hover {
  color: #ffffff;
}

.ml-footer-bottom {
  padding-top: 20px;
  text-align: center;
}

.ml-footer-copy {
  font-size: 0.72rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.4);
}

/* --- Responsive: Tablet (<=1024px) --- */

@media (max-width: 1024px) {
  .ml-nav { padding: 20px 24px; }
  .ml-nav-links { gap: 18px; }
  .ml-hero-content { padding: 80px 24px 40px; }
  .ml-hero-headline { letter-spacing: -3px; }
  .ml-stats-bar { gap: 32px; padding: 24px; }
  .ml-steps-grid { grid-template-columns: repeat(2, 1fr); }
  .ml-features-grid { grid-template-columns: repeat(2, 1fr); }
  .ml-section { padding: 80px 0; }
}

/* --- Responsive: Mobile (<=768px) --- */

@media (max-width: 768px) {
  .ml-nav { padding: 16px 20px; }
  .ml-nav-links { display: none; }
  .ml-nav-logo { font-size: 1.4rem; }
  .ml-nav-cta { padding: 8px 18px; font-size: 0.8rem; }

  .ml-hero-content {
    padding: 40px 20px 24px;
    justify-content: center;
  }

  .ml-hero-headline {
    font-size: clamp(2.5rem, 11vw, 3.8rem);
    letter-spacing: -2px;
    line-height: 0.88;
    margin-bottom: 20px;
  }

  .ml-hero-sub {
    font-size: 0.88rem;
    margin-bottom: 28px;
  }

  .ml-hero-badge {
    margin-bottom: 20px;
    font-size: 0.72rem;
    padding: 5px 12px;
    gap: 8px;
  }

  .ml-hero-badge-tag {
    font-size: 0.65rem;
    padding: 2px 8px;
  }

  .ml-hero-cta-group {
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }

  .ml-cta-primary {
    padding: 12px 22px;
    font-size: 0.85rem;
  }

  .ml-cta-secondary {
    padding: 12px 18px;
    font-size: 0.85rem;
  }

  .ml-stats-bar {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
  }

  .ml-stat {
    align-items: flex-start;
  }

  .ml-stat-value {
    font-size: 1rem;
  }

  .ml-stat-label {
    font-size: 0.62rem;
  }

  .ml-section { padding: 56px 0; }
  .ml-section-inner { padding: 0 20px; }
  .ml-section-header { margin-bottom: 36px; }

  .ml-section-title {
    font-size: clamp(1.8rem, 7vw, 2.5rem);
    letter-spacing: -1.5px;
  }

  .ml-section-sub {
    font-size: 0.9rem;
  }

  .ml-steps-grid { grid-template-columns: 1fr; gap: 12px; }
  .ml-features-grid { grid-template-columns: 1fr; gap: 12px; }

  .ml-step-card,
  .ml-feature-card {
    padding: 24px 20px;
  }

  .ml-step-number {
    font-size: 1.5rem;
    margin-bottom: 10px;
  }

  .ml-cta-buttons {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }

  .ml-final-cta { padding: 64px 0; }

  .ml-cta-headline {
    font-size: clamp(1.8rem, 7vw, 2.5rem);
    letter-spacing: -1.5px;
  }

  .ml-cta-sub {
    font-size: 0.9rem;
  }

  .ml-footer {
    padding: 36px 20px 20px;
  }

  .ml-footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .ml-footer-brand-col {
    grid-column: 1 / -1;
  }

  .ml-footer-desc {
    max-width: 100%;
  }

  .ml-partner-name {
    font-size: 1rem;
  }

  .ml-partners-logos {
    flex-wrap: wrap;
    gap: 16px 24px;
    justify-content: center;
  }
}

/* --- Responsive: Small Phone (<=480px) --- */

@media (max-width: 480px) {
  .ml-hero-content { padding: 32px 16px 20px; }

  .ml-hero-headline {
    font-size: 2.4rem;
    letter-spacing: -1.5px;
  }

  .ml-hero-sub { font-size: 0.82rem; }
  .ml-section-inner { padding: 0 16px; }

  .ml-stats-bar {
    gap: 14px;
    padding: 16px;
  }

  .ml-hero-cta-group {
    flex-direction: column;
    align-items: flex-start;
  }

  .ml-section { padding: 48px 0; }
  .ml-final-cta { padding: 48px 0; }

  .ml-footer-top {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}
