/* Pricing and checkout pages. Built only from the tokens in styles.css. */

.store-head {
  padding: calc(var(--header) + 72px) 0 44px;
}
.store-head h1 {
  margin-top: 14px;
  font-size: clamp(36px, 4.4vw, 56px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-feature-settings: "palt";
}
.store-lead {
  margin-top: 20px;
  max-width: 46em;
  font-size: 17px;
  line-height: 1.85;
  color: var(--ink-2);
}
.store-head-compact {
  padding: calc(var(--header) + 40px) 0 24px;
}
.store-head-compact h1 {
  margin-top: 18px;
  font-size: clamp(30px, 3.2vw, 40px);
}
.store-section {
  padding-bottom: 88px;
}
.store-section-tight {
  padding-bottom: 120px;
}
.store-section-head {
  display: grid;
  gap: 8px;
  margin-bottom: 26px;
}
.store-section-head h2 {
  font-size: clamp(24px, 2.4vw, 30px);
  font-weight: 750;
  letter-spacing: -0.02em;
}
.store-section-head p {
  max-width: 40em;
  font-size: 15.5px;
  color: var(--ink-3);
}
.store-section-head a,
.store-notes a {
  color: var(--blue-600);
  font-weight: 600;
}
.button-ghost {
  background: white;
  color: var(--ink);
  box-shadow:
    inset 0 0 0 1px var(--rule-strong),
    0 1px 2px #0a10200d;
}

/* Plans */
.plans {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
}
.plan {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 26px;
  padding: 34px 32px 30px;
  border-radius: 28px;
  background: white;
  box-shadow:
    inset 0 0 0 1px var(--rule),
    var(--shadow-sm);
}
.plan.is-featured {
  box-shadow:
    inset 0 0 0 2px var(--blue),
    var(--shadow-md);
}
.plan-head h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 19px;
  font-weight: 750;
}
.plan-tag {
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--blue-50);
  color: var(--blue-700);
  font-size: 12.5px;
  font-weight: 650;
  line-height: 1.5;
}
.plan-price {
  display: flex;
  align-items: baseline;
  gap: 2px;
  height: 58px;
  margin-top: 20px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.plan-price span {
  font-size: 24px;
  font-weight: 750;
}
.plan-price b {
  font-size: 58px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.045em;
}
.plan-price em {
  margin-left: 10px;
  font-style: normal;
  font-size: 15px;
  color: var(--ink-3);
}
.plan-desc {
  margin-top: 14px;
  font-size: 15px;
  color: var(--ink-3);
}
.plan-facts {
  display: grid;
  align-content: start;
  gap: 13px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
}
.plan-facts li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-2);
}
.plan-facts .icon {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 3px;
  color: var(--good);
  stroke-width: 2.2;
}
.plan-facts b {
  color: var(--ink);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}
.plan-facts .is-off {
  color: var(--ink-4);
}
.plan-facts .is-off .icon {
  color: var(--ink-4);
}
.plan-action {
  display: grid;
  gap: 10px;
  text-align: center;
}
.plan-action .button {
  width: 100%;
}
.plan-action small {
  font-size: 13px;
  color: var(--ink-4);
}

/* Point packs */
.packs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.pack {
  display: grid;
  gap: 4px;
  padding: 24px 24px 20px;
  border-radius: 22px;
  background: white;
  box-shadow: inset 0 0 0 1px var(--rule);
  transition: box-shadow 200ms ease;
}
.pack b {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.pack b small {
  margin-left: 6px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--ink-3);
}
.pack-price {
  font-size: 18px;
  font-weight: 700;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.pack-go {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 14px;
  font-weight: 650;
  color: var(--blue-600);
}
.pack-go .icon {
  width: 16px;
  height: 16px;
  transition: transform 300ms var(--ease);
}

/* Purchase notes */
.store-notes-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr);
  gap: 64px;
  align-items: start;
}
.store-notes-layout .store-section-head {
  position: sticky;
  top: calc(var(--header) + 32px);
}
.store-notes > div {
  padding: 22px 0;
  border-top: 1px solid var(--rule);
}
.store-notes > div:last-child {
  border-bottom: 1px solid var(--rule);
}
.store-notes dt {
  font-size: 16.5px;
  font-weight: 700;
}
.store-notes dd {
  margin-top: 6px;
  font-size: 15px;
  line-height: 1.85;
  color: var(--ink-2);
}

/* Checkout */
.steps {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  font-size: 14px;
  color: var(--ink-3);
}
.steps li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.steps li + li::before {
  content: "";
  width: 28px;
  height: 1px;
  margin-right: 4px;
  background: var(--rule-strong);
}
.steps i {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px var(--rule-strong);
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
}
.steps .is-done i {
  background: var(--blue-50);
  box-shadow: none;
  color: var(--blue-700);
}
.steps .is-current {
  color: var(--ink);
  font-weight: 650;
}
.steps .is-current i {
  background: var(--blue);
  box-shadow: none;
  color: white;
}
.checkout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: 28px;
  align-items: start;
}
.checkout-main {
  display: grid;
  gap: 18px;
  min-width: 0;
}
.co-card {
  min-width: 0;
  margin: 0;
  padding: 26px 28px 28px;
  border: 0;
  border-radius: 24px;
  background: white;
  box-shadow:
    inset 0 0 0 1px var(--rule),
    var(--shadow-sm);
}
.co-card legend {
  float: left;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  margin-bottom: 20px;
  padding: 0;
  font-size: 18px;
  font-weight: 750;
}
.co-card legend + * {
  clear: both;
}
.co-no {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--blue-50);
  color: var(--blue-700);
  font-size: 13px;
  font-weight: 750;
}
.co-group-label {
  margin: 0 0 10px;
  font-size: 13.5px;
  font-weight: 650;
  color: var(--ink-3);
}
.co-group-label small {
  margin-left: 10px;
  font-size: 12.5px;
  font-weight: 400;
  color: var(--ink-4);
}
.options {
  display: grid;
  gap: 12px;
}
.options + .co-group-label {
  margin-top: 22px;
}
.options-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.options-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.option {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 16px 18px;
  border-radius: 16px;
  background: white;
  box-shadow: inset 0 0 0 1.5px var(--rule-strong);
  cursor: pointer;
  transition:
    box-shadow 160ms ease,
    background-color 160ms ease;
}
.option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.option::before {
  content: "";
  flex: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px #0a102040;
  background: white;
  transition: box-shadow 160ms ease;
}
.option:has(input:checked) {
  background: #f5f8ff;
  box-shadow:
    inset 0 0 0 2px var(--blue),
    0 0 0 4px #1769ff14;
}
.option:has(input:checked)::before {
  box-shadow: inset 0 0 0 5.5px var(--blue);
}
.option:has(input:focus-visible) {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}
.option-body {
  display: grid;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.option-body b {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  font-size: 15.5px;
  font-weight: 700;
}
.option-body em {
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--blue-50);
  color: var(--blue-700);
  font-style: normal;
  font-size: 12px;
  font-weight: 650;
}
.option-body small {
  font-size: 13px;
  color: var(--ink-3);
  word-break: keep-all;
}
.option-price {
  font-size: 18px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}
.option-compact {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 10px;
  row-gap: 2px;
  padding: 14px 16px;
}
.option-compact .option-body b {
  font-size: 14.5px;
  white-space: nowrap;
}
.option-compact .option-price {
  grid-column: 2;
  font-size: 15px;
  color: var(--ink-2);
}
.pay-mark {
  display: grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: #1677ff;
  color: white;
  font-size: 17px;
  font-weight: 800;
}
.field {
  display: grid;
  gap: 8px;
}
.field > span {
  font-size: 14px;
  font-weight: 650;
  color: var(--ink-2);
}
.field > span b {
  margin-left: 3px;
  color: var(--bad);
}
.field input {
  height: 50px;
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: white;
  box-shadow: inset 0 0 0 1.5px var(--rule-strong);
  color: var(--ink);
  font: inherit;
  font-size: 16px;
  transition: box-shadow 160ms ease;
}
.field input::placeholder {
  color: var(--ink-4);
}
.field input:focus {
  outline: none;
  box-shadow:
    inset 0 0 0 2px var(--blue),
    0 0 0 4px #1769ff1f;
}
.field-hint {
  margin-top: 10px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--ink-3);
}
.text-link {
  padding: 0;
  border: 0;
  background: none;
  color: var(--blue-600);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Order summary */
.summary {
  position: sticky;
  top: calc(var(--header) + 20px);
  padding: 28px;
  border-radius: 28px;
  background: white;
  box-shadow:
    inset 0 0 0 1px var(--rule),
    var(--shadow-md);
}
.summary h2 {
  font-size: 18px;
  font-weight: 750;
}
.summary-rows {
  margin-top: 14px;
}
.summary-rows > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--rule-strong);
  font-size: 14px;
}
.summary-rows > div[hidden] {
  display: none;
}
.summary-rows dt {
  flex: none;
  color: var(--ink-3);
}
.summary-rows dd {
  min-width: 0;
  overflow-wrap: anywhere;
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.summary-rows dd.is-empty {
  color: var(--ink-4);
  font-weight: 400;
}
.summary-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-top: 18px;
}
.summary-total span {
  font-size: 15px;
  font-weight: 650;
  color: var(--ink-2);
}
.summary-total strong {
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.agree {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 18px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--ink-2);
  cursor: pointer;
}
.agree input {
  flex: none;
  width: 17px;
  height: 17px;
  margin: 3px 0 0;
  accent-color: var(--blue);
}
.agree a {
  color: var(--blue-600);
  font-weight: 600;
}
.pay-button {
  width: 100%;
  margin-top: 18px;
  gap: 10px;
}
.pay-button:disabled {
  background: #a9bde3;
  box-shadow: none;
  cursor: not-allowed;
}
.pay-requirement {
  margin-top: 10px;
  font-size: 13px;
  color: var(--ink-4);
  text-align: center;
}
.pay-requirement[hidden] {
  display: none;
}
.pay-status {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--warn-bg);
  color: var(--warn);
  font-size: 13px;
  line-height: 1.65;
}
.pay-status .icon {
  flex: none;
  width: 17px;
  height: 17px;
  margin-top: 2px;
}
.summary-notes {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--rule);
}
.summary-notes li {
  position: relative;
  padding-left: 13px;
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--ink-3);
}
.summary-notes li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--ink-4);
}
.summary-notes a {
  color: var(--blue-600);
}

@media (hover: hover) and (pointer: fine) {
  .button-ghost:hover {
    background: white;
    box-shadow:
      inset 0 0 0 1.5px var(--blue),
      0 1px 2px #0a10200d;
    color: var(--blue-700);
  }
  .pack:hover {
    box-shadow: inset 0 0 0 1.5px var(--blue);
  }
  .pack:hover .pack-go .icon {
    transform: translateX(3px);
  }
  .option:hover {
    box-shadow: inset 0 0 0 1.5px #1769ff80;
  }
}
@media (max-width: 1199px) {
  .checkout {
    grid-template-columns: minmax(0, 1fr) 340px;
  }
  .options-2 {
    grid-template-columns: minmax(0, 1fr);
  }
  .options-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 1023px) {
  .plans {
    grid-template-columns: minmax(0, 1fr);
    max-width: 560px;
  }
  .packs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .store-notes-layout,
  .checkout {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }
  .store-notes-layout .store-section-head,
  .summary {
    position: static;
  }
}
@media (max-width: 760px) {
  .store-head {
    padding-top: calc(var(--header) + 44px);
  }
  .options-2 {
    grid-template-columns: minmax(0, 1fr);
  }
  .options-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .co-card,
  .summary {
    padding: 22px 20px;
    border-radius: 22px;
  }
  .plan {
    padding: 28px 24px 24px;
  }
  .steps {
    gap: 8px 16px;
  }
  .steps li + li::before {
    display: none;
  }
}
@media (max-width: 420px) {
  .packs {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Online payment status on checkout (checkout.js sets data-tone). */
.pay-status[data-tone="info"] {
  background: var(--blue-50);
  color: var(--blue-700);
}
.pay-status[data-tone="error"] {
  background: var(--bad-bg);
  color: var(--bad);
}

/* Payment result page. */
.pay-result {
  display: grid;
  gap: 18px;
  max-width: 720px;
}
.pay-result .result-notes {
  padding: 0 4px;
}
.result-card {
  padding: 32px 32px 28px;
  border-radius: 28px;
  background: white;
  box-shadow:
    inset 0 0 0 1px var(--rule),
    var(--shadow-md);
}
.result-badge {
  display: inline-flex;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--blue-50);
  color: var(--blue-700);
  font-size: 13px;
  font-weight: 650;
}
.pay-result[data-state="paid"] .result-badge {
  background: var(--good-bg);
  color: var(--good);
}
.pay-result[data-state="exception"] .result-badge,
.pay-result[data-state="waiting"] .result-badge {
  background: var(--warn-bg);
  color: var(--warn);
}
.pay-result[data-state="closed"] .result-badge,
.pay-result[data-state="missing"] .result-badge {
  background: var(--paper-2);
  color: var(--ink-3);
}
.result-card h2 {
  margin-top: 14px;
  font-size: 26px;
  font-weight: 750;
  line-height: 1.3;
}
.result-copy {
  margin-top: 8px;
  color: var(--ink-3);
  line-height: 1.7;
}
.code-box {
  display: grid;
  gap: 12px;
  justify-items: start;
  margin-top: 22px;
  padding: 22px 24px;
  border-radius: 20px;
  background: var(--good-bg);
}
.code-box[hidden] {
  display: none;
}
.code-label {
  color: var(--good);
  font-size: 13px;
  font-weight: 650;
}
.code-value {
  font-family: var(--mono);
  font-size: clamp(22px, 4vw, 30px);
  font-weight: 700;
  letter-spacing: 0.08em;
  word-break: break-all;
  user-select: all;
}
.code-copy .icon {
  width: 18px;
  height: 18px;
}
.code-hint {
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.65;
}
.result-rows {
  margin-top: 22px;
}
.result-rows dd {
  font-variant-numeric: tabular-nums;
  word-break: break-all;
}
.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}
.result-actions [hidden],
.result-actions:not(:has(> :not([hidden]))) {
  display: none;
}
.result-feedback {
  margin-top: 12px;
  color: var(--ink-2);
  font-size: 13px;
}
.result-feedback:empty {
  display: none;
}
.result-notes {
  margin-top: 0;
  padding: 0 8px;
  border-top: 0;
}
@media (max-width: 760px) {
  .result-card {
    padding: 24px 20px;
    border-radius: 22px;
  }
}
@media (max-width: 420px) {
  .result-rows dt {
    flex: none;
  }
  .result-rows dd {
    font-size: 12.5px;
    letter-spacing: -0.01em;
  }
}
