/* ===========================================================================
   Pricing page (/pricing).

   A simple page: a text-only hero with a segment controller, one pricing
   card (Core), and a press logos row. No hero photograph, no split section.
   Everything structural — buttons, the CTA band — comes from the shared
   marketing stylesheets.
   =========================================================================== */

/* ==========================================================================
   Hero

   No photograph. A centred column with headline, subtitle, and a pill-shaped
   segment controller for Monthly / Yearly billing.
   ========================================================================== */

.pricing-hero {
  padding: 160px var(--mz-gutter) 0;
}

.pricing-hero-inner {
  max-width: var(--mz-page-max);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
}

.pricing-hero-headline {
  font-family: var(--mz-font-serif);
  font-weight: 400;
  font-size: 72px;
  line-height: 0.85;
  letter-spacing: -1.44px;
  color: var(--mz-white);
}

.pricing-hero-subtitle {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: -0.16px;
  color: var(--mz-white);
  max-width: 600px;
}

/* --- Segment controller ---------------------------------------------------
   A pill-shaped toggle with two tabs. The active tab gets a white fill and
   dark text; the inactive tab is transparent with white text.
   ------------------------------------------------------------------------- */

.pricing-segment {
  display: inline-flex;
  align-items: center;
  background: var(--mz-ink);
  border: 1px solid var(--mz-rule);
  border-radius: 100px;
  height: 60px;
  padding: 4px;
  gap: 0;
}

.pricing-segment-tab {
  appearance: none;
  border: none;
  background: none;
  color: var(--mz-white);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.28;
  letter-spacing: -0.16px;
  padding: 0 24px;
  height: 100%;
  border-radius: 100px;
  cursor: pointer;
  transition: background var(--mz-transition), color var(--mz-transition);
}

.pricing-segment-tab.is-active {
  background: var(--mz-white);
  color: var(--mz-ink);
}

.pricing-segment-badge {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--mz-lilac);
  margin-left: 4px;
}

.pricing-segment-tab.is-active .pricing-segment-badge {
  color: #8b5cf6;
}

/* ==========================================================================
   Pricing cards

   Currently one card (Core). The container is set up for a row of three so
   additional tiers can be dropped in later.
   ========================================================================== */

.pricing-cards {
  padding: 100px var(--mz-gutter) 100px;
}

.pricing-cards-header {
  max-width: var(--mz-page-max);
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.pricing-cards-label {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--mz-text-secondary);
}

/* --- Yearly toggle --------------------------------------------------------- */

.pricing-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.pricing-toggle-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pricing-toggle-track {
  position: relative;
  width: 48px;
  height: 28px;
  background: var(--mz-rule);
  border-radius: 100px;
  transition: background var(--mz-transition);
}

.pricing-toggle-input:checked + .pricing-toggle-track {
  background: var(--mz-lilac);
}

.pricing-toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 22px;
  height: 22px;
  background: var(--mz-ink);
  border-radius: 50%;
  transition: transform var(--mz-transition);
}

.pricing-toggle-input:checked + .pricing-toggle-track .pricing-toggle-thumb {
  transform: translateX(20px);
}

.pricing-toggle-label {
  font-size: 14px;
  font-weight: 400;
  color: var(--mz-white);
}

.pricing-toggle-label strong {
  font-weight: 700;
}

/* The toggle's mobile caption. Desktop keeps the single "Yearly pricing"
   label to the right of the switch instead. */
.pricing-toggle-text {
  display: none;
}

.pricing-toggle-title {
  font-size: 14px;
  font-weight: 400;
  color: var(--mz-white);
}

.pricing-toggle-savings {
  font-size: 14px;
  font-weight: 400;
  color: var(--mz-text-secondary);
}

.pricing-toggle-savings strong {
  color: var(--mz-lilac);
  font-weight: 600;
}

.pricing-cards-inner {
  max-width: var(--mz-page-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  /* Equal-height cards: the tallest feature list sets the row, and every
     card fills it, so the three CTAs line up. */
  grid-auto-rows: 1fr;
  gap: 12px;
}

.pricing-card {
  min-width: 0;
  background: var(--mz-panel);
  padding: 40px 24px 40px;
  display: flex;
  flex-direction: column;
  gap: 80px;
  height: 100%;
}

.pricing-card-top {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.pricing-card-tier-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pricing-card-tier {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--mz-lilac);
}

.pricing-card-badge {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--mz-lilac);
  border: 1px solid var(--mz-lilac);
  padding: 4px 10px;
  border-radius: 4px;
}

.pricing-card-subtitle {
  font-family: var(--mz-font-serif);
  font-size: 32px;
  font-weight: 400;
  line-height: 0.9;
  letter-spacing: -0.32px;
  color: var(--mz-white);
}

.pricing-card-price {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.pricing-card-amount {
  font-family: var(--mz-font-sans);
  font-weight: 400;
  font-size: 20px;
  line-height: 1.28;
  color: var(--mz-white);
}

.pricing-card-period {
  font-size: 14px;
  font-weight: 400;
  line-height: 1.28;
  color: var(--mz-text-secondary);
}

.pricing-card-billing {
  font-size: 14px;
  font-weight: 400;
  line-height: 1.28;
  color: var(--mz-text-secondary);
}

.pricing-card-cta {
  width: 100%;
}

.pricing-card-cta--outline {
  background: none;
  border: 1px solid var(--mz-lilac);
  color: var(--mz-lilac);
}
.pricing-card-cta--outline:hover {
  background: rgba(232, 187, 255, 0.1);
}

/* --- Features list --------------------------------------------------------
   Each feature row has a top border and a check icon beside the text.
   ------------------------------------------------------------------------- */

.pricing-card-features-section {
  display: flex;
  flex-direction: column;
}

.pricing-card-features-label {
  display: none;
}

.pricing-card-features-label {
  display: none;
}

.pricing-card-features {
  list-style: none;
  display: flex;
  flex-direction: column;
}

.pricing-card-feature {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.pricing-card-feature img {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  filter: brightness(0) invert(1);
}

.pricing-card-feature span {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.28;
  letter-spacing: -0.16px;
  color: var(--mz-white);
}

/* ==========================================================================
   Press logos

   Mirrors the home page's press section but namespaced to this page.
   ========================================================================== */

.pricing-press {
  padding: 80px var(--mz-gutter);
}

.pricing-press-inner {
  max-width: 1320px;
  margin: 0 auto;
}

.pricing-press-logos {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 40px;
}

.pricing-press-logos a {
  display: flex;
  align-items: center;
  transition: opacity 0.2s ease;
}
.pricing-press-logos a:hover { opacity: 0.9; }

.pricing-press-logos img {
  height: auto;
  max-height: 40px;
}

/* ==========================================================================
   Mobile
   ========================================================================== */

@media (max-width: 1023px) {
  .pricing-hero {
    padding: 140px var(--mz-gutter-mobile) 0;
  }

  .pricing-hero-headline {
    font-size: 48px;
    letter-spacing: -0.48px;
  }

  .pricing-cards {
    padding: 40px var(--mz-gutter-mobile) 60px;
  }

  /* The header stacks: the "Compare plans" label is dropped and the toggle
     takes the full width, captioned on the left and switched on the right. */
  .pricing-cards-header {
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
  }

  .pricing-cards-label {
    display: none;
  }

  .pricing-toggle {
    width: 100%;
    justify-content: space-between;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  }

  .pricing-toggle-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .pricing-toggle-label {
    display: none;
  }

  /* Cards become separate panels rather than a seamless 2px-gapped block. */
  .pricing-cards-inner {
    grid-template-columns: 1fr;
    grid-auto-rows: auto;
    gap: 12px;
  }

  .pricing-card {
    min-height: auto;
    gap: 0;
    padding: 24px 20px;
    border-radius: 12px;
  }

  .pricing-card-top {
    gap: 12px;
  }

  /* Each card's feature list collapses behind its own button, so three
     plans fit on a phone without a page of scrolling between them. */
  .pricing-card-features-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    appearance: none;
    border: none;
    background: none;
    color: var(--mz-text-secondary);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.28;
    padding: 16px 0;
    margin: 20px 0 0;
    cursor: pointer;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .pricing-card-features-label svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    transition: transform var(--mz-transition);
  }

  .pricing-card-features-label.is-open svg {
    transform: rotate(180deg);
  }

  /* Collapsed by animating the grid row from 0fr to 1fr rather than a
     max-height. A max-height has to be guessed, and the guess crops the list
     silently the day a plan gains a feature; 1fr is whatever the list needs.
     The section is the grid -- button on an auto row, list on the row that
     animates -- so the <ul> needs no wrapper of its own. */
  .pricing-card-features-section {
    display: grid;
    /* minmax(0, ...) because an `fr` track still floors at its automatic
       minimum -- a bare 0fr leaves the first feature showing. */
    grid-template-rows: auto minmax(0, 0fr);
    transition: grid-template-rows 0.3s ease;
  }

  .pricing-card-features {
    min-height: 0;
    overflow: hidden;
  }

  .pricing-card-features-section.is-open {
    grid-template-rows: auto minmax(0, 1fr);
  }

  .pricing-card-feature img {
    width: 18px;
    height: 18px;
  }


  .pricing-press {
    padding: 48px var(--mz-gutter-mobile);
  }

  .pricing-press-logos {
    flex-wrap: wrap;
    gap: 24px 32px;
    justify-content: center;
    height: auto;
  }

  .pricing-press-logos img {
    max-height: 28px;
  }
}
