/* Loaded after vendor wallet CSS */

header nav.app-header-nav {
  display: none !important;
}

@media (min-width: 640px) {
  header nav.app-header-nav {
    display: flex !important;
    flex-shrink: 0 !important;
  }
}

header .header-nav-link {
  display: inline-flex !important;
  align-items: center !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  color: #475569 !important;
  text-decoration: none !important;
  padding: 0.25rem 0.5rem !important;
  white-space: nowrap !important;
  opacity: 1 !important;
  visibility: visible !important;
  width: auto !important;
  max-width: none !important;
  overflow: visible !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  cursor: pointer !important;
  -webkit-text-fill-color: #475569 !important;
}

header .header-nav-link:hover {
  color: #0f172a !important;
  -webkit-text-fill-color: #0f172a !important;
  background: transparent !important;
}

header a.header-start-migration {
  display: none !important;
}

@media (min-width: 768px) {
  header a.header-start-migration {
    display: inline-flex !important;
  }
}

header .header-connect-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.5rem !important;
  min-height: 2.375rem !important;
  padding: 0.4375rem 1rem !important;
  border-radius: 9999px !important;
  font-size: 0.875rem !important;
  font-weight: 600 !important;
  line-height: 1.25rem !important;
  letter-spacing: -0.01em !important;
  white-space: nowrap !important;
  opacity: 1 !important;
  cursor: pointer !important;
  border: none !important;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background 180ms ease,
    border-color 180ms ease,
    color 180ms ease !important;
}

header .header-connect-btn:focus-visible {
  outline: 2px solid rgba(147, 51, 234, 0.45) !important;
  outline-offset: 2px !important;
}

header .header-connect-btn--disconnected {
  color: #ffffff !important;
  background: linear-gradient(135deg, #9333ea 0%, #7c3aed 45%, #6366f1 100%) !important;
  box-shadow:
    0 1px 2px rgba(15, 23, 42, 0.06),
    0 4px 16px rgba(124, 58, 237, 0.32) !important;
}

header .header-connect-btn--disconnected:hover {
  color: #ffffff !important;
  background: linear-gradient(135deg, #a855f7 0%, #8b5cf6 45%, #818cf8 100%) !important;
  box-shadow:
    0 2px 4px rgba(15, 23, 42, 0.08),
    0 8px 24px rgba(124, 58, 237, 0.38) !important;
  transform: translateY(-1px) !important;
}

header .header-connect-btn--disconnected:active {
  color: #ffffff !important;
  background: linear-gradient(135deg, #7e22ce 0%, #6d28d9 45%, #4f46e5 100%) !important;
  box-shadow: 0 2px 8px rgba(124, 58, 237, 0.28) !important;
  transform: translateY(0) !important;
}

header .header-connect-btn--connected {
  color: #0f172a !important;
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06) !important;
}

header .header-connect-btn--connected:hover {
  color: #0f172a !important;
  background: #fafafa !important;
  border-color: #c4b5fd !important;
  box-shadow: 0 4px 14px rgba(124, 58, 237, 0.12) !important;
  transform: translateY(-1px) !important;
}

header .header-connect-btn--connected:active {
  color: #0f172a !important;
  background: #f8fafc !important;
  border-color: #ddd6fe !important;
  transform: translateY(0) !important;
}

header .header-connect-btn__status {
  width: 0.5rem !important;
  height: 0.5rem !important;
  border-radius: 9999px !important;
  background: #22c55e !important;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2) !important;
  flex-shrink: 0 !important;
}

header .header-menu-btn,
header .header-menu-btn:hover {
  opacity: 1 !important;
  color: #475569 !important;
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  padding: 0 !important;
  cursor: pointer;
}

.privacy-consent-banner .privacy-consent-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  opacity: 1 !important;
  cursor: pointer !important;
  font-weight: 600 !important;
  border-radius: 9999px !important;
  transition:
    transform 150ms ease,
    box-shadow 150ms ease,
    background 150ms ease,
    border-color 150ms ease,
    color 150ms ease !important;
}

.privacy-consent-banner .privacy-consent-btn--ghost,
.privacy-consent-banner .privacy-consent-btn--ghost:hover,
.privacy-consent-banner .privacy-consent-btn--ghost:active {
  color: #334155 !important;
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  box-shadow: none !important;
}

.privacy-consent-banner .privacy-consent-btn--ghost:hover,
.privacy-consent-banner .privacy-consent-btn--ghost:active {
  color: #0f172a !important;
  background: #f8fafc !important;
  border-color: #94a3b8 !important;
}

.privacy-consent-banner .privacy-consent-btn--accept,
.privacy-consent-banner .privacy-consent-btn--accept:hover,
.privacy-consent-banner .privacy-consent-btn--accept:active {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  background: linear-gradient(135deg, #9333ea 0%, #db2777 100%) !important;
  border: 1px solid transparent !important;
  box-shadow: 0 4px 20px rgba(147, 51, 234, 0.3) !important;
  text-decoration: none !important;
  opacity: 1 !important;
}

.privacy-consent-banner .privacy-consent-btn--accept:hover {
  background: linear-gradient(135deg, #a855f7 0%, #ec4899 100%) !important;
  box-shadow: 0 6px 24px rgba(147, 51, 234, 0.35) !important;
  transform: translateY(-1px) !important;
}

.privacy-consent-banner .privacy-consent-btn--accept:active {
  transform: translateY(0) !important;
}

.asset-table-row .asset-table-include {
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 2.75rem;
}

/* Toggle — div-based so vendor wallet `button {}` resets cannot hide it. */
.yeet-switch {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  cursor: pointer !important;
  outline: none !important;
  user-select: none !important;
}

.yeet-switch--disabled,
.yeet-switch[aria-disabled="true"] {
  opacity: 0.45 !important;
  cursor: not-allowed !important;
  pointer-events: none !important;
}

.yeet-switch:focus-visible .yeet-switch__track {
  outline: 2px solid rgba(147, 51, 234, 0.45) !important;
  outline-offset: 2px !important;
}

.yeet-switch__track {
  display: inline-flex !important;
  align-items: center !important;
  box-sizing: border-box !important;
  width: 2.75rem !important;
  height: 1.625rem !important;
  min-width: 2.75rem !important;
  min-height: 1.625rem !important;
  padding: 2px !important;
  border-radius: 9999px !important;
  background-color: #cbd5e1 !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.1) !important;
  transition: background-color 200ms ease, box-shadow 200ms ease !important;
}

.yeet-switch:hover:not(.yeet-switch--disabled) .yeet-switch__track {
  background-color: #94a3b8 !important;
}

.yeet-switch[aria-checked="true"] .yeet-switch__track {
  background: linear-gradient(135deg, #9333ea 0%, #7c3aed 100%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 2px 10px rgba(124, 58, 237, 0.35) !important;
}

.yeet-switch[aria-checked="true"]:hover:not(.yeet-switch--disabled) .yeet-switch__track {
  background: linear-gradient(135deg, #a855f7 0%, #8b5cf6 100%) !important;
}

.yeet-switch__thumb {
  display: block !important;
  width: 1.25rem !important;
  height: 1.25rem !important;
  min-width: 1.25rem !important;
  min-height: 1.25rem !important;
  border-radius: 9999px !important;
  background-color: #ffffff !important;
  box-shadow:
    0 1px 3px rgba(15, 23, 42, 0.16),
    0 1px 2px rgba(15, 23, 42, 0.1) !important;
  transition: transform 200ms cubic-bezier(0.4, 0, 0.2, 1) !important;
  transform: translateX(0) !important;
}

.yeet-switch[aria-checked="true"] .yeet-switch__thumb {
  transform: translateX(1.125rem) !important;
}

/* App buttons — resist vendor wallet `button { width: 100% }` resets */
.btn-pop:not(.btn-pop--block):not(.btn-pop--mobile-full):not(.ai-chat-btn-primary) {
  display: inline-flex !important;
  width: auto !important;
  max-width: 100% !important;
}
.btn-pop.btn-pop--block {
  width: 100% !important;
}
@media (max-width: 639px) {
  .btn-pop.btn-pop--mobile-full {
    width: 100% !important;
  }
}
@media (min-width: 640px) {
  .btn-pop.btn-pop--mobile-full {
    width: auto !important;
  }
}

/* AI chat widget — scoped button overrides (loads after vendor wallet CSS) */
.ai-chat-widget .ai-chat-btn-primary {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  min-height: 2.75rem !important;
  padding: 0.625rem 1rem !important;
  border: none !important;
  border-radius: 9999px !important;
  background: linear-gradient(135deg, #9333ea 0%, #db2777 100%) !important;
  background-image: linear-gradient(135deg, #9333ea 0%, #db2777 100%) !important;
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  font-size: 0.875rem !important;
  font-weight: 600 !important;
  line-height: 1.25rem !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  box-shadow: 0 4px 20px rgba(147, 51, 234, 0.3) !important;
  cursor: pointer !important;
  opacity: 1 !important;
  appearance: none !important;
  -webkit-appearance: none !important;
}
.ai-chat-widget .ai-chat-btn-primary:hover,
.ai-chat-widget .ai-chat-btn-primary:focus-visible {
  background: linear-gradient(135deg, #a855f7 0%, #ec4899 100%) !important;
  background-image: linear-gradient(135deg, #a855f7 0%, #ec4899 100%) !important;
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
}

/* AI chat FAB — pinned bottom-right (duplicate of globals.css for vendor load order) */
#ai-chat-fab {
  position: fixed !important;
  right: max(1rem, env(safe-area-inset-right)) !important;
  bottom: max(1rem, env(safe-area-inset-bottom)) !important;
  left: auto !important;
  top: auto !important;
  z-index: 60 !important;
}

#ai-chat-fab.ai-chat-fab--privacy {
  bottom: calc(7.5rem + env(safe-area-inset-bottom)) !important;
}

@media (min-width: 640px) {
  #ai-chat-fab {
    right: max(1.25rem, env(safe-area-inset-right)) !important;
    bottom: max(1.25rem, env(safe-area-inset-bottom)) !important;
  }

  #ai-chat-fab.ai-chat-fab--privacy {
    bottom: calc(8.5rem + env(safe-area-inset-bottom)) !important;
  }
}

/* AI chat — compact floating panel on desktop (not full-height sidebar) */
@media (min-width: 640px) {
  .ai-chat-widget {
    width: 24rem !important;
    height: min(32rem, calc(100vh - 6rem)) !important;
    max-height: calc(100vh - 6rem) !important;
  }
}
@media (min-width: 768px) {
  .ai-chat-widget {
    width: 26rem !important;
    height: min(34rem, calc(100vh - 6rem)) !important;
  }
}
