/* /subscribe/ (plans, success, cancel). The staging build also links it on every page. */

.subscribe-page .wrap {
  width: min(36rem, calc(100% - 2rem));
}

.subscribe-page h1 {
  font-size: clamp(2rem, 7vw, 2.75rem);
  margin-bottom: 0.45rem;
}

.subscribe-page .lede {
  margin-bottom: 1rem;
}

.subscribe-hero .lede {
  margin-bottom: 1.15rem;
}

.hero-cta {
  width: 100%;
  scroll-margin-top: 1rem;
}

.hero-proof {
  margin: 0.85rem 0 0;
  color: var(--bmm-muted);
  font-size: 0.95rem;
}

.hero-secondary {
  margin: 0.1rem 0 0;
}

.price-merchant {
  margin-top: 0.85rem;
}

.price-strip {
  margin: 0;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.everyone {
  margin-top: 2.25rem;
}

.everyone p {
  margin: 0 0 0.5rem;
}

.everyone-soft {
  color: var(--bmm-muted);
  font-size: 0.95rem;
}

.how-it-works {
  margin-top: 2.25rem;
}

.everyone h2,
.how-it-works h2,
.subscribe-block h2 {
  margin: 0 0 0.75rem;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.how-it-works ol {
  display: grid;
  gap: 0.9rem;
  margin: 0.35rem 0 0;
  padding-left: 1.35rem;
}

.how-it-works li {
  padding-left: 0.2rem;
}

.checkout-block {
  margin-top: 2.25rem;
  padding: 1.15rem 1.05rem 1.2rem;
  background: var(--bmm-card);
  border: 1px solid var(--bmm-border);
  border-radius: var(--bmm-radius-card);
  box-shadow: var(--bmm-shadow-soft);
  scroll-margin-top: 1rem;
}

.subscribe-block {
  margin-top: 1.75rem;
}

.checkout-block .subscribe-block:first-child {
  margin-top: 0;
}

.handle-forever,
.honesty {
  color: var(--bmm-muted);
  font-size: 0.95rem;
}

.handle-forever {
  margin: 1rem 0 0;
}

.diy-strip {
  margin-top: 2.5rem;
  color: var(--bmm-muted);
  font-size: 0.95rem;
}

.diy-strip p {
  margin: 0;
}

.diy-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.15rem 0.65rem;
}

.diy-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--bmm-muted);
  font-weight: 650;
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.honesty {
  margin: 1.35rem 0 0;
}

.subscribe-page .site-footer {
  margin-top: 1.75rem;
}

.plan-grid {
  display: grid;
  gap: 0.75rem;
}

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

.plan-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  width: 100%;
  min-height: 44px;
  padding: 1rem 1.05rem 1.05rem;
  border: 2px solid transparent;
  border-radius: var(--bmm-radius-card);
  background: var(--bmm-card);
  box-shadow: var(--bmm-shadow-soft);
  color: var(--bmm-ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition:
    border-color 150ms ease,
    background-color 150ms ease,
    box-shadow 150ms ease;
}

.plan-card.is-selected {
  border-color: var(--bmm-blue);
  background: var(--bmm-blue-soft);
  box-shadow: var(--bmm-shadow-card);
}

.plan-card:focus-visible {
  outline: 2px solid var(--bmm-blue);
  outline-offset: 2px;
}

.plan-price {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.plan-soft {
  color: var(--bmm-muted);
  font-size: 0.95rem;
}

/* #64748b on the selected card's #eff6ff is 4.37:1; #475569 clears AA. */
.plan-card.is-selected .plan-soft {
  color: #475569;
}

.trial-trust {
  margin-top: 1rem;
  padding: 1rem 1.05rem;
  background: var(--bmm-card);
  border: 1px solid var(--bmm-border);
  border-radius: var(--bmm-radius-card);
}

.trial-trust p {
  margin: 0 0 0.55rem;
}

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

.staging-trust {
  margin-top: 0.35rem;
  color: var(--bmm-ink);
  font-weight: 650;
}

.access-ends {
  color: var(--bmm-muted);
  font-size: 0.95rem;
}

.handle-help {
  margin-top: -0.25rem;
}

.handle-field {
  display: block;
}

.handle-field input {
  width: 100%;
  min-height: 56px;
  padding: 0.75rem 0.9rem;
  border: 2px solid var(--bmm-border);
  border-radius: var(--bmm-radius-btn);
  background: var(--bmm-card);
  color: var(--bmm-ink);
  font: inherit;
  font-size: 1.25rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  /* Clear the heading above and the fixed sticky bar below when #address is the target. */
  scroll-margin-top: 7rem;
  scroll-margin-bottom: calc(12rem + env(safe-area-inset-bottom));
}

.handle-field input:focus {
  border-color: var(--bmm-blue);
  outline: none;
}

.handle-field input:focus-visible {
  outline: 3px solid var(--bmm-blue);
  outline-offset: 2px;
}

.handle-field input[aria-invalid="true"] {
  border-color: #b91c1c;
}

.live-url {
  margin: 0.85rem 0 0.35rem;
  scroll-margin-bottom: calc(10rem + env(safe-area-inset-bottom));
  color: var(--bmm-ink);
  font-size: clamp(1.35rem, 5vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
  overflow-wrap: normal;
}

.live-url-lead {
  display: block;
  margin-bottom: 0.15rem;
  color: var(--bmm-muted);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0;
}

.live-url [data-live-host] {
  overflow-wrap: anywhere;
}

.live-url.is-ghost [data-live-host] {
  overflow-wrap: normal;
  white-space: nowrap;
}

.live-url.is-ghost {
  color: var(--bmm-muted);
  font-weight: 650;
}

.handle-status {
  min-height: 1.5rem;
  margin: 0.35rem 0 0;
  font-weight: 650;
}

.handle-status.is-error {
  color: #b91c1c;
}

.handle-status.is-available {
  color: var(--bmm-success);
  animation: handle-check-in 150ms ease;
}

@keyframes handle-check-in {
  from {
    opacity: 0;
    transform: translateY(2px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.suggest-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.suggest-chip {
  min-height: 44px;
  padding: 0.4rem 0.9rem;
  border: 1px solid var(--bmm-border);
  border-radius: 999px;
  background: var(--bmm-card);
  color: var(--bmm-ink);
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.handle-retry {
  margin-top: 0.65rem;
}

.subscribe-sticky {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  gap: 0.15rem;
  padding: 0.75rem 1rem calc(0.75rem + env(safe-area-inset-bottom));
  background: rgba(248, 250, 252, 0.96);
  border-top: 1px solid var(--bmm-border);
  backdrop-filter: blur(10px);
}

.subscribe-sticky .btn,
.sticky-then,
.sticky-note,
.sticky-stub {
  width: min(36rem, 100%);
  margin-left: auto;
  margin-right: auto;
}

.subscribe-sticky .btn:disabled {
  opacity: 0.4;
  box-shadow: none;
}

.subscribe-sticky .btn:disabled.is-loading {
  opacity: 1;
  cursor: progress;
}

.sticky-then,
.sticky-note,
.sticky-stub {
  margin-top: 0;
  margin-bottom: 0;
  text-align: center;
}

.sticky-then {
  font-weight: 700;
}

.sticky-note,
.sticky-stub {
  color: var(--bmm-muted);
  font-size: 0.92rem;
}

.sticky-stub {
  color: var(--bmm-ink);
  font-weight: 650;
}

/* Stays in the accessibility tree while empty so role="status" announces the next message. */

body[data-subscribe-page="plans"] .wrap {
  padding-bottom: calc(11rem + env(safe-area-inset-bottom));
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  .plan-card,
  .handle-status.is-error {
  color: #b91c1c;
}

.handle-status.is-available {
    transition: none;
    animation: none;
  }
}

@media (min-width: 480px) {
  .hero-cta {
    width: auto;
  }
}
