.pricing-page {
  --pricing-sage: #f1f5ed;
  --pricing-selected: #e6efde;
}
.pricing-shell {
  width: min(1000px, calc(100% - 96px));
  margin-inline: auto;
  padding-bottom: 84px;
}
.pricing-intro {
  padding: 78px 0 48px;
  text-align: center;
}
.pricing-intro h1 {
  font-size: clamp(31px, 3.14vw, 40px);
  font-weight: 460;
  line-height: 1.65;
  letter-spacing: .01em;
}
.pricing-intro p {
  margin-top: 12px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.9;
}
.recharge-heading h2,
.rates-section h2 {
  font-size: 29px;
  font-weight: 460;
  line-height: 1.5;
  letter-spacing: -.015em;
}
.recharge-section {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--pricing-sage);
}
.recharge-heading { margin-bottom: 18px; }
#account-summary {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.checkout-options,
.checkout-summary { min-width: 0; }
.recharge-options {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.recharge-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 90px;
  padding: 12px 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  transition: border-color .18s, background .18s;
}
.recharge-option:hover { border-color: #89a47a; background: #f6f9f2; }
.recharge-option[aria-pressed="true"] {
  border-color: var(--accent);
  background: var(--pricing-selected);
  box-shadow: inset 0 0 0 .5px var(--accent);
}
.recharge-option strong {
  font-size: 20px;
  font-weight: 550;
  line-height: 1.3;
  letter-spacing: -.025em;
  font-variant-numeric: tabular-nums;
}
.recharge-option .offer-bonus { color: var(--accent); font-size: 12px; line-height: 1.4; }
.recharge-option .offer-arrival { color: var(--muted); font-size: 13px; line-height: 1.5; }
.recharge-option .offer-arrival b { font-weight: 550; }
.checkout-summary {
  position: relative;
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.arrival-label {
  display: block;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}
.arrival-value {
  display: block;
  margin-top: 3px;
  color: var(--accent);
  font-size: 28px;
  font-weight: 550;
  line-height: 1.25;
  letter-spacing: -.025em;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
#arrival-total { font-weight: inherit; }
#arrival-unit { font-size: 15px; }
.checkout-summary > .button {
  width: 100%;
  min-height: 40px;
  margin-top: 13px;
  padding: 8px 12px;
  white-space: normal;
}
.recharge-note {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}
.custom-amount {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 16px;
  color: var(--text);
  font-size: 13px;
}
.pricing-page input:not([type="checkbox"]) {
  min-width: 0;
  min-height: 44px;
  border: 1px solid #cfd8c9;
  border-radius: 6px;
  padding: 10px 13px;
  background: rgba(255,255,255,.6);
  color: var(--text);
  font: inherit;
}
.pricing-page input::placeholder { color: #687363; }
.pricing-page .custom-amount input { width: 120px; }
.custom-amount:focus-within input { border-color: var(--accent); }
.pricing-page input[aria-invalid="true"] { border-color: #a64b37; }
.rates-section { margin-top: 40px; }
.product-prices {
  margin-top: 16px;
  padding-inline: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}
.price-product {
  display: grid;
  grid-template-columns: 34% minmax(0, 1fr);
  align-items: center;
  min-height: 76px;
  padding: 14px 0;
}
.price-product + .price-product { border-top: 1px solid var(--line); }
.price-product-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  min-height: 40px;
  padding-inline-end: 12px;
  border-inline-end: 1px solid var(--line);
}
.price-product-heading img {
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 9px;
  object-fit: contain;
}
.price-product-heading h3 { font-size: 16px; font-weight: 550; line-height: 1.35; }
.price-product-heading p { margin-top: 3px; color: var(--muted); font-size: 12px; line-height: 1.5; }
.price-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
  margin: 0;
  padding-inline-start: 20px;
}
.price-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 8px;
}
.price-row dt { font-size: 13px; line-height: 1.5; }
.price-row dd {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  margin: 0;
  white-space: nowrap;
}
.price-row strong {
  color: var(--accent);
  font-size: 23px;
  font-weight: 550;
  line-height: 1.15;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}
.price-row dd > span { color: var(--muted); font-size: 12px; }
.pricing-note {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.pricing-note .inline-action { color: var(--accent); }
.inline-action {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font-size: inherit;
  text-decoration: underline;
  text-decoration-color: #879e7d;
  text-underline-offset: 4px;
}
.inline-action:hover { color: var(--accent); }
.retry-action { margin-top: 8px; min-height: 36px; color: var(--accent); font-size: 14px; }
.inline-message { margin-top: 12px; color: #9a422f; font-size: 13px; line-height: 1.8; }
.inline-message[data-kind="success"] { color: var(--accent); }
.pricing-page button:disabled { cursor: default; opacity: .58; }
.pricing-dialog { width: min(420px, calc(100% - 32px)); max-height: calc(100dvh - 48px); margin: auto; padding: 30px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--text); overflow: auto; box-shadow: 0 20px 70px rgba(26,40,20,.14); }
.pricing-dialog::backdrop { background: rgba(28,36,26,.34); backdrop-filter: blur(4px); }
.dialog-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; margin-bottom: 24px; }
.dialog-heading h2 { font-size: 20px; font-weight: 500; line-height: 1.4; }
.dialog-heading p { margin-top: 8px; color: var(--muted); font-size: 13px; line-height: 1.6; }
.dialog-close { flex-shrink: 0; min-height: 32px; padding: 3px 0 3px 8px; border: 0; background: none; color: var(--muted); font-size: 12px; }
.login-form { display: grid; gap: 20px; }
.login-form > label:not(.agreement-check) { display: grid; gap: 9px; font-size: 13px; }
.login-form input:not([type="checkbox"]) { width: 100%; }
.code-field { display: flex; gap: 10px; }
.code-field > .button { flex-shrink: 0; min-width: 104px; }
.agreement-check { display: flex; align-items: flex-start; gap: 8px; color: var(--muted); font-size: 12px; line-height: 1.8; }
.agreement-check input { margin: 4px 0 0; accent-color: var(--accent); width: 16px; height: 16px; flex-shrink: 0; }
.login-form > .inline-message { margin: -7px 0; }
.login-form > .button { min-height: 44px; font-size: 14px; }
.login-footnote { text-align: center; color: var(--muted); font-size: 11px; }
.payment-dialog { text-align: center; }
.payment-dialog > p { color: var(--muted); font-size: 13px; line-height: 1.8; }
.payment-qr-frame { width: min(232px, 100%); aspect-ratio: 1; padding: 10px; margin: 20px auto; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.payment-qr-frame img { width: 100%; height: 100%; display: block; object-fit: contain; }
.payment-amount { display: block; margin: 8px 0; font-size: 30px; font-weight: 550; }
.payment-dialog > .payment-status { margin: 18px 0; color: var(--accent); }
.payment-dialog > .payment-status[data-kind="error"] { color: #9a422f; }
.payment-dialog > .button { margin: 4px; min-height: 40px; }
.dialog-copy { color: var(--muted); font-size: 14px; line-height: 1.9; }
.dialog-copy p + p { margin-top: 16px; }
.agreement-dialog { width: min(640px, calc(100% - 32px)); }
.agreement-body { font-size: 13px; line-height: 1.9; color: var(--muted); }
.agreement-body h3 { margin: 20px 0 7px; color: var(--text); font-size: 14px; font-weight: 550; }
.agreement-dialog > .button { width: 100%; margin-top: 25px; min-height: 44px; }

@media (min-width: 961px) {
  .recharge-section {
    --checkout-columns: minmax(0, 2.24fr) minmax(0, 1fr);
    --checkout-gap: 28px;
    display: grid;
    grid-template-columns: var(--checkout-columns);
    column-gap: var(--checkout-gap);
  }
  .recharge-heading,
  .checkout-options { grid-column: 1; }
  .checkout-layout { grid-column: 1 / -1; }
  .checkout-summary { min-height: 180px; margin-top: 0; }
  @supports (grid-template-rows: subgrid) {
    .recharge-heading { grid-row: 1; }
    .checkout-layout {
      display: grid;
      grid-row: 1 / 3;
      grid-template-columns: subgrid;
      grid-template-rows: subgrid;
    }
    .checkout-options { grid-row: 2; }
    .checkout-summary { grid-area: 1 / 2 / 3; align-self: start; }
    .checkout-summary::before {
      position: absolute;
      inset-block: 2px;
      inset-inline-start: calc(var(--checkout-gap) / -2 - 1px);
      border-inline-start: 1px solid var(--line);
      content: "";
    }
  }
  @supports not (grid-template-rows: subgrid) {
    .checkout-layout { display: grid; grid-template-columns: var(--checkout-columns); gap: var(--checkout-gap); }
  }
  .recharge-section > noscript { grid-column: 1 / -1; }
}
@media (max-width: 850px) {
  .pricing-shell { width: calc(100% - 48px); }
  .price-list { gap: 10px 12px; }
}
@media (max-width: 650px) {
  .pricing-shell { padding-bottom: 64px; }
  .pricing-intro { padding: 48px 0 32px; }
  .pricing-intro h1 { font-size: clamp(22px, 6.16vw, 31px); }
  .pricing-intro p { font-size: 13px; }
  .recharge-heading h2, .rates-section h2 { font-size: 26px; }
  .recharge-section { padding: 16px; }
  .recharge-options { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .recharge-option { min-height: 76px; }
  .checkout-summary { padding: 14px; margin-top: 16px; }
  .checkout-summary > .button { min-height: 44px; font-size: 13px; }
  .rates-section { margin-top: 32px; }
  .product-prices { margin-top: 16px; padding-inline: 14px; }
  .price-product { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 16px 0; }
  .price-product-heading { min-height: 0; padding: 0; border: 0; }
  .price-list { grid-template-columns: minmax(0, 1fr); gap: 6px; padding: 0; }
  .price-row { justify-content: space-between; }
  .pricing-note > [aria-hidden="true"] { display: none; }
  .pricing-dialog { padding: 24px; }
}
@media (max-width: 480px) {
  .pricing-shell { width: calc(100% - 36px); }
}
