:root{
  --btn-gradient: linear-gradient(to right, #43ca69, #2eccdb, #f58afb, #52e4f1, #43ca69);
  --panel-bg: rgba(10, 14, 24, 0.95);
  --card-bg: rgba(255, 255, 255, 0.06);
  --text-main: #ffffff;
  --text-sub: rgba(255,255,255,0.82);
  --border-soft: rgba(255,255,255,0.12);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --app-height: 100vh;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
  font-family: Arial, "Microsoft YaHei", sans-serif;
}

body {
  position: relative;
  color: var(--text-main);
}

body.modal-open {
  overflow: hidden;
}

.site-main {
  position: relative;
  min-height: 100%;
}

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

#bgv {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  background: #000;
  z-index: 1;
  opacity: 0;
  transition: opacity .6s ease;
}

#bgv.play {
  opacity: 1;
}

.video-mask {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.18);
  z-index: 2;
  pointer-events: none;
}

.page-content {
  position: relative;
  z-index: 3;
  width: 100%;
  min-height: var(--app-height);
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px 20px 110px;
}

.center-menu {
  width: 100%;
  max-width: 420px;
  padding: 10px 8px 8px;
  border-radius: 16px;
  background: transparent;
  box-shadow: none;
}

.logo-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 28px;
}

.logo-wrap img {
  height: 120px;
  width: auto;
  max-width: 100%;
  display: block;
  object-fit: contain;
}

.menu-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  justify-items: center;
}

.menu-btn {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 280px;
  max-width: 100%;
  padding: 6px 0 8px;
  text-decoration: none;
  outline: none;
  border: 0;
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  background: linear-gradient(to right, #43ca69, #2eccdb, #f58afb, #52e4f1, #43ca69);
  background-size: 400% 100%;
  border-radius: 3px;
  transition: .1s ease-in-out;
  animation: buttonAni 10s linear infinite;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
  user-select: none;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.menu-btn:hover {
  transform: scale(1.05);
}

.menu-btn:active {
  transform: scale(1);
}

#download-app {
  position: fixed;
  left: 50%;
  bottom: calc(-5px + var(--safe-bottom));
  transform: translateX(-50%);
  width: 350px;
  max-width: calc(100% - 24px);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding: 8px 0 13px;
  border-radius: 10px 10px 0 0;
  text-decoration: none;
  background: linear-gradient(to right, #43ca69, #2eccdb, #f58afb, #52e4f1, #43ca69);
  background-size: 200% 100%;
  animation: titleAni 2s linear infinite;
  transition: .1s ease-in-out;
  z-index: 6;
  box-shadow: 0 -2px 18px rgba(0, 0, 0, 0.2);
}

#download-app span {
  color: rgba(0, 0, 0, 0.76);
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
}

#download-app .app-icon-img {
  width: 30px;
  height: 30px;
  display: block;
  object-fit: contain;
  opacity: .9;
  flex: 0 0 auto;
}

#download-app:hover {
  transform: translateX(-50%) translateY(-5px);
}

#download-app:active {
  transform: translateX(-50%);
}

.yx-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.yx-modal.show {
  display: flex;
}

.yx-modal-dialog {
  position: relative;
  width: min(100%, 760px);
  max-height: min(88vh, calc(var(--app-height) - 40px));
  display: flex;
  flex-direction: column;
  border-radius: 16px;
  overflow: hidden;
  background:
    linear-gradient(var(--panel-bg), var(--panel-bg)) padding-box,
    var(--btn-gradient) border-box;
  border: 2px solid transparent;
  box-shadow: 0 18px 40px rgba(0,0,0,.42);
}

.yx-modal-head {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 58px 12px 58px;
  background: rgba(255,255,255,0.04);
  border-bottom: 1px solid var(--border-soft);
}

.yx-modal-title {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 280px;
  max-width: 100%;
  padding: 6px 0 8px;
  border-radius: 3px;
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  background: linear-gradient(to right, #43ca69, #2eccdb, #f58afb, #52e4f1, #43ca69);
  background-size: 400% 100%;
  animation: buttonAni 10s linear infinite;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
}

.modal-close {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border-radius: 3px;
  border: 0;
  outline: none;
  font-size: 22px;
  line-height: 1;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(to right, #43ca69, #2eccdb, #f58afb, #52e4f1, #43ca69);
  background-size: 400% 100%;
  animation: buttonAni 10s linear infinite;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
}

.yx-modal-body {
  padding: 16px;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}

.yx-section-card {
  padding: 14px;
  border-radius: 12px;
  background: var(--card-bg);
  border: 1px solid var(--border-soft);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
}

.yx-section-card + .yx-section-card {
  margin-top: 12px;
}

.yx-section-title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 8px;
  color: #fff;
}

.yx-section-desc {
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-sub);
  word-break: break-word;
}

.yx-note-list {
  display: grid;
  gap: 8px;
}

.yx-note-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-sub);
}

.yx-note-bullet {
  flex: 0 0 auto;
  color: #fff;
  font-weight: 700;
  transform: translateY(1px);
}

.yx-kv-grid {
  display: grid;
  gap: 10px;
}

.yx-kv-item {
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--text-sub);
  font-size: 14px;
  line-height: 1.8;
}

.yx-kv-item b {
  display: block;
  color: #fff;
  margin-bottom: 4px;
  font-size: 15px;
}

.yx-table-wrap {
  margin-top: 10px;
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.08);
}

.yx-data-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  background: rgba(255,255,255,0.03);
}

.yx-data-table th,
.yx-data-table td {
  padding: 10px 8px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  text-align: center;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-sub);
  white-space: normal;
  word-break: break-word;
}

.yx-data-table th {
  color: #fff;
  font-weight: 700;
  background: rgba(255,255,255,0.06);
}

.yx-data-table strong {
  color: #fff;
}

.yx-modal-actions {
  padding: 12px 16px 16px;
  border-top: 1px solid var(--border-soft);
  background: rgba(255,255,255,0.03);
}

.modal-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  padding: 10px 12px;
  border-radius: 3px;
  text-decoration: none;
  border: 0;
  outline: none;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  background: linear-gradient(to right, #43ca69, #2eccdb, #f58afb, #52e4f1, #43ca69);
  background-size: 400% 100%;
  animation: buttonAni 10s linear infinite;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
  transition: .1s ease-in-out;
}

.modal-btn:hover {
  transform: scale(1.02);
}

.modal-btn:active {
  transform: scale(0.99);
}

@keyframes titleAni {
  0% { background-position: 0% 0; }
  100% { background-position: 200% 0; }
}

@keyframes buttonAni {
  0% { background-position: 0% 0; }
  100% { background-position: 400% 0; }
}

@media screen and (max-width: 640px) {
  .page-content {
    padding: 14px 14px 95px;
  }

  .center-menu {
    max-width: 92%;
    padding: 8px 6px 6px;
    border-radius: 12px;
  }

  .logo-wrap {
    margin-bottom: 22px;
  }

  .logo-wrap img {
    height: 5rem;
    width: auto;
    max-width: 100%;
  }

  .menu-grid {
    gap: 8px;
  }

  .menu-btn {
    width: 280px;
    max-width: 100%;
    font-size: 1rem;
  }

  .menu-btn:hover {
    transform: scale(1);
  }

  .menu-btn:active {
    transform: scale(.95);
  }

  #download-app {
    width: 85%;
    gap: 8px;
  }

  #download-app:hover {
    transform: translateX(-50%);
  }

  #download-app:active {
    transform: translateX(-50%) translateY(8px);
  }

  #download-app span {
    font-size: 14px;
  }

  #download-app .app-icon-img {
    width: 24px;
    height: 24px;
  }

  .yx-modal {
    padding: 10px;
  }

  .yx-modal-dialog {
    width: 100%;
    max-height: min(88vh, calc(var(--app-height) - 20px));
    border-radius: 14px;
  }

  .yx-modal-head {
    padding: 10px 48px 10px 48px;
  }

  .yx-modal-title {
    width: 220px;
    font-size: 16px;
    padding: 5px 0 7px;
  }

  .modal-close {
    right: 10px;
    width: 34px;
    height: 34px;
    flex-basis: 34px;
    font-size: 20px;
  }

  .yx-modal-body {
    padding: 10px;
  }

  .yx-section-card {
    padding: 10px;
  }

  .yx-section-title {
    font-size: 15px;
  }

  .yx-section-desc,
  .yx-note-item,
  .yx-kv-item {
    font-size: 13px;
    line-height: 1.72;
  }

  .yx-data-table {
    min-width: 480px;
  }

  .yx-data-table th,
  .yx-data-table td {
    font-size: 12px;
    padding: 8px 6px;
  }

  .yx-modal-actions {
    padding: 10px;
  }

  .modal-btn {
    min-height: 46px;
    font-size: 15px;
  }

  #modal-activity .yx-table-wrap {
    overflow-x: hidden;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.08);
  }

  #modal-activity .yx-data-table {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
  }

  #modal-activity .yx-data-table thead {
    display: table-header-group;
  }

  #modal-activity .yx-data-table tbody {
    display: table-row-group;
  }

  #modal-activity .yx-data-table tr {
    display: table-row;
  }

  #modal-activity .yx-data-table th,
  #modal-activity .yx-data-table td {
    display: table-cell;
    width: 33.3333%;
    padding: 6px 4px;
    font-size: 11px;
    line-height: 1.45;
    text-align: center;
    white-space: normal;
    word-break: break-word;
  }

  #modal-activity .yx-data-table td::before {
    content: none !important;
  }
}

@media screen and (max-width: 360px) {
  .menu-btn {
    font-size: 15px;
  }

  #download-app span {
    font-size: 13px;
  }

  #download-app .app-icon-img {
    width: 22px;
    height: 22px;
  }

  .yx-modal-title {
    width: 200px;
    font-size: 15px;
  }

  #modal-activity .yx-data-table th,
  #modal-activity .yx-data-table td {
    padding: 5px 3px;
    font-size: 10px;
    line-height: 1.35;
  }
}