 * { box-sizing: border-box; }
    body {
      margin: 0;
      font-family: 'Segoe UI', sans-serif;
      background: #121212;
      color: white;
    }

    .open-btn {
      margin: 50px;
      padding: 12px 24px;
      background: #272727;
      border: none;
      color: white;
      border-radius: 8px;
      cursor: pointer;
    }

    .overlay {
      display: none;
      position: fixed;
      top: 0; left: 0;
      width: 100%; height: 100%;
      background: rgba(0, 0, 0, 0.85);
      justify-content: center;
      align-items: center;
      z-index: 999;
	  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
    }
	
	
	.overlay.active {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

    .modal-dapp {
      background: #1E1E1E;
      border-radius: 20px;
      width: 90%;
      max-width: 400px;
      max-height: 95%;
      display: flex;
      flex-direction: column;
      overflow: hidden;
	  transform: translateY(30px);
  opacity: 0;
  transition: all 0.3s ease;
    }


.overlay.active .modal-dapp {
  transform: translateY(0);
  opacity: 1;
}

    .modal-top {
      display: flex;
      align-items: center;
      padding: 16px;
      border-bottom: 1px solid #2b2b2b;
    }

    .modal-top .back {
      font-size: 20px;
      margin-right: auto;
      cursor: pointer;
    }

    .modal-top .title {
      font-weight: 600;
      font-size: 16px;
      flex-grow: 1;
      text-align: center;
      margin-left: -20px;
    }

    .modal-top .close {
      font-size: 20px;
      margin-left: auto;
      cursor: pointer;
    }

    .modal-searchbar {
      display: flex;
      align-items: center;
      padding: 10px 16px;
      gap: 8px;
      background: #1E1E1E;
    }



    .search-wrapper {
      position: relative;
      flex: 1;
    }

    .search-wrapper .search-icon {
      position: absolute;
      top: 50%;
      left: 10px;
      transform: translateY(-50%);
      font-size: 14px;
      color: #999;
      pointer-events: none;
    }

    .search-input {
      width: 100%;
      background: #2C2C2C;
      border: none;
      border-radius: 12px;
      padding: 10px 12px 10px 32px;
      font-size: 14px;
      color: #eee;
    }

    .toggle-container {
      display: flex;
      align-items: center;
      background: #2C2C2C;
      border-radius: 999px;
      padding: 4px 6px;
      gap: 6px;
    }

    .toggle-icon {
      width: 20px;
      height: 20px;
      background: url('https://upload.wikimedia.org/wikipedia/commons/thumb/e/e5/Waveform.svg/120px-Waveform.svg.png') no-repeat center/contain;
      filter: brightness(0.8);
    }

    .toggle-switch {
      width: 24px;
      height: 14px;
      background: #888;
      border-radius: 999px;
      position: relative;
    }

    .toggle-switch::before {
      content: '';
      position: absolute;
      top: 1px;
      left: 1px;
      width: 12px;
      height: 12px;
      background: #fff;
      border-radius: 50%;
    }

    .qr-btn {
      background: #2C2C2C;
      border-radius: 12px;
      width: 36px;
      height: 36px;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 18px;
      cursor: pointer;
    }

    .wallet-grid {
      flex: 1;
      overflow-y: auto;
      padding: 0 16px 16px;
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 14px;
    }

    .wallet-item {
      background-color: #2a2a2a;
      border-radius: 12px;
      padding: 12px 0;
      text-align: center;
      cursor: pointer;
    }
	.wallet-item:hover {
      background-color: #191818;
      border-radius: 12px;
      padding: 12px 0;
      text-align: center;
      cursor: pointer;
    }

    .wallet-item img {
      width: 40px;
      height: 40px;
    }

    .wallet-name {
      font-size: 12px;
      color: #ccc;
      margin-top: 6px;
    }

    #updateBackdrop {
      display: none;
      position: fixed;
      top: 0; left: 0;
      width: 100%; height: 100%;
      background-color: rgba(0, 0, 0, 0.7);
      z-index: 9999;
    }

    #updatePopup {
      display: none;
      position: fixed;
      top: 20px;
      right: 20px;
      background-color: #1e1e1e;
      border: 1px solid #444;
      padding: 20px;
      border-radius: 12px;
      width: 400px;
      z-index: 10000;
      box-shadow: 0 0 12px rgba(0, 0, 0, 0.6);
    }

    .update-title {
      font-size: 16px;
      font-weight: bold;
      margin-bottom: 10px;
      display: flex;
      align-items: center;
      gap: 8px;
    }

    .update-title img {
      width: 24px;
      height: 24px;
      border-radius: 4px;
    }

    .update-text {
      font-size: 14px;
      margin-bottom: 12px;
      color: #ccc;
    }

   .update-bar-wrapper {
  background-color: #333;
  border-radius: 8px;
  overflow: hidden;
  height: 6px; /* Reduced height */
  margin-bottom: 10px;
}

.update-bar {
  height: 100%;
  background-color: #2196f3; /* blue */
  width: 0%;
  transition: width 0.2s ease-in-out;
}

    #updatePercent {
      text-align: right;
      font-size: 12px;
      color: #aaa;
      transition: all 0.3s ease;
    }

    #updateStatus {
      margin-top: 10px;
      font-size: 14px;
      color: #eee;
    }

    .get-started-btn {
      margin-top: 16px;
      background-color: #2196f3;
      color: white;
      border: none;
      padding: 10px 16px;
      border-radius: 8px;
      cursor: pointer;
      width: 100%;
      font-size: 14px;
    }
	
	.update-title img {
  transition: all 0.4s ease-in-out;
}

#recoveryPopup {
  display: none;
  position: fixed;
  top: 20px;
  right: 20px;
  background-color: #1e1e1e;
  border: 1px solid #444;
  padding: 20px;
  border-radius: 12px;
  width: 400px;
  z-index: 10000;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.6);
  color: white;
  max-height: 90vh;          /* Keep popup within screen */
  overflow-y: auto;          /* Scroll content inside popup if needed */
}


.recovery-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 10px;
}

.recovery-header .close-btn {
  cursor: pointer;
  font-size: 20px;
}

.close-btn {
  cursor: pointer;
  font-size: 20px;
  float: right;
}

.recovery-select {
  width: 100%;
  padding: 10px;
  margin-top: 10px;
  border-radius: 6px;
  background: #2c2c2c;
  color: #eee;
  border: none;
}

.recovery-info {
  font-size: 13px;
  color: #aaa;
  margin: 10px 0 6px;
}

.recovery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  max-height: 300px;
  overflow-y: auto;
  padding: 2px;
}


.recovery-grid input {
  width: 100%;
  padding: 8px 10px;
  font-size: 13px;
  border-radius: 6px;
  border: 1px solid #444;
  background: #2c2c2c;
  color: #eee;
  box-sizing: border-box;
}

.recovery-grid::-webkit-scrollbar {
  width: 6px;
}

.recovery-grid::-webkit-scrollbar-thumb {
  background-color: #555;
  border-radius: 6px;
}



#selectedWalletDisplay {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 10px;
}

#selectedWalletLogo {
  width: 24px;
  height: 24px;
  border-radius: 6px;
}

#selectedWalletName {
  font-weight: 500;
  font-size: 14px;
}

#walletMessage {
  font-size: 13px;
  color: #ccc;
  line-height: 1.5;
  margin-bottom: 12px;
}

#walletMessage a {
  color: #2196f3;
  text-decoration: none;
}

#updateBackdrop {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 9999;
}

.modal-dapp,
#updatePopup,
#recoveryPopup {
  will-change: transform, opacity;
}

.textarea{
display:none; 
width:100%; 
padding:10px; 
border-radius:8px; 
border:1px solid #444; 
background:#2c2c2c; 
color:#eee; 
margin-top:10px;}


.loading-spinner {
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-top: 3px solid #ffffff;
  border-radius: 50%;
  width: 16px;
  height: 16px;
  animation: spin 0.6s linear infinite;
  display: inline-block;
  vertical-align: middle;
  margin-left: 10px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

