/* KIDS V2 preview form (12 Nov 2026): 1 / 2 / 3 children, every child the same card and the same fields.
   Tokens come from base.css (4 / 8 px spacing, durations + easings, warm light palette). No raw px for spacing, no default easing. */
.k3 { min-height: 100dvh; display: flex; flex-direction: column; }
.k3-top { position: sticky; top: 0; z-index: 10; background: rgba(252, 246, 236, .94); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.k3-top-in { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); max-width: 640px; margin-inline: auto; padding: var(--s-2) var(--s-4); }
.k3-brand { display: inline-flex; align-items: center; gap: var(--s-2); text-decoration: none; color: var(--ink); font: 600 18px/1 var(--f-display); letter-spacing: -0.02em; }
.k3-brand img { border-radius: 50%; }
.k3-brand b { color: var(--wax); font-weight: 600; }
.k3-step { font-size: var(--t-sm); font-weight: 600; color: var(--ink-2); font-variant-numeric: tabular-nums; text-align: right; }
.k3-bar { height: 4px; background: var(--frost); }
.k3-bar i { display: block; height: 100%; width: 100%; background: var(--wax); transform-origin: left; transform: scaleX(.1); transition: transform var(--d-panel) var(--e-std); }
.k3-main { flex: 1; width: 100%; max-width: 640px; margin-inline: auto; padding: var(--s-6) var(--s-4) var(--s-12); outline: none; }
.k3-foot { padding: var(--s-4); text-align: center; font-size: var(--t-sm); color: var(--muted); }

/* layout primitives */
.k3-stack { display: flex; flex-direction: column; gap: var(--gap, var(--s-4)); }
.k3-cluster { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2); }

.k3-h { font-size: clamp(24px, 4.4vw + 8px, 32px); line-height: 1.08; letter-spacing: -0.03em; text-wrap: balance; }
.k3-lead { color: var(--ink-2); text-wrap: pretty; }
.k3-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s-5) var(--s-4); box-shadow: var(--shadow-1); }
.k3-note { padding: var(--s-3) var(--s-4); border-radius: var(--r-md); background: var(--gold-wash); color: var(--ink-2); font-size: var(--t-sm); text-wrap: pretty; }
.k3-preview { align-self: flex-start; padding: var(--s-1) var(--s-3); border-radius: var(--r-pill); background: var(--pine-wash); color: var(--pine); font-size: var(--t-xs); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }

/* how many children: three equal buttons */
.k3-seg { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: var(--s-2); }
.k3-seg:has(> [data-n="4"]) { grid-template-columns: repeat(2, minmax(0, 1fr)); } /* four children (SANTA_KIDS4_LANGS): 2 x 2 */
@media (min-width: 600px) { .k3-seg:has(> [data-n="4"]) { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.k3-seg button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s-1); min-height: 80px; padding: var(--s-3) var(--s-2); border-radius: var(--r-md); border: 1.5px solid var(--line-2); background: #fff; cursor: pointer; color: var(--ink);
  transition: border-color var(--d-hover) var(--e-std), background-color var(--d-hover) var(--e-std), box-shadow var(--d-hover) var(--e-std), transform var(--d-tap) var(--e-std); }
.k3-seg button b { font: 600 var(--t-md)/1.2 var(--f-ui); }
.k3-seg button span { font-size: var(--t-sm); color: var(--muted); font-variant-numeric: tabular-nums; }
.k3-seg button:active { transform: scale(.98); }
.k3-seg button[aria-checked="true"] { border-color: var(--wax); background: var(--wax-wash); box-shadow: 0 0 0 3px var(--wax-wash); }
.k3-seg button[aria-checked="true"] b, .k3-seg button[aria-checked="true"] span { color: var(--wax-dark); }

/* the children: equal cards, always (grid-auto-rows: 1fr) */
.k3-kids { display: grid; grid-template-columns: minmax(0, 1fr); grid-auto-rows: 1fr; gap: var(--s-3); }
.k3-kid { display: flex; flex-direction: column; gap: var(--s-2); padding: var(--s-4); border-radius: var(--r-md); border: 1px solid var(--line); background: var(--snow); }
.k3-kid-h { font: 600 var(--t-md)/1.2 var(--f-display); color: var(--ink-2); }
@media (min-width: 600px) { .k3-kids.n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .k3-kids.n3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* fields */
.k3-fld { display: flex; flex-direction: column; gap: var(--s-2); min-width: 0; }
.k3-label { font-weight: 600; color: var(--ink); }
.k3-label .opt { font-weight: 500; color: var(--muted); }
.k3-label .req { font-size: var(--t-xs); font-weight: 700; color: var(--wax-dark); background: var(--wax-wash); padding: 0 var(--s-2); border-radius: var(--r-pill); margin-left: var(--s-1); white-space: nowrap; }
.k3-hint { font-size: var(--t-sm); color: var(--muted); text-wrap: pretty; }
.k3-hint:empty { display: none; }
/* the gentle girl / boy vs name question (copii.js gHint): a soft note, never an error */
.k3-soft { color: var(--ink-2); background: var(--frost); border-radius: var(--r-md); padding: var(--s-2) var(--s-3); }
.k3-row > .k3-soft { grid-column: 1 / -1; }
.k3-gnote.off, .k3-keep { visibility: hidden; } /* keep their place (picking «Fată» / «Băiat» moves nothing) */
.k3-keep { pointer-events: none; }
.k3-err { font-size: var(--t-sm); font-weight: 600; color: var(--wax); text-wrap: pretty; }
.k3-err:empty { display: none; }
.k3-inp { width: 100%; min-height: 48px; padding: var(--s-3) var(--s-4); border-radius: var(--r-md); border: 1.5px solid var(--line-2); background: #fff; font-size: var(--t-md); color: var(--ink);
  transition: border-color var(--d-hover) var(--e-std), box-shadow var(--d-hover) var(--e-std); }
.k3-inp::placeholder { color: #9A8676; }
.k3-inp:focus { outline: none; border-color: var(--wax); box-shadow: 0 0 0 3px var(--wax-wash); }
.k3-inp[aria-invalid="true"] { border-color: var(--wax); }
textarea.k3-inp { min-height: 96px; resize: vertical; font-family: inherit; line-height: 1.5; }
.k3-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--s-4); align-items: start; }
.k3-age { position: relative; }
.k3-age .k3-inp { padding-right: var(--s-12); }
.k3-age span { position: absolute; right: var(--s-4); top: 50%; transform: translateY(-50%); font-size: var(--t-sm); color: var(--muted); pointer-events: none; }

/* chips */
.k3-chip { display: inline-flex; align-items: center; gap: var(--s-2); min-height: 44px; padding: var(--s-2) var(--s-4); border-radius: var(--r-pill); border: 1.5px solid var(--line-2); background: #fff; color: var(--ink); font-size: var(--t-sm); font-weight: 500; cursor: pointer; text-align: left;
  transition: border-color var(--d-hover) var(--e-std), background-color var(--d-hover) var(--e-std), color var(--d-hover) var(--e-std), transform var(--d-tap) var(--e-std); }
.k3-chip:active { transform: scale(.98); }
.k3-chip[aria-pressed="true"], .k3-chip[aria-checked="true"] { border-color: var(--wax); background: var(--wax-wash); color: var(--wax-dark); font-weight: 600; }
.k3-chip[disabled] { opacity: .5; cursor: default; }
.k3-chip svg { width: 16px; height: 16px; flex: none; }
.k3-chip.more { border-style: dashed; color: var(--wax-dark); background: transparent; font-weight: 600; }
.k3-two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: var(--s-2); }
.k3-two .k3-chip { justify-content: center; }
.k3-add { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--s-2); }

/* child tabs: every child the same pill */
.k3-tabs { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: var(--s-2); }
.k3-tab { display: flex; align-items: center; justify-content: center; gap: var(--s-1); min-height: 44px; padding: var(--s-1) var(--s-2); border-radius: var(--r-pill); border: 1.5px solid var(--line); background: var(--card); color: var(--ink-2); font-size: var(--t-sm); font-weight: 600; cursor: pointer; overflow: hidden;
  transition: border-color var(--d-hover) var(--e-std), background-color var(--d-hover) var(--e-std), color var(--d-hover) var(--e-std); }
.k3-tab span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.k3-tab svg { width: 16px; height: 16px; flex: none; color: var(--pine); }
.k3-tab[aria-current="step"] { border-color: var(--wax); background: var(--wax-wash); color: var(--wax-dark); }

/* photos: equal squares */
.k3-ups { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: var(--s-2); }
.k3-up { position: relative; aspect-ratio: 1; border-radius: var(--r-md); overflow: hidden; background: var(--snow); }
.k3-up img { width: 100%; height: 100%; object-fit: cover; }
.k3-up label { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s-1); width: 100%; height: 100%; padding: var(--s-2); border-radius: var(--r-md); border: 1.5px dashed var(--line-2); color: var(--wax-dark); text-align: center; font-size: var(--t-xs); font-weight: 600; line-height: 1.25; cursor: pointer;
  transition: border-color var(--d-hover) var(--e-std), background-color var(--d-hover) var(--e-std); }
.k3-up label:hover, .k3-up label:focus-within { border-color: var(--wax); background: #FFFBFA; }
.k3-up.main label { border-style: solid; border-color: var(--wax); background: #FFFBFA; }
.k3-up label svg { width: 24px; height: 24px; }
.k3-up.busy img { opacity: .5; }
.k3-up .sp { position: absolute; inset: 0; margin: auto; width: 28px; height: 28px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .7); border-top-color: var(--wax); animation: k3spin 800ms var(--e-std) infinite; }
.k3-up .x { position: absolute; top: 0; right: 0; display: flex; align-items: flex-start; justify-content: flex-end; width: 44px; height: 44px; padding: var(--s-1); border: 0; background: none; cursor: pointer; } /* a finger's 44 px in the corner */
.k3-up .x .xb { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: rgba(255, 253, 249, .94); color: var(--ink); box-shadow: var(--shadow-1); transition: transform var(--d-tap) var(--e-std); } /* the visible badge stays small, off the face */
.k3-up .x:active .xb { transform: scale(.9); }
.k3-up .x svg { width: 12px; height: 12px; }
.k3-up.wide { grid-column: 1 / -1; aspect-ratio: 16 / 9; background: var(--frost); }
.k3-up.wide img { object-fit: contain; } /* «o poză cu toți»: the whole group shows, not a square cut from its middle */
@keyframes k3spin { to { transform: rotate(360deg); } }

/* buttons */
.k3-btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2); width: 100%; min-height: 56px; padding: var(--s-3) var(--s-6); border: 0; border-radius: var(--r-pill); background: var(--wax); color: #fff; font: 700 var(--t-lg)/1.2 var(--f-ui); cursor: pointer; box-shadow: var(--shadow-2); font-variant-numeric: tabular-nums;
  transition: background-color var(--d-hover) var(--e-std), transform var(--d-tap) var(--e-std), box-shadow var(--d-hover) var(--e-std); }
.k3-btn:hover { background: var(--wax-hi); }
.k3-btn:active { transform: scale(.98); }
.k3-btn[disabled] { opacity: .6; cursor: default; }
.k3-btn svg { width: 20px; height: 20px; }
.k3-link { align-self: center; min-height: 44px; padding: var(--s-2) var(--s-3); border: 0; background: none; color: var(--wax-dark); font-weight: 600; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
.k3-ghost { min-height: 48px; padding: var(--s-2) var(--s-4); border-radius: var(--r-md); border: 1.5px solid var(--line-2); background: #fff; color: var(--wax-dark); font-weight: 600; cursor: pointer; transition: border-color var(--d-hover) var(--e-std); }
.k3-ghost:hover { border-color: var(--wax); }

/* town list */
.k3-cityin { position: relative; } /* the list opens right under the field, over the hint lines */
.k3-list { position: absolute; left: 0; right: 0; top: 100%; z-index: 5; margin: var(--s-1) 0 0; padding: var(--s-1); list-style: none; background: #fff; border: 1px solid var(--line-2); border-radius: var(--r-md); box-shadow: var(--shadow-2); }
.k3-list li { min-height: 44px; display: flex; align-items: center; padding: var(--s-2) var(--s-3); border-radius: var(--r-sm); cursor: pointer; }
.k3-list li:hover, .k3-list li[aria-selected="true"] { background: var(--wax-wash); }
.k3-list small { color: var(--muted); margin-left: var(--s-2); }

/* optional extras */
.k3-more > summary { display: flex; align-items: center; justify-content: space-between; gap: var(--s-2); min-height: 48px; cursor: pointer; font-weight: 600; color: var(--wax-dark); list-style: none; }
.k3-more > summary::-webkit-details-marker { display: none; }
.k3-more > summary svg { width: 16px; height: 16px; transition: transform var(--d-hover) var(--e-std); }
.k3-more[open] > summary svg { transform: rotate(180deg); }

/* pay step: one equal card per child */
.k3-sum { display: grid; grid-template-columns: minmax(0, 1fr); grid-auto-rows: 1fr; gap: var(--s-2); }
.k3-sumkid { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: var(--s-1) var(--s-3); align-items: center; padding: var(--s-3) var(--s-3) 0; /* the link's own 44 px tap height is the bottom space */ border-radius: var(--r-md); border: 1px solid var(--line); background: var(--snow); }
.k3-sumkid img, .k3-sumkid .ph { width: 56px; height: 56px; border-radius: var(--r-sm); object-fit: cover; background: var(--frost); }
.k3-sumkid b { display: block; font: 600 var(--t-md)/1.2 var(--f-display); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.k3-sumkid small { display: block; color: var(--muted); font-size: var(--t-sm); line-height: 1.35; text-wrap: pretty; }
.k3-sumkid .k3-link { grid-column: 2; justify-self: start; align-self: end; min-height: 44px; padding: var(--s-3) 0; font-size: var(--t-sm); line-height: 1.4; }
.k3-sumkid img, .k3-sumkid .ph { grid-row: span 2; align-self: start; }
.k3-lines { display: flex; flex-direction: column; gap: var(--s-2); margin: 0; }
.k3-lines div { display: flex; justify-content: space-between; gap: var(--s-4); }
.k3-lines dt { color: var(--ink-2); text-wrap: pretty; }
.k3-lines dd { margin: 0; font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 600; }
.k3-lines .tot { padding-top: var(--s-3); border-top: 1px solid var(--line); font-size: var(--t-lg); }
.k3-lines .tot dt { color: var(--ink); font-weight: 700; }
.k3-lines .tot .k3-vat { font-weight: 400; font-size: var(--t-sm, 14px); color: var(--muted, #6B5646); } /* «inkl. MwSt.» (DE, shared-fix 14 Nov 2026) */
.k3-chk { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: var(--s-3); align-items: start; min-height: 44px; font-size: var(--t-sm); color: var(--ink-2); cursor: pointer; }
.k3-chk input { width: 24px; height: 24px; margin: 0; accent-color: var(--wax); }
.k3-chk .soft { color: var(--muted); }

/* go-live prep (12 Nov 2026): the price lines' discount, the inline link in a note, the list of things to check, the demo card */
.k3-lines .off dt, .k3-lines .off dd { color: var(--pine); font-weight: 600; }
.k3-link.k3-inl { display: inline; min-height: 0; padding: 0; }
.k3-errs { margin: var(--s-2) 0 0; padding-left: var(--s-5); }
.k3-demo { margin-top: 0; }
.k3-demo .k3-ghost { display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2); width: 100%; }
.k3-demo .k3-ghost svg { width: 16px; height: 16px; flex: none; }
.k3-demo .k3-chk { min-height: 0; }
.k3 .rd { margin-bottom: 0; }
.k3 .code-row { margin-top: calc(var(--s-2) * -1); }
.k3 .code-tog, .k3 .code-x { display: inline-flex; align-items: center; min-height: 44px; padding: var(--s-2) 0; } /* a finger's tap height */
.k3 .code-tog[hidden], .k3 .code-x[hidden] { display: none; }
.k3 .rm-l { margin-top: 0; }
.k3-card > .rm-l { margin-block: calc(var(--s-4) * -1); } /* the reminder line sits with the button above and «Înapoi» below (8 px each), not a card gap away */
/* «Moșul va citi așa», folded per child: the price and the pay button stay close; a corrected part is flagged */
.k3-rd { border-top: 1px solid var(--line); }
.k3-rd > summary { display: flex; align-items: center; gap: var(--s-2); min-height: 44px; padding: var(--s-2) 0; cursor: pointer; list-style: none; font-size: var(--t-sm); font-weight: 600; color: var(--wax-dark); }
.k3-rd > summary::-webkit-details-marker { display: none; }
.k3-rd > summary .t { flex: 1; min-width: 0; text-wrap: pretty; }
.k3-rd > summary .fx { flex: none; padding: var(--s-1) var(--s-2); border-radius: var(--r-pill); background: var(--gold-wash); color: var(--gold-ink); font-size: var(--t-xs); font-weight: 700; }
.k3-rd > summary svg { flex: none; width: 16px; height: 16px; transition: transform var(--d-panel) var(--e-std); }
.k3-rd[open] > summary svg { transform: rotate(180deg); }
.k3-rd[open] > .rd-list { padding-bottom: var(--s-3); animation: k3rd var(--d-panel) var(--e-std) both; }
@keyframes k3rd { from { opacity: 0; transform: translateY(calc(var(--s-2) * -1)); } to { opacity: 1; transform: none; } }
.k3 .rd { gap: var(--s-2); }

::view-transition-old(root) { animation-duration: var(--d-hover); animation-timing-function: var(--e-acc); }
::view-transition-new(root) { animation-duration: var(--d-panel); animation-timing-function: var(--e-dec); }
/* reduced motion: once, globally, in base.css */
