:root {
  --app-bg: #e3e7eb;
  --screen-bg: #f5f5f5;
  --card-bg: #ffffff;
  --text: #151922;
  --muted: #6d7788;
  --line: #e5e7eb;
  --primary: #ff3b6c;
  --primary-shadow: rgba(255, 59, 108, 0.3);
  --disabled: #d1d5db;
  --overlay: rgba(17, 20, 26, 0.64);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body.redeem-body {
  font-family: "Inter", sans-serif;
  background: var(--app-bg);
  color: var(--text);
}

.redeem-shell {
  min-height: 100vh;
  display: grid;
  place-items: start center;
}

.redeem-phone {
  width: min(100%, 430px);
  min-height: 100vh;
  background: var(--screen-bg);
  padding-bottom: 24px;
}

.redeem-topbar {
  height: 56px;
  background: #fff;
  display: grid;
  grid-template-columns: 24px 1fr 24px;
  align-items: center;
  padding: 0 16px;
  border-bottom: 1px solid #eceef2;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.05);
  position: sticky;
  top: 0;
  z-index: 6;
}

.redeem-icon-btn {
  border: 0;
  background: transparent;
  width: 24px;
  height: 24px;
  color: #111827;
  display: grid;
  place-items: center;
  cursor: pointer;
  padding: 0;
}

.redeem-icon-btn svg {
  width: 22px;
  height: 22px;
}

.redeem-title {
  margin: 0;
  text-align: center;
  font-size: 17px;
  font-weight: 700;
  color: #111827;
}

.redeem-content {
  padding: 12px 16px 0;
}

.balance-wrap {
  margin-top: 2px;
}

.balance-top {
  position: relative;
  background: #121418;
  border-radius: 16px 16px 0 0;
  padding: 18px 20px 16px;
  color: #fff;
  overflow: hidden;
}

.balance-top p {
  margin: 0;
}

.balance-top .label {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.82);
}

.balance-top .amount {
  margin-top: 2px;
  font-size: 38px;
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.balance-top .points {
  margin-top: 3px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.62);
}

.balance-coin {
  position: absolute;
  right: 16px;
  top: 10px;
  width: 90px;
  height: 90px;
  border-radius: 50%;
}

.balance-cut {
  position: relative;
  height: 14px;
  background: #121418;
}

.cut {
  position: absolute;
  top: 50%;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--screen-bg);
  transform: translateY(-50%);
}

.cut.left {
  left: 0;
  transform: translate(-50%, -50%);
}

.cut.right {
  right: 0;
  transform: translate(50%, -50%);
}

.cut-line {
  margin: 0 20px;
  border-top: 2px dashed rgba(255, 255, 255, 0.2);
}

.balance-bottom {
  width: 100%;
  border: 0;
  border-radius: 0 0 16px 16px;
  background: #121418;
  color: rgba(255, 255, 255, 0.72);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 20px 12px;
  font-family: inherit;
  font-size: 13px;
  text-align: left;
}

.balance-bottom i {
  font-style: normal;
  font-size: 18px;
}

.card {
  margin-top: 16px;
  background: var(--card-bg);
  border-radius: 16px;
  padding: 20px;
}

.card h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #111827;
}

.pay-methods {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
}

.pay-methods svg {
  width: 18px;
  height: 18px;
}

.pay-methods img {
  height: 18px;
  width: auto;
  object-fit: contain;
}

.value-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.value-btn {
  height: 76px;
  border-radius: 8px;
  border: 2px solid #e5e7eb;
  background: #fff;
  color: #111827;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.value-btn.active {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(255, 59, 108, 0.05);
}

.main-btn {
  margin-top: 14px;
  width: 100%;
  height: 52px;
  border: 0;
  border-radius: 12px;
  background: var(--primary);
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px var(--primary-shadow);
}

.main-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: none;
}

.note {
  margin: 12px 2px 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.center-note {
  text-align: center;
}

.live-card {
  position: relative;
  overflow: hidden;
}

.live-card h2 {
  margin-right: 84px;
}

.live-card p {
  margin: 6px 84px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.rose {
  position: absolute;
  right: 16px;
  top: 12px;
  width: 70px;
  height: 70px;
  object-fit: contain;
}

.disabled-btn {
  margin-top: 14px;
  width: 100%;
  height: 52px;
  border: 0;
  border-radius: 12px;
  background: var(--disabled);
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  opacity: 0.8;
}

.recharge-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.carriers {
  display: flex;
  align-items: center;
  gap: 5px;
}

.carriers img {
  height: 20px;
  width: auto;
  object-fit: contain;
}

.phone-row {
  display: flex;
  align-items: center;
  border-bottom: 1px solid #e5e7eb;
  padding-bottom: 12px;
  margin-bottom: 12px;
}

.phone-row span,
.phone-row strong {
  color: var(--muted);
  font-size: 16px;
  font-weight: 400;
}

.phone-row i {
  width: 1px;
  height: 20px;
  background: #e5e7eb;
  margin: 0 12px;
}

.overlay {
  position: fixed;
  inset: 0;
  background: var(--overlay);
  opacity: 0;
  pointer-events: none;
  display: grid;
  align-items: end;
  z-index: 20;
  transition: opacity 180ms ease;
}

.overlay.show {
  opacity: 1;
  pointer-events: auto;
}

.sheet {
  width: min(100%, 560px);
  margin: 0 auto;
  background: #fff;
  border-radius: 18px 18px 0 0;
  overflow: hidden;
  transform: translateY(14px);
  transition: transform 180ms ease;
}

.overlay.show .sheet {
  transform: translateY(0);
}

.sheet-head {
  height: 66px;
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 26px 1fr 26px;
  align-items: center;
  padding: 0 14px;
}

.sheet-head h3 {
  margin: 0;
  text-align: center;
  font-size: 20px;
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  font-weight: 800;
  color: #111827;
}

.sheet-body {
  padding: 12px 20px 22px;
}

.sheet-note {
  margin: 0 0 8px;
  color: #657893;
  font-size: 14px;
  line-height: 1.5;
}

.form-row {
  margin-top: 10px;
}

.form-row label {
  display: block;
  margin-bottom: 6px;
  color: #4f6078;
  font-size: 15px;
  font-weight: 500;
}

.field {
  width: 100%;
  height: 46px;
  border: 2px solid #d4dae2;
  border-radius: 10px;
  padding: 0 14px;
  font-family: inherit;
  font-size: 14px;
  color: #1a212d;
  outline: 0;
}

.field.has-error {
  border-color: #ff5a84;
  background: #fff7fa;
}

.field::placeholder {
  color: #a7b1bf;
}

.form-error {
  display: none;
  margin-top: 4px;
  color: #ff3b6c;
  font-size: 12px;
  font-weight: 600;
}

.form-error.show {
  display: block;
}

.form-tip {
  margin-top: 4px;
  color: #76869d;
  font-size: 12px;
}

.method-item {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: #fff;
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 10px;
  padding: 14px 0;
  text-align: left;
  cursor: pointer;
}

.method-item img {
  width: 30px;
  height: 18px;
  object-fit: contain;
}

.method-item strong {
  display: block;
  color: #161d2a;
  font-size: 15px;
  font-weight: 700;
}

.method-item small {
  color: #627590;
  font-size: 13px;
}

.method-item em {
  font-style: normal;
  color: #5d6f87;
  font-size: 13px;
}

.method-item i {
  font-style: normal;
  color: #a1adbd;
  font-size: 17px;
}

.invalid {
  color: #ff6f93;
  margin-left: 8px;
}

.sheet-footnote {
  margin-top: 12px;
  color: #9ba8ba;
  font-size: 12px;
  line-height: 1.45;
}

.key-group {
  margin-top: 4px;
}

.key-label {
  margin: 0 0 8px;
  color: #5f7089;
  font-size: 15px;
}

.key-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.key-btn {
  height: 44px;
  border-radius: 10px;
  border: 2px solid #d6dce3;
  background: #fff;
  color: #161f2e;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.key-btn.active {
  border-color: var(--primary);
  background: rgba(255, 59, 108, 0.12);
  color: #be1e4f;
  box-shadow: inset 0 0 0 1px rgba(255, 59, 108, 0.4);
}

.confirm-list {
  margin-top: 4px;
}

.confirm-row {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.confirm-row span {
  color: #58708d;
  font-size: 15px;
}

.confirm-row strong {
  color: #0f1724;
  font-size: 15px;
  font-weight: 700;
}

@media (max-width: 430px) {
  .sheet {
    width: 100%;
  }
}
