/* Family Plan pages on the grown-ups site (kidsgamearcade.com): builds on /styles.css and /site.css (colors, .btn, .block,
   Fredoka). Light only, like the rest of the site. */
.family { display: flex; flex-direction: column; gap: 4px; }
.family h1 { margin-bottom: 4px; }
.family .muted, .family .small.muted { color: var(--muted); }
.family .small { font-size: 15px; }
.who { font-weight: 600; color: var(--muted); font-size: 15px; overflow-wrap: anywhere; }
.family .block { display: flex; flex-direction: column; gap: 12px; }
.family .block p { color: var(--text); }
.family .row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; justify-content: flex-start;
  /* the site's own .row (game cards, /styles.css) adds padding, a tint and a dashed rule: not here */
  padding: 0; margin-top: 0; background: none; border: 0; }
.family .between { justify-content: space-between; }
.family input[type=email], .family input[type=text], .family input[type=number], .family select, .family textarea {
  min-height: 48px; padding: 0 14px; border-radius: 14px; border: 3px solid var(--ink); background: #fff; color: var(--text);
  font: 500 17px "Fredoka", ui-rounded, system-ui, sans-serif; min-width: 0; flex: 1 1 220px; }
.family input[type=number] { flex: 0 0 7.5rem; }
.family select { flex: 0 1 220px; }
.family input:focus-visible, .family select:focus-visible { outline: 4px solid var(--purple); outline-offset: 3px; }
.family label { display: flex; gap: 12px; align-items: flex-start; font-weight: 600; }
.family label.field { flex-direction: column; gap: 6px; }
.family input[type=checkbox] { width: 24px; height: 24px; margin-top: 2px; flex: none; accent-color: var(--green); }
.family .consent { display: flex; flex-direction: column; gap: 12px; }
.family .notice { background: var(--soft); border: 2px dashed var(--ink); border-radius: 16px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.family .notice ul { margin: 0; padding-left: 22px; }
.family .notice li { margin: 4px 0; }
.btn.danger { background: #fff; color: var(--red); border-color: var(--red); box-shadow: 0 4px 0 var(--red); }
.family .bar { height: 16px; border-radius: 999px; background: #fff; border: 3px solid var(--ink); overflow: hidden; }
.family .bar > i { display: block; height: 100%; background: var(--yellow); }
.family .pill { font-weight: 700; font-size: 14px; padding: 3px 12px; border-radius: 999px; border: 2px solid var(--ink); background: #fff; }
.family .pill.ok { background: var(--green); color: #fff; }
.family .pill.warn { background: var(--yellow); }
.family .code { font: 700 30px/1 ui-monospace, Menlo, Consolas, monospace; letter-spacing: 0.18em; background: #fff; border: 3px solid var(--ink); padding: 10px 16px; border-radius: 14px; align-self: flex-start; }
.family .kids { display: flex; flex-direction: column; }
.family details summary { cursor: pointer; font-weight: 700; min-height: 32px; }
.family .log { display: flex; flex-direction: column; max-height: 440px; overflow-y: auto; border: 2px solid var(--ink); border-radius: 14px; background: #fff; margin-top: 8px; }
.family .log .entry { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr); gap: 10px; padding: 10px 12px; border-top: 2px dashed #e7cf86; font-size: 16px; }
.family .log .entry:first-child { border-top: 0; }
.family .log .when { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.family .log .text { white-space: pre-wrap; overflow-wrap: anywhere; }
.family .log .kind-prompt .text { font-weight: 700; }
.family .log .kind-flag .text { color: #a35a00; }
.family .log .kind-reply .text { color: var(--muted); }
.family .error { color: #c0392b; font-weight: 600; }
.family .draft { align-self: flex-start; background: var(--yellow); border: 2px solid var(--ink); border-radius: 999px; padding: 4px 14px; font-weight: 700; margin-top: 18px; }
@media (max-width: 520px) { .family .log .entry { grid-template-columns: 1fr; gap: 2px; } }
.family .log .kind-report .text { color: #c0392b; font-weight: 700; }

/* the purchase screen: headline, price, statements, checkbox and button all on the first screen */
.family .buy { display: flex; flex-direction: column; gap: 6px; }
.family .buy h1 { margin: 14px 0 0; }
.family .buy .lead { margin: 0; font-size: 19px; }
.family .buy .lead { text-wrap: pretty; max-width: none; }
.family h1, .family h2 { text-wrap: balance; }
/* four perks: an even 2 x 2 grid (one column on phones), never 3 + 1 */
.family .checks.perks-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; margin: 8px 0 0; }
@media (max-width: 560px) { .family .checks.perks-list { grid-template-columns: 1fr; } }
/* the pay box reads top to bottom: price, terms box, button, fine print */
.family .paybox { margin-top: 14px; gap: 12px; }
.family .paybox .btn.big { align-self: flex-start; }
@media (max-width: 560px) { .family .paybox .btn.big { align-self: stretch; } }
.family .price { margin: 0; font-size: 40px; font-weight: 700; line-height: 1; }
.family .price small { font-size: 18px; font-weight: 600; color: var(--muted); }
.family .agree span { flex: 1; min-width: 0; }
.family .linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--ink); text-decoration: underline; cursor: pointer; }
.family .consent { gap: 10px; margin-top: 10px; }
.family .confirm-head { margin: 0; }
.family .confirm { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 3px; font-size: 16px; }
.family .agree { font-size: 18px; padding: 10px 12px; background: var(--soft); border: 2px solid var(--ink); border-radius: 14px; align-items: center; }
.family .agree input { margin-top: 0; }
.family .fine { margin: 0; font-size: 14px; color: var(--muted); }
.family .fine b { color: var(--text); }
.family .collect summary { list-style: none; cursor: pointer; }
.family .collect summary::-webkit-details-marker { display: none; }
.family .collect summary h2 { display: inline; font-size: 19px; }
.family .collect summary::after { content: " ▸"; font-weight: 700; }
.family .collect[open] summary::after { content: " ▾"; }
.family .collect ul { margin: 0; padding-left: 22px; }
.family details.collect { display: block; }
.family details.collect > * + * { margin-top: 10px; }
.family .agree span { text-wrap: pretty; }

/* a kid's games: a list of rows (tile, name and status, actions) */
.family .gsection h3 { margin: 4px 0 8px; font-size: 18px; }
.family .gsection h3 .muted { font-weight: 600; font-size: 15px; }
.family .games { list-style: none; margin: 0; padding: 0; border: 2px solid var(--ink); border-radius: 16px; background: #fff; overflow: hidden; }
.family .game { padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.family .game + .game { border-top: 2px dashed #e7cf86; }
.family .gmain { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.family .gtile { width: 44px; height: 44px; border-radius: 12px; border: 2px solid var(--ink); display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 22px; -webkit-text-stroke: .5px var(--ink); }
.family .gtext { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.family .gname { font-size: 17px; overflow-wrap: anywhere; }
.family .gmeta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.family .gstatus { font-weight: 700; color: var(--muted); }
.family .gnote { margin: 0; font-size: 14px; color: #a35a00; }
.family .gactions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
.family .gactions .btn { white-space: nowrap; }
.family .game form.submit { display: flex; flex-direction: column; gap: 8px; border-top: 2px dashed #e7cf86; padding-top: 10px; }
.family .game form.submit[hidden] { display: none; }
@media (max-width: 600px) {
  .family .gmain { grid-template-columns: 44px minmax(0, 1fr); }
  .family .gactions { grid-column: 1 / -1; justify-content: flex-start; }
}
.family label.field input, .family label.field select { flex: none; }
.family .tags { display: flex; flex-wrap: wrap; gap: 8px; }
.family .tag { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; padding: 3px 4px 3px 12px; border: 2px solid var(--ink); border-radius: 999px; background: var(--soft); }
.family .tag button { font: inherit; font-weight: 700; border: 0; background: none; cursor: pointer; padding: 0 6px; border-radius: 999px; }
.family .tag button:hover { background: #fff; }
.family .log .kind-blocked .text { color: #c0392b; }
.family .pair { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 16px; align-items: center; }
.family .pair .qr { background: #fff; border: 3px solid var(--ink); border-radius: 14px; padding: 6px; }
.family .pair .qr svg { display: block; width: 100%; height: auto; }
.family .pair p { margin: 0 0 6px; }
@media (max-width: 520px) { .family .pair { grid-template-columns: 1fr; } .family .pair .qr { max-width: 200px; } }
.family .row.end { justify-content: flex-end; }
.family .logactions { margin-top: 8px; }
.confirm-box { border: 3px solid var(--ink); border-radius: 20px; box-shadow: 0 6px 0 var(--ink); padding: 20px 22px; max-width: min(440px, calc(100vw - 32px)); background: #fff; color: var(--text); font-family: "Fredoka", ui-rounded, system-ui, sans-serif; }
.confirm-box::backdrop { background: rgba(43, 27, 14, 0.45); }
.confirm-box h2 { margin: 0 0 8px; font-size: 22px; }
.confirm-box p { margin: 0 0 16px; }
.confirm-box .row { display: flex; gap: 10px; justify-content: flex-end; }
.family .pair .code { display: inline-block; margin: 4px 0 8px; }
.family .limit .row { flex-wrap: nowrap; }
.family .limit .unit { font-weight: 700; white-space: nowrap; }
.family .limit input[type=number] { flex: 0 0 7.5rem; }

/* contact form */
.family textarea { width: 100%; resize: vertical; min-height: 140px; padding: 12px 14px; line-height: 1.45; }
#contact { gap: 16px; }
#contact input[type=email], #contact select { width: 100%; max-width: 420px; flex: none; }
#turnstile { min-height: 65px; }

/* one-page sign-up: Stripe's checkout mounts under the boxes */
.family .checkout { min-height: 420px; margin-top: 4px; border-radius: 16px; overflow: hidden; }
.family .already { margin: -6px 0 6px; }
.family .agree input:disabled + span { opacity: .75; }

/* extra sparks: three packs, each a button; the purchase is confirmed in a box first */
.family .topup { border-top: 2px dashed #e7cf86; padding-top: 12px; margin-top: 4px; }
.family .topup h3 { margin: 0; font-size: 18px; color: var(--ink); }
.family .packs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 10px 0 6px; }
.family .pack { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 12px 8px; border: 3px solid var(--ink); border-radius: 16px; background: #fff; box-shadow: 0 4px 0 var(--ink); font: inherit; color: var(--ink); cursor: pointer; }
.family .pack:hover { background: var(--soft); } .family .pack:focus-visible { outline: 4px solid var(--purple); outline-offset: 3px; }
.family .pack b { font-size: 17px; } .family .pack span { font-size: 20px; font-weight: 700; color: var(--green); -webkit-text-stroke: .4px var(--ink); }
@media (max-width: 480px) { .family .packs { grid-template-columns: 1fr; } }
.notice-ok { background: #dcf8e6; border: 2px solid var(--ink); border-radius: 14px; padding: 10px 14px; font-weight: 600; }

/* the family page in tabs: Sparks · Kids · Moderation · Bug reports · Account */
.family .ftabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 4px 0 2px; }
.family .ftabs button { font: 700 16px "Fredoka", ui-rounded, system-ui, sans-serif; color: var(--ink); padding: 8px 16px; border: 3px solid var(--ink); border-radius: 999px; background: #fff; cursor: pointer; box-shadow: 0 3px 0 var(--ink); }
.family .ftabs button[aria-selected="true"] { background: var(--yellow); }
.family .ftabs button:focus-visible { outline: 4px solid var(--purple); outline-offset: 3px; }
.family .panel { display: flex; flex-direction: column; gap: 18px; }
@media (max-width: 480px) { .family .ftabs button { padding: 6px 12px; font-size: 15px; } }
/* bug report form */
.family .bugform { display: flex; flex-direction: column; gap: 12px; }
.family .bugform select { align-self: flex-start; }
.family .ok { color: #1d7a45; font-weight: 600; }
/* no kids yet: three steps */
.family .steps-kids { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.family .steps-kids li { counter-increment: step; display: flex; flex-direction: column; gap: 4px; padding: 12px; border: 2px dashed var(--ink); border-radius: 14px; background: var(--bg); }
.family .steps-kids li::before { content: counter(step); width: 28px; height: 28px; border-radius: 50%; background: var(--green); color: #fff; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--ink); }
.family .steps-kids b { color: var(--ink); } .family .steps-kids span { font-size: 14px; color: var(--muted); }
@media (max-width: 600px) { .family .steps-kids { grid-template-columns: 1fr; } }

/* a kid asked to send a game: the parent decides */
.family .asks { background: #fff3c4; border: 3px solid var(--ink); border-radius: 16px; box-shadow: 0 4px 0 var(--ink); padding: 10px 16px; display: flex; flex-direction: column; gap: 4px; }
.family .asks p { margin: 0; }
.family .pill.ask { background: #fff3c4; border-color: var(--ink); }
.family .gnote.ok { color: #1d7a45; }

/* offer codes on the sign-up page, and the founding family badge */
.family .promo { margin: -4px 0 4px; }
.family .promo .row { margin-top: 4px; }
.family .promo input { flex: 0 1 220px; text-transform: uppercase; }
.family .price .was { color: var(--muted); font-size: 24px; font-weight: 600; margin-right: 6px; }
.family .pill.founder { background: var(--purple); color: #fff; border-color: var(--ink); }

/* Go live off */
.family .pack:disabled { opacity: .7; cursor: default; box-shadow: none; }
.family #pay:disabled { opacity: .75; cursor: default; }
