/*
 * Gymboland Magazin — store front-end styles (Sprint 2, extended Sprint 3 + 4).
 * Design system ported from the approved mockup (docs/Gymboland Magazin.html):
 * Fredoka (display) + Nunito (body), warm cream canvas, magenta accent, rounded playful cards.
 * Only the store CONTENT is styled here — the partner site provides the page chrome (this page
 * is embedded via <iframe>), so there is no header/nav/hero here (see plan §2.3).
 * Sprint 4 (US-4.2) adds the applied-code chip under "discount box" below; the input/button/error
 * states reuse the existing .gb-input, .gb-btn--purple and .gb-auth__error-style tokens.
 * T-4.3 adds .gb-state__spinner (the "Plata în curs…" polling panel) under "empty / loading / error
 * states" below -- every other payment-panel state (idle/paid/cancelled/expired/timeout) reuses
 * .gb-state/.gb-btn/.gb-auth__error as-is, no new classes needed.
 */

:root {
  /* palette */
  --bg: #fffaf2;
  --surface: #ffffff;
  --ink: #2f2a4a;
  --muted: #9a93a8;
  --muted-2: #8a86a0;
  --muted-3: #6b6580;
  --line: #f0e9da;        /* warm hairline */
  --line-lav: #efe9ff;    /* lavender input border */
  --accent: #d6286b;      /* primary CTA (magenta-pink) */
  --purple: #3a2b8c;      /* deep brand purple */
  --purple-2: #7b4fc4;
  --teal: #3fc1c9;
  --teal-ink: #199aa0;
  --teal-bg: #e6f7f7;
  --amber: #ff8a3d;

  /* section tints */
  --tint-bilete: #e6f7f7;
  --tint-petreceri: #fdeaf1;
  --tint-carduri: #fff3d6;

  /* type */
  --font-display: 'Fredoka', system-ui, -apple-system, Segoe UI, sans-serif;
  --font-body: 'Nunito', system-ui, -apple-system, Segoe UI, sans-serif;

  /* radii + shadow */
  --r-card: 20px;
  --r-ctrl: 12px;
  --r-input: 11px;
  --shadow-card: 0 4px 16px rgba(58, 43, 140, .05);
  --shadow-float: 0 12px 34px rgba(58, 43, 140, .10);
  --shadow-accent: 0 6px 16px rgba(214, 40, 107, .28);
}

* { box-sizing: border-box; }
html, body { margin: 0; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 600;
  -webkit-font-smoothing: antialiased;
}

.gb-store { max-width: 1180px; margin: 0 auto; padding: 24px 28px 72px; }

/* keyboard focus — visible everywhere (quality floor) */
:focus-visible { outline: 3px solid var(--purple-2); outline-offset: 2px; border-radius: 6px; }
button, input, select { font-family: inherit; }

/* scrollbars (cosmetic, matches mockup) */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #e3dccb; border-radius: 10px; }

/* ---------- buttons ---------- */
.gb-btn {
  border: none; cursor: pointer; font-family: var(--font-body); font-weight: 800;
  border-radius: 999px; display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 18px; font-size: 14px; line-height: 1; transition: filter .12s ease, transform .12s ease;
}
.gb-btn:hover { filter: brightness(1.06); }
.gb-btn:active { transform: translateY(1px); }
.gb-btn--accent { background: var(--accent); color: #fff; box-shadow: var(--shadow-accent); }
.gb-btn--purple { background: var(--purple); color: #fff; box-shadow: 0 4px 12px rgba(58, 43, 140, .28); }
.gb-btn--ghost { background: #fff; color: var(--purple); border: 2px solid var(--line-lav); }
.gb-btn--block { width: 100%; justify-content: center; border-radius: 14px; padding: 15px; font-size: 16px; font-weight: 900; }

/* ---------- location bar ---------- */
.gb-locbar {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-card);
  box-shadow: var(--shadow-float); padding: 18px 22px;
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
}
.gb-locbar__pin {
  width: 48px; height: 48px; border-radius: 14px; background: #efe9ff;
  display: flex; align-items: center; justify-content: center; font-size: 23px; flex: none;
}
.gb-locbar__info { flex: 1; min-width: 180px; }
.gb-locbar__eyebrow { font-size: 12.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.gb-locbar__name { font-family: var(--font-display); font-weight: 600; font-size: 21px; line-height: 1.15; }
.gb-locbar__name .city { color: var(--teal); font-size: 15px; }
.gb-locbar__lead { font-family: var(--font-display); font-weight: 600; font-size: 21px; line-height: 1.15; }
.gb-locbar__sub { color: var(--muted); font-weight: 600; font-size: 14.5px; }
.gb-locbar__actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* cart button + count badge */
.gb-cartbtn { position: relative; }
.gb-cartbtn__count {
  min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: #fff; color: var(--accent);
  font-size: 12px; font-weight: 900; display: inline-flex; align-items: center; justify-content: center;
}

/* ---------- catalog ---------- */
.gb-section { margin: 34px 0 10px; }
.gb-section__head { display: flex; align-items: flex-end; gap: 13px; margin: 0 0 20px; }
.gb-section__icon {
  width: 42px; height: 42px; border-radius: 13px; display: flex; align-items: center; justify-content: center;
  font-size: 21px; flex: none;
}
.gb-section__title { font-family: var(--font-display); font-weight: 700; font-size: 27px; margin: 0; line-height: 1; letter-spacing: -.01em; }
.gb-section__subtitle { color: var(--muted); font-weight: 600; font-size: 14.5px; }

.gb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 22px; }

.gb-card {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--r-card);
  overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow-card);
}
.gb-card__media {
  position: relative; flex: none; width: 100%; height: 152px; min-height: 120px;
  display: flex; align-items: center; justify-content: center;
}
.gb-card__photo-label {
  font-family: ui-monospace, monospace; font-size: 11.5px; color: #00000055;
  background: #ffffff8c; padding: 5px 9px; border-radius: 7px;
}
.gb-card__gift { display: flex; flex-direction: column; align-items: center; color: #fff; text-shadow: 0 2px 8px rgba(0, 0, 0, .18); }
.gb-card__gift-amount { font-family: var(--font-display); font-weight: 700; font-size: 46px; line-height: .9; }
.gb-card__gift-lei { font-weight: 800; font-size: 14px; letter-spacing: .18em; }
.gb-card__body { padding: 16px 17px 17px; display: flex; flex-direction: column; flex: 1; }
.gb-card__name { font-family: var(--font-display); font-weight: 600; font-size: 18.5px; margin: 0 0 5px; line-height: 1.15; }
.gb-card__sub { margin: 0 0 15px; color: var(--muted-2); font-weight: 600; font-size: 13.5px; line-height: 1.45; flex: 1; }
.gb-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.gb-card__price { font-family: var(--font-display); font-weight: 600; font-size: 21px; color: var(--ink); }
.gb-card__price small { display: block; font-family: var(--font-body); font-weight: 700; font-size: 11.5px; color: var(--muted); }
.gb-card__add {
  border: none; cursor: pointer; background: var(--accent); color: #fff; font-family: var(--font-body);
  font-weight: 800; font-size: 13.5px; padding: 10px 15px; border-radius: var(--r-ctrl);
  display: inline-flex; align-items: center; gap: 6px; box-shadow: 0 4px 11px rgba(214, 40, 107, .25);
}
.gb-card__add:hover { filter: brightness(1.06); }

/* party: dual purchase option (Plătesc integral / avansul) — required by plan US-2.2 */
.gb-card__options { display: flex; flex-direction: column; gap: 8px; }
.gb-opt {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  border: 2px solid var(--line-lav); background: #fbfaff; border-radius: var(--r-ctrl); padding: 9px 12px;
  cursor: pointer; text-align: left; width: 100%; font-family: var(--font-body); font-weight: 800; color: var(--ink);
}
.gb-opt:hover { border-color: var(--accent); }
.gb-opt__label { font-size: 13px; }
.gb-opt__label small { display: block; color: var(--muted); font-weight: 700; font-size: 11px; }
.gb-opt__price { font-family: var(--font-display); font-weight: 600; font-size: 16px; white-space: nowrap; }

/* badge (unused by data yet, kept for parity) */
.gb-badge {
  position: absolute; top: 11px; left: 11px; font-weight: 900; font-size: 11px; letter-spacing: .04em;
  padding: 5px 10px; border-radius: 999px; text-transform: uppercase;
}

/* ---------- empty / loading / error states ---------- */
.gb-state {
  text-align: center; padding: 64px 20px; border: 2px dashed #e6dcc6; border-radius: 24px; background: #fffdf8;
}
.gb-state__emoji { font-size: 52px; }
.gb-state__title { font-family: var(--font-display); font-weight: 600; font-size: 23px; margin: 14px 0 6px; }
.gb-state__text { color: var(--muted); font-weight: 600; max-width: 440px; margin: 0 auto 22px; }
.gb-float { animation: gbFloat 4s ease-in-out infinite; }
/* T-4.3: "Plata în curs…" polling panel spinner (bigger standalone sibling of the inline .gb-spinner
   used inside busy buttons -- same gbSpin keyframe, same palette tokens). */
.gb-state__spinner {
  width: 40px; height: 40px; margin: 6px auto 4px; border-radius: 50%;
  border: 4px solid var(--line-lav); border-top-color: var(--accent);
  animation: gbSpin .8s linear infinite;
}
.gb-skeleton {
  height: 300px; border-radius: var(--r-card); background: linear-gradient(100deg, #f4eee3 30%, #fbf7ef 50%, #f4eee3 70%);
  background-size: 200% 100%; animation: gbShimmer 1.3s linear infinite;
}

/* ---------- cart ---------- */
.gb-back {
  border: none; background: none; cursor: pointer; color: var(--purple-2); font-family: var(--font-body);
  font-weight: 800; font-size: 14.5px; display: inline-flex; align-items: center; gap: 7px; padding: 6px 0;
}
.gb-cart-title { font-family: var(--font-display); font-weight: 700; font-size: 32px; margin: 14px 0 4px; letter-spacing: -.01em; }
.gb-cart-sub { color: var(--muted-2); font-weight: 700; margin: 0 0 24px; }
.gb-cart-sub .city { color: var(--teal); }
.gb-cart-grid { display: grid; grid-template-columns: 1fr 360px; gap: 26px; align-items: start; }

.gb-line {
  display: flex; gap: 14px; align-items: center; padding: 13px 14px; border: 1px solid var(--line);
  border-radius: 16px; background: #fff; margin-bottom: 12px; box-shadow: 0 3px 12px rgba(58, 43, 140, .04);
}
.gb-line__media {
  width: 64px; height: 64px; border-radius: 13px; flex: none; display: flex; align-items: center; justify-content: center;
  color: #fff; font-family: var(--font-display); font-weight: 700; font-size: 18px; text-shadow: 0 1px 4px rgba(0, 0, 0, .2);
}
.gb-line__info { flex: 1; min-width: 0; }
.gb-line__name { font-family: var(--font-display); font-weight: 600; font-size: 17px; line-height: 1.15; }
.gb-line__unit { color: var(--muted); font-weight: 700; font-size: 13px; }
.gb-stepper { display: flex; align-items: center; gap: 2px; background: #f6f1e6; border-radius: 11px; padding: 4px; }
.gb-stepper button {
  width: 30px; height: 30px; border: none; background: #fff; border-radius: 8px; cursor: pointer;
  font-size: 18px; font-weight: 800; color: var(--purple-2); line-height: 1;
}
.gb-stepper button:hover { filter: brightness(.97); }
.gb-stepper__qty { min-width: 26px; text-align: center; font-family: var(--font-display); font-weight: 600; font-size: 16px; }
.gb-line__total { width: 96px; text-align: right; font-family: var(--font-display); font-weight: 600; font-size: 18px; }
.gb-line__remove {
  width: 32px; height: 32px; border: none; background: none; cursor: pointer; color: #c9c0d6; font-size: 16px; border-radius: 8px;
}
.gb-line__remove:hover { background: #fceef3; color: var(--accent); }

/* summary */
.gb-summary {
  position: sticky; top: 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-card);
  box-shadow: var(--shadow-float); padding: 22px 22px 24px;
}
.gb-summary__title { font-family: var(--font-display); font-weight: 600; font-size: 20px; margin: 0 0 16px; }
.gb-summary__row { display: flex; justify-content: space-between; margin-bottom: 11px; font-weight: 700; color: var(--muted-3); }
.gb-summary__row span:last-child { color: var(--ink); }
.gb-summary__row--discount { font-weight: 800; color: var(--teal-ink); }
.gb-summary__row--discount span { color: var(--teal-ink); }
.gb-summary__rule { height: 1px; background: var(--line); margin: 14px 0; }
.gb-summary__total { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 18px; }
.gb-summary__total .lbl { font-family: var(--font-display); font-weight: 600; font-size: 19px; }
.gb-summary__total .val { font-family: var(--font-display); font-weight: 700; font-size: 27px; color: var(--accent); }
.gb-summary__note { display: flex; align-items: center; gap: 8px; margin-top: 14px; color: var(--muted); font-weight: 700; font-size: 12.5px; }

/* discount box */
.gb-discount { margin-top: 18px; background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
.gb-discount__title { font-family: var(--font-display); font-weight: 600; font-size: 16px; margin-bottom: 11px; display: flex; align-items: center; gap: 8px; }
.gb-discount__row { display: flex; gap: 9px; }
.gb-input {
  border: 2px solid var(--line-lav); background: #fbfaff; border-radius: var(--r-input); padding: 11px 14px;
  font-family: var(--font-body); font-weight: 800; font-size: 14.5px; color: var(--ink); outline: none;
}
.gb-input--code { flex: 1; letter-spacing: .04em; text-transform: uppercase; }
.gb-discount__hint { color: #b6ae98; font-weight: 700; font-size: 12.5px; margin-top: 9px; }
.gb-discount__error { color: var(--accent); font-weight: 800; font-size: 12.5px; min-height: 1em; margin-top: 9px; }
/* applied-code chip (US-4.2) */
.gb-discount__applied {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  background: var(--teal-bg); border: 1px solid #bfe9e9; border-radius: var(--r-input); padding: 11px 14px;
}
.gb-discount__applied-label { display: flex; align-items: center; gap: 8px; font-weight: 800; color: var(--teal-ink); font-size: 13.5px; }
.gb-discount__check { font-size: 15px; }
.gb-discount__remove {
  border: none; background: none; cursor: pointer; color: var(--teal-ink); font-family: var(--font-body);
  font-weight: 800; font-size: 13px; text-decoration: underline; padding: 0;
}

/* ---------- location modal ---------- */
.gb-modal {
  position: fixed; inset: 0; z-index: 90; background: rgba(35, 26, 70, .5); backdrop-filter: blur(3px);
  display: flex; align-items: flex-start; justify-content: center; padding: 5vh 18px;
}
.gb-modal__panel {
  width: 560px; max-width: 100%; max-height: 86vh; background: var(--bg); border-radius: 24px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, .32); display: flex; flex-direction: column; overflow: hidden;
  animation: gbPop .16s ease;
}
.gb-modal__head { padding: 22px 24px 16px; border-bottom: 1px solid var(--line); background: #fff; }
.gb-modal__titlerow { display: flex; align-items: center; justify-content: space-between; }
.gb-modal__title { font-family: var(--font-display); font-weight: 600; font-size: 23px; margin: 0; }
.gb-modal__close {
  border: none; background: #f3eee2; width: 34px; height: 34px; border-radius: 50%; cursor: pointer;
  font-size: 17px; color: var(--muted-3);
}
.gb-search { margin-top: 14px; display: flex; align-items: center; gap: 10px; background: #f6f1e6; border: 1px solid #ece4d2; border-radius: 13px; padding: 11px 14px; }
.gb-search input { border: none; background: transparent; outline: none; font-family: var(--font-body); font-weight: 600; font-size: 15px; width: 100%; color: var(--ink); }
/* The input suppresses its own outline, so surface keyboard focus on the whole search pill instead. */
.gb-search:focus-within { outline: 3px solid var(--purple-2); outline-offset: 2px; }
.gb-modal__body { overflow-y: auto; padding: 8px 14px 16px; }
.gb-locgroup { margin: 10px 0 4px; }
.gb-locgroup__city { font-weight: 900; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #b6ae98; padding: 6px 10px; }
.gb-locopt {
  width: 100%; text-align: left; border: 1px solid var(--line); background: #fff; border-radius: 13px;
  padding: 13px 15px; margin: 5px 0; cursor: pointer; display: flex; align-items: center; gap: 12px;
}
.gb-locopt:hover { border-color: var(--accent); }
.gb-locopt--selected { border-color: var(--teal); background: #eafafa; }
.gb-locopt__pin { width: 34px; height: 34px; border-radius: 10px; background: #efe9ff; display: flex; align-items: center; justify-content: center; font-size: 16px; flex: none; }
.gb-locopt__text { flex: 1; }
.gb-locopt__name { display: block; font-family: var(--font-display); font-weight: 500; font-size: 16px; color: var(--ink); line-height: 1.1; }
.gb-locopt__mall { color: var(--muted); font-weight: 700; font-size: 12.5px; }
.gb-locopt__check { color: #fff; background: var(--teal); font-size: 13px; font-weight: 900; width: 24px; height: 24px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }

/* ---------- account chip (US-3.6b2) ---------- */
.gb-acct { display: flex; align-items: center; gap: 10px; }
.gb-acct__hello { font-family: var(--font-body); font-weight: 800; font-size: 14.5px; color: var(--ink); white-space: nowrap; }

/* ---------- auth modal (US-3.6b2) — reuses .gb-modal / .gb-modal__panel above ---------- */
.gb-modal__back {
  border: none; background: #f3eee2; width: 34px; height: 34px; border-radius: 50%; cursor: pointer;
  font-size: 17px; color: var(--muted-3); flex: none;
}
.gb-modal__titlewrap { display: flex; align-items: center; gap: 10px; min-width: 0; }

.gb-field { margin-bottom: 14px; display: flex; flex-direction: column; gap: 6px; }
.gb-field__label { font-weight: 800; font-size: 13px; color: var(--muted-3); }
.gb-field input.gb-input { width: 100%; }
.gb-code-input { letter-spacing: .3em; text-align: center; font-family: var(--font-display); font-size: 20px; font-weight: 600; }

/* ---------- checkout details step (US-4.1/T-4.2) — plain white card + a 2-col field grid, reusing
   .gb-field/.gb-input/.gb-auth__error/.gb-summary/.gb-line as-is for everything else ---------- */
.gb-panel { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 18px; box-shadow: 0 3px 12px rgba(58, 43, 140, .04); }
.gb-panel__title { font-family: var(--font-display); font-weight: 600; font-size: 17px; margin: 0 0 14px; }
.gb-field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 14px; }
.gb-field-grid .gb-field { margin-bottom: 10px; }

/* ---------- details step — full mockup §2.3 (stepper, tabs, preferred location, children, create-account) ---------- */
/* stepper (Coș → Detalii → Confirmare), shared by the cart + details steps */
.gb-stepper-nav { display: flex; align-items: center; max-width: 460px; margin: 20px 0 2px; }
.gb-step { display: flex; align-items: center; gap: 8px; flex: none; }
.gb-step__circle {
  width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-weight: 900; font-size: 13px; border: 2px solid transparent; flex: none;
}
.gb-step__label { font-weight: 800; font-size: 13.5px; }
.gb-step__conn { flex: 1; height: 2px; background: #e6dcc6; margin: 0 10px; border-radius: 2px; }
.gb-step__conn.is-done { background: var(--teal); }
.gb-step.is-done .gb-step__circle { background: var(--teal); border-color: var(--teal); color: #fff; }
.gb-step.is-done .gb-step__label { color: var(--ink); }
.gb-step.is-active .gb-step__circle { background: var(--accent); border-color: var(--accent); color: #fff; }
.gb-step.is-active .gb-step__label { color: var(--ink); }
.gb-step.is-todo .gb-step__circle { background: #f6f1e6; border-color: #e6dcc6; color: #b6ae98; }
.gb-step.is-todo .gb-step__label { color: #b6ae98; }

/* left column layout + bottom actions */
.gb-detform { display: flex; flex-direction: column; gap: 16px; }
.gb-detform__actions { display: flex; gap: 12px; align-items: center; margin-top: 4px; flex-wrap: wrap; }
.gb-detform__actions .gb-btn { border-radius: 14px; padding: 14px 20px; font-size: 15px; }
.gb-detform__submit { flex: 1; justify-content: center; font-size: 16px; font-weight: 900; }

/* tabs card ("Client nou" / "Am deja cont") */
.gb-tabs-card { background: #fff; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: 0 3px 12px rgba(58, 43, 140, .04); }
.gb-tabs { display: flex; }
.gb-tab {
  flex: 1; border: none; border-bottom: 3px solid transparent; cursor: pointer; padding: 14px;
  font-family: var(--font-body); font-weight: 800; font-size: 14px; background: #fff; color: var(--muted-2);
}
.gb-tab.is-active { border-bottom-color: var(--accent); background: #faf7ff; color: var(--purple); }
.gb-tab:hover:not(.is-active) { background: #fbfaff; }
.gb-infobanner { padding: 13px 16px; color: var(--muted-2); font-weight: 700; font-size: 13.5px; display: flex; align-items: center; gap: 8px; }
.gb-tabpanel { padding: 16px; }

/* uppercase field caption + required marker + optional/required badges */
.gb-flabel { font-weight: 900; font-size: 11.5px; color: var(--muted-3); letter-spacing: .06em; text-transform: uppercase; }
.gb-flabel__req { color: var(--accent); }
.gb-panel__title--badge { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.gb-badge-req { color: var(--accent); font-size: 11.5px; font-weight: 900; background: #fde8ef; padding: 3px 8px; border-radius: 6px; }
.gb-opt-hint { color: var(--muted); font-size: 11.5px; font-weight: 700; }
.gb-panel__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.gb-panel__head .gb-panel__title { margin: 0; }
.gb-btn--sm { padding: 8px 14px; font-size: 13px; }

/* preferred-location select (custom chevron, matches .gb-input) */
.gb-select {
  width: 100%; border: 2px solid var(--line-lav); background: #fbfaff; border-radius: var(--r-input);
  padding: 11px 36px 11px 14px; font-family: var(--font-body); font-weight: 700; font-size: 14.5px; color: var(--ink);
  outline: none; cursor: pointer; appearance: none; -webkit-appearance: none; -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4.5l4 4 4-4' stroke='%237b4fc4' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}

/* children ("Copiii mei") */
.gb-children-empty { text-align: center; color: #b6ae98; font-weight: 700; font-size: 13.5px; padding: 8px 0; }
.gb-childrow {
  display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 9px; margin-bottom: 10px;
  background: #faf7ff; border: 1px solid #ede8f8; border-radius: 12px; padding: 10px 12px;
}
.gb-childrow__idx { font-family: var(--font-display); font-weight: 600; color: var(--purple-2); font-size: 14px; white-space: nowrap; }
.gb-childrow .gb-input { border-color: #ede8f8; background: #fff; border-radius: 9px; padding: 9px 12px; font-size: 13.5px; font-weight: 700; }
.gb-childrow__name { width: 100%; min-width: 0; }
.gb-childrow__dob { font-size: 13px; }
.gb-childrow__remove {
  width: 30px; height: 30px; border: none; background: #f7f0ff; border-radius: 8px; cursor: pointer; color: #c9c0d6; font-size: 15px;
}
.gb-childrow__remove:hover { background: #fceef3; color: var(--accent); }

/* "Creează un cont Gymboland" checkbox card + revealed password */
.gb-createacct {
  display: flex; align-items: center; gap: 12px; cursor: pointer; padding: 15px 16px; background: #fff;
  border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 3px 12px rgba(58, 43, 140, .04);
}
.gb-createacct input { width: 18px; height: 18px; accent-color: var(--purple); cursor: pointer; flex: none; }
.gb-createacct__text { display: flex; flex-direction: column; gap: 2px; }
.gb-createacct__title { font-weight: 800; font-size: 14px; color: var(--ink); }
.gb-createacct__sub { font-weight: 700; font-size: 12.5px; color: var(--muted); }

/* compact mini-summary line (sidebar) */
.gb-sumline { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.gb-sumline__media {
  width: 40px; height: 40px; border-radius: 10px; flex: none; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 700; font-size: 13px; color: #fff; text-shadow: 0 1px 3px rgba(0, 0, 0, .2);
}
.gb-sumline__info { flex: 1; min-width: 0; }
.gb-sumline__name { font-weight: 800; font-size: 13px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gb-sumline__meta { color: var(--muted); font-weight: 700; font-size: 12px; }
.gb-sumline__total { font-family: var(--font-display); font-weight: 600; font-size: 15px; white-space: nowrap; }

.gb-auth__text { color: var(--muted-2); font-weight: 700; font-size: 14.5px; line-height: 1.5; margin: 0 0 16px; }
.gb-auth__error { color: var(--accent); font-weight: 800; font-size: 13.5px; min-height: 1em; margin: 2px 0 14px; }
.gb-auth__link {
  border: none; background: none; cursor: pointer; color: var(--purple-2); font-family: var(--font-body);
  font-weight: 800; font-size: 13.5px; padding: 14px 0 0; display: block; text-align: center; width: 100%;
}
.gb-auth__chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; }
.gb-auth__chip { background: #efe9ff; color: var(--purple); font-weight: 800; font-size: 13px; padding: 8px 13px; border-radius: 999px; }
.gb-auth__channels { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }

.gb-radio-pills { display: flex; gap: 10px; }
.gb-radio-pill {
  display: flex; align-items: center; gap: 8px; border: 2px solid var(--line-lav); background: #fbfaff;
  border-radius: var(--r-ctrl); padding: 10px 14px; cursor: pointer; font-weight: 800; color: var(--ink);
  font-size: 14px; flex: 1;
}
.gb-radio-pill input { accent-color: var(--accent); width: 16px; height: 16px; margin: 0; }
.gb-radio-pill:has(input:checked) { border-color: var(--accent); background: #fceef3; }
.gb-checkbox-row { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 13.5px; color: var(--muted-3); margin: 4px 0 16px; cursor: pointer; }
.gb-checkbox-row input { accent-color: var(--accent); width: 17px; height: 17px; margin: 0; flex: none; }

/* busy submit buttons: aria-disabled + inert (not the real disabled attribute — see store.js setBusy) */
.gb-spinner {
  display: inline-block; width: 14px; height: 14px; border-radius: 50%; margin-right: 8px; vertical-align: -2px;
  border: 2px solid rgba(255, 255, 255, .5); border-top-color: #fff; animation: gbSpin .6s linear infinite;
}
.gb-btn--busy { pointer-events: none; cursor: default; opacity: .85; }
.gb-btn[disabled] { opacity: .5; cursor: default; pointer-events: none; }

/* ---------- "adăugat în coș" modal — reuses .gb-modal / .gb-modal__panel above ---------- */
.gb-modal__panel--sm { width: 440px; }
.gb-added {
  display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid var(--line);
  border-radius: 16px; padding: 16px; margin: 10px 6px 0;
}
.gb-added__check {
  flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--teal); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 20px; font-weight: 900;
}
.gb-added__text { min-width: 0; }
.gb-added__name { font-family: var(--font-display); font-weight: 500; font-size: 17px; color: var(--ink); line-height: 1.2; }
.gb-added__note { color: var(--muted); font-weight: 700; font-size: 12.5px; margin-top: 3px; }
.gb-added__price { font-weight: 900; font-size: 14.5px; color: var(--purple); margin-top: 5px; }
.gb-added__summary { text-align: center; color: var(--muted-3); font-weight: 700; font-size: 13.5px; margin: 14px 6px 0; }
.gb-added__actions { display: flex; flex-direction: column; gap: 10px; margin: 16px 6px 4px; }

/* ---------- toast ---------- */
.gb-toast {
  position: fixed; left: 50%; bottom: 30px; transform: translateX(-50%); z-index: 120;
  background: var(--ink); color: #fff; font-weight: 800; font-size: 14.5px; padding: 14px 22px; border-radius: 999px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .3); display: flex; align-items: center; gap: 10px; animation: gbToast 1.9s ease forwards;
}

/* storage-blocked banner (US-2.3 fallback) */
.gb-storagewarn {
  background: #fff7e6; border: 1px solid #f4dfae; border-radius: 14px; padding: 12px 16px; margin: 0 0 18px;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap; color: #8a6d1f; font-weight: 700; font-size: 13.5px;
}
.gb-storagewarn a { color: var(--purple); font-weight: 800; }

/* ---------- animations ---------- */
@keyframes gbPop { 0% { transform: scale(.96); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes gbToast { 0% { transform: translate(-50%, 16px); opacity: 0; } 12%, 88% { transform: translate(-50%, 0); opacity: 1; } 100% { transform: translate(-50%, 8px); opacity: 0; } }
@keyframes gbFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
@keyframes gbShimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
@keyframes gbSpin { to { transform: rotate(360deg); } }

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .gb-cart-grid { grid-template-columns: 1fr; }
  .gb-summary { position: static; }
}
@media (max-width: 560px) {
  .gb-store { padding: 16px 16px 56px; }
  .gb-grid { grid-template-columns: 1fr; }
  .gb-section__title { font-size: 23px; }
  .gb-cart-title { font-size: 26px; }
  .gb-line { flex-wrap: wrap; }
  .gb-line__total { width: auto; }
  .gb-field-grid { grid-template-columns: 1fr; }
  /* children rows reflow: label + name stack full-width, date + remove share a row */
  .gb-childrow { grid-template-columns: 1fr auto; }
  .gb-childrow__idx { grid-column: 1 / -1; }
  .gb-childrow__name { grid-column: 1 / -1; }
  /* stepper stays legible on narrow screens */
  .gb-step__label { font-size: 11.5px; }
  .gb-step__conn { margin: 0 6px; }
}

/* respect reduced motion (quality floor) */
@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
