/* 代币释放平台样式文件 */

body {
  background: -webkit-linear-gradient(to bottom right, #1e3a8a, #6b21a8, #1e3a8a);
  background: linear-gradient(to bottom right, #1e3a8a, #6b21a8, #1e3a8a);
  background-color: #1e3a8a;
  background-attachment: fixed;
  min-height: 100vh;
  color: #ffffff;
}

/* Banner 样式 */
.banner {
  height: 400px !important;
  /* background: linear-gradient(90deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57); */
  background-size: 100% auto;
  background-position: 0 50%;
  /* animation: gradientShift 8s ease infinite; */
  position: relative;
  overflow: hidden;
  background-image: url('./images/unlock-banner.jpg');
}

/* 空投Banner样式 */
.bridge-banner {
  height: 550px !important;
  background-image: url('./images/bridge-2.jpg');
  background-size: 100% auto;
  background-position: 50% 30%;
  background-repeat: no-repeat;
  position: relative;
  overflow: hidden;
}

.bridge-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
}

.banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  /* background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent); */
  /* animation: shimmer 3s infinite; */
}

/* 动画效果 */
@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}



@keyframes shimmer {
  0% {
    left: -100%;
  }

  100% {
    left: 100%;
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* 卡片样式 */
.card {
  background: linear-gradient(145deg, rgba(30, 58, 138, 0.8), rgba(107, 33, 168, 0.8));
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

/* 按钮样式 */
.gradient-button {
  background: linear-gradient(90deg, #3b82f6, #a855f7);
  transition: transform 0.2s, background 0.3s;
}

.gradient-button:hover {
  transform: scale(1.05);
  background: linear-gradient(90deg, #2563eb, #9333ea);
}

.gradient-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* 输入框样式 */
input {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  transition: border-color 0.3s;
}

input:focus {
  border-color: #a855f7;
  outline: none;
}

::placeholder {
  color: rgba(255, 255, 255, 0.7);
}

/* 加载动画 */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, .3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 1s ease-in-out infinite;
}

/* 状态消息样式 */
.status-success {
  color: #10b981;
}

.status-error {
  color: #ef4444;
}

.status-warning {
  color: #f59e0b;
}

/* 进度条样式 */
.progress-bar {
  background: linear-gradient(90deg, #3b82f6, #a855f7);
  height: 4px;
  border-radius: 2px;
  transition: width 0.3s ease;
}

/* 响应式设计 - 平板端优化 */
@media (max-width: 1024px) and (min-width: 769px) {
  .container {
    padding: 1.5rem;
  }

  .card {
    padding: 1.5rem;
  }

  .navbar img {
    width: 250px;
  }
}

/* 响应式设计 - 移动端优化 */
@media (max-width: 768px) {

  /* Banner 移动端优化 */
  .banner {
    height: 300px !important;
    padding: 2rem 1rem !important;
  }

  .banner h1 {
    font-size: 2rem !important;
    margin-bottom: 1rem !important;
    margin-top: 1rem !important;
  }

  .banner p {
    font-size: 1rem;
  }

  .banner .flex {
    flex-direction: column;
    gap: 1rem;
  }

  /* 空投Banner移动端优化 */
  .bridge-banner {
    height: 350px !important;
    padding: 2rem 1rem !important;
  }

  .bridge-banner h1 {
    font-size: 2rem !important;
    margin-top: 2rem !important;
  }

  .bridge-banner p {
    font-size: 1.1rem !important;
  }

  /* 导航栏移动端优化 */
  .navbar .container {
    padding: 1rem !important;
  }

  .navbar .flex {
    flex-wrap: wrap;
    gap: 0.25rem;
  }

  .navbar img {
    width: 200px !important;
    height: auto;
  }

  /* 导航标签移动端优化 */
  .nav-tab {
    padding: 8px 10px !important;
    font-size: 0.875rem;
  }

  /* 钱包连接按钮移动端优化 */
  #connectWallet {
    padding: 8px !important;
    font-size: 0.875rem;
  }

  /* 隐藏移动端不必要的信息 */
  /* .navbar .text-right {
    display: none !important;
  } */

  /* 容器移动端优化 */
  .container {
    padding: 1rem !important;
  }

  /* 卡片移动端优化 */
  .card {
    margin-bottom: 1rem !important;
    padding: 1rem !important;
  }

  /* 网格布局移动端优化 - 保持部分PC布局 */
  .grid-cols-4 {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .grid-cols-3 {
    grid-template-columns: 1fr !important;
  }

  .grid-cols-2 {
    grid-template-columns: 1fr !important;
  }

  /* 按钮移动端优化 - 不强制全宽 */
  .gradient-button,
  button {
    padding: 12px 16px !important;
    font-size: 0.875rem;
  }

  /* 特定按钮保持全宽 */
  #bridgeDepositBtn,
  #claimButton {
    width: 100%;
  }

  /* 输入框移动端优化 */
  input,
  textarea {
    padding: 12px !important;
    font-size: 16px;
    /* 防止iOS缩放 */
  }

  /* 链选择器移动端优化 */
  .chain-selector {
    padding: 1rem !important;
    margin-bottom: 1rem;
  }

  .chain-selector .w-16 {
    width: 3rem !important;
    height: 3rem !important;
  }

  /* 跨链箭头移动端优化 */
  /* .bridge-arrow {
    transform: rotate(90deg);
    margin: 1rem 0;
  } */

  /* 弹性布局移动端优化 - 选择性应用 */
  /* .chain-selector-container {
    flex-direction: column !important;
    align-items: center !important;
  } */

  .chain-selector-container .space-x-8>*+* {
    margin-left: 0 !important;
    margin-top: 1rem;
  }

  /* 按钮组保持水平布局 */
  .flex.space-x-4:not(.chain-selector-container .flex),
  .flex.space-x-3:not(.chain-selector-container .flex),
  .flex.space-x-2:not(.chain-selector-container .flex) {
    flex-direction: row;
    flex-wrap: wrap;
  }

  /* 文本大小移动端优化 */
  .text-4xl {
    font-size: 2rem !important;
  }

  .text-2xl {
    font-size: 1.5rem !important;
  }

  .text-xl {
    font-size: 1.125rem !important;
  }

  /* 批量添加区域移动端优化 */
  .batch-input-area textarea {
    min-height: 100px !important;
    font-size: 14px;
  }

  /* 历史记录移动端优化 */
  .bridge-history-item {
    padding: 12px !important;
  }

  /* 状态徽章移动端优化 */
  .status-badge {
    font-size: 10px !important;
    padding: 2px 6px !important;
  }
}

/* 小屏幕设备优化 (手机竖屏) */
@media (max-width: 480px) {

  /* 更小的Banner */
  .banner,
  .bridge-banner {
    height: 250px !important;
    padding: 1rem 0.5rem !important;
  }

  .banner h1,
  .bridge-banner h1 {
    font-size: 1.5rem !important;
    margin-top: 1rem !important;
  }

  /* 更紧凑的导航 */
  .navbar .container {
    padding: 0.75rem 0 !important;
  }

  .navbar img {
    width: 120px !important;
  }

  /* 更小的卡片间距 */
  .card {
    padding: 0.75rem !important;
    margin-bottom: 0.75rem !important;
  }

  /* 更小的按钮 */
  .gradient-button,
  button {
    padding: 10px 12px !important;
    font-size: 0.8rem;
  }

  /* 更小的输入框 */
  input,
  textarea {
    padding: 10px !important;
  }

  /* 链选择器更紧凑 */
  .chain-selector {
    padding: 0.75rem !important;
  }

  .chain-selector .w-16 {
    width: 2.5rem !important;
    height: 2.5rem !important;
  }

  /* 文本进一步缩小 */
  .text-2xl {
    font-size: 1.25rem !important;
  }

  .text-xl {
    font-size: 1rem !important;
  }

  .text-lg {
    font-size: 0.95rem !important;
  }
}

/* 横屏手机优化 */
@media (max-width: 768px) and (orientation: landscape) {

  .banner,
  .bridge-banner {
    height: 200px !important;
  }

  .banner h1,
  .bridge-banner h1 {
    font-size: 1.75rem !important;
    margin-top: 0.5rem !important;
  }
}

/* PC端优化 */
@media (min-width: 1025px) {

  /* 大屏幕下的容器最大宽度 */
  .container {
    max-width: 1200px;
  }

  /* PC端悬停效果 */
  .card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
  }

  .gradient-button:hover {
    transform: scale(1.05);
  }

  .chain-selector:hover {
    border-color: rgba(59, 130, 246, 0.5);
    background: rgba(59, 130, 246, 0.1);
  }

  /* PC端网格布局优化 */
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  /* PC端按钮组布局 */
  .flex.space-x-4,
  .flex.space-x-3,
  .flex.space-x-2 {
    flex-direction: row;
    align-items: center;
  }

  /* PC端导航栏 */
  .navbar .flex {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

/* 工具提示样式 */
.tooltip {
  position: relative;
  display: inline-block;
}

.tooltip .tooltiptext {
  visibility: hidden;
  width: 200px;
  background-color: rgba(0, 0, 0, 0.8);
  color: #fff;
  text-align: center;
  border-radius: 6px;
  padding: 8px;
  position: absolute;
  z-index: 1;
  bottom: 125%;
  left: 50%;
  margin-left: -100px;
  opacity: 0;
  transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
  visibility: visible;
  opacity: 1;
}

/* 导航栏样式 */
.navbar {
  background: linear-gradient(145deg, rgba(30, 58, 138, 0.9), rgba(107, 33, 168, 0.9));
  backdrop-filter: blur(15px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  position: sticky;
  top: 0;
  z-index: 50;
}

.nav-tab {
  padding: 12px 24px;
  border-radius: 8px;
  transition: all 0.3s ease;
  cursor: pointer;
  border: 1px solid transparent;
}

.nav-tab:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
}

.nav-tab.active {
  background: linear-gradient(90deg, #3b82f6, #a855f7);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.nav-tab.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* 内容区域 */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 批量添加样式 */
.batch-input-area {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  transition: border-color 0.3s;
}

.batch-input-area:focus-within {
  border-color: #a855f7;
}

.batch-input-area textarea {
  background: transparent;
  border: none;
  outline: none;
  resize: vertical;
  min-height: 120px;
}

.batch-preview {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 6px;
  max-height: 200px;
  overflow-y: auto;
}

.batch-item {
  padding: 8px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.batch-item:last-child {
  border-bottom: none;
}

.batch-item.error {
  background: rgba(239, 68, 68, 0.2);
  border-color: rgba(239, 68, 68, 0.3);
}

.batch-item.success {
  background: rgba(16, 185, 129, 0.2);
  border-color: rgba(16, 185, 129, 0.3);
}

/* 切换按钮样式 */
.toggle-button {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s ease;
}

.toggle-button.active {
  background: linear-gradient(90deg, #3b82f6, #a855f7);
  border-color: rgba(255, 255, 255, 0.3);
}

/* 跨链桥样式 */
.token-selector {
  cursor: pointer;
  transition: all 0.3s ease;
}

.token-selector:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

.token-selector.selected {
  background: linear-gradient(90deg, rgba(59, 130, 246, 0.2), rgba(168, 85, 247, 0.2));
  border-color: #3b82f6;
}

.amount-input-container {
  position: relative;
}

.max-button {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: linear-gradient(90deg, #3b82f6, #a855f7);
  color: white;
  border: none;
  padding: 4px 12px;
  border-radius: 4px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.max-button:hover {
  transform: translateY(-50%) scale(1.05);
}

.bridge-info-card {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 16px;
  margin: 16px 0;
}

.bridge-warning {
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: #fbbf24;
}

.bridge-success {
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #10b981;
}

.bridge-error {
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

/* 代币图标 */
.token-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
}

.usdt-icon {
  background: linear-gradient(135deg, #26a17b, #2ea169);
  color: white;
}

/* 链图标样式 */
.chain-icon {
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.chain-icon:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* 跨链桥箭头动画 */
.bridge-arrow {
  animation: pulse 2s infinite;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.8;
    transform: scale(1.05);
  }
}

/* 跨链桥特定样式 */
.bridge-info-section {
  background: rgba(30, 64, 175, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 12px;
}

.chain-selector {
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 12px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.chain-selector:hover {
  border-color: rgba(59, 130, 246, 0.5);
  background: rgba(59, 130, 246, 0.1);
}

.chain-selector.selected {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.8);
}

/* 跨链历史记录样式 */
.bridge-history-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 16px;
  transition: all 0.3s ease;
}

.bridge-history-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.status-badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
}

.status-pending {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-completed {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-failed {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-confirming {
  background: rgba(59, 130, 246, 0.2);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

/* 进度条样式 */
.progress-container {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  height: 4px;
  overflow: hidden;
}

.progress-bar-history {
  height: 100%;
  border-radius: 4px;
  transition: width 0.3s ease;
}

.progress-pending {
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
  animation: progressPulse 2s infinite;
}

.progress-completed {
  background: linear-gradient(90deg, #10b981, #34d399);
}

.progress-failed {
  background: linear-gradient(90deg, #ef4444, #f87171);
}

@keyframes progressPulse {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }
}

/* 历史记录筛选器 */
.history-filter {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 14px;
}

.history-filter:focus {
  outline: none;
  border-color: #3b82f6;
}

/* 时间轴样式 */
.timeline-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  position: relative;
}

.timeline-dot::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
  opacity: 0.3;
  animation: ripple 2s infinite;
}

.timeline-dot.pending {
  background: #fbbf24;
}

.timeline-dot.pending::after {
  background: #fbbf24;
}

.timeline-dot.completed {
  background: #10b981;
}

.timeline-dot.completed::after {
  background: #10b981;
}

.timeline-dot.failed {
  background: #ef4444;
}

.timeline-dot.failed::after {
  background: #ef4444;
}

@keyframes ripple {
  0% {
    transform: translate(-50%, -50%) scale(0);
    opacity: 0.3;
  }

  100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0;
  }
}

/* 滚动条样式 */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(90deg, #3b82f6, #a855f7);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(90deg, #2563eb, #9333ea);
}

/* 弹窗样式 */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: fadeIn 0.3s ease-out;
}

.modal-container {
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  animation: slideUp 0.3s ease-out;
}

.modal-content {
  background: linear-gradient(145deg, rgba(30, 58, 138, 0.95), rgba(107, 33, 168, 0.95));
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.modal-header {
  padding: 24px 24px 0 24px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.modal-body {
  padding: 24px;
}

.modal-footer {
  padding: 0 24px 24px 24px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* 弹窗关闭动画 */
.modal-overlay.closing {
  animation: fadeOut 0.3s ease-out;
}

.modal-overlay.closing .modal-container {
  animation: slideDown 0.3s ease-out;
}

@keyframes fadeOut {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}

@keyframes slideDown {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }

  to {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
}

/* 复制按钮动画 */
.copy-success {
  animation: copyPulse 0.6s ease-out;
}

@keyframes copyPulse {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.1);
    background: rgba(34, 197, 94, 0.2);
  }

  100% {
    transform: scale(1);
  }
}

/* 响应式设计 */
@media (max-width: 640px) {
  .modal-container {
    width: 95%;
  }

  .modal-header,
  .modal-body,
  .modal-footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .modal-body {
    padding-top: 16px;
    padding-bottom: 16px;
  }
}

/* 移动端特定优化 */
@media (max-width: 768px) {

  /* 触摸友好的按钮 */
  button,
  .gradient-button,
  .nav-tab,
  .token-selector,
  .chain-selector {
    min-height: 44px;
    /* iOS推荐的最小触摸目标 */
    touch-action: manipulation;
    /* 防止双击缩放 */
  }

  /* 防止文本选择 */
  .nav-tab,
  .token-selector,
  .chain-selector,
  button {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
  }

  /* 移动端滚动优化 */
  .max-h-96 {
    max-height: 250px !important;
  }

  /* 移动端表格优化 */
  .grid-cols-4 {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  .grid-cols-3 {
    grid-template-columns: 1fr !important;
  }

  .grid-cols-2 {
    grid-template-columns: 1fr !important;
  }

  /* 移动端间距优化 */
  .space-y-4>*+* {
    margin-top: 0.75rem !important;
  }

  .space-y-3>*+* {
    margin-top: 0.5rem !important;
  }

  /* 移动端字体优化 */
  body {
    font-size: 14px;
    line-height: 1.5;
  }

  /* 移动端输入框优化 */
  input[type="number"] {
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: none;
  }

  input[type="number"]::-webkit-outer-spin-button,
  input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
  }

  /* 移动端弹窗优化 */
  .modal-container {
    width: 95% !important;
    margin: 1rem;
  }

  .modal-header,
  .modal-body,
  .modal-footer {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }

  /* 移动端导航优化 */
  /* .navbar .flex {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }
   */
  .navbar .space-x-2 {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }

  .navbar .space-x-2>*+* {
    margin-left: 0 !important;
  }

  /* 移动端链选择器布局 */
  /* .chain-selector-container {
    flex-direction: column !important;
    align-items: center;
  }
  
  .chain-selector-container .flex {
    flex-direction: column;
    align-items: center;
    margin: 1rem 0;
  } */

  /* 移动端统计卡片优化 */
  .stats-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 0.5rem !important;
  }

  .stats-card {
    padding: 0.75rem !important;
    text-align: center;
  }

  .stats-card p:first-child {
    font-size: 0.75rem !important;
  }

  .stats-card p:last-child {
    font-size: 0.9rem !important;
  }
}

/* 超小屏幕优化 */
@media (max-width: 360px) {
  .container {
    padding: 0.5rem !important;
  }

  .card {
    padding: 0.5rem !important;
  }

  .banner,
  .bridge-banner {
    height: 200px !important;
    padding: 1rem 0.25rem !important;
  }

  .banner h1,
  .bridge-banner h1 {
    font-size: 1.25rem !important;
  }

  .navbar img {
    width: 120px !important;
  }

  .stats-grid {
    grid-template-columns: 1fr !important;
  }
}

/* 高DPI屏幕优化 */
@media (-webkit-min-device-pixel-ratio: 2),
(min-resolution: 192dpi) {

  .banner,
  .bridge-banner {
    background-size: cover;
  }
}

/* 暗色模式支持 */
@media (prefers-color-scheme: dark) {
  /* 已经是暗色主题，保持现有样式 */
}

/* 减少动画偏好 */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* iOS Safari 特定优化 */
@supports (-webkit-touch-callout: none) {

  /* iOS Safari 输入框优化 */
  input,
  textarea {
    border-radius: 0;
    -webkit-appearance: none;
    appearance: none;
  }

  /* iOS Safari 按钮优化 */
  button,
  .gradient-button {
    border-radius: 8px;
    -webkit-appearance: none;
    appearance: none;
  }
}

/* 移动设备特定样式 */
.mobile-device {
  /* 防止页面缩放 */
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
}

/* 移动端Toast样式 */
.mobile-toast {
  transition: all 0.3s ease;
  animation: slideInFromTop 0.3s ease-out;
}

@keyframes slideInFromTop {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

/* 移动端特定的触摸反馈 */
@media (max-width: 768px) {

  /* 触摸反馈 */
  button:active,
  .gradient-button:active,
  .nav-tab:active,
  .token-selector:active,
  .chain-selector:active {
    transform: scale(0.95) !important;
    transition: transform 0.1s ease;
  }

  /* 移动端输入框优化 */
  input:focus,
  textarea:focus {
    transform: scale(1.02);
    transition: transform 0.2s ease;
  }

  /* 移动端卡片悬停效果调整 */
  .card:hover {
    transform: none !important;
  }

  .gradient-button:hover {
    transform: none !important;
  }

  .chain-selector:hover {
    transform: none !important;
  }

  /* 移动端按钮组优化 - 仅针对特定容器 */
  .sm\\:flex-row {
    flex-direction: column !important;
    align-items: stretch !important;
  }

  .sm\\:flex-row>* {
    margin-left: 0 !important;
    margin-bottom: 0.5rem;
  }

  .sm\\:flex-row>*:last-child {
    margin-bottom: 0;
  }

  /* 移动端表单优化 */
  .grid.gap-3,
  .grid.gap-4 {
    gap: 0.75rem !important;
  }

  /* 移动端文本截断 */
  .break-all {
    word-break: break-word;
    overflow-wrap: break-word;
  }

  /* 移动端滚动条优化 */
  .max-h-96::-webkit-scrollbar,
  .overflow-y-auto::-webkit-scrollbar {
    width: 4px;
  }

  .max-h-96::-webkit-scrollbar-thumb,
  .overflow-y-auto::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
  }

  /* 移动端导航优化 */
  /* .navbar .flex {
    flex-direction: column !important;
    align-items: center !important;
    gap: 1rem;
  } */

  .navbar .space-x-2 {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }

  .navbar .space-x-2>*+* {
    margin-left: 0 !important;
  }
}

/* 移动端横屏特殊处理 */
@media (max-width: 768px) and (orientation: landscape) {

  .banner,
  .bridge-banner {
    height: 180px !important;
  }

  .navbar {
    padding: 0.5rem 0 !important;
  }

  .container {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
  }
}

/* 移动端安全区域适配 (iPhone X等) */
@supports (padding: max(0px)) {
  .navbar {
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-right: max(1rem, env(safe-area-inset-right));
  }

  .container {
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-right: max(1rem, env(safe-area-inset-right));
  }

  .modal-container {
    margin-left: max(1rem, env(safe-area-inset-left));
    margin-right: max(1rem, env(safe-area-inset-right));
  }
}

/* 移动端性能优化 */
@media (max-width: 768px) {
  * {
    /* 启用硬件加速 */
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
  }

  .card,
  .gradient-button,
  .nav-tab {
    /* 优化重绘性能 */
    will-change: transform;
  }

  /* 减少阴影复杂度 */
  .card {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2) !important;
  }

  .gradient-button:hover {
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2) !important;
  }
}

/* 通用响
应式优化 */
@media (max-width: 640px) {

  /* 超小屏幕下的弹窗优化 */
  .modal-container {
    width: 95% !important;
    margin: 0.5rem;
  }

  .modal-header,
  .modal-body,
  .modal-footer {
    padding: 1rem !important;
  }

  /* 超小屏幕下的按钮优化 */
  .gradient-button,
  button {
    min-height: 48px;
    font-size: 0.875rem;
  }

  /* 超小屏幕下的输入框优化 */
  input,
  textarea {
    min-height: 48px;
    font-size: 16px;
  }
}

/* 中等屏幕优化 */
@media (min-width: 769px) and (max-width: 1024px) {
  .container {
    padding: 1.5rem;
  }

  .card {
    padding: 1.5rem;
  }

  /* 保持部分PC端布局 */
  .grid-cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-cols-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* 大屏幕优化 */
@media (min-width: 1440px) {
  .container {
    max-width: 1400px;
  }

  .banner,
  .bridge-banner {
    height: 600px !important;
  }

  .banner h1,
  .bridge-banner h1 {
    font-size: 4rem !important;
  }
}

/* 打印样式 */
@media print {

  .navbar,
  .banner,
  .bridge-banner,
  footer,
  .modal-overlay {
    display: none !important;
  }

  .card {
    border: 1px solid #000;
    background: white !important;
    color: black !important;
    break-inside: avoid;
  }

  body {
    background: white !important;
    color: black !important;
  }
}

/* 高对比度模式支持 */
@media (prefers-contrast: high) {
  .card {
    border: 2px solid rgba(255, 255, 255, 0.8);
  }

  .gradient-button {
    background: #0066cc !important;
    border: 2px solid #ffffff;
  }

  input {
    border: 2px solid rgba(255, 255, 255, 0.8);
  }
}

/* 焦点可见性优化 */
@media (prefers-reduced-motion: no-preference) {

  button:focus-visible,
  input:focus-visible,
  .nav-tab:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
  }
}

/* 触摸设备特定优化 */
@media (pointer: coarse) {

  button,
  .gradient-button,
  .nav-tab,
  .token-selector,
  .chain-selector {
    min-height: 44px;
    min-width: 44px;
  }

  /* 增加触摸目标间距 */
  .space-x-2>*+* {
    margin-left: 0.75rem;
  }

  .space-y-2>*+* {
    margin-top: 0.75rem;
  }
}

/* 鼠标设备特定优化 */
@media (pointer: fine) {

  /* 精确指针设备的悬停效果 */
  .card:hover {
    transform: translateY(-2px);
    transition: transform 0.2s ease;
  }

  .gradient-button:hover {
    transform: scale(1.02);
    transition: transform 0.2s ease;
  }

  /* 滚动条样式 */
  ::-webkit-scrollbar {
    width: 12px;
  }

  ::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
  }

  ::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, #3b82f6, #a855f7);
    border-radius: 6px;
  }
}

/* 网络状态优化 */
@media (prefers-reduced-data: reduce) {

  /* 减少动画和效果 */
  *,
  *::before,
  *::after {
    animation-duration: 0.1s !important;
    transition-duration: 0.1s !important;
  }

  /* 简化背景 */
  .banner,
  .bridge-banner {
    background-image: none !important;
    background: linear-gradient(135deg, #1e3a8a, #6b21a8) !important;
  }
}