:root {
  --sidebar: #dff3e7;
  --sidebar-dark: #c9ead7;
  --active: #72d69a;
  --topbar: #bce9cf;
  --primary: #38b66f;
  --accent: #1d9a59;
  --text: #263247;
  --muted: #7b8496;
  --line: #dcefe4;
  --page: #eef8f2;
  --content-scale: 0.8;
}

* { box-sizing: border-box; }

html {
  height: 100%;
}

body {
  margin: 0;
  height: 100%;
  min-width: 1180px;
  overflow: hidden;
  background: var(--page);
  color: var(--text);
  font-family: "Helvetica Neue", Helvetica, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

button, input, select, textarea { font: inherit; }

.app-shell {
  height: 100vh;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 240px 1fr;
  overflow: hidden;
}

.sidebar {
  background: var(--sidebar);
  color: #1f5e3a;
  height: 100vh;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.brand {
  height: 112px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 26px;
  background: rgba(255, 255, 255, 0.32);
}

.logo-mark {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(145deg, #35bd71, #8de6b0);
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  box-shadow: 0 12px 25px rgba(42, 117, 73, 0.16);
}

.brand-name {
  font-size: 29px;
  font-weight: 800;
  color: #1f7d4c;
}

.menu-group { border-top: 1px solid rgba(32, 120, 72, 0.12); }

.menu-title {
  height: 58px;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 0 24px;
}

.menu-icon { width: 20px; color: #2e8c58; }
.submenu { background: var(--sidebar-dark); }

.submenu button,
.menu-group.single > button {
  width: 100%;
  height: 54px;
  padding: 0 30px 0 64px;
  border: 0;
  background: transparent;
  color: #21563a;
  text-align: left;
  cursor: pointer;
}

.menu-group.single > button { padding-left: 56px; background: var(--sidebar); }
.submenu button.active, .menu-group.single > button.active { background: var(--active); color: #133820; font-weight: 700; }
.menu-group.admin { margin-top: 18px; opacity: 0.96; }

.main {
  min-width: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--page);
  overflow: hidden;
}

.content-frame {
  flex: 0 0 calc((100vh - 58px) / var(--content-scale));
  min-height: 0;
  height: calc((100vh - 58px) / var(--content-scale));
  width: calc(100% / var(--content-scale));
  overflow: auto;
  transform: scale(var(--content-scale));
  transform-origin: top left;
}

.number-content-frame {
  overflow: hidden;
}

.topbar {
  flex: 0 0 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 22px;
  background: var(--topbar);
  color: #19472e;
}

.hamburger {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: #21643f;
  font-size: 20px;
}

.top-actions { display: flex; align-items: center; gap: 10px; }
.language-toggle {
  height: 32px;
  border: 0;
  padding: 0 18px;
  background: rgba(255, 255, 255, 0.78);
  color: #1d5738;
  cursor: pointer;
}

.avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #28a960, #93e6b2);
  color: #fff;
  font-weight: 800;
}
.avatar.large {
  width: 76px;
  height: 76px;
  border-radius: 18px;
  font-size: 30px;
}

.breadcrumb {
  height: 44px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 0 22px;
  background: #fff;
  color: #667466;
  border-bottom: 1px solid #edf0f4;
}

.content { width: calc(100% - 36px); margin: 18px; }
.number-content {
  height: calc((100vh - 58px) / var(--content-scale) - 44px - 36px);
  overflow: visible;
}
.number-store-page {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.panel {
  background: #fff;
  border: 1px solid var(--line);
  padding: 18px;
}

.notice {
  flex: 0 0 auto;
  background: #f3fbf6;
  border: 1px solid #cfeedd;
  color: #287a4c;
  line-height: 1.45;
  margin-bottom: 12px;
  padding: 12px 18px;
}

.notice strong {
  display: block;
  margin-bottom: 8px;
}

.notice p {
  margin: 0 0 8px;
}

.notice p:last-child {
  margin-bottom: 0;
}

.store-panel {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.store-toolbar {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: 260px 250px minmax(430px, 1fr);
  gap: 12px;
  align-items: center;
  margin-bottom: 18px;
}

.store-toolbar.real-toolbar {
  grid-template-columns: 260px minmax(620px, 820px);
  justify-content: start;
}

.store-toolbar.virtual-toolbar {
  grid-template-columns: 240px 250px minmax(340px, 460px);
  justify-content: start;
}

.country-select, .search-row, .table-search {
  height: 46px;
  display: flex;
  align-items: center;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0 16px;
}

.country-select { gap: 14px; }
.country-select span { color: var(--muted); white-space: nowrap; }
.country-select select, .search-row input, .table-search input, .admin-product-card input, textarea {
  width: 100%;
  border: 0;
  outline: none;
  color: var(--text);
  background: transparent;
}

.toolbar-segmented {
  height: 46px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  border: 1px solid #cfeedd;
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
  padding: 4px;
}

.toolbar-segmented button {
  border: 0;
  border-radius: 4px;
  background: #f3fbf6;
  color: #4f6d5e;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.toolbar-segmented button:last-child {
  border-right: 0;
}

.toolbar-segmented button.active {
  background: linear-gradient(135deg, #35b76d, #72d69a);
  color: #fff;
  box-shadow: 0 6px 14px rgba(38, 152, 86, 0.22);
}

.search-row {
  gap: 10px;
  padding-right: 4px;
  min-width: 0;
}
.search-row input { min-width: 0; flex: 1; }
.search-row .btn { white-space: nowrap; }

.btn {
  height: 42px;
  border: 0;
  padding: 0 20px;
  background: var(--primary);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.btn.ghost { background: #e7f6ed; color: #1f7d4c; }

.products-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 6px;
}

.products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 20px;
}

.product-card {
  min-height: 152px;
  display: grid;
  grid-template-columns: 126px 1fr;
  gap: 20px;
  align-items: center;
  padding: 18px 22px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 1px 4px rgba(33, 100, 63, 0.08);
  cursor: pointer;
}

.product-icon {
  width: 116px;
  height: 116px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(145deg, #29a860, #7bd99f);
  color: #fff;
  font-size: 42px;
  font-weight: 800;
  border: 4px solid #f6f7fb;
  box-shadow: 0 2px 8px rgba(38, 90, 61, 0.16);
}

.product-icon.product-image {
  background: #fff;
  padding: 12px;
}

.product-icon.product-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.product-icon.small { width: 54px; height: 54px; font-size: 22px; border-width: 2px; }

.product-name { font-size: 22px; font-weight: 700; margin-bottom: 12px; }
.product-country { display: flex; align-items: center; gap: 8px; color: var(--muted); margin-bottom: 10px; }
.meta-row { display: flex; gap: 12px; align-items: baseline; color: var(--muted); margin-top: 8px; }
.meta-row strong { color: #263247; font-size: 18px; font-weight: 500; }

.mini-flag { width: 24px; height: 16px; display: inline-block; border: 1px solid #d3ded8; background: #fff; }
.mini-flag.us { background: linear-gradient(#b22234 0 7.7%, #fff 7.7% 15.4%, #b22234 15.4% 23.1%, #fff 23.1% 30.8%, #b22234 30.8% 38.5%, #fff 38.5% 46.2%, #b22234 46.2% 53.9%, #fff 53.9% 61.6%, #b22234 61.6% 69.3%, #fff 69.3% 77%, #b22234 77% 84.7%, #fff 84.7% 92.4%, #b22234 92.4%), linear-gradient(#3c3b6e, #3c3b6e); background-size: 100% 100%, 43% 54%; background-repeat: no-repeat; }
.mini-flag.ca { background: linear-gradient(90deg, #d52b1e 0 28%, #fff 28% 72%, #d52b1e 72%); }
.mini-flag.uk { background: #012169; }

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}

.stat-card {
  min-height: 104px;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--line);
  color: #1d5738;
}

.stat-value { font-size: 28px; font-weight: 800; margin-top: 8px; }
.stat-label { color: var(--muted); font-weight: 700; }

.table-toolbar, .admin-heading { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.table-search { width: 360px; }
.table-scroll { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; background: #fff; }
th, td { height: 58px; padding: 0 16px; border-bottom: 1px solid #f0f3f8; text-align: left; white-space: nowrap; }
th { background: #f8fffb; color: #637568; font-weight: 700; }
.mono { font-family: Consolas, "SFMono-Regular", monospace; }
.amount.green { color: #1dbb70; font-weight: 700; }
.amount.orange { color: #ef8a2e; font-weight: 700; }
.amount.blue { color: #5d78e8; font-weight: 700; }
.status { padding: 6px 10px; background: #dcf8e8; color: #139454; font-weight: 700; }
.status.success { background: #dcf8e8; color: #139454; }
.status.warning { background: #fff4cf; color: #a36400; }
.status.danger { background: #ffe3e3; color: #d93030; }
.status.muted { background: #edf1f5; color: #64748b; }
.kind-pill { display: inline-flex; align-items: center; min-height: 28px; padding: 0 10px; background: #e9f8ef; color: #167a47; font-weight: 800; }
.kind-pill.virtual { background: #edf4ff; color: #315db8; }
.small-btn { height: 32px; border: 0; padding: 0 12px; background: #e7f0eb; color: #244a37; cursor: pointer; }
.small-btn.primary { background: var(--primary); color: #fff; }
.small-btn.modal-action { width: 100%; height: 42px; margin: 0 0 12px; font-weight: 800; }

.admin-products { display: grid; grid-template-columns: repeat(auto-fit, minmax(360px, 1fr)); gap: 20px; }
.admin-product-card { background: #fff; border: 1px solid var(--line); padding: 22px; }
.admin-product-head { display: flex; gap: 16px; align-items: center; padding-bottom: 18px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.admin-product-head h3 { margin: 0 0 6px; }
.admin-product-head span { color: var(--muted); }
.admin-product-card label { display: block; color: var(--muted); margin: 14px 0 8px; }
.admin-product-card input, textarea { min-height: 40px; border: 1px solid var(--line); padding: 10px; }
textarea { height: 90px; resize: vertical; }
.price-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.empty-inline { min-height: 220px; display: grid; place-items: center; grid-column: 1 / -1; color: var(--muted); border: 1px dashed var(--line); background: #fbfffc; }
.wallet-address { margin: 12px 0; padding: 14px; border: 1px solid var(--line); background: #f8fffb; font-family: Consolas, monospace; }

.renewal-page {
  min-height: calc(100vh - 170px);
  display: grid;
  align-content: start;
  gap: 22px;
}

.renewal-notice {
  width: 100%;
  border: 1px solid #bcd2ff;
  background: #eef3ff;
  color: #234a82;
  padding: 18px 22px;
  line-height: 1.8;
}

.renewal-notice strong {
  display: block;
  margin-bottom: 6px;
}

.renewal-notice p {
  margin: 2px 0;
}

.renewal-tabs {
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

.renewal-tabs button {
  min-width: 150px;
  height: 44px;
  border: 0;
  border-bottom: 3px solid transparent;
  background: transparent;
  color: var(--muted);
  font-weight: 900;
  cursor: pointer;
}

.renewal-tabs button.active,
.renewal-tabs button:hover {
  border-bottom-color: var(--primary);
  color: var(--primary-dark);
  background: #effaf4;
}

.renewal-choice-wrap {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 360px));
  justify-content: center;
  gap: 22px;
}

.renewal-choice-wrap.single {
  grid-template-columns: minmax(260px, 420px);
  min-height: 240px;
  align-items: center;
}

.renewal-choice-card {
  min-height: 150px;
  border: 1px solid #cfe3d8;
  background: #fff;
  box-shadow: 0 6px 18px rgba(32, 120, 72, 0.08);
  cursor: pointer;
  display: grid;
  align-content: center;
  gap: 12px;
  padding: 28px;
  text-align: left;
  color: var(--text);
}

.renewal-choice-card:hover {
  border-color: var(--primary);
  box-shadow: 0 10px 26px rgba(32, 120, 72, 0.14);
}

.renewal-choice-card strong {
  font-size: 24px;
  color: #184b30;
}

.renewal-choice-card span {
  color: var(--muted);
  line-height: 1.6;
}

.renewal-inline-card {
  width: 100%;
  justify-self: stretch;
  display: grid;
  gap: 18px;
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
}

.renewal-inline-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  padding: 4px 0 14px;
}

.renewal-inline-head h2 {
  margin: 0;
  color: #184b30;
  font-size: 22px;
}

.renewal-inline-head span {
  color: var(--muted);
  font-weight: 700;
}

.renewal-page-message {
  width: min(760px, 100%);
  justify-self: center;
}

.renewal-modal {
  width: min(900px, calc((100vw - 300px) / var(--content-scale)));
}

.renewal-modal-body {
  display: grid;
  gap: 16px;
  padding: 20px 22px 24px;
  overflow: visible;
}

.renewal-top-tip {
  border: 1px solid #cfe3d8;
  background: #f3fbf6;
  color: #17613b;
  padding: 13px 15px;
  font-weight: 800;
}

.renewal-form-grid {
  display: grid;
  grid-template-columns: minmax(190px, 260px) minmax(320px, 1fr);
  gap: 18px;
}

.renewal-form-grid label,
.renewal-number-input {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-weight: 700;
}

.renewal-form-grid select,
.renewal-number-input textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  padding: 0 12px;
  outline: none;
}

.renewal-form-grid select {
  height: 44px;
}

.renewal-number-input textarea {
  min-height: 168px;
  padding: 12px;
  resize: vertical;
  font-family: Consolas, "Courier New", monospace;
}

.renewal-price-box {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  border: 1px solid #e0ece6;
  background: #fbfffd;
  padding: 12px 14px;
}

.renewal-price-box span,
.renewal-price-box em {
  color: var(--muted);
  font-style: normal;
}

.renewal-price-box strong {
  color: var(--primary);
  font-size: 18px;
}

.renewal-validation {
  border: 1px solid #d8e5df;
  padding: 12px 14px;
  background: #fff;
}

.renewal-validation.ok {
  border-color: #bfe8cf;
  background: #f4fff8;
}

.renewal-validation.bad {
  border-color: #ffd5d5;
  background: #fff8f8;
}

.renewal-validation-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  font-weight: 800;
}

.renewal-validation.ok strong { color: #139454; }
.renewal-validation.bad strong { color: #c83232; }

.renewal-invalid-list {
  display: grid;
  gap: 6px;
  max-height: 110px;
  overflow: auto;
  margin-top: 8px;
}

.renewal-invalid-list div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  color: #822;
}

.renewal-balance-warning {
  margin: 10px 0 0;
  color: #c83232;
  font-weight: 800;
}

.renewal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

.renewal-actions button:disabled {
  border-color: #d7dedb;
  background: #eef2f0;
  color: #8c9993;
  cursor: not-allowed;
}

.renewal-history-card {
  width: 100%;
  justify-self: center;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 8px 22px rgba(32, 120, 72, 0.08);
}

.renewal-history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px 0;
}

.renewal-history-head h2 {
  margin: 0 0 14px;
}

.renewal-number-cell {
  min-width: 190px;
  max-width: 240px;
  vertical-align: top;
}

.renewal-number-list {
  display: grid;
  gap: 6px;
}

.renewal-number-count {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.renewal-number-scroll {
  max-height: 108px;
  overflow-y: auto;
  border: 1px solid var(--line);
  background: #f8fcfa;
  padding: 6px 8px;
}

.renewal-number-scroll span {
  display: block;
  line-height: 1.65;
  white-space: nowrap;
  font-family: Consolas, "Courier New", monospace;
  color: #24334d;
}

.renewal-records-panel {
  display: grid;
  gap: 18px;
}

.renewal-record-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 14px;
}

.renewal-record-stats div {
  border: 1px solid var(--line);
  background: #fff;
  padding: 16px 18px;
  box-shadow: 0 8px 20px rgba(32, 120, 72, 0.06);
}

.renewal-record-stats span {
  color: var(--muted);
  font-weight: 800;
}

.renewal-record-stats strong {
  display: block;
  margin-top: 8px;
  color: var(--primary-dark);
  font-size: 22px;
}

.renewal-table-scroll {
  width: 100%;
  overflow-x: auto;
}

.renewal-record-table {
  min-width: 1280px;
  border-collapse: collapse;
}

.renewal-record-table th {
  background: #eef8f2;
  color: #355946;
}

.renewal-record-table td,
.renewal-record-table th {
  border-bottom: 1px solid var(--line);
  padding: 13px 14px;
  text-align: left;
}

@media (max-width: 900px) {
  .renewal-choice-wrap,
  .renewal-form-grid {
    grid-template-columns: 1fr;
  }
  .renewal-modal {
    width: calc(100vw - 28px);
  }
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  bottom: auto;
  min-height: 100vh;
  height: 100vh;
  padding: 18px;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.42);
  z-index: 1000;
}

.content-frame .modal-backdrop {
  height: calc((100vh - 58px) / var(--content-scale));
  min-height: calc((100vh - 58px) / var(--content-scale));
}

.modal-backdrop.open { display: flex; }
.order-modal { position: relative; z-index: 1001; width: min(980px, calc((100vw - 300px) / var(--content-scale))); max-height: calc((100vh - 24px) / var(--content-scale)); overflow: visible; background: #fff; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.24); display: flex; flex-direction: column; }
.order-modal.small-modal { width: min(860px, calc((100vw - 300px) / var(--content-scale))); }
.order-modal.order-details-modal { width: min(952px, calc(100vw - 36px)); }
body > .modal-backdrop.viewport-order-details {
  z-index: 80;
  padding: 24px;
}
body > .modal-backdrop.viewport-order-details .legacy-order-modal {
  width: min(782px, calc(100vw - 48px));
  max-height: calc(100vh - 48px);
}
body > .modal-backdrop.viewport-order-details .details-body {
  max-height: calc(100vh - 106px);
}
.modal-title { height: 58px; display: flex; align-items: center; justify-content: space-between; padding: 0 22px; background: var(--topbar); color: #17492d; font-weight: 800; }
.close-btn { border: 0; background: transparent; color: #1d5738; font-size: 28px; cursor: pointer; }
.modal-body { max-height: none; overflow: visible; display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(330px, 360px); gap: 18px; padding: 18px; }
.modal-left, .modal-right, .note-box { border: 1px solid var(--line); background: #fff; }
.modal-product { display: grid; grid-template-columns: 210px 1fr; gap: 20px; padding: 22px; }
.modal-product .product-icon { width: 190px; height: 190px; font-size: 66px; }
.detail-table { border-left: 1px solid var(--line); }
.detail-table div { min-height: 48px; display: grid; grid-template-columns: 90px 1fr; align-items: center; border-bottom: 1px solid var(--line); }
.detail-table span { color: var(--muted); }
.note-box { margin-top: 18px; min-height: 210px; padding: 24px; line-height: 1.8; }
.note-box p { white-space: pre-line; }
.modal-right { padding: 18px; }
.balance-line { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.balance-line strong { color: var(--accent); font-size: 22px; }
.choice-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 18px 0; }
.choice-row.single { grid-template-columns: 1fr; }
.choice-row button { height: 42px; border: 1px solid var(--line); background: #fff; cursor: pointer; }
.choice-row button.active { color: var(--primary); border-color: var(--primary); font-weight: 700; }
.choice-row button small { margin-left: 4px; color: #d05a1f; font-weight: 800; }
.choice-row button.active small { color: #b14415; }
.field { height: 48px; display: flex; align-items: center; gap: 12px; border: 1px solid var(--line); margin-bottom: 14px; padding: 0 14px; color: var(--muted); }
.field.has-error { border-color: #ff5a5f; }
.field-error { margin: -10px 0 14px; color: #ff3b3f; font-size: 13px; line-height: 1.4; }
.field-error.hidden { display: none; }
.modal-input { width: 100%; border: 0; outline: none; }
.voice-price-note { margin-left: 6px; color: #d05a1f; font-weight: 800; }
.modal-control {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
}
.modal-control select,
.modal-control input {
  width: 100%;
  height: 42px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  padding: 0 12px;
  outline: none;
}
.designated-input {
  width: 100%;
  min-height: 138px;
  margin-bottom: 14px;
  border: 1px solid var(--line);
  padding: 12px;
  resize: vertical;
  outline: none;
}
.inventory-status {
  margin: -4px 0 12px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
.designated-price-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  border: 1px solid #b7ecd0;
  background: #f3fbf6;
  color: #315b43;
  padding: 9px 11px;
  font-size: 14px;
}
.designated-price-line strong {
  color: #168552;
  font-size: 15px;
}
.designated-price-line em {
  margin-left: auto;
  color: #0f6c42;
  font-style: normal;
  font-weight: 700;
}
.designated-hint {
  margin-bottom: 12px;
  border: 1px dashed #a9dfc2;
  background: #f8fffb;
  color: #42614f;
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.6;
}
.option-block,
.inventory-picker {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
}
.option-chips,
.segment-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.option-chip,
.segment-chip {
  min-height: 34px;
  border: 1px solid var(--line);
  background: #fff;
  color: #315342;
  padding: 0 10px;
  cursor: pointer;
}
.option-chip.active,
.segment-chip.active {
  border-color: var(--primary);
  background: #e9fbf0;
  color: var(--accent);
  font-weight: 800;
}
.dropdown-block {
  position: relative;
}
.select-trigger {
  width: 100%;
  min-height: 46px;
  display: grid;
  grid-template-columns: 28px 1fr;
  align-items: center;
  gap: 10px;
  border: 1px solid #18bfa5;
  border-radius: 8px;
  background: #fff;
  color: #243247;
  padding: 10px 14px;
  text-align: left;
  cursor: pointer;
}
.select-trigger span:last-child {
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.45;
}
.select-icon {
  color: #94a7bb;
  font-size: 20px;
  text-align: center;
}
.select-menu {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% - 1px);
  z-index: 40;
  max-height: 318px;
  overflow: auto;
  border: 1px solid #8a98a8;
  border-top: 0;
  background: #fff;
  box-shadow: 0 10px 22px rgba(33, 61, 86, 0.16);
}
.select-menu.single {
  max-height: 190px;
}
.select-option {
  width: 100%;
  min-height: 36px;
  border: 0;
  background: #fff;
  color: #0d1f38;
  padding: 0 60px;
  text-align: left;
  cursor: pointer;
}
.select-option:hover,
.select-option.active {
  background: #236dd1;
  color: #fff;
}
.select-option.disabled,
.select-option:disabled,
.select-option.disabled:hover,
.select-option:disabled:hover {
  background: #f1f5f3;
  color: #98a8a0;
  cursor: not-allowed;
}
.feedback-backdrop {
  z-index: 1200;
}
.feedback-modal {
  width: min(430px, calc(100vw - 40px));
  background: #fff;
  border: 1px solid #d8eee0;
  box-shadow: 0 18px 44px rgba(30, 83, 56, 0.22);
  padding: 30px 28px 26px;
  text-align: center;
}
.feedback-mark {
  width: 58px;
  height: 58px;
  margin: 0 auto 16px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  font-size: 30px;
  font-weight: 900;
}
.feedback-modal.success .feedback-mark { background: #35b96d; }
.feedback-modal.error .feedback-mark { background: #e05252; }
.feedback-modal h3 {
  margin: 0 0 10px;
  color: var(--text);
  font-size: 21px;
}
.feedback-modal p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.renewal-confirm-modal {
  position: relative;
  text-align: left;
}

.renewal-confirm-close {
  position: absolute;
  top: 10px;
  right: 14px;
  font-size: 24px;
}

.renewal-confirm-modal h3 {
  text-align: center;
  margin-right: 24px;
}

.renewal-confirm-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 18px 0;
}

.renewal-confirm-summary div {
  border: 1px solid #d8eee0;
  background: #f6fbf8;
  padding: 12px;
}

.renewal-confirm-summary span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 6px;
}

.renewal-confirm-summary strong {
  color: var(--primary);
  font-size: 20px;
}

.renewal-confirm-modal p {
  text-align: center;
}
.feedback-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 22px;
}
.option-empty {
  min-height: 38px;
  display: grid;
  align-items: center;
  border: 1px dashed var(--line);
  background: #fbfffc;
  color: var(--muted);
  padding: 0 12px;
}
.inventory-list {
  max-height: 150px;
  overflow: auto;
  display: grid;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--line);
  background: #fbfffc;
}
.inventory-number {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 36px;
  border: 1px solid #d7ecdf;
  background: #fff;
  color: var(--text);
  padding: 0 10px;
  cursor: pointer;
}
.inventory-number small {
  color: var(--muted);
}
.buy-btn { width: 100%; height: 56px; border: 0; background: var(--primary); color: #fff; font-size: 17px; font-weight: 800; cursor: pointer; }
.buy-btn.disabled,
.buy-btn:disabled { background: #b9c7bd; color: #f4fff8; cursor: not-allowed; box-shadow: none; }
.purchase-footer { display: grid; gap: 8px; margin: 8px 0 22px; }
.purchase-hint { min-height: 20px; font-size: 13px; line-height: 1.5; }
.purchase-hint.ok { color: #168552; }
.purchase-hint.danger { color: #d93030; }
.order-total-line strong { font-size: 18px; }
.service-lines { display: grid; gap: 14px; padding-top: 8px; border-top: 1px solid var(--line); color: var(--muted); line-height: 1.55; }
.details-body {
  max-height: calc(88vh - 58px);
  overflow: auto;
  padding: 18px;
}
.legacy-order-modal { width: min(884px, calc(100vw - 36px)); border-radius: 8px; }
.legacy-order-body { display: grid; gap: 16px; }
.order-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 1px solid var(--line);
  background: #fff;
  font-size: 12.6px;
}
.order-summary-grid div {
  min-height: 35px;
  display: grid;
  grid-template-columns: 84px 1fr;
  align-items: center;
  gap: 9px;
  padding: 6px 12px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.order-summary-grid div:nth-child(2n) { border-right: 0; }
.order-summary-grid span { color: var(--muted); }
.order-summary-grid strong { color: var(--text); overflow-wrap: anywhere; font-size: 13.6px; }
.details-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 10px;
}
.legacy-number-box {
  min-height: 180px;
  max-height: 310px;
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--line);
  background: #fbfffc;
  font-family: Consolas, "SFMono-Regular", monospace;
  font-size: 12px;
  line-height: 1.6;
}
.legacy-number-line {
  display: block;
  min-width: 100%;
  width: max-content;
  padding: 2px 0;
}
.legacy-number-line span {
  white-space: nowrap;
  word-break: normal;
  overflow: visible;
  user-select: text;
}
.legacy-number-line small {
  grid-column: 1 / -1;
  color: var(--muted);
  font-family: Arial, "Microsoft YaHei", sans-serif;
  font-size: 12px;
}
.sms-log-section {
  display: grid;
  gap: 10px;
}
.sms-log-section h3 {
  margin: 4px 0 0;
  font-size: 16px;
}
.hidden-copy-source {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
}
.receive-cell {
  max-width: 340px;
  display: grid;
  gap: 6px;
  line-height: 1.45;
  word-break: break-all;
}
.receive-cell a {
  color: var(--accent);
  font-weight: 700;
  text-decoration: none;
}
.receive-cell small {
  color: var(--muted);
}
.inline-success {
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid #bdeed0;
  background: #effcf4;
  color: #167a47;
  font-weight: 800;
}

.muted { color: var(--muted); line-height: 1.7; }
.form-grid { display: grid; gap: 12px; margin: 14px 0; }
.form-grid label { color: var(--muted); }
.form-grid input { width: 100%; height: 42px; margin-top: 8px; border: 1px solid var(--line); padding: 0 12px; outline: none; }
.table-toolbar.compact { margin-bottom: 10px; }

.notice-items { display: grid; gap: 14px; }
.notice-item { padding: 18px; border: 1px solid var(--line); background: #fbfffc; }
.notice-title-item { padding: 0; }
.notice-title-button {
  width: 100%;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border: 0;
  background: transparent;
  color: var(--text);
  padding: 0 18px;
  text-align: left;
  cursor: pointer;
}
.notice-title-button:hover { background: #f0fbf5; color: var(--accent); }
.notice-title-button span { color: var(--muted); font-size: 13px; }
.notice-item div { display: flex; justify-content: space-between; gap: 20px; }
.notice-item span { color: var(--muted); }
.notice-item p { margin-bottom: 0; line-height: 1.7; }
.platform-notice-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: grid;
  place-items: center;
  background: rgba(24, 48, 38, 0.32);
  padding: 24px;
}
.platform-notice-modal {
  width: min(900px, calc(100vw - 48px));
  min-height: 540px;
  max-height: calc(100vh - 56px);
  display: grid;
  grid-template-rows: 64px minmax(0, 1fr) auto;
  background: #fff;
  border: 1px solid #d9efe2;
  box-shadow: 0 18px 48px rgba(24, 83, 56, 0.26);
}
.platform-notice-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  background: var(--topbar);
  color: #17492d;
  font-size: 22px;
  font-weight: 800;
}
.platform-notice-close {
  border: 0;
  background: transparent;
  color: #1d5738;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
}
.platform-notice-body {
  overflow: auto;
  padding: 34px 32px 26px;
  color: #59636d;
  line-height: 1.8;
}
.platform-notice-body h2 {
  margin: 0 0 24px;
  text-align: center;
  color: #202b3d;
  font-size: 24px;
}
.platform-notice-time {
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  color: #8390a3;
}
.platform-notice-content {
  display: grid;
  gap: 14px;
  text-align: center;
  font-size: 17px;
}
.platform-notice-content p { margin: 0; }
.platform-notice-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 0 28px 24px;
}
.notice-switch {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  color: #293447;
}
.notice-switch input { display: none; }
.notice-switch span {
  width: 52px;
  height: 28px;
  position: relative;
  border-radius: 999px;
  background: #d9dee8;
  transition: background 0.2s ease;
}
.notice-switch span::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  left: 3px;
  top: 3px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.16);
  transition: transform 0.2s ease;
}
.notice-switch input:checked + span { background: var(--primary); }
.notice-switch input:checked + span::after { transform: translateX(24px); }
.notice-switch em { font-style: normal; }

.support-panel { max-width: 1040px; margin-inline: auto; }
.support-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; margin-top: 18px; }
.support-card { min-height: 380px; padding: 22px; border: 1px solid var(--line); background: #fbfffc; display: flex; flex-direction: column; align-items: stretch; text-align: center; gap: 16px; text-decoration: none; color: inherit; box-shadow: 0 10px 28px rgba(44, 108, 72, .07); transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease; }
.support-card-link { cursor: pointer; }
.support-card-link:hover { border-color: #57c788; box-shadow: 0 14px 30px rgba(41, 132, 84, .12); transform: translateY(-1px); }
.support-image-wrap { width: 100%; height: 260px; display: grid; place-items: center; border: 1px solid #d7ecdf; background: #fff; overflow: hidden; }
.support-image { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; object-position: center center; border-radius: 6px; background: #fff; }
.support-image-wrap > img.support-image { width: 100%; height: 100%; min-width: 0; min-height: 0; object-fit: contain; }
.support-image-placeholder { width: 100%; height: 100%; display: grid; place-items: center; border: 1px dashed var(--line); color: #1d9a59; font-size: 44px; font-weight: 900; }
.support-card-body { width: 100%; display: grid; align-content: start; justify-items: center; gap: 9px; }
.support-card span { color: var(--muted); font-weight: 800; }
.support-card p { margin: 0; color: #546273; line-height: 1.65; }
.support-card strong { width: 100%; padding: 10px 12px; border: 1px solid var(--line); background: #f6fbf8; font-size: 16px; color: #1d5738; overflow-wrap: anywhere; }
.support-card em { width: max-content; margin-top: 4px; padding: 6px 10px; background: #e5f7ed; color: #167a47; font-style: normal; font-weight: 800; }
.support-card-link strong { text-decoration: underline; text-underline-offset: 4px; }

@media (max-width: 1100px) {
  .support-grid { grid-template-columns: repeat(2, minmax(260px, 1fr)); }
}

@media (max-width: 720px) {
  .support-grid { grid-template-columns: 1fr; }
}

.partner-panel { max-width: 1040px; margin-inline: auto; }
.partner-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); justify-content: center; gap: 28px; margin-top: 18px; }
.partner-card { min-height: 360px; padding: 22px; border: 1px solid var(--line); background: #fbfffc; display: flex; flex-direction: column; align-items: stretch; text-align: center; gap: 16px; color: inherit; text-decoration: none; box-shadow: 0 10px 28px rgba(44, 108, 72, .07); transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease; }
.partner-card-link { cursor: pointer; }
.partner-card-link:hover { border-color: #57c788; box-shadow: 0 14px 30px rgba(41, 132, 84, .12); transform: translateY(-1px); }
.partner-image-wrap { width: 100%; height: 210px; display: grid; place-items: center; border: 1px solid #d7ecdf; background: #fff; overflow: hidden; }
.partner-image { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; object-position: center center; background: #fff; }
.partner-image-wrap > img.partner-image { width: 100%; height: 100%; min-width: 0; min-height: 0; object-fit: contain; }
.partner-image-placeholder { width: 100%; height: 100%; display: grid; place-items: center; color: #1d9a59; font-size: 36px; font-weight: 900; border: 1px dashed var(--line); }
.partner-card-body { width: 100%; min-width: 0; display: grid; justify-items: center; gap: 9px; align-content: start; }
.partner-card strong { color: #1d5738; font-size: 17px; overflow-wrap: anywhere; }
.partner-card p { margin: 0; color: #546273; line-height: 1.55; overflow-wrap: anywhere; }
.partner-card span { width: max-content; max-width: 100%; padding: 6px 10px; background: #e5f7ed; color: #167a47; font-weight: 800; }

@media (max-width: 1180px) {
  .partner-grid { grid-template-columns: repeat(2, minmax(260px, 1fr)); }
}

@media (max-width: 760px) {
  .partner-grid { grid-template-columns: 1fr; }
}

.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
  background: #eef8f2;
}

.auth-shell {
  width: min(980px, calc(100vw - 72px));
  min-height: 580px;
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  transform: scale(var(--content-scale));
  transform-origin: center;
  overflow: hidden;
  border: 1px solid rgba(39, 145, 83, 0.18);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 55px rgba(35, 105, 66, 0.16);
}

.auth-intro {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 24px;
  padding: 54px;
  background: #2a9b60;
  color: #fff;
}

.auth-logo-line {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 30px;
  font-weight: 900;
}

.auth-logo-mark {
  width: 56px;
  height: 56px;
  border: 2px solid rgba(255, 255, 255, 0.7);
  background: rgba(255, 255, 255, 0.18);
  box-shadow: none;
}

.auth-intro h1 {
  max-width: 360px;
  margin: 0;
  font-size: 28px;
  line-height: 1.22;
  letter-spacing: 0;
}

.auth-intro p {
  max-width: 390px;
  margin: -10px 0 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 16px;
  line-height: 1.8;
}

.auth-badges {
  display: grid;
  gap: 10px;
}

.auth-badges span {
  min-height: 34px;
  display: flex;
  align-items: center;
  border-left: 3px solid rgba(255, 255, 255, 0.75);
  padding: 0 0 0 12px;
  background: transparent;
  font-weight: 800;
}

.auth-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 46px 52px;
}

.auth-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.auth-panel-head h2 {
  margin: 0 0 8px;
  color: #1f4d35;
  font-size: 28px;
  letter-spacing: 0;
}

.auth-panel-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.auth-panel-head button {
  height: 34px;
  border: 1px solid #cfeedd;
  border-radius: 6px;
  background: #f5fff9;
  color: #1e8650;
  padding: 0 14px;
  cursor: pointer;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  overflow: hidden;
  margin-bottom: 18px;
  border: 1px solid #cfeedd;
  border-radius: 6px;
  background: #f7fffa;
}

.auth-tabs button {
  height: 42px;
  border: 0;
  background: transparent;
  color: #5f7869;
  font-weight: 800;
  cursor: pointer;
}

.auth-tabs button.active {
  background: linear-gradient(135deg, #34b76d, #72d69a);
  color: #fff;
}

.auth-form {
  display: grid;
  gap: 13px;
}

.auth-form label {
  display: grid;
  gap: 8px;
  color: #315342;
  font-weight: 800;
}

.auth-form input {
  width: 100%;
  height: 42px;
  border: 1px solid #d5eadf;
  border-radius: 6px;
  background: #fbfffc;
  color: var(--text);
  padding: 0 14px;
  outline: none;
}

.auth-form input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(56, 182, 111, 0.12);
}

.captcha-row {
  display: grid;
  grid-template-columns: 108px 1fr 82px;
  gap: 8px;
}

.captcha-row strong {
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid #d5eadf;
  border-radius: 6px;
  background: #f1fbf5;
  color: #1f6d43;
  font-size: 17px;
}

.captcha-row input {
  margin: 0;
}

.captcha-row button {
  height: 42px;
  border: 1px solid #cfeedd;
  border-radius: 6px;
  background: #f5fff9;
  color: #1e8650;
  font-weight: 800;
  cursor: pointer;
}

.auth-submit {
  width: 100%;
  height: 44px;
  margin-top: 8px;
  border-radius: 6px;
  font-size: 17px;
}

.auth-bottom {
  display: flex;
  justify-content: flex-start;
  gap: 12px;
  margin-top: 24px;
}

.auth-bottom button {
  border: 0;
  background: transparent;
  color: var(--primary);
  font-weight: 800;
  cursor: pointer;
}

.wallet-tabs {
  display: flex;
  gap: 36px;
  padding: 0 0 16px;
  margin-bottom: 22px;
  border-bottom: 1px solid #d9e4df;
}

.wallet-tabs button {
  height: 46px;
  border: 0;
  border-bottom: 3px solid transparent;
  background: transparent;
  color: #526a82;
  font-size: 20px;
  cursor: pointer;
}

.wallet-tabs button.active {
  border-color: #12bfa8;
  color: #08aa97;
  font-weight: 800;
}

.wallet-card {
  padding: 36px;
  background: #fff;
  border: 1px solid #dbe5ee;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(29, 68, 102, 0.08);
}

.wallet-tip {
  padding: 26px;
  border: 1px solid #a9cbff;
  border-radius: 8px;
  background: #eef6ff;
  color: #0b48f0;
  line-height: 1.8;
  font-size: 16px;
}

.wallet-tip .danger,
.wallet-tip p.danger {
  color: #ef1d2f;
  font-weight: 800;
}

.recharge-form {
  display: grid;
  gap: 28px;
  margin-top: 42px;
  max-width: 720px;
}

.form-row {
  display: grid;
  grid-template-columns: 120px 1fr;
  align-items: center;
  gap: 24px;
}

.form-row label {
  color: #223149;
  font-size: 18px;
  font-weight: 800;
}

.form-row em {
  color: #f23333;
  font-style: normal;
}

.pay-method {
  width: 240px;
  height: 58px;
  border: 2px solid #12bfa8;
  border-radius: 8px;
  background: #f5fffc;
  color: #087d71;
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
}

.pay-method span {
  display: inline-grid;
  width: 28px;
  height: 28px;
  place-items: center;
  margin-right: 8px;
  border-radius: 50%;
  background: #12bfa8;
  color: #fff;
}

.pay-method b {
  display: inline-grid;
  width: 20px;
  height: 20px;
  place-items: center;
  margin-left: 8px;
  border-radius: 50%;
  background: #12bfa8;
  color: #fff;
}

.amount-input {
  display: grid;
  grid-template-columns: 1fr 86px;
  width: 430px;
  height: 50px;
  border: 1px solid #d7e1ed;
  border-radius: 8px;
  overflow: hidden;
}

.amount-input.txid-input {
  grid-template-columns: 1fr;
  width: min(560px, 100%);
}

.amount-input input {
  border: 0;
  padding: 0 20px;
  outline: none;
}

.amount-input span {
  display: grid;
  place-items: center;
  background: #e4ebf4;
  color: #314c6d;
  font-weight: 800;
}

.submit-recharge {
  width: 140px;
  height: 50px;
  margin-left: 144px;
  border: 0;
  border-radius: 8px;
  background: #5547e8;
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  box-shadow: 0 6px 14px rgba(85, 71, 232, 0.28);
  cursor: pointer;
}

.recharge-active-card {
  padding: 28px;
}

.recharge-result-card {
  min-height: 420px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 16px;
  text-align: center;
}

.recharge-result-icon {
  width: 86px;
  height: 86px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #25bf76;
  color: #fff;
  font-size: 52px;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(37, 191, 118, 0.22);
}

.recharge-result-card.ended .recharge-result-icon {
  background: #e74b4b;
  box-shadow: 0 14px 30px rgba(231, 75, 75, 0.2);
}

.recharge-result-card h3 {
  margin: 0;
  color: #123424;
  font-size: 28px;
}

.recharge-result-card p {
  margin: 0;
  color: #607382;
  font-size: 17px;
  font-weight: 700;
}

.recharge-result-meta,
.recharge-result-txid {
  display: grid;
  gap: 6px;
  padding: 12px 18px;
  border: 1px solid #d8ede4;
  border-radius: 10px;
  background: #f7fffb;
}

.recharge-result-meta span,
.recharge-result-txid span {
  color: #6b7d8a;
  font-weight: 700;
}

.recharge-result-meta strong {
  color: #118f58;
  font-size: 24px;
  font-weight: 900;
}

.recharge-result-txid code {
  max-width: min(760px, 76vw);
  overflow-wrap: anywhere;
  color: #223149;
  font-family: Consolas, monospace;
}

.recharge-result-primary {
  width: auto;
  min-width: 130px;
  margin-left: 0;
  padding: 0 24px;
}

.recharge-active-grid {
  display: grid;
  grid-template-columns: minmax(220px, 300px) 1fr;
  gap: 28px;
  align-items: stretch;
}

.recharge-qr-panel {
  display: grid;
  justify-items: center;
  gap: 16px;
  padding: 24px;
  border: 1px solid #b8e8df;
  border-radius: 12px;
  background: linear-gradient(180deg, #f6fffc 0%, #eefaf6 100%);
}

.recharge-qr {
  width: min(220px, 100%);
  aspect-ratio: 1;
  border: 10px solid #fff;
  border-radius: 12px;
  box-shadow: 0 10px 22px rgba(18, 120, 96, 0.12);
}

.recharge-pay-amount,
.recharge-countdown {
  display: grid;
  justify-items: center;
  gap: 6px;
}

.recharge-pay-amount span,
.recharge-countdown span {
  color: #5f7184;
  font-weight: 700;
}

.recharge-pay-amount strong {
  color: #e43b46;
  font-size: 28px;
  font-weight: 900;
}

.recharge-pay-amount em {
  color: #08aa97;
  font-size: 15px;
  font-style: normal;
}

.recharge-countdown strong {
  color: #223149;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 24px;
}

.recharge-payment-panel {
  display: grid;
  align-content: start;
  gap: 16px;
}

.recharge-panel-title {
  color: #12223b;
  font-size: 22px;
  font-weight: 900;
}

.recharge-address-box {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid #d6e7e1;
  border-radius: 10px;
  background: #f8fbfa;
}

.recharge-address-box span {
  color: #5f7184;
  font-size: 14px;
  font-weight: 800;
}

.recharge-address-box code {
  color: #102033;
  font-size: 16px;
  font-weight: 800;
  word-break: break-all;
}

.recharge-copy-row,
.recharge-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.recharge-copy-row button,
.secondary-action {
  min-width: 116px;
  height: 38px;
  border: 1px solid #12bfa8;
  border-radius: 8px;
  background: #f1fffb;
  color: #087d71;
  font-weight: 800;
  cursor: pointer;
}

.secondary-action {
  border-color: #d5e1de;
  background: #fff;
  color: #526a82;
}

.recharge-steps {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 16px 20px 16px 34px;
  border-radius: 10px;
  background: #eef6ff;
  color: #223149;
  line-height: 1.6;
}

.recharge-steps b {
  color: #e43b46;
}

.waiting-recharge {
  padding: 12px 14px;
  border-radius: 10px;
  background: #fff8e7;
  color: #9a6200;
  font-weight: 800;
}

.wallet-table-card {
  overflow: hidden;
  border: 1px solid #dbe5ee;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(29, 68, 102, 0.08);
}

.wallet-table-card th {
  height: 64px;
  background: #eef3f8;
  font-size: 18px;
}

.empty-cell {
  height: 130px;
  text-align: center;
  color: #526a82;
  font-size: 20px;
}

.finance-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 28px;
}

.finance-card {
  min-height: 130px;
  padding: 34px;
  border-radius: 10px;
  color: #fff;
  box-shadow: 0 8px 18px rgba(38, 57, 77, 0.18);
}

.finance-card strong {
  display: block;
  margin-bottom: 18px;
  font-size: 28px;
  font-weight: 900;
}

.finance-card span {
  font-size: 16px;
  font-weight: 700;
}

.finance-card.green { background: #2ecc71; }
.finance-card.orange { background: #f39c12; }
.finance-card.purple { background: #9b59b6; }

.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(360px, 0.65fr);
  gap: 18px;
}

.profile-card {
  min-height: 260px;
}

.profile-card h2 {
  margin: 0 0 14px;
  color: #214331;
}

.profile-head {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 18px;
}

.profile-head p {
  margin: 0;
  color: var(--muted);
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 18px;
}

.stat-card.compact {
  min-height: 94px;
}

.stat-card.compact.green .stat-value { color: #1dbb70; }
.stat-card.compact.blue .stat-value { color: #5d78e8; }
.stat-card.compact.orange .stat-value { color: #ef8a2e; }

.profile-table {
  display: grid;
  border: 1px solid var(--line);
  background: #fbfffc;
}

.profile-table div {
  min-height: 50px;
  display: grid;
  grid-template-columns: 150px 1fr;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding: 0 16px;
}

.profile-table div:last-child {
  border-bottom: 0;
}

.profile-table span {
  color: var(--muted);
}

.profile-table strong {
  color: #263247;
}

.profile-form .btn {
  width: 180px;
}

.inline-error,
.inline-success {
  padding: 10px 12px;
  margin-bottom: 12px;
  border: 1px solid #ffd2d2;
  background: #fff7f7;
  color: #b42318;
  line-height: 1.5;
}

.inline-success {
  border-color: #bcebd1;
  background: #f1fff7;
  color: #138c50;
}

@media (max-width: 900px) {
  .recharge-active-grid { grid-template-columns: 1fr; }
  .recharge-active-card { padding: 18px; }
  .recharge-form { max-width: 100%; }
  .form-row { grid-template-columns: 1fr; gap: 10px; }
  .amount-input { width: 100%; }
  .submit-recharge { margin-left: 0; }
  .order-summary-grid { grid-template-columns: 1fr; }
  .order-summary-grid div { border-right: 0; grid-template-columns: 96px 1fr; }
  .details-actions { justify-content: stretch; flex-wrap: wrap; }
  .details-actions .small-btn { flex: 1; min-width: 120px; }
  .legacy-number-line { padding: 2px 0; }
}

/* kksms mobile responsive patch */
@media (max-width: 820px) {
  :root {
    --content-scale: 1;
  }

  html,
  body {
    width: 100%;
    min-width: 0;
    height: 100%;
    overflow: hidden;
  }

  body {
    min-width: 0;
    font-size: 14px;
  }

  .app-shell {
    width: 100%;
    height: 100dvh;
    min-height: 100dvh;
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr);
  }

  .sidebar {
    position: relative;
    z-index: 5;
    width: 100%;
    height: auto;
    max-height: 38dvh;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-content: start;
    overflow-y: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .brand {
    grid-column: 1 / -1;
    height: 64px;
    padding: 0 14px;
    gap: 10px;
    position: sticky;
    top: 0;
    z-index: 2;
    background: var(--sidebar-bg);
  }

  .logo-mark {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 22px;
  }

  .brand-name {
    font-size: 24px;
  }

  .menu-group {
    border-top: 0;
    border-bottom: 1px solid rgba(64, 184, 116, 0.12);
  }

  .menu-group.single > button,
  .submenu button {
    height: 44px;
    padding: 0 8px;
    justify-content: center;
    text-align: center;
    font-size: 15px;
    white-space: nowrap;
  }

  .menu-group.single > button {
    border-left: 0;
  }

  .menu-group.single.active > button {
    border-left: 0;
    box-shadow: inset 0 -3px 0 var(--green);
  }

  .main {
    min-width: 0;
    min-height: 0;
    height: auto;
  }

  .topbar {
    height: 50px;
    min-height: 50px;
    padding: 0 10px;
  }

  .hamburger {
    width: 34px;
    font-size: 20px;
  }

  .top-actions {
    gap: 8px;
  }

  .top-actions button,
  .language-toggle,
  .logout-btn {
    height: 34px;
    padding: 0 12px;
    min-width: 0;
    font-size: 14px;
  }

  .user-chip {
    width: 36px;
    height: 36px;
  }

  .breadcrumb {
    min-height: 36px;
    height: auto;
    padding: 7px 12px;
    flex-wrap: wrap;
    font-size: 13px;
  }

  .content-frame {
    width: 100%;
    height: 100%;
    transform: none;
    transform-origin: center;
    overflow: auto;
  }

  .content {
    width: 100%;
    min-width: 0;
    padding: 12px;
    margin: 0;
  }

  .panel,
  .wallet-card,
  .profile-card,
  .notice-card,
  .admin-card {
    padding: 14px;
  }

  .section-title,
  .page-title,
  .wallet-title,
  .profile-title {
    font-size: 20px;
  }

  .notice-box,
  .tips-box,
  .number-tip {
    padding: 12px 14px;
    font-size: 14px;
    line-height: 1.55;
  }

  .notice-box p,
  .tips-box p,
  .number-tip p {
    margin: 6px 0;
  }

  .number-content {
    min-height: 0;
    height: auto;
    overflow: visible;
  }

  .number-store-page {
    height: auto;
    min-height: 0;
    overflow: visible;
    gap: 12px;
  }

  .store-panel {
    min-height: 0;
    padding: 12px;
  }

  .store-toolbar,
  .real-toolbar,
  .virtual-toolbar {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
    align-items: stretch;
  }

  .country-select,
  .card-type-switch,
  .search-row,
  .store-search {
    width: 100%;
    min-width: 0;
  }

  .country-select {
    height: 42px;
  }

  .card-type-switch {
    height: auto;
    grid-template-columns: repeat(2, 1fr);
  }

  .card-type-switch button {
    height: 40px;
    font-size: 14px;
  }

  .search-row,
  .store-search {
    height: auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
  }

  .search-row input,
  .store-search input {
    min-width: 0;
    height: 42px;
    font-size: 14px;
  }

  .search-row button,
  .store-search button {
    height: 42px;
    min-width: 64px;
    padding: 0 12px;
    font-size: 14px;
  }

  .products-scroll {
    height: auto;
    max-height: none;
    overflow: visible;
    padding: 0;
  }

  .product-grid,
  .products-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .product-card,
  .app-card {
    min-width: 0;
    min-height: 114px;
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 12px;
    padding: 12px;
  }

  .product-logo,
  .app-logo {
    width: 78px;
    height: 78px;
    font-size: 36px;
    border-radius: 9px;
  }

  .product-name,
  .app-name {
    font-size: 18px;
    line-height: 1.25;
  }

  .product-meta,
  .app-meta,
  .price-line,
  .stock-line {
    font-size: 14px;
    line-height: 1.55;
  }

  .modal-backdrop,
  .legacy-modal-backdrop,
  .notice-modal-backdrop,
  .confirm-backdrop {
    padding: 8px;
    align-items: center;
    justify-content: center;
  }

  .purchase-modal,
  .order-modal,
  .legacy-order-modal,
  .platform-notice-modal,
  .notice-detail-modal,
  .feedback-modal,
  .confirm-modal {
    width: calc(100vw - 16px);
    max-width: calc(100vw - 16px);
    max-height: calc(100dvh - 16px);
    margin: 0;
    overflow: hidden;
  }

  .modal-header,
  .legacy-modal-header,
  .platform-notice-header,
  .notice-detail-header {
    min-height: 52px;
    padding: 0 14px;
  }

  .modal-title,
  .legacy-modal-title,
  .platform-notice-title,
  .notice-detail-title {
    font-size: 18px;
  }

  .modal-body,
  .legacy-modal-body,
  .platform-notice-body,
  .notice-detail-body {
    max-height: calc(100dvh - 78px);
    padding: 14px;
    overflow: auto;
  }

  .purchase-body,
  .order-detail-grid,
  .legacy-detail-grid,
  .detail-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .purchase-product,
  .modal-product {
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 12px;
  }

  .option-row,
  .form-line,
  .purchase-line {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .option-control,
  .select-control,
  .input-control,
  .quantity-control {
    width: 100%;
    min-width: 0;
  }

  .dropdown-panel,
  .option-dropdown {
    max-height: 42dvh;
  }

  .selected-prefixes,
  .selected-tags {
    max-height: 120px;
    overflow-y: auto;
  }

  .modal-actions,
  .legacy-actions,
  .details-actions {
    gap: 8px;
    justify-content: stretch;
    flex-wrap: wrap;
  }

  .modal-actions button,
  .legacy-actions button,
  .details-actions button {
    flex: 1 1 120px;
    min-width: 0;
  }

  .detail-table,
  .order-detail-table,
  .legacy-detail-table {
    font-size: 13px;
  }

  .detail-table div,
  .order-detail-table div,
  .legacy-detail-table div {
    min-height: 34px;
    grid-template-columns: 84px minmax(0, 1fr);
    padding: 6px 8px;
  }

  .card-key-box,
  .legacy-cardkeys,
  .sms-link-box {
    max-height: 36dvh;
    overflow: auto;
    font-size: 12px;
    line-height: 1.6;
    white-space: nowrap;
  }

  .stats-grid,
  .stats,
  .finance-summary,
  .wallet-summary,
  .profile-grid,
  .profile-stats,
  .renewal-record-stats,
  .admin-stats {
    grid-template-columns: 1fr;
  }

  .wallet-tabs,
  .renewal-tabs,
  .notice-tabs {
    overflow-x: auto;
    white-space: nowrap;
    gap: 18px;
  }

  .wallet-tabs button,
  .renewal-tabs button,
  .notice-tabs button {
    flex: 0 0 auto;
  }

  .table-toolbar,
  .orders-toolbar,
  .records-toolbar,
  .admin-heading {
    grid-template-columns: 1fr;
    gap: 10px;
    align-items: stretch;
  }

  .table-search,
  .records-search,
  .admin-search {
    width: 100%;
  }

  .table-wrap,
  .records-table-wrap,
  .admin-table-wrap {
    overflow-x: auto;
  }

  table,
  .records-table,
  .orders-table,
  .admin-table {
    min-width: 720px;
  }

  .recharge-active-grid,
  .recharge-form,
  .wallet-form,
  .profile-table div {
    grid-template-columns: 1fr;
  }

  .wallet-tip {
    padding: 12px;
    font-size: 14px;
  }

  .amount-input,
  .submit-recharge,
  .profile-form .btn {
    width: 100%;
  }

  .support-grid,
  .partner-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .support-card,
  .partner-card {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
  }

  .support-image,
  .partner-image {
    height: 220px;
  }

  .renewal-page {
    padding: 0;
  }

  .renewal-layout,
  .renewal-form-grid {
    grid-template-columns: 1fr;
  }

  .renewal-panel {
    padding: 14px 0 0;
    box-shadow: none;
    background: transparent;
  }

  .renewal-inline-card {
    padding: 12px;
  }

  .auth-page {
    padding: 14px;
    align-items: flex-start;
    overflow: auto;
  }

  .auth-shell {
    width: 100%;
    min-height: auto;
    display: block;
  }

  .auth-intro,
  .auth-panel {
    padding: 22px;
  }

  .auth-title {
    font-size: 28px;
  }

  .captcha-row {
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 8px;
  }

  .captcha-row button {
    grid-column: 1 / -1;
    width: 100%;
  }
}

@media (max-width: 480px) {
  .sidebar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-height: 42dvh;
  }

  .brand {
    height: 58px;
  }

  .brand-name {
    font-size: 22px;
  }

  .content {
    padding: 10px;
  }

  .topbar {
    padding: 0 8px;
  }

  .top-actions {
    gap: 6px;
  }

  .logout-btn,
  .language-toggle {
    padding: 0 9px;
    font-size: 13px;
  }

  .product-card,
  .app-card {
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 10px;
    min-height: 104px;
  }

  .product-logo,
  .app-logo {
    width: 64px;
    height: 64px;
    font-size: 30px;
  }

  .product-name,
  .app-name {
    font-size: 16px;
  }

  .search-row,
  .store-search {
    grid-template-columns: minmax(0, 1fr) 58px 58px;
  }

  .search-row button,
  .store-search button {
    min-width: 0;
    padding: 0 8px;
  }

  .support-image,
  .partner-image {
    height: 190px;
  }
}

