/* KeepGlide page rules (redesign 2026-11, DEC-W82): the layouts of the Bento pages and the utility pages.
   Load after /styles.css. Every value comes from a token in /styles.css (Index tokens); reuse the Index
   components first and add here only what they do not cover. No colour literals. */

/* 1. Bento tiles: the grid itself is in /styles.css (.bento, .bento__feature). These add the tile sizes. */
.bento > .bento__tile { min-width: 0; }
.bento > .bento__wide { grid-column: span 2; min-width: 0; }
.bento > .bento__xwide { grid-column: span 3; min-width: 0; }
.bento > .bento__full { grid-column: span 4; min-width: 0; }
.bento > .bento__tile > .pill { align-self: flex-start; }

.bento__head {
  display: flex;
  align-items: center;
  gap: var(--element-gap);
  min-width: 0;
}
.bento__head .card__title,
.bento__head .os-tile__name { margin: 0; }
.bento__icon {
  flex: none;
  width: var(--space-48);
  height: var(--space-48);
}

@media (max-width: 939px) {
  .bento > .bento__wide,
  .bento > .bento__xwide,
  .bento > .bento__full { grid-column: 1 / -1; }
}
@media (max-width: 767px) {
  .bento > .bento__wide,
  .bento > .bento__xwide,
  .bento > .bento__full,
  .bento > .bento__tile { grid-column: auto; }
}

/* 2. Forms: /styles.css sets the form gap only; the page grid sets the layout. */
form.form { display: grid; gap: var(--space-16); }
.waitlist-tile .form { max-width: 40rem; }
.waitlist__error,
.form__note.waitlist__error { color: var(--accent-coral); }
/* The invalid email field takes the same colour as its error text. */
.form__input[aria-invalid="true"] { border-color: var(--accent-coral); }
/* The waitlist form draws the card's own border and radius. */
.waitlist.form { border: inherit; border-radius: inherit; }
.waitlist__hp {
  position: absolute;
  width: var(--size-hairline);
  height: var(--size-hairline);
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.form__status { min-height: var(--space-24); }
.form__status[data-state="ok"] { color: var(--color-ok); }
.form__status[data-state="error"] { color: var(--accent-coral); }

/* 3. Download page (/desktop/get): the mark, the notes under the hero, the Linux tile. */
.get__mark {
  width: 96px;
  height: 96px;
  margin-bottom: var(--space-8);
}
.get__notify { color: var(--text-ash); font-size: var(--text-small); }
.hero .hero__actions { margin-top: var(--space-8); }

/* 4. Text helpers used by the legal and waitlist copy. */
.nowrap { white-space: nowrap; }

/* 5. Alias kept for the AppImage button that src/pages.js still emits (outside this change's scope).
   Same look as .button--cta; remove once src/pages.js uses .button--cta. */
.button--hero {
  border-color: transparent;
  background: var(--gradient-cta);
  color: var(--color-on-cta);
}
.button--hero:hover { background: var(--gradient-cta); border-color: var(--border-iris); filter: brightness(1.08); }

/* 6. Bento grid: /styles.css (LEGACY block) sets .bento to one column later in the file; restate the Index grid here
   so these pages keep 4 / 2 / 1 columns until the LEGACY block is deleted. */
.bento { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-12); }
@media (max-width: 939px) { .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px) { .bento { grid-template-columns: minmax(0, 1fr); } }

/* 7. Breadcrumb kicker of the app sections: a 44px tap target on phones, and the product name keeps its case
   (the Index .kicker a rule does not reach these links, which sit in a .card__note paragraph). */
@media (max-width: 479px) {
  .card__note > a[data-testid="kicker-desktop"] { display: inline-flex; align-items: center; min-height: 44px; text-transform: none; }
  [data-testid="cta"] p a { display: inline-flex; align-items: center; min-height: 44px; }
}

/* 8. The About CTA heading balances its lines, as the Index gives .cta h2 and .section-head h2. */
#cta-title { text-wrap: balance; }

/* 9. Page art (images and their prompts: docs/images-2026-11-pages.md). Decorative, so alt is empty. */
.page-art { margin: 0 auto var(--space-24); max-width: 28rem; }
.page-art img { display: block; width: 100%; height: auto; border-radius: var(--radius-card); }
.get-hero { background: url("/assets/pages/get-hero-orbit-sunrise.webp") right center / cover no-repeat; }
[data-testid="platforms"] .card { background-image: url("/assets/pages/get-bento-texture.webp"); background-size: cover; }

/* 10. Donate page, Pix card (DEC-W58, L8). Suggested amounts are native radios; each option shows its own QR and code.
   Unselected panels are hidden with the sibling selectors below, so the card works without JavaScript. */
.pix-status { margin: var(--space-xs) 0 0; color: var(--color-text); font-size: var(--font-size-md); }
.pix-status:empty { margin: 0; }
.pix-amounts { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-sm); margin: var(--space-md) 0 0; padding: 0; border: 0; min-width: 0; }
.pix-amounts__legend { flex-basis: 100%; margin-bottom: var(--space-xs); padding: 0; color: var(--color-strong); font-size: var(--font-size-md); font-weight: var(--weight-medium); }
.pix-amounts .chip { font-size: var(--font-size-md); }
.pix-amounts__input:checked + .chip { background: var(--color-selected); border-color: var(--color-accent); color: var(--color-accent-text); font-weight: var(--weight-medium); }
.pix-amounts__input:focus-visible + .chip { outline: var(--focus-width) solid var(--color-accent); outline-offset: var(--focus-offset); }
.pix-panels { flex-basis: 100%; }
.pix-panel { display: none; flex-wrap: wrap; align-items: flex-start; gap: var(--space-md); margin-top: var(--space-md); }
#pix-amount-any:checked ~ .pix-panels > #pix-panel-any,
#pix-amount-10:checked ~ .pix-panels > #pix-panel-10,
#pix-amount-25:checked ~ .pix-panels > #pix-panel-25,
#pix-amount-50:checked ~ .pix-panels > #pix-panel-50 { display: flex; }
.pix-panel__qr { box-sizing: border-box; display: block; width: 200px; max-width: 100%; height: auto; padding: var(--space-sm); background: var(--text-bone); border-radius: var(--radius-sm); }
.pix-panel__code { display: flex; flex: 1 1 14rem; flex-direction: column; align-items: flex-start; gap: var(--space-sm); min-width: 0; }
.pix-panel__text { display: block; max-width: 100%; font-size: var(--font-size-md); overflow-wrap: anywhere; white-space: normal; }

/* 9. Donate (DEC-W111): a page hero with no card; the Pix card is the main card and Other ways sits beside it
   from 940 px, stacked below it on phones. align-items: start, so no card stretches to its neighbour.
   Reading text is 1rem (16 px), not the 15 px card text. */
.donate-hero { display: grid; gap: var(--space-12); align-items: center; }
.donate-hero__copy { min-width: 0; }
.donate-hero__art { justify-self: center; max-width: 20rem; margin: 0; }
.donate-grid { display: grid; gap: var(--space-12); align-items: start; grid-template-columns: minmax(0, 1fr); }
.donate-grid .card p { font-size: var(--font-size-md); }
.donate-thanks { margin-top: var(--space-12); }
@media (min-width: 940px) {
  .donate-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 20rem); }
  .donate-grid { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
}
