/* SPDX-License-Identifier: MIT */
/* The pricing page, over site.css: the promise beside its two prices, what each AI costs as a table that a narrow
   window stacks, an organisation's two prices with what the price comes to per person beside a price per seat, and
   what is not for sale.
   Logical properties only; classes start with pricing-. */

/* The promise, and its two prices beside it, each leading to its part */
.pricing-hero { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr); gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.pricing-hero .site-hero-text { max-inline-size: none; }
.pricing-rest { display: inline-block; }
.pricing-tags { container-type: inline-size; display: flex; flex-direction: column; min-inline-size: 0; border: 1px solid var(--line); border-radius: var(--site-pane); background: var(--room); box-shadow: var(--site-float); }
.pricing-tags li + li { border-block-start: 1px solid var(--line); }
.site a.pricing-tag { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0.25rem 1.5rem; padding: 1.75rem; border-radius: var(--site-pane); color: var(--ink); text-decoration: none; }
.site a.pricing-tag:hover .pricing-who b { text-decoration: underline; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
.pricing-who, .pricing-what { display: flex; flex-direction: column; gap: 0.2rem; }
.pricing-what { align-items: flex-end; gap: 0.7rem; text-align: end; }
.pricing-who b { font-size: 1.05rem; font-weight: 600; }
.pricing-tag small { color: var(--ink-soft); font-size: 0.875rem; line-height: 1.45; }
.pricing-what b { font: 700 clamp(2.4rem, 4.4vw, 3.2rem)/1 var(--display); white-space: nowrap; }
/* Where the card is narrow, beside the promise on a tablet or on a small phone: who over the price and its terms */
@container (inline-size < 20rem) {
  .site a.pricing-tag { grid-template-columns: minmax(0, 1fr); gap: 1.3rem; }
  .pricing-what { flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 0.2rem 0.6rem; text-align: start; }
}

/* What each AI costs */
.pricing-ways { inline-size: 100%; border: 1px solid var(--line); border-radius: var(--site-pane); border-collapse: separate; border-spacing: 0; background: var(--room); overflow: hidden; }
.pricing-ways :is(th, td) { padding: 1.15rem 1.5rem; text-align: start; vertical-align: middle; font-weight: 400; }
.pricing-ways thead th { padding-block: 0.7rem; background: var(--room-2); color: var(--ink-soft); font-size: 0.8125rem; font-weight: 600; }
.pricing-ways tbody :is(th, td) { border-block-start: 1px solid var(--line); }
.pricing-ways td:last-child { color: var(--ink-soft); }
.pricing-way { display: flex; align-items: center; gap: 0.6rem; font-size: 1.05rem; font-weight: 600; }
.pricing-way .icon { color: var(--flame); }
/* Over its cell's own weight: the display face is bold at any, but a language it has no letters for falls back to the system's */
.pricing-ways .pricing-pay { font: 700 1.5rem/1.15 var(--display); }

/* An organisation's two prices, what the price comes to per person, and what is not for sale */
.pricing-cards { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); gap: 1.25rem; }
.pricing-cards > li { display: flex; flex-direction: column; align-items: flex-start; gap: 0.9rem; padding: 1.75rem; border: 1px solid var(--line-strong); border-radius: var(--site-pane); background: var(--room); }
.pricing-cards h4 { color: var(--ink-soft); font-size: 0.9375rem; }
.pricing-figure { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.2rem 0.6rem; margin-block-start: 0.6rem; }
.pricing-figure b { font: 700 clamp(2.4rem, 4.4vw, 3.2rem)/1.05 var(--display); }
.pricing-figure small { color: var(--ink-soft); font-size: 0.9375rem; }
.pricing-cards > li > .button { margin-block-start: auto; }
.pricing-ticks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6rem 1.5rem; inline-size: 100%; padding-block-end: 0.6rem; }
.pricing-per { display: flex; flex-direction: column; gap: 1rem; }
.pricing-per .site-stats span { color: var(--ink-soft); }
/* Under them, what a price per seat comes to, for comparison: its figure as large as theirs, so the eye sets them
   side by side, but in the soft ink, since it isn't Jean's; then what it is and where it was read */
.pricing-seat { display: grid; grid-template-columns: fit-content(15rem) minmax(0, 1fr); align-items: center; gap: 1rem 2.5rem; margin-block-start: 0.25rem; padding: 1.5rem; border: 1px solid var(--line); border-radius: var(--site-pane); }
.pricing-seat-figure { display: flex; flex-direction: column; gap: 0.6rem; color: var(--ink-soft); }
.pricing-seat-figure b { font: 700 clamp(2.2rem, 4vw, 3rem)/1 var(--display); white-space: nowrap; }
.pricing-seat-note { display: flex; flex-direction: column; gap: 0.4rem; color: var(--ink-soft); font-size: 0.9375rem; }
/* As many across as their titles fit in, so a title struck by hand stays on one line */
.pricing-nots { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); gap: 1.5rem 2.5rem; }
.pricing-nots li { display: flex; flex-direction: column; align-items: flex-start; gap: 0.4rem; }
.site .pricing-nots h4 { font: 700 1.5rem/1.2 var(--display); }
.pricing-nots p { color: var(--ink-soft); }

/* Your turn's other way, for whoever hosts it */
.pricing-other { color: var(--ink-soft); }

/* A tablet, a phone, or any narrow window: the promise and its prices side by side by halves, then one column, and
   each AI's row its name over what it costs and needs, each with its column's name, all of it still there */
@media (max-width: 68rem) {
  .pricing-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
@media (max-width: 52rem) {
  .pricing-hero, .pricing-cards, .pricing-ticks, .pricing-seat { grid-template-columns: minmax(0, 1fr); }
  /* The heading's link to itself follows its words here, and would drop below a part kept whole that wraps */
  .pricing-rest { display: inline; }
  .site a.pricing-tag { padding: 1.25rem; }
  .pricing-ways, .pricing-ways tbody { display: block; }
  .pricing-ways thead { display: none; }
  .pricing-ways tbody tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.75rem 1rem; padding: 1.15rem 1.25rem; }
  .pricing-ways tbody tr + tr { border-block-start: 1px solid var(--line); }
  .pricing-ways tbody :is(th, td) { display: block; padding: 0; border: 0; }
  .pricing-ways tbody th { grid-column: 1 / -1; }
  .pricing-ways td::before { content: attr(data-label); display: block; margin-block-end: 0.15rem; color: var(--ink-soft); font: 600 0.8125rem/1.4 var(--sans); }
  .pricing-ways .pricing-pay { font-size: 1.35rem; }
}
/* Where a struck title may take two lines, the pen's one stroke would pass between them: the type's own instead */
@media (max-width: 22.5rem) {
  .pricing-nots svg.felt-strike { display: none; }
  .pricing-nots h4 { text-decoration: line-through; }
}
@media (forced-colors: active) {
  .pricing-nots h4 { text-decoration: line-through; }
}
