body {
  background-color: #1b1d28;
  color: white;
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
}

.top-bar {
  display: flex;
  justify-content: space-between;
  padding: 10px;
  align-items: center;
  background-color: #1b1d28;
}

.top-bar1 {
  font-size: 14px;
  display: flex;
  align-items: center;
}

.top-bar span {
  margin: 0 5px;
}
.select {
  width: 200px;
  display: flex;
  flex-wrap: wrap;
  margin-left: 15px;
}
img {
  display: block;
}
.icons {
  display: flex;
}
.icons img{
  margin: 0 2px;
}

.alerts {
  display: flex;
}
.alert {
  margin: 0 10px;
  padding: 10px;
  border-radius: 5px;
  color: black;
}
@keyframes bounce {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(20px);
  }
}

@keyframes colorChange {
  0% {
    background-color: #FCA5A5;
  }
  25% {
    background-color: #93C5FD;
  }
  50% {
    background-color: #ffff00;
  }
  100% {
    background-color: #86EFAC;
  }
}

.yellow {
  animation: bounce 0.3s cubic-bezier(0.20, 0.75, 1.00, -0.17)infinite, 
  colorChange 1s cubic-bezier(0.1, 0, 0.2, 1) infinite;
  background-color: #ffff00;
}

.blue {
  animation: bounce 0.2s cubic-bezier(0.00, 1.00, 1.00, 0.65)infinite, 
  colorChange 1s cubic-bezier(0.1, 0, 0.2, 1) infinite;
  background-color: #0099ff;
}

.content {
  text-align: center;
}

h1,
h2 {
  margin: 20px 0;
}

.coin-details {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px 0;
}

.search {
  width: 375px;
  display: flex;
  justify-content: center;
  margin: 65px auto;
}

.search input {
  padding: 13px 10px;
  width: 200px;
  background-color: rgb(134 239 172);
  border-radius: 5px;
  border: none;
}

.search button {
  padding: 10px 20px;
  margin-left: 10px;
  background-color: rgb(134 239 172);
  border: none;
  color: black;
  border-radius: 5px;
  cursor: pointer;
}
/* 容器样式 */
.container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  width: 95%;
  margin: 0 auto;
  padding: 20px;
}

/* 文章标题样式 */
h1 {
  font-size: 32px;
  margin-bottom: 10px;
}

/* 段落样式 */
p {
  font-size: 16px;
  margin-bottom: 15px;
  line-height: 1.8;
}

/* 链接样式 */
a {
  color: #3498db;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* 卡片样式 */
.card {
  display: flex;
  align-items: start;
  border-radius: 8px;
  padding: 10px;
  width: 30%;
  margin-bottom: 20px;
}
.img {
  margin: 0 auto;
  width: 166px;
  height: 32px;
}
.img img {
  width: 100%;
}
.card img {
  width: 128px;
  object-fit: contain;
}
.style {
  margin-left: 10px;
}
.style div:nth-child(1) {
  color: #bfdbfe;
  font-size: 12px;
}
.style {
  line-height: 20px;
}
.coin-image {
  width: 80px;
  height: 80px;
}
.coin-image img {
  width: 100%;
}
.style div:nth-child(2) {
  color: #86efac;
  font-size: 12px;
}

.style div:nth-child(3) {
  font-size: 12px;
}

.style div:nth-child(4) {
  word-break: break-word;
  color: #9ca3af;
  font-size: 14px;
}
.style div:nth-child(4) span {
  font-weight: bold;
  font-size: 12px;
}
/* 按钮样式 */
.button {
  display: inline-block;
  padding: 10px 20px;
  background-color: #3498db;
  color: white;
  font-size: 16px;
  border-radius: 5px;
  text-align: center;
  text-decoration: none;
  margin-top: 10px;
}

.button:hover {
  background-color: #2980b9;
}

/* 页脚样式 */
footer {
  display: flex;
  color: white;
  margin-top: 100px;
  padding: 20px;
}
footer span:last-child {
  margin-left: calc(50% - 200px);
}

.controls {
  display: flex;
  align-items: center;
  gap: 20px;
  width: 95%;
  margin: 0 auto;
}

.dropdown {
  background-color: #a8f5c5;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
  color: #000;
  font-weight: bold;
}
.toggle-group {
  font-size: 14px;
  display: flex;
  flex-direction: column;
}
.toggle-label {
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 5px;
}

.toggle {
  display: inline-flex;
  align-items: center;
  padding: 5px;
  border-radius: 15px;
  cursor: pointer;
  color: rgb(107 114 128);
  font-weight: bold;
}

.toggle span {
  padding: 2px;
  font-size: 14px;
  background-color: transparent;
  border-radius: 4px;
}

.toggle .active {
  background-color: #a8f5c5;
  color: #000;
}
.page {
  text-align: center;
  margin-top: 50px;
}
/* 响应式设计 */
@media (max-width: 768px) {
  .container {
    padding: 10px;
  }
  .select {
    width: 178px;
  }
  h1 {
    font-size: 24px;
  }

  .card {
    width: 100%;
  }

  .button {
    padding: 8px 16px;
  }
  .alerts {
    display: none;
  }
  .controls {
    display: block;
  }
  .toggle-group {
    flex-direction: row;
  }
  .search {
    margin: 20px auto;
    width: 95%;
  }
  .search input {
    flex: 1;
  }
}
/* 弹框样式 */
.popup {
  display: none; /* 初始时隐藏弹框 */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.popup-content {
  background-color: grey;
  padding: 20px;
  border-radius: 10px;
  text-align: center;
  position: relative;
}

.close-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 20px;
  cursor: pointer;
}

.confirm-btn {
  display: inline-block;
  padding: 10px 20px;
  background: linear-gradient(116deg, rgb(98, 83, 225), rgb(4, 190, 254));
  color: white;
  text-decoration: none;
  border-radius: 5px;
  margin-top: 10px;
}
