/* Pricing: the plans of the billing catalog (pages/landing/plans.js) on the tile surface. The plans stay in one row and scale
   with it; rows are shared through subgrid, so prices and buttons line up. */
/* the anchor stops the plans under the sticky topbar, like the questions */
.pricing { scroll-margin-top: 88px; width: min(1100px, calc(100% - 48px)); margin: 0 auto 160px; container-type: inline-size; }

/* the heading reads like the pain heading above it */
.pricing-head { margin-bottom: 44px; text-align: center; }
.pricing-head h2 { font-size: clamp(30px, 3.6vw, 48px); font-weight: 540; line-height: 1.1; letter-spacing: -.04em; text-wrap: balance; }

/* --plans is the number of terms in the catalog */
.plan-grid { display: grid; grid-template-columns: repeat(var(--plans, 3), minmax(0, 1fr)); grid-template-rows: repeat(4, auto); column-gap: 14px; }
.plan { --plan-pad: clamp(22px, 2.8cqi, 30px); position: relative; isolation: isolate; grid-row: span 4; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: subgrid; row-gap: 4px; min-width: 0; padding: var(--plan-pad); border-radius: 28px; background: #121212; }
.plan-name { display: flex; align-items: center; min-height: 30px; font-size: clamp(16px, 1.8cqi, 20px); font-weight: 650; letter-spacing: -.02em; white-space: nowrap; }
.plan-price { display: flex; align-items: baseline; margin-top: clamp(10px, 1.6cqi, 18px); white-space: nowrap; }
.plan-price strong { font-size: clamp(34px, 5.4cqi, 60px); font-weight: 650; letter-spacing: -.05em; font-variant-numeric: tabular-nums; }
.plan-price span { margin-left: .25em; color: var(--muted); font-size: clamp(14px, 1.6cqi, 18px); font-weight: 550; }
.plan-total { color: var(--muted); font-size: 15px; line-height: 1.35; }
.plan-buy { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; margin-top: clamp(18px, 2.4cqi, 26px); padding: 0 8px; border-radius: 999px; background: #2e2e2e; color: #f0f0f0; font-size: 16px; font-weight: 550; white-space: nowrap; transition: background .18s ease; }
.plan-buy:hover { background: #383838; }
/* the 3-month plan is the suggested one: a lighter card and button, covered with tiny egg faces of the mascot like a
   textile print; the print sits behind the text (.plan isolates) and fades out before the price; no discount shown */
.pricing { --eggs: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='60'%3E%3Cg fill='none' stroke='%23fff' stroke-width='1.3'%3E%3Cpath transform='translate(6 6) rotate(-12 9 10) scale(.22) translate(-20 -16)' vector-effect='non-scaling-stroke' d='M58 18C84 16 102 40 100 66C98 90 80 104 58 102C34 100 18 84 20 60C22 36 36 20 58 18Z'/%3E%3Cpath transform='translate(34 36) rotate(12 9 10) scale(.22) translate(-20 -16)' vector-effect='non-scaling-stroke' d='M58 18C84 16 102 40 100 66C98 90 80 104 58 102C34 100 18 84 20 60C22 36 36 20 58 18Z'/%3E%3C/g%3E%3Cg fill='%23fff'%3E%3Cg transform='translate(6 6) rotate(-12 9 10)'%3E%3Ccircle cx='5.8' cy='9.4' r='2'/%3E%3Ccircle cx='12.3' cy='8.7' r='1.2'/%3E%3C/g%3E%3Cg transform='translate(34 36) rotate(12 9 10)'%3E%3Ccircle cx='5.8' cy='9.4' r='2'/%3E%3Ccircle cx='12.3' cy='8.7' r='1.2'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E"); }
.plan.is-suggested { background: #262626; }
.plan.is-suggested::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: var(--eggs); background-size: 56px 60px; opacity: .13; mask: linear-gradient(#000, #0000 62%); pointer-events: none; }
.plan.is-suggested .plan-buy { background: #474747; }
.plan.is-suggested .plan-buy:hover { background: #525252; }

/* while the catalog loads, faint bars hold the rows of a plan; an error or an empty catalog takes the whole row */
.plan.is-loading i { display: block; width: 46%; height: 20px; border-radius: 999px; background: rgba(255, 255, 255, .06); }
.plan.is-loading .is-price { width: 70%; height: clamp(34px, 5.4cqi, 60px); margin-top: clamp(10px, 1.6cqi, 18px); }
.plan.is-loading .is-button { width: 100%; height: 48px; margin-top: clamp(18px, 2.4cqi, 26px); }
.plans-state { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; padding: clamp(22px, 3.4cqi, 36px); border-radius: 32px; background: #1a1a1a; color: #c7c7c7; font-size: 16px; line-height: 1.45; }
.plan-retry { min-height: 44px; padding: 0 20px; border: 0; border-radius: 999px; background: #2e2e2e; color: #f0f0f0; font: inherit; font-size: 15px; font-weight: 550; cursor: pointer; }
.plan-retry:hover { background: #383838; }

/* the renewal line right under the plans */
.plan-renewal { margin-top: 24px; color: var(--muted); font-size: 15px; line-height: 1.45; text-align: center; }

/* phones: plans stack into rows — name and price on top, total and button below */
@media (max-width: 760px) {
  .pricing { width: calc(100% - 32px); margin-bottom: 96px; }
  .pricing-head { margin-bottom: 28px; }
  .plan-grid { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; row-gap: 10px; }
  .plan.is-suggested { margin-block: 8px; }
  .plan { grid-row: auto; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-rows: auto auto; grid-template-areas: "name . price" "total total buy"; align-items: center; gap: 12px 8px; padding: 18px 16px 16px 20px; border-radius: 28px; }
  .plan-name { grid-area: name; min-height: 0; font-size: 17px; }
  .plan-price { grid-area: price; margin: 0; }
  .plan-price strong { font-size: 30px; }
  .plan-price span { font-size: 14px; }
  .plan-total { grid-area: total; font-size: 13px; }
  .plan-buy { grid-area: buy; min-height: 44px; margin: 0; padding: 0 20px; font-size: 15px; }
  .plan-renewal { font-size: 13px; text-align: left; }
    }
