/*
 * PUBLICZNY SKLEP DOSTAWCY - kierunek "Bento" (store_investigation/makiety/bento),
 * katalog jako rowna siatka kart (D9: bez slotow, jeden kurs = jedna pozycja).
 * Ladowany PO shared.css, wiec kolory bierze z tych samych tokenow, ktore
 * maluje ProviderTheme w <head> (--accent*, --bg, --surface, --text, --muted,
 * --highlight). Nie ma tu wlasnego :root z paleta - to jest whitelabel, kolory
 * sa dostawcy. Wlasne sa tylko ksztalty: sklep ma wieksze zaokraglenia niz
 * panel, wiec stoja jako zmienne lokalne na body.store.
 *
 * ⚠ KAZDA REGULA ZACZYNA SIE OD `.store`. Makieta uzywa tych samych nazw klas
 * co base.css (.nav, .btn, .card, .notice, table) w innym znaczeniu - zakres
 * na body daje wyzsza wage i sklep nie przefarbowuje paneli.
 */

.store {
  --store-radius: 22px;
  --store-radius-sm: 14px;
  --store-soft: 0 1px 2px rgba(0, 42, 23, .05), 0 18px 40px rgba(0, 42, 23, .06);
  --maxw: 1200px;
  line-height: 1.6;
}

.store h1, .store h2, .store h3 {
  font-family: var(--font-head);
  font-weight: 900;
  letter-spacing: -.025em;
  margin: 0;
  line-height: 1.05;
  color: var(--text);
}
.store a { color: inherit; text-decoration: none; }
.store p a, .store li a { border-bottom: 0; }
.store .mt0 { margin-top: 0; }
.store .sticky { position: sticky; top: 86px; }

/* ---------- nav ---------- */
.store .nav {
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 40;
  border: 0;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(10px);
}
.store .nav-in { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; display: flex; align-items: center; gap: 16px; }
.store .logo { display: flex; gap: 10px; align-items: center; font-weight: 800; font-size: 1.05rem; }
.store .logo img { display: block; height: 30px; width: auto; }
.store .logo strong { font: 800 1.05rem/1 var(--font-head); white-space: nowrap; }
.store .nav-links { margin-left: auto; display: flex; gap: 20px; align-items: center; font-size: .92rem; color: var(--muted); }
.store .nav-links a { color: var(--muted); font-size: .92rem; padding: 0; }
.store .nav-links a:hover { color: var(--text); }
.store .nav-links a.active { color: var(--text); font-weight: 600; }
.store .nav-links a:not(.btn)::after { content: none; }
.store .pillbtn,
.store .nav-links a.pillbtn {
  background: var(--text);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 600;
  font-size: .9rem;
  white-space: nowrap;
}
.store .nav-links a.pillbtn:hover { color: #fff; background: var(--accent-deep); }
.store .nav-links a.pillbtn.active { background: var(--accent); color: #fff; }
/* AS-0071: nawigacja sklepu w trybie zgodnosci - aktywna jest sekcja, w ktorej jestes. */
.store .nav-links .nav-ic { display: inline-flex; align-items: center; gap: 7px; padding: 9px 14px; border-radius: 999px; color: var(--muted); font-weight: 600; }
.store .nav-links .nav-ic:hover { color: var(--text); background: color-mix(in srgb, var(--text) 6%, transparent); }
.store .nav-links .nav-ic.is-on { background: var(--text); color: #fff; }
.store .nav-links .nav-ic .ic { width: 18px; height: 18px; }
.store .nav-links .nav-count { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: #fff;
  font-size: .74rem; display: inline-flex; align-items: center; justify-content: center; }
.store .nav-logout-form { margin: 0; display: inline-flex; }
.store .nav-logout, .store .nav-links a.nav-logout { display: inline-flex; align-items: center; gap: 7px; background: none; border: 1.5px solid var(--text); border-radius: 999px;
  padding: 8px 15px; color: var(--text); font: inherit; font-size: .9rem; font-weight: 700; cursor: pointer; }
.store .nav-logout:hover, .store .nav-links a.nav-logout:hover, .store .nav-links a.nav-logout:hover * { background: var(--text); color: #fff; }
.store .nav-links a.nav-logout:hover * { background: none; }
.store .nav-logout .ic { width: 18px; height: 18px; }
.store .account-box--login { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; border-style: solid; }
.store .account-box--login .btn { display: inline-flex; align-items: center; gap: 8px; }
.store .account-box--login .btn .ic { width: 18px; height: 18px; }

@media (max-width: 900px) {
  .store .nav { position: sticky; }
  .store .nav-links { display: flex; position: static; flex-direction: row; padding: 0; border: 0; box-shadow: none; background: none; }
  .store .nav-links a { border: 0; padding: 0; font-size: .92rem; }
}
/* Po regule wyzej (zeruje ramki i paddingi linkow): pigulki nawigacji w trybie zgodnosci zostaja. */
@media (max-width: 900px) {
  .store .nav-links a.nav-ic { padding: 9px 14px; }
  .store .nav-links a.nav-logout { border: 1.5px solid var(--text); padding: 8px 15px; }
}
@media (max-width: 640px) {
  .store .nav-links { gap: 6px; }
  .store .nav-links a.nav-ic, .store .nav-links .nav-ic { padding: 8px 10px; }
  .store .nav-links .lbl:not(.lbl--keep) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .store .nav-logout, .store .nav-links a.nav-logout { padding: 8px 10px; }
  /* AS-0257: z przelacznikiem Kursy | Materialy nie miescilo sie w jednym rzedzie - flex sciskal
     logo i ikony do zera; przelacznik schodzi pod logo na cala szerokosc. */
  .store .nav-in { flex-wrap: wrap; row-gap: 10px; }
  .store .logo, .store .nav-links > *, .store .nav-links .ic { flex-shrink: 0; }
}

/* ---------- naglowki / hero ---------- */
/* AS-0257: tylko pion - `padding: 26px 0` zerowal boczny gutter .wrap i na telefonie tekst stal na krawedzi. */
.store .head { padding-top: 26px; padding-bottom: 8px; }
.store .head h1 { font-size: clamp(2.2rem, 5.4vw, 4.2rem); margin: 16px 0 0; max-width: 18ch; }
.store .head .sub { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-top: 16px; flex-wrap: wrap; }
.store .head p { color: var(--muted); font-size: 1.12rem; max-width: 52ch; margin: 0; }
.store .page-title { font-size: 2.6rem; }
.store .product-title { font-size: 2.4rem; margin: 6px 0 0; }
.store .lead { font-size: 1.1rem; max-width: 60ch; }
/* Opis z panelu bywa wieloakapitowy (simple_format) - odstep miedzy akapitami. */
.store .lead-body p { margin: 0 0 .7em; }
.store .lead-body p:last-child { margin-bottom: 0; }
/* margin: 0 auto wraca, bo panel.css ma nieskopowane `.crumb { margin: 0 0 10px }`,
   ktore wypychalo "Wroc do katalogu" do lewej krawedzi okna. */
.store .crumb { margin: 0 auto; padding: 20px var(--gutter) 0; color: var(--muted); font-size: .9rem; }
.store .crumb a:hover { color: var(--text); }

/* Powrot do katalogu / koszyka: link z strzalka, na hover podswietlenie i podkreslenie. */
.store .back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px 6px 8px;
  margin-left: -8px;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 600;
  text-decoration: none;
  transition: color .16s, background .16s;
}
.store .back-link__arrow { font-size: 1.1em; line-height: 1; transition: transform .16s; }
.store .back-link:hover,
.store .crumb a.back-link:hover { color: var(--text); background: var(--accent-soft); text-decoration: underline; text-underline-offset: 3px; }
.store .back-link:hover .back-link__arrow { transform: translateX(-3px); }
.store .back-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- przyciski ---------- */
.store .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 13px 22px;
  border-radius: var(--store-radius-sm);
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  border: 1px solid transparent;
  background: var(--surface);
  color: var(--text);
  box-shadow: none;
  transition: transform .16s, box-shadow .16s, background .16s;
  font-family: inherit;
}
.store .btn:hover { background: var(--surface); transform: none; box-shadow: none; }
.store .btn.on { background: var(--accent); color: #fff; box-shadow: 0 2px 6px color-mix(in srgb, var(--accent) 22%, transparent); }
.store .btn.on:hover { background: var(--accent-dark); transform: translateY(-1px); box-shadow: 0 4px 10px color-mix(in srgb, var(--accent) 28%, transparent); }
.store .btn.dark { background: var(--text); color: #fff; }
.store .btn.dark:hover { background: var(--text); transform: translateY(-2px); }
.store .btn.line { background: var(--surface); border-color: var(--border); color: var(--text); }
.store .btn.line:hover { border-color: var(--accent-mid); transform: translateY(-2px); }
.store .btn.block { width: 100%; }
.store .btn.sm { padding: 9px 15px; font-size: .88rem; }
.store .btn:disabled, .store .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; pointer-events: none; }
.store .btn:disabled:hover { transform: none; }

/* Przycisk, ktory czyta sie jak link - button_to daje <form>. */
.store form.button_to { display: inline; margin: 0; }
.store .txtbtn { border: 0; background: none; padding: 0; font: inherit; font-size: .875rem; color: var(--muted); cursor: pointer; }
.store .txtbtn:hover { color: var(--bad); }

/* Przycisk-ikona (kosz w koszyku): sama ikonka, nazwa w aria-label/title. */
.store .iconbtn {
  display: inline-grid; place-items: center;
  width: 36px; height: 36px; padding: 0;
  border: 1px solid transparent; border-radius: 10px;
  background: none; color: var(--muted); cursor: pointer;
  transition: color .14s, background .14s, border-color .14s;
}
.store .iconbtn svg { width: 18px; height: 18px; }
.store .iconbtn:hover, .store .iconbtn:focus-visible { color: var(--text); background: var(--bg); border-color: var(--border); outline: none; }
.store .iconbtn--danger:hover, .store .iconbtn--danger:focus-visible { color: var(--bad); background: var(--bad-soft); border-color: transparent; }

.store .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* Trust-chipy pod naglowkiem: tylko to, co prawdziwe dla kazdej pozycji. */
.store .trust { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.store .chip {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border);
  font-size: .86rem; font-weight: 600; color: var(--text);
  box-shadow: 0 1px 2px rgba(0, 42, 23, .04);
}
.store .chip .ic { width: 16px; height: 16px; color: var(--accent-dark); flex: 0 0 16px; }

/* AS-0058: przelacznik Kursy | Materialy obok logo. */
.store .store-switch { display: inline-flex; gap: 4px; padding: 4px; margin-left: 18px; border: 1px solid var(--border);
  border-radius: 999px; background: var(--surface); }
.store .store-switch__tab { padding: 7px 14px; border-radius: 999px; font-size: .88rem; font-weight: 600;
  color: var(--muted); text-decoration: none; white-space: nowrap; }
.store .store-switch__tab:hover, .store .store-switch__tab:focus-visible { color: var(--text); background: var(--bg); }
.store .store-switch__tab.is-on { background: var(--accent); color: #fff; }
@media (max-width: 640px) {
  .store .store-switch { order: 3; flex: 1 0 100%; margin-left: 0; }
  .store .store-switch__tab { flex: 1; text-align: center; padding: 6px 10px; font-size: .82rem; }
}

/* AS-0058: polki sklepu nad katalogiem (StoreCategory). */
.store .store-cats { display: flex; flex-wrap: wrap; gap: 8px; padding: 24px 0 0; }
.store .store-cats + .bento { padding-top: 18px; }
.store .store-cats__chip {
  display: inline-flex; align-items: center; padding: 8px 14px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border); color: var(--text);
  font-size: .86rem; font-weight: 600; text-decoration: none;
}
.store .store-cats__chip:hover, .store .store-cats__chip:focus-visible { border-color: var(--accent); }
.store .store-cats__chip.is-on { background: var(--accent); border-color: var(--accent); color: #fff; }

/* AS-0058: lista plikow materialu na stronie produktu (bez pobierania przed zakupem). */
.store .files { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.store .files li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: 10px; font-size: .92rem; }
.store .files__ext { font: 700 .7rem/1 ui-monospace, Menlo, monospace; padding: 5px 6px; border-radius: 5px;
  background: var(--accent-soft); color: var(--accent-dark); }
.store .files__name { overflow-wrap: anywhere; }
.store .files__size { color: var(--muted); font-variant-numeric: tabular-nums; font-size: .84rem; }

/* ---------- katalog: bento (wariant-3-bento.html) ----------
   4 kolumny; .feat = 2x2, kazdy inny kurs = jedna komorka (bez kafli-statystyk
   i bez .wide - siatka domyka sie bez dziur przy kazdej liczbie pozycji).
   .mini zostaje dla kafli faktow na stronie produktu (.bento--facts).
   ⚠ panel.css ma nieskopowane `.tile { grid-column: span 6 }` pod 1200px -
   `.store .tile` wraca do `auto`, a span dostaje TYLKO feat. */
.store .bento { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; padding: 30px 0 70px; align-items: stretch; }
.store .bento--facts { padding: 6px 0 0; grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .store .bento { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .store .bento { grid-template-columns: 1fr; } .store .bento--facts { grid-template-columns: 1fr 1fr; } }

.store .tile {
  position: relative;
  grid-column: auto;
  grid-row: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--store-radius);
  overflow: hidden;
  transition: transform .2s, box-shadow .2s, border-color .2s;
  display: flex;
  flex-direction: column;
}
.store .tile:hover { transform: translateY(-4px); box-shadow: var(--store-soft); border-color: var(--accent-mid); }
.store .tile a.cov { display: grid; }
.store .tile .cov img { transition: transform .4s; }
.store .tile:hover .cov img { transform: scale(1.04); }

.store .tile.feat { grid-column: span 2; grid-row: span 2; background: var(--accent-night); border-color: var(--accent-night); color: #fff; }
.store .tile.feat .cov { aspect-ratio: 16 / 9; }
.store .tile.feat .in { padding: 24px; }
.store .tile.feat .badge {
  display: inline-block; align-self: flex-start;
  background: var(--highlight); color: #3a2b00;
  font-weight: 800; font-size: .72rem; letter-spacing: .04em; text-transform: uppercase;
  padding: 5px 11px; border-radius: 999px; margin-bottom: 12px;
}
.store .tile.feat h3 { font-size: clamp(1.5rem, 2.6vw, 2rem); color: #fff; margin-bottom: 8px; }
.store .tile.feat .m { color: rgba(255, 255, 255, .72); }
.store .tile.feat .d { color: rgba(255, 255, 255, .84); font-size: .95rem; margin: 0 0 14px; max-width: 46ch; }
.store .tile.feat .p { color: #fff; font-size: 1.6rem; }
.store .tile.feat .p small { color: rgba(255, 255, 255, .6); }
.store .tile.feat .go { background: var(--accent); color: #fff; }
.store .tile.feat:hover .go { background: var(--accent-dark); }
@media (max-width: 900px) {
  .store .tile.feat { grid-column: span 2; grid-row: auto; }
}
@media (max-width: 560px) {
  .store .tile.feat { grid-column: span 1; }
}

.store .cov { aspect-ratio: 16 / 9; position: relative; display: block; overflow: hidden; background: var(--accent-night); }
.store .cov::after { content: ""; position: absolute; inset: 0; background: radial-gradient(120% 90% at 15% 0%, rgba(255, 255, 255, .22), transparent 55%); pointer-events: none; }
.store .cov img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.store .cov--hero { border-radius: var(--store-radius); aspect-ratio: 16 / 9; }

/* Zaslepka okladki (StorefrontHelper#store_cover_blank): gradient marki
   z tokenow dostawcy, cienka siatka, tarcza w obrysie i tytul kursu pod
   wordmarkiem dostawcy. Jedna i ta sama na kaflu, w feat, na produkcie
   i w koszyku - tam bez podpisu, bo miniatura ma 72px. */
.store .cov--blank {
  color: #fff;
  background:
    linear-gradient(to right, rgba(255, 255, 255, .06) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(to bottom, rgba(255, 255, 255, .06) 1px, transparent 1px) 0 0 / 28px 28px,
    radial-gradient(90% 90% at 100% 100%, color-mix(in srgb, var(--accent) 55%, transparent), transparent 62%),
    linear-gradient(150deg, var(--accent-deep), var(--accent-night));
}
.store .cov__art {
  position: absolute; top: -10%; right: -8%;
  width: 62%; aspect-ratio: 1;
  color: #fff; opacity: .14;
  transition: transform .4s;
}
.store .tile:hover .cov__art { transform: scale(1.04) rotate(-2deg); }
.store .cov__cap {
  position: absolute; inset: auto 0 0; z-index: 1;
  display: grid; gap: 3px; padding: 14px 16px;
  background: linear-gradient(to top, rgba(0, 0, 0, .3), transparent);
}
.store .cov__brand { font-size: .66rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: rgba(255, 255, 255, .6); }
.store .cov__title {
  font-family: var(--font-head); font-weight: 800; font-size: .95rem; line-height: 1.2; letter-spacing: -.01em;
  color: rgba(255, 255, 255, .94);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.store .tile.feat .cov__cap { padding: 18px 24px; }
.store .tile.feat .cov__title { font-size: 1.2rem; }
.store .cov--hero .cov__cap { padding: 22px 28px; gap: 5px; }
.store .cov--hero .cov__brand { font-size: .74rem; }
.store .cov--hero .cov__title { font-size: clamp(1.2rem, 2.4vw, 1.7rem); }
.store .cov--hero .cov__art { width: 46%; top: -6%; right: -4%; }

.store .tile .in { padding: 16px 18px; display: flex; flex-direction: column; flex: 1; }
.store .tile h3 { font-size: 1.12rem; margin: 0 0 4px; }
.store .tile .m { color: var(--muted); font-size: .84rem; margin-bottom: 12px; }
.store .tile .f { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.store .tile .p { font-family: var(--font-head); font-weight: 900; font-size: 1.35rem; }
.store .tile .p small { font-family: var(--font-body); font-weight: 400; color: var(--muted); font-size: .72rem; display: block; }
.store .tile .go {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-weight: 700;
  font-size: .85rem;
  white-space: nowrap;
  transition: .16s;
}
.store .tile .go::after { content: "→"; font-size: 1.05em; }
.store .tile:hover .go { background: var(--accent); color: #fff; }

.store .mini { background: var(--accent-soft); border-color: var(--accent-mid); align-items: flex-start; justify-content: center; padding: 22px 20px; gap: 6px; }
.store .mini b { font-family: var(--font-head); font-size: 2.4rem; color: var(--accent-deep); line-height: 1; letter-spacing: -.02em; }
.store .mini span { color: var(--accent-dark); font-weight: 600; line-height: 1.3; }
.store .mini:hover { transform: none; box-shadow: none; }

/* ---------- strona produktu: media, "co dostajesz", karta zakupu ---------- */
.store .media {
  margin: 0; position: relative; overflow: hidden;
  border-radius: var(--store-radius); border: 1px solid var(--border);
  aspect-ratio: 16 / 9; background: var(--accent-night); box-shadow: var(--store-soft);
}
.store .media img, .store .media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.store .media--video { background: #000; }
.store .media--video video { object-fit: contain; }
.store .cov--hero.media { aspect-ratio: 16 / 9; }
.store .t .ic { width: 12px; height: 12px; vertical-align: -2px; margin-right: 3px; }

.store .gets h3, .store .card > h3.mt0 { margin-bottom: 12px; }
.store .gets__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.store .gets__list li { display: flex; align-items: flex-start; gap: 10px; font-size: .98rem; }
.store .gets__list .ic { width: 22px; height: 22px; flex: 0 0 22px; padding: 4px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-dark); }

.store .buy { border-color: var(--accent-mid); box-shadow: 0 1px 2px rgba(0, 42, 23, .05), 0 22px 48px color-mix(in srgb, var(--accent) 14%, transparent); }
.store .buy__label { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 6px; }
.store .buy__trust { list-style: none; margin: 0; padding: 14px 0 0; border-top: 1px solid var(--border); display: grid; gap: 8px; font-size: .86rem; color: var(--muted); }
.store .buy__trust li { display: flex; align-items: center; gap: 8px; }
.store .buy__trust .ic { width: 16px; height: 16px; flex: 0 0 16px; color: var(--accent-dark); }

/* ---------- karty / uklad ---------- */
.store .card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--store-radius); padding: 22px; box-shadow: var(--store-soft); }
.store .card--table { padding: 0; overflow: hidden; }
.store .split { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; align-items: start; padding: 22px 0 70px; }
@media (max-width: 960px) { .store .split { grid-template-columns: 1fr; } .store .sticky { position: static; } }
.store .stack > * + * { margin-top: 14px; }
.store .tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.store .t { font-size: .72rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-dark); }
.store .t.star { background: var(--warn-soft); color: var(--warn); }
.store .t.off { background: var(--bg); color: var(--muted); }
.store .t.ok { background: var(--ok-soft); color: var(--ok); }
.store .program { margin: 0; padding-left: 20px; }
.store .program li { padding-left: 4px; }
.store .price-big { font-family: var(--font-head); font-weight: 900; font-size: 2rem; line-height: 1.1; }
.store .price-big .small { font-family: var(--font-body); font-weight: 400; }

.store .store-empty {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 56px 24px 52px; margin: 30px auto 70px; max-width: 520px;
}
.store .store-empty__ic {
  width: 64px; height: 64px; border-radius: 50%; margin-bottom: 18px;
  display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-dark);
}
.store .store-empty__ic svg { width: 30px; height: 30px; }
.store .store-empty__title { font-family: var(--font-head); font-size: 1.4rem; margin: 0 0 8px; }
.store .store-empty__sub { margin: 0 0 24px; max-width: 42ch; color: var(--muted); line-height: 1.55; }
.store .store-empty__cta { min-width: 220px; }

/* ---------- formularze ---------- */
.store label { display: block; font-size: .85rem; font-weight: 700; margin-bottom: 6px; }
.store input, .store select, .store textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--border);
  border-radius: var(--store-radius-sm);
  font: inherit;
  background: var(--surface);
  color: var(--text);
  transition: .14s;
}
.store input:focus, .store select:focus, .store textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); outline: none; }
.store input:disabled { background: var(--bg); color: var(--muted); cursor: not-allowed; }
.store .field + .field { margin-top: 14px; }
.store .hint { margin: .5em 0 0; }
.store .choice { display: block; border: 1px solid var(--border); border-radius: var(--store-radius-sm); padding: 15px; background: var(--surface); box-shadow: none; }
.store .choice + .choice { margin-top: 10px; }
.store .choice[data-on="true"] { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft); }
.store .choice .tt { font-weight: 700; display: flex; gap: 9px; align-items: center; }
.store .choice .dd { display: block; color: var(--muted); font-size: .875rem; margin-top: 5px; }
/* Osoba prywatna / JDG na checkoucie: kafelek jest etykieta z radiem w srodku,
   wiec zdejmujemy z niego reguly dla zwyklych etykiet i pol. */
.store label.choice { font-size: inherit; margin-bottom: 0; cursor: pointer; }
.store .choice input[type="radio"] { width: auto; padding: 0; margin: 0; accent-color: var(--accent); }
.store .buyer-kind { margin-bottom: 14px; }

/* ---------- tabele ---------- */
.store table { width: 100%; border-collapse: collapse; font-size: .925rem; }
.store th, .store td { text-align: left; padding: 13px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; white-space: nowrap; }
.store td:first-child { white-space: normal; min-width: 220px; }
.store th { font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
.store tbody tr:last-child td { border-bottom: 0; }
.store tbody tr:hover { background: transparent; }
.store .table-scroll { overflow-x: auto; }
.store .thumb { width: 72px; height: 46px; border-radius: 10px; overflow: hidden; flex: 0 0 72px; }
.store .thumb.cov { aspect-ratio: auto; }
.store .thumb .cov__art { inset: 15% 0; width: auto; margin: auto; opacity: .55; }
.store .thumb .cov__cap { display: none; }
.store .title-cell { display: flex; gap: 12px; align-items: center; }
.store .title-cell a:hover { color: var(--accent-dark); }

/* Tabela w karcie bez paddingu (.card--table): komorki same trzymaja odstep
   od krawedzi karty, zeby tresc nie klejala sie do lewej. */
.store .card--table th, .store .card--table td { padding: 16px 14px; }
.store .card--table th:first-child, .store .card--table td:first-child { padding-left: 24px; }
.store .card--table th:last-child, .store .card--table td:last-child { padding-right: 20px; }
.store .cart-table .price-cell { font-family: var(--font-head); font-size: 1.02rem; font-variant-numeric: tabular-nums; }
.store .cart-table td:last-child { width: 1%; }

/* Kurs wycofany ze sprzedazy po dodaniu do koszyka: wiersz wyszarzony,
   plakietka zamiast metadanych, zostaje tylko usuniecie. */
.store .cart-table tr.is-withdrawn td { background: var(--bg); }
.store .cart-table tr.is-withdrawn .title-cell > :not(.withdrawn-badge),
.store .cart-table tr.is-withdrawn .price-cell { opacity: .55; }
.store .cart-table tr.is-withdrawn .withdrawn-badge { margin-top: 6px; }
.store .cart-table tr.is-withdrawn .t.off { background: var(--surface); border: 1px solid var(--border); color: var(--muted); white-space: normal; }
.store .cart-table tr.is-withdrawn .iconbtn { opacity: 1; }

/* ---------- podsumowanie ----------
   Nazwa zwyklym tekstem po lewej, cena wyraznie i rowno do prawej; Razem
   odsuniete linia i pogrubione. Te same klasy stoja na checkoucie i na
   potwierdzeniu. */
.store .sum { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 9px 0; font-size: .95rem; color: var(--text); }
.store .sum > span:first-child { flex: 1 1 auto; min-width: 0; line-height: 1.4; }
.store .sum > span:last-child { flex: 0 0 auto; text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.store .sum-list { margin: 0; }
.store .sum-list .sum + .sum { border-top: 1px dashed var(--border); }
.store .sum.sum--withdrawn { color: var(--muted); }
.store .sum.sum--withdrawn > span:first-child { text-decoration: line-through; }
.store .sum.sum--withdrawn > span:last-child { font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; }
.store .sum.total { border-top: 2px solid var(--text); margin-top: 6px; padding-top: 14px; font-family: var(--font-head); font-size: 1.05rem; font-weight: 800; }
.store .sum.total > span:last-child { font-size: 1.35rem; font-weight: 900; }
.store .stack > .sum-list + .sum.total { margin-top: 4px; }
.store .cart-blocked { margin: 0; }

/* ---------- komunikaty ---------- */
.store .notice { display: block; border: 1px dashed var(--accent-mid); border-left-width: 1px; background: var(--accent-soft); border-radius: var(--store-radius-sm); padding: 15px 17px; font-size: .9rem; }
.store .notice.stripe { border-color: #635bff; background: #f2f1ff; color: #3d38a8; }
.store .notice.bad { border-style: solid; border-color: #edc7c7; background: var(--bad-soft); color: var(--bad); }
.store .notice__body { margin: .5em 0 0; }
.store ul.notice__body { padding-left: 18px; }
.store .notice > .notice__body:first-child { margin-top: 0; }
/* AS-0071: kurs, ktory konto juz ma - zakup przedluza dostep. */
.store .held-course { color: #6b4a04; font-weight: 600; margin-top: 4px; }
.store .notice.held-course { border-style: solid; border-color: var(--warn, #b45309); background: var(--warn-soft, #fef3c7); font-weight: 500; margin: 0; }
.store .notice.held-course a { color: inherit; font-weight: 700; }
.store .account-box { padding: 12px 15px; }

/* ---------- podglad administratora (pozycja in_test) ----------
   Klient nigdy tego nie widzi - kafel i baner sa tylko dla zalogowanego
   administratora dostawcy, wiec moga byc glosne. */
.store .tile--preview { outline: 2px dashed var(--warn, #b45309); outline-offset: -2px; }
.store .preview-badge {
  display: inline-block; align-self: flex-start; margin-bottom: 10px;
  background: var(--warn-soft, #fef3c7); color: var(--warn, #b45309);
  border: 1px dashed currentColor; border-radius: 999px;
  font-weight: 800; font-size: .68rem; letter-spacing: .04em; text-transform: uppercase; padding: 4px 10px;
}
.store .tile.feat .preview-badge { background: rgba(255, 255, 255, .92); }
.store .preview-notice { border-style: dashed; border-color: var(--warn, #b45309); background: var(--warn-soft, #fef3c7); color: #6b4a04; margin-bottom: 18px; }
.store .preview-notice__link { margin-left: 8px; font-weight: 700; color: inherit; text-decoration: underline; }
.store .order-status { font-size: .8rem; padding: 6px 12px; white-space: nowrap; }
.store .kbd { font-family: ui-monospace, Menlo, monospace; background: var(--bg); border: 1px solid var(--border); border-radius: 5px; padding: 1px 6px; font-size: .82rem; }

/* ---------- stopka ---------- */
.store .footer { border-top: 1px solid var(--border); margin-top: 30px; padding: 28px 0 44px; color: var(--muted); font-size: .85rem; }
.store .footer__grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) auto; gap: 24px 40px; align-items: start; }
.store .footer__text { white-space: pre-line; max-width: 52ch; }
.store .footer__contact { font-style: normal; display: grid; gap: 4px; }
.store .footer__contact b { color: var(--text); }
.store .footer__nav { display: grid; gap: 4px; }
.store .footer__link { color: var(--muted); text-decoration: none; }
.store .footer__link:hover { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 3px; }
.store .footer__trust { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--border); font-weight: 600; color: var(--text); }
.store .footer__trust span { display: inline-flex; align-items: center; gap: 7px; }
.store .footer__trust .ic { width: 15px; height: 15px; color: var(--accent-dark); }
@media (max-width: 760px) { .store .footer__grid { grid-template-columns: 1fr; gap: 18px; } }

/* ---------- regulamin ---------- */
.store .store-terms { max-width: 760px; margin: 22px auto 70px; padding: 32px 30px 36px; }
.store .store-terms h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); }
.store .store-terms__by { margin: 6px 0 22px; color: var(--muted); }
.store .store-terms__body { line-height: 1.7; }
.store .store-terms__body p { margin: 0 0 1em; }
.store .store-terms__body h2, .store .store-terms__body h3, .store .store-terms__body h4 { margin: 1.4em 0 .5em; line-height: 1.25; }
.store .store-terms__body h2 { font-size: 1.35rem; }
.store .store-terms__body h3 { font-size: 1.15rem; }
.store .store-terms__body h4 { font-size: 1rem; }
.store .store-terms__body ul, .store .store-terms__body ol { margin: 0 0 1em; padding-left: 1.4em; }
/* AS-0049: podpunkty "a) b) c)" niosa litere w tekscie - bez kropki. */
.store .store-terms__body ul { list-style: none; }
/* AS-0049: tabele w politykach (cele przetwarzania, wykaz cookies). */
.store .store-terms__body table { width: 100%; border-collapse: collapse; margin: 0 0 1.2em; font-size: .9rem; line-height: 1.45; display: block; overflow-x: auto; }
.store .store-terms__body th, .store .store-terms__body td { border: 1px solid var(--border); padding: 7px 9px; text-align: left; vertical-align: top; }
.store .store-terms__body th { background: var(--accent-soft); font-weight: 700; }
/* AS-0049 stopka A8: dane sprzedawcy z NIP i piec linkow w jednym rzedzie. */
.store .footer__nav--legal { flex-wrap: wrap; }
.store .store-terms__body blockquote { margin: 0 0 1em; padding: 4px 0 4px 16px; border-left: 3px solid var(--accent-mid); color: var(--muted); }
.store .store-terms__body a { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 2px; }
.store .store-terms__empty { color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .store .tile:hover, .store .btn.on:hover, .store .btn.line:hover, .store .btn.dark:hover { transform: none; }
}

/* AS-0050: checkout w trybie zgodnosci - klauzula drobnym drukiem i pola zgod (A2-A6). */
.store .checkout-legal .block { display: block; margin-top: 2px; }
.store .checkout-legal__notice { font-size: .78rem; line-height: 1.5; margin: 4px 0 0; }
.store .checkout-legal__cb { display: flex; gap: 10px; align-items: flex-start; font-size: .88rem; line-height: 1.5; cursor: pointer; }
.store .checkout-legal__cb input[type=checkbox] { width: 18px; height: 18px; margin-top: 2px; flex-shrink: 0; accent-color: var(--accent); }
.store .checkout-legal .notice.small { font-size: .85rem; padding: 8px 10px; margin: -4px 0 0; }

/* AS-0053: krotki opis i plakietki na kaflu katalogu. */
.store .tile__lead { margin: 4px 0 8px; font-size: .88rem; line-height: 1.45; color: var(--muted); }
.store .tags--tile { margin: 0 0 8px; }
/* AL-0105 / AS-0053: okladki 16:9 - obraz 16:9 widac w calosci (bylo 16:10 i 16:8). */

/* Podpowiedz w polu nie moze wygladac jak wpisana wartosc. */
.store input::placeholder, .store textarea::placeholder { color: color-mix(in srgb, var(--muted) 55%, transparent); font-style: italic; }
/* A6: pole zgody bez zaznaczenia - czerwona ramka checkboxa, komunikat stoi na gorze formularza. */
.store .checkout-legal__cb .field_with_errors { display: contents; }
.store .checkout-legal__cb.is-bad input[type=checkbox] { outline: 2px solid var(--bad); outline-offset: 2px; border-radius: 3px; }
.store .checkout-errors { scroll-margin-top: 90px; }
.store .checkout-errors:focus { outline: none; }
/* Dane kupujacego na potwierdzeniu: etykieta nad wartoscia, wartosc czytelna. */
.store .facts { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px 24px; }
.store .facts > div { border-top: 1px dashed var(--border); padding-top: 10px; min-width: 0; }
.store .facts dt { font-size: .78rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 0 0 4px; }
.store .facts dd { margin: 0; font-size: 1rem; font-weight: 600; color: var(--text); overflow-wrap: anywhere; }

/* ---------- checkout w trybie zgodnosci (AS-0071): kroki, formularz po lewej, zamowienie po prawej ---------- */
.store .co-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 18px; }
.store .co-back { font-size: .88rem; font-weight: 600; color: var(--muted); }
.store .co-back:hover { color: var(--text); }
.store .co-steps { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 6px; font-size: .82rem; font-weight: 600; color: var(--muted); }
.store .co-steps li { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px 5px 6px; border-radius: 999px; }
.store .co-steps li + li::before { content: "›"; margin: 0 6px 0 -2px; color: var(--border); font-size: 1rem; }
.store .co-steps a { display: inline-flex; align-items: center; gap: 7px; color: inherit; }
.store .co-steps__n { width: 22px; height: 22px; border-radius: 50%; background: color-mix(in srgb, var(--text) 8%, transparent); display: inline-flex; align-items: center; justify-content: center; font-size: .72rem; }
.store .co-steps li.is-on { background: var(--accent-soft); color: var(--accent-deep, var(--accent)); box-shadow: inset 0 0 0 1px var(--accent-mid); }
.store .co-steps li.is-on .co-steps__n { background: var(--accent); color: #fff; }
.store .co-steps li.is-done .co-steps__n { color: var(--accent); }
.store .co-head { padding: 22px 0 18px; }
.store .co-title { margin: 0; font: 800 clamp(1.7rem, 3.4vw, 2.3rem)/1.1 var(--font-head); letter-spacing: -.02em; }
.store .co-lead { margin: 8px 0 0; color: var(--muted); font-size: .98rem; }
.store .co-muted { color: var(--muted); font-size: .86rem; margin: 2px 0 0; line-height: 1.5; }
.store .co-req { color: var(--bad); font-weight: 700; }
.store .co-hint { color: var(--muted); font-weight: 400; font-size: .78rem; }
.store .co-chip { display: inline-block; padding: 2px 9px; border-radius: 7px; background: var(--accent-soft); color: var(--accent-deep, var(--accent)); font-size: .82rem; font-weight: 600; overflow-wrap: anywhere; }
.store .co-chip--muted { background: color-mix(in srgb, var(--text) 8%, transparent); color: var(--text); border-radius: 999px; }

.store .co-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 28px; align-items: start; padding-bottom: 40px; }
.store .co-main { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.store .co-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--store-radius); padding: 24px 26px; }
.store .co-card__head { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 14px; margin-bottom: 18px; border-bottom: 1px solid var(--border); }
.store .co-card h2, .store .co-sum h2 { margin: 0; font: 700 1.15rem/1.25 var(--font-head); }
.store .co-sub { margin: 22px 0 12px; padding-top: 18px; border-top: 1px solid var(--border); font-size: .76rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--text); }

.store .co-auth { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 18px 20px; border-radius: var(--store-radius-sm);
  background: linear-gradient(135deg, var(--accent-soft), color-mix(in srgb, var(--accent-soft) 40%, var(--surface))); border: 1px solid var(--accent-mid); }
.store .co-auth__ic, .store .co-auth__av { width: 42px; height: 42px; border-radius: 12px; flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; }
.store .co-auth__ic { background: var(--surface); color: var(--accent); }
.store .co-auth__ic .ic { width: 20px; height: 20px; }
.store .co-auth__av { border-radius: 50%; background: var(--accent); color: #fff; font-weight: 800; font-size: .85rem; }
.store .co-auth__txt { flex: 1 1 260px; min-width: 0; }
.store .co-auth__txt p { margin: 0; }
.store .co-auth__txt p + p { margin-top: 3px; }
.store .co-auth__btn { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.store .co-auth__btn .ic { width: 18px; height: 18px; }
.store .co-auth__out { margin: 0; }
.store .co-link { background: none; border: 0; padding: 0; font: inherit; font-size: .88rem; color: var(--muted); text-decoration: underline; cursor: pointer; }
.store .co-link:hover { color: var(--text); }

.store .co-kinds { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 18px; }
.store .co-kind { display: flex; align-items: flex-start; gap: 11px; padding: 15px 16px; border: 1.5px solid var(--border); border-radius: var(--store-radius-sm); cursor: pointer; background: var(--surface); }
.store .co-kind[data-on="true"] { border-color: var(--accent); background: color-mix(in srgb, var(--accent-soft) 45%, var(--surface)); box-shadow: 0 0 0 1px var(--accent); }
.store .co-kind input { margin-top: 3px; accent-color: var(--accent); width: 17px; height: 17px; flex: 0 0 auto; }
.store .co-kind__t { display: block; font-weight: 700; font-size: .95rem; margin: 0; }
.store .co-kind__d { display: block; color: var(--muted); font-size: .84rem; margin: 2px 0 0; line-height: 1.45; }

.store .co-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
.store .co-fields--addr { grid-template-columns: 1fr 2fr; }
.store .co-fields .co-f2 { grid-column: 1 / -1; }
.store .co-fields--addr .co-f2 { grid-column: auto; }
.store .co-fields .co-f3 { grid-column: 1 / -1; }
.store .co-fields .field { margin: 0; min-width: 0; }
.store .co-fields .field[hidden] { display: none; }

.store .co-pay { display: flex; gap: 12px; padding: 16px 18px; border: 1.5px solid var(--accent); border-radius: var(--store-radius-sm); box-shadow: 0 0 0 1px var(--accent);
  background: color-mix(in srgb, var(--accent-soft) 35%, var(--surface)); }
.store .co-pay__dot { width: 17px; height: 17px; margin-top: 2px; border-radius: 50%; border: 5px solid var(--accent); background: #fff; flex: 0 0 auto; }

.store .co-sum { position: sticky; top: 90px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--store-radius); overflow: hidden; }
.store .co-sum__head { display: flex; align-items: center; gap: 10px; padding: 18px 22px; border-bottom: 1px solid var(--border); background: color-mix(in srgb, var(--text) 3%, var(--surface)); }
.store .co-sum__body { padding: 20px 22px; display: flex; flex-direction: column; gap: 16px; }
.store .co-sum__foot { margin: 0; padding: 12px 22px; border-top: 1px solid var(--border); background: color-mix(in srgb, var(--text) 3%, var(--surface)); color: var(--muted); font-size: .76rem; }
.store .co-line { display: flex; gap: 12px; padding-bottom: 16px; border-bottom: 1px solid var(--border); }
.store .co-line__cov { width: 64px; height: 64px; flex: 0 0 auto; border-radius: 12px; overflow: hidden; }
.store .co-line__cov img { width: 100%; height: 100%; object-fit: cover; display: block; }
.store .co-line__cov .cov__cap { display: none; }
.store .co-line__txt { min-width: 0; flex: 1; }
.store .co-line__row { display: flex; justify-content: space-between; gap: 10px; font-size: .92rem; line-height: 1.35; }
.store .co-line__row b { white-space: nowrap; font-variant-numeric: tabular-nums; }
.store .co-line .held-course { margin: 6px 0 0; font-size: .82rem; }
.store .co-total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-family: var(--font-head); font-weight: 800; }
.store .co-total span:last-child { font-size: 1.7rem; color: var(--accent-deep, var(--accent)); font-variant-numeric: tabular-nums; }
.store .co-sum .checkout-legal__notice { margin: 0; padding-top: 14px; border-top: 1px solid var(--border); color: var(--muted); font-size: .76rem; line-height: 1.55; }
.store .co-sum .checkout-legal__cb { font-size: .84rem; font-weight: 400; color: var(--text); line-height: 1.5; }
.store .co-pay-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 15px 18px; font-size: 1rem; }
.store .co-pay-btn .ic { width: 18px; height: 18px; }
.store .co-info { padding: 14px 16px; border-radius: var(--store-radius-sm); background: color-mix(in srgb, var(--text) 3%, var(--surface)); border: 1px solid var(--border); font-size: .82rem; color: var(--muted); }
.store .co-info p { margin: 0; line-height: 1.5; }
.store .co-info p + p { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); }
.store .co-info__t { display: flex; align-items: center; gap: 7px; color: var(--text); font-weight: 700; }
.store .co-info__t .ic { width: 16px; height: 16px; color: var(--accent); }
.store .co-info strong { color: var(--text); }

@media (max-width: 980px) {
  .store .co-grid { grid-template-columns: minmax(0, 1fr); }
  .store .co-sum { position: static; }
}
@media (max-width: 640px) {
  .store .co-steps { display: none; }
  .store .co-card { padding: 18px 16px; }
  .store .co-kinds, .store .co-fields, .store .co-fields--addr { grid-template-columns: minmax(0, 1fr); }
  .store .co-fields--addr .co-f2 { grid-column: 1 / -1; }
}
