/* Pricing page. Loads after site.css and home.css (shared section, plan card
   and FAQ styles). */

/* Hero with the three plans */
.pricing-hero {
  position: relative;
  isolation: isolate;
  padding: 32px 0 64px;
  overflow: hidden;
  background: var(--lg-cloud);
  color: #fff;
  text-align: center;
}

.pricing-hero-title {
  font-family: var(--lg-serif);
  font-size: clamp(44px, min(6.9vw, 11.5vh), 100px);
  font-weight: 900;
  letter-spacing: -0.015em;
  line-height: 1;
}

.pricing-hero-title span {
  display: block;
}

/* Keyword label inside the h1; see the same pattern in home.css. */
.pricing-hero-title .lg-label {
  display: flex;
  width: fit-content;
  margin: 0 auto 20px;
  font-family: var(--lg-sans);
  letter-spacing: 0;
  line-height: 1.5;
}

.pricing-hero-lead {
  max-width: 840px;
  margin: 20px auto 0;
  color: var(--lg-mist);
  font-size: 20px;
  line-height: 1.5;
}

.pricing-plans {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: center;
  gap: 32px;
  margin-top: 48px;
  color: var(--lg-night);
  text-align: left;
}

/* Night band behind the heading that ends part-way down the cards, with two soft glows. */
.pricing-plans::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -1200px;
  bottom: calc(100% - 210px);
  left: 50%;
  width: 100vw;
  background:
    radial-gradient(ellipse 420px 230px at calc(50% - 190px) calc(100% - 70px), rgba(31, 91, 255, 0.5), transparent 100%),
    radial-gradient(ellipse 320px 200px at calc(50% + 350px) calc(100% - 60px), rgba(255, 83, 100, 0.3), transparent 100%),
    var(--lg-night);
  transform: translateX(-50%);
}

/* The gradient line that closes the night band, as under the blog and help heroes. It runs
   behind the plan cards. */
.pricing-plans::after {
  content: "";
  position: absolute;
  z-index: -1;
  top: 210px;
  left: 50%;
  width: 100vw;
  height: 4px;
  background: var(--lg-gradient);
  transform: translateX(-50%);
}

.pricing-plan {
  display: flex;
  flex-direction: column;
  box-shadow: 0 30px 80px rgba(11, 16, 38, 0.14);
}

.pricing-plan.is-featured {
  margin: 0 -4px;
  padding-block: 56px;
  border: 4px solid transparent;
  border-radius: 36px;
  background: linear-gradient(#fff, #fff) padding-box, var(--lg-gradient) border-box;
}

.pricing-plan .home-card-title {
  font-size: 36px;
  line-height: 44px;
}

.pricing-plan-credit-example {
  display: block;
  margin-top: 5px;
  color: var(--lg-slate);
  font-size: 14px;
  line-height: 18px;
}

.pricing-plan-for {
  margin-top: 6px;
  color: var(--lg-slate);
  font-size: 15.5px;
  line-height: 19px;
}

.pricing-plan .home-plan-price {
  margin-top: 17px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--lg-line);
}

.pricing-plan .home-plan-price s {
  color: var(--lg-mist);
}

.pricing-plan ul {
  margin: 30px 0 52px;
}

.pricing-plan .lg-btn {
  margin-top: auto;
}

/* Signed-in accounts: plan actions and account notices in place of the sign-up links. */
.pricing-plan-action {
  margin-top: auto;
}

.pricing-plan-action :is(button, a) {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 56px;
  padding: 0 28px;
  border: 0;
  border-radius: 999px;
  background: var(--lg-night);
  color: #fff;
  font-family: var(--lg-sans);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
}

.pricing-plan-action.is-featured :is(button, a) {
  background: var(--lg-gradient);
}

.pricing-plan-action :is(button, a):disabled {
  background: var(--lg-cloud);
  color: var(--lg-slate);
  cursor: default;
}

.pricing-plan-action :is(button, a):not(:disabled):hover {
  filter: brightness(1.1);
}

.pricing-billing-notes {
  display: grid;
  justify-items: center;
  gap: 8px;
  margin-top: 18px;
}

.pricing-billing-notes:empty {
  display: none;
}

.pricing-billing-note {
  max-width: 100%;
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--lg-night-2);
  color: var(--lg-mist);
  font-size: 14px;
  line-height: 22px;
}

.pricing-billing-note strong {
  color: #fff;
}

.pricing-billing-note code {
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 13px;
}

.pricing-billing-note.is-success {
  background: #e6f8f1;
  color: #0f6b4b;
}

.pricing-billing-note.is-warning {
  background: #fff4dc;
  color: #7a5200;
}

.pricing-billing-note.is-danger {
  background: #fff0f2;
  color: #b42335;
}

.pricing-note {
  margin-top: 30px;
  color: var(--lg-slate);
  font-size: 15px;
}

/* Section headings on this page run one step smaller than on the homepage */
.pricing-title {
  font-size: clamp(36px, 5vw, 72px);
  line-height: 1.085;
}

.pricing-sub {
  margin-top: 14px;
  color: var(--lg-slate);
  font-size: 18px;
  line-height: 1.5;
}

/* In every plan */
.pricing-included {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 55px 0 0;
  padding: 0;
  list-style: none;
}

.pricing-included li {
  padding: 20px 22px 22px;
  border-radius: 20px;
  background: var(--lg-cloud);
}

.pricing-included strong {
  position: relative;
  display: block;
  padding-left: 24px;
  font-size: 16.5px;
  font-weight: 600;
  line-height: 20px;
}

.pricing-included strong::before {
  content: "";
  position: absolute;
  top: 4px;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 4px;
  background: var(--lg-gradient);
}

.pricing-included span {
  display: block;
  margin-top: 6px;
  padding-left: 24px;
  color: var(--lg-slate);
  font-size: 14px;
  line-height: 20px;
}

/* Comparison table */
.pricing-table-wrap {
  margin-top: 42px;
  overflow: hidden;
  border-radius: 28px;
  background: #fff;
}

.pricing-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 16px;
  line-height: 20px;
}

.pricing-table col:first-child {
  width: 32.3%;
}

.pricing-table th,
.pricing-table td {
  padding: 15px 12px;
  font-weight: 400;
  text-align: center;
}

.pricing-table tbody th,
.pricing-table tbody td {
  border-top: 1px solid var(--lg-line);
}

.pricing-table thead th {
  padding: 24px 12px 23px;
  font-family: var(--lg-serif);
  font-size: 22px;
  font-weight: 900;
  line-height: 29px;
}

.pricing-table tbody th {
  padding-left: 32px;
  font-weight: 500;
  text-align: left;
}

.pricing-table tbody tr:last-child > * {
  padding-bottom: 19px;
}

.pricing-table .is-featured {
  background: #eef2ff;
  font-weight: 700;
}

/* What a credit buys */
.pricing-credits {
  padding: 88px 0 92px;
}

.pricing-credit-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  margin: 40px 0 0;
  padding: 0;
  list-style: none;
}

.pricing-credit-grid li {
  display: flex;
  flex-direction: column-reverse;
  justify-content: flex-end;
  min-height: 150px;
  padding: 12px 24px 28px;
  border-radius: 24px;
  background: var(--lg-night-2);
  color: var(--lg-mist);
  font-size: 15.5px;
  line-height: 19px;
}

.pricing-credit-grid strong {
  display: block;
  margin-bottom: 14px;
  color: #fff;
  font-family: var(--lg-display);
  font-size: 64px;
  font-weight: 400;
  line-height: 76px;
}

.pricing-credits-note {
  margin-top: 30px;
  color: var(--lg-mist);
  font-size: 16px;
}

@media (max-width: 1199px) {
  .pricing-plans {
    gap: 20px;
  }

  /* Keeps the three prices on one line when a tagline wraps. */
  .pricing-plan-for {
    min-height: 38px;
  }

  .pricing-included {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pricing-credit-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 991px) {
  .pricing-hero {
    padding-bottom: 56px;
  }

  .pricing-hero-title {
    font-size: clamp(40px, 8.4vw, 76px);
  }

  .pricing-hero-lead {
    font-size: 18px;
  }

  .pricing-plans {
    grid-template-columns: minmax(0, 1fr);
    max-width: 520px;
    margin: 40px auto 0;
  }

  .pricing-plans::before {
    bottom: calc(100% - 150px);
  }

  .pricing-plan.is-featured {
    order: -1;
    margin: 0;
    padding-block: 32px;
  }

  .pricing-plan-for {
    min-height: 0;
  }

  .pricing-plan ul {
    margin-bottom: 30px;
  }

  .pricing-included,
  .pricing-table-wrap,
  .pricing-credit-grid {
    margin-top: 36px;
  }

  .pricing-credits {
    padding: 72px 0 76px;
  }
}

@media (max-width: 599px) {
  .pricing-hero {
    padding-top: 28px;
  }

  .pricing-included {
    grid-template-columns: minmax(0, 1fr);
  }

  .pricing-table {
    font-size: 14px;
  }

  .pricing-table col:first-child {
    width: 37%;
  }

  .pricing-table th,
  .pricing-table td {
    padding: 13px 4px;
  }

  .pricing-table thead th {
    padding: 18px 4px 16px;
    font-size: 17px;
  }

  .pricing-table tbody th {
    padding-left: 16px;
  }

  .pricing-credit-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .pricing-credit-grid li {
    min-height: 0;
    padding: 8px 18px 20px;
  }

  .pricing-credit-grid strong {
    margin-bottom: 8px;
    font-size: 52px;
    line-height: 64px;
  }

  .pricing-credits {
    padding: 56px 0 60px;
  }
}
