:root {
  font-family: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  color: #24282a;
  background: #f5f6f7;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-width: 320px;
  background: #f5f6f7;
}

body {
  min-height: 100vh;
  margin: 0;
  background: #f5f6f7;
}

button,
a {
  letter-spacing: 0;
}

.site-header {
  display: flex;
  width: min(1080px, calc(100% - 40px));
  height: 72px;
  align-items: center;
  justify-content: space-between;
  margin: 0 auto;
  border-bottom: 1px solid #e2e5e6;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #22292b;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
}

.brand img {
  width: 34px;
  height: 34px;
}

.site-actions,
.account-mode,
.code-input-row,
.admin-heading,
.admin-panel header,
.admin-user,
.admin-user-actions,
.admin-orders > div {
  display: flex;
  align-items: center;
}

.site-actions { gap: 8px; }

button,
select,
input { font: inherit; }

.text-button {
  height: 32px;
  padding: 0 10px;
  border: 1px solid #d8dddd;
  border-radius: 5px;
  color: #4e5859;
  background: #fff;
  font-size: 12px;
  cursor: pointer;
}

main {
  width: min(1080px, calc(100% - 40px));
  margin: 0 auto;
}

.download-view {
  display: flex;
  min-height: min(620px, calc(100vh - 118px));
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 68px 0 74px;
  text-align: center;
}

.release-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 28px;
  color: #697174;
  font-size: 12px;
}

.release-status span {
  display: block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #2f9968;
  box-shadow: 0 0 0 4px rgba(47, 153, 104, 0.12);
}

.product-mark {
  width: 104px;
  height: 104px;
  margin-bottom: 22px;
  filter: drop-shadow(0 12px 22px rgba(42, 48, 50, 0.14));
}

h1 {
  margin: 0;
  color: #202526;
  font-size: 40px;
  font-weight: 720;
  line-height: 1.2;
}

.release-summary {
  margin: 14px 0 28px;
  color: #687073;
  font-size: 15px;
  line-height: 1.7;
}

.download-button {
  display: inline-flex;
  min-width: 224px;
  height: 50px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 24px;
  border: 1px solid #277c58;
  border-radius: 6px;
  color: #fff;
  background: #2e8b63;
  box-shadow: 0 8px 18px rgba(42, 112, 80, 0.2);
  font-size: 15px;
  font-weight: 650;
  text-decoration: none;
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.download-button:hover {
  background: #267a56;
  box-shadow: 0 10px 22px rgba(42, 112, 80, 0.25);
  transform: translateY(-1px);
}

.download-button:active {
  transform: translateY(0);
}

.download-button:focus-visible {
  outline: 3px solid rgba(46, 139, 99, 0.25);
  outline-offset: 3px;
}

.download-button svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.release-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 7px 18px;
  margin-top: 17px;
  color: #858c8f;
  font-size: 11px;
}

.checksum {
  min-height: 16px;
  margin: 9px 0 0;
  color: #9ba0a2;
  font-family: Consolas, monospace;
  font-size: 10px;
}

.release-band {
  display: grid;
  grid-template-columns: minmax(180px, 0.7fr) minmax(0, 1.5fr);
  gap: 72px;
  padding: 42px 0 52px;
  border-top: 1px solid #dfe3e4;
}

.section-label {
  margin: 0 0 7px;
  color: #2f8c65;
  font-size: 11px;
  font-weight: 650;
}

.release-band h2 {
  margin: 0;
  color: #2c3234;
  font-size: 22px;
  font-weight: 680;
}

.release-band ul {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  color: #5f676a;
  font-size: 13px;
  line-height: 1.7;
  list-style: none;
}

.release-band li {
  position: relative;
  padding-left: 17px;
}

.release-band li::before {
  position: absolute;
  top: 0.72em;
  left: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #db9d32;
  content: "";
}

.is-modal-open { overflow: hidden; }

.auth-modal {
  position: fixed;
  z-index: 50;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
}

.auth-modal[hidden] { display: none; }

.auth-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: rgba(24, 29, 30, 0.48);
  backdrop-filter: blur(3px);
}

.auth-dialog {
  position: relative;
  width: min(430px, 100%);
  overflow: hidden;
  border: 1px solid #d8dddc;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(24, 30, 30, 0.24);
}

.auth-dialog__header {
  display: flex;
  min-height: 78px;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid #e6e9e8;
}

.auth-dialog__header > div { display: flex; align-items: center; gap: 11px; }
.auth-dialog__header img { width: 38px; height: 38px; }
.auth-dialog__header h2 { margin: 0; color: #252d2e; font-size: 17px; }
.auth-dialog__header p { margin: 5px 0 0; color: #7b8385; font-size: 11px; }
.auth-close { width: 34px; height: 34px; padding: 0; border: 0; color: #687173; background: transparent; font-size: 24px; line-height: 1; cursor: pointer; }
.auth-dialog .account-form { padding: 18px; }
.auth-dialog .account-fields { grid-template-columns: 1fr; }

.account-form {
  display: grid;
  gap: 14px;
}

.account-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.account-mode {
  gap: 0;
  border-bottom: 1px solid #dfe3e4;
}

.account-mode button {
  height: 34px;
  padding: 0 11px;
  border: 0;
  border-bottom: 2px solid transparent;
  color: #697174;
  background: transparent;
  font-size: 12px;
  cursor: pointer;
}

.account-mode button.is-active {
  border-bottom-color: #2e8b63;
  color: #267a56;
  font-weight: 650;
}

.account-form label {
  display: grid;
  gap: 7px;
  color: #626a6d;
  font-size: 12px;
}

.account-form input {
  width: 100%;
  height: 40px;
  padding: 0 11px;
  border: 1px solid #d7dcde;
  border-radius: 5px;
  color: #252b2d;
  background: #fff;
  font: inherit;
}

.account-form select {
  width: 100%;
  height: 40px;
  padding: 0 10px;
  border: 1px solid #d7dcde;
  border-radius: 5px;
  color: #252b2d;
  background: #fff;
}

.code-input-row { gap: 8px; }
.code-input-row input { min-width: 0; }
.code-input-row button,
.account-fields > button,
.account-member > button,
.admin-heading > button,
.admin-code-form > button,
.admin-user-actions button {
  height: 40px;
  padding: 0 12px;
  border: 1px solid #2e8b63;
  border-radius: 5px;
  color: #fff;
  background: #2e8b63;
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
  white-space: nowrap;
}

.account-form input:focus {
  border-color: #4b9a72;
  outline: 3px solid rgba(46, 139, 99, 0.12);
}

.account-actions {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.account-actions button {
  height: 40px;
  border: 1px solid #2e8b63;
  border-radius: 5px;
  color: #fff;
  background: #2e8b63;
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}

.account-actions button + button {
  border-color: #d4dad7;
  color: #496052;
  background: #fff;
}

.account-status {
  grid-column: 1 / -1;
  min-height: 18px;
  margin: 0;
  color: #687073;
  font-size: 12px;
}

.account-status.is-error {
  color: #b14e45;
}

.account-member {
  grid-template-columns: minmax(0, 1fr);
  align-items: stretch;
}

.account-member strong { color: #273032; font-size: 16px; }
.account-member p:last-child { margin: 8px 0 0; color: #687073; font-size: 12px; }
.account-member > button { border-color: #d5dcda; color: #56625d; background: #fff; }
.profile-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: end; }
.profile-form label { display: grid; gap: 7px; color: #626a6d; font-size: 12px; }
.profile-form button, .account-member-actions button { height: 40px; padding: 0 12px; border: 1px solid #2e8b63; border-radius: 5px; color: #fff; background: #2e8b63; font: inherit; font-size: 12px; font-weight: 650; cursor: pointer; }
.account-member-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.account-member-actions button:last-child { border-color: #d5dcda; color: #56625d; background: #fff; }

.subscription-page { padding: 42px 0 56px; border-top: 1px solid #dfe3e4; }
.subscription-page__header { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.subscription-page__header h2 { margin: 0; color: #2c3234; font-size: 22px; }
.subscription-status { min-height: 44px; margin: 20px 0; padding: 12px 14px; border: 1px solid #dfe4e3; border-radius: 6px; color: #5e686a; background: #fff; font-size: 13px; }
.subscription-status.is-error { border-color: #e7c2bd; color: #a4483e; background: #fff8f7; }
.subscription-plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.subscription-plan { display: grid; gap: 12px; min-height: 188px; padding: 18px; border: 1px solid #dfe4e3; border-radius: 6px; background: #fff; }
.subscription-plan h3, .subscription-plan p { margin: 0; }
.subscription-plan h3 { color: #273032; font-size: 16px; }
.subscription-plan p { color: #697274; font-size: 12px; line-height: 1.6; }
.subscription-plan strong { color: #257a56; font-size: 23px; }
.subscription-plan button { align-self: end; height: 40px; border: 1px solid #2e8b63; border-radius: 5px; color: #fff; background: #2e8b63; font: inherit; font-size: 13px; font-weight: 650; cursor: pointer; }
.subscription-plan button:disabled { border-color: #d9dfdc; color: #89918f; background: #eef1f0; cursor: not-allowed; }

.admin-band {
  padding: 42px 0 56px;
  border-top: 1px solid #dfe3e4;
}

.admin-heading { justify-content: space-between; gap: 16px; }
.admin-heading h2 { margin: 0; color: #2c3234; font-size: 22px; }
.admin-metrics { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin: 22px 0; }
.admin-metrics > div { padding: 14px; border: 1px solid #dfe4e3; border-radius: 6px; background: #fff; }
.admin-metrics span, .admin-metrics strong { display: block; }
.admin-metrics span { color: #778083; font-size: 11px; }
.admin-metrics strong { margin-top: 7px; color: #26332f; font-size: 18px; }
.admin-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 16px; }
.admin-panel { border: 1px solid #dfe4e3; border-radius: 6px; background: #fff; }
.admin-panel header { min-height: 50px; justify-content: space-between; gap: 12px; padding: 0 14px; border-bottom: 1px solid #edf0ef; }
.admin-panel h3 { margin: 0; color: #2e3637; font-size: 14px; }
.admin-panel header input { width: min(220px, 54%); height: 32px; padding: 0 9px; border: 1px solid #d6ddda; border-radius: 4px; }
.admin-list { max-height: 440px; overflow: auto; }
.admin-user { justify-content: space-between; gap: 12px; padding: 12px 14px; border-bottom: 1px solid #edf0ef; }
.admin-user:last-child { border-bottom: 0; }
.admin-user strong, .admin-user span, .admin-user small { display: block; }
.admin-user strong { color: #354041; font-size: 13px; }
.admin-user span, .admin-user small { margin-top: 4px; color: #737d7f; font-size: 11px; }
.admin-user-actions { gap: 6px; }
.admin-user-actions input { width: 56px; height: 32px; padding: 0 6px; border: 1px solid #d6ddda; border-radius: 4px; }
.admin-user-actions button { height: 32px; padding: 0 9px; }
.admin-user-actions button:last-child { border-color: #d6ddda; color: #56625d; background: #fff; }
.admin-code-form { display: grid; gap: 12px; padding: 14px; }
.admin-code-form label { display: grid; gap: 6px; color: #687174; font-size: 12px; }
.admin-codes { max-height: 240px; overflow: auto; margin: 0; padding: 12px 14px; border-top: 1px solid #edf0ef; color: #26332f; background: #f8faf9; font: 11px/1.65 Consolas, monospace; }
.admin-orders-panel { margin-top: 16px; }
.admin-orders { overflow-x: auto; }
.admin-orders > div { display: grid; grid-template-columns: 1.35fr 1.2fr .85fr .6fr .6fr 1.2fr; min-width: 760px; gap: 10px; padding: 10px 14px; border-bottom: 1px solid #edf0ef; color: #596365; font-size: 11px; }

footer {
  display: flex;
  width: min(1080px, calc(100% - 40px));
  min-height: 68px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 0 auto;
  border-top: 1px solid #e2e5e6;
  color: #949a9c;
  font-size: 11px;
}

@media (max-width: 640px) {
  .site-header,
  main,
  footer {
    width: min(100% - 28px, 1080px);
  }

  .site-header {
    height: 62px;
  }

  .download-view {
    min-height: 540px;
    padding: 54px 0 62px;
  }

  .product-mark {
    width: 88px;
    height: 88px;
  }

  h1 {
    font-size: 32px;
  }

  .release-band {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 34px 0 42px;
  }

  .account-fields,
  .admin-grid,
  .subscription-plans { grid-template-columns: 1fr; }

  .profile-form { grid-template-columns: 1fr; }

  .admin-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .admin-user { align-items: flex-start; flex-direction: column; }

  footer {
    align-items: flex-start;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    padding: 18px 0;
  }
}
