/* 0.99.8 · pkt 4 / 0.99.9: strona „Rozpoznaj minifigurkę” dokładnie według makiety „Wersja 2” (ciemny, jasny, telefon).
   Pełna szerokość nagłówka z banerem, treść w kolumnie 1232 px. Zmienne z makiety, motyw przełącza data-ui-theme. */
.sf-rec2 { --r-banner: #121619; --r-surface: #171D28; --r-surface2: #1E2633; --r-stage: #0C1016; --r-line: #2B3546; --r-line2: #3A4659;
  --r-text: #EEF2F8; --r-muted: #A3AEBF; --r-body: #B7C1D0; --r-primary: #2A6FD6; --r-link: #8DBBFF; --r-sel-bg: #EEF2F8; --r-sel-text: #10141B;
  --r-good: #6FD39B; --r-good-bar: #3BB273; --r-warn: #F5B25C; --r-warn-line: #F0A03C; --r-danger: #FF9A9A; --r-saved-bg: #1F2B3F;
  --r-ph1: #283141; --r-ph2: #222A37; --r-sil: #4A5870; --r-corner: #F7C61A; --r-scrim: rgba(12, 16, 22, .85); --r-catalog: #F4F6FA; --r-bg: #10141B;
  --r-hero-img: url("../images/headers/sf-rozpoznaj-header-dark.jpg");
  max-width: 1232px; margin: 0 auto; padding: 0 24px 80px; box-sizing: border-box; color: var(--r-text); font-variant-numeric: tabular-nums; }
html[data-ui-theme="light"] .sf-rec2 { --r-banner: #F0E8DB; --r-surface: #FFFFFF; --r-surface2: #F3F5F8; --r-stage: #F7F8FA; --r-line: #D5DAE2; --r-line2: #BFC7D3;
  --r-text: #141A24; --r-muted: #4F5867; --r-body: #3A4352; --r-primary: #0057A8; --r-link: #0057A8; --r-sel-bg: #141A24; --r-sel-text: #FFFFFF;
  --r-good: #1E7A47; --r-good-bar: #2FAE64; --r-warn: #9A5200; --r-warn-line: #E08A1E; --r-danger: #C4262E; --r-saved-bg: #E3EEFA;
  --r-ph1: #D6DCE4; --r-ph2: #E2E6EC; --r-sil: #97A3B4; --r-corner: #E8B100; --r-scrim: rgba(20, 26, 36, .82); --r-catalog: #FFFFFF; --r-bg: #E9ECF1;
  --r-hero-img: url("../images/headers/sf-rozpoznaj-header-light.jpg"); }
html[data-ui-theme] body:has(.sf-rec2-hero) { background-image: none !important; background-color: #10141B !important; }
html[data-ui-theme="light"] body:has(.sf-rec2-hero) { background-color: #E9ECF1 !important; }
html:has(.sf-rec2-hero) { overflow-x: clip; }
.sf-rec2 a { color: var(--r-link); }
.sf-rec2 :is(a, button, input, summary, select, label):focus-visible { outline: 3px solid var(--r-link); outline-offset: 2px; }
html[data-ui-theme] body .main-content .sf-rec2 :is(h1, h2, h3) { color: var(--r-text); }

/* nagłówek z banerem (pełna szerokość) */
.sf-rec2-hero { position: relative; background: var(--r-banner); box-shadow: 0 0 0 100vmax var(--r-banner); clip-path: inset(0 -100vmax); }
.sf-rec2-hero::before { content: ""; position: absolute; top: 0; bottom: 0; right: calc(50% - 50vw); width: 100vw; background: var(--r-hero-img) right bottom / auto 100% no-repeat; pointer-events: none; }
.sf-rec2-hero::after { content: ""; position: absolute; left: calc(50% - 50vw); right: calc(50% - 50vw); bottom: 0; height: 1px; background: var(--r-line); }
.sf-rec2-hero-in { position: relative; z-index: 1; min-height: 280px; padding: 30px 0 40px; box-sizing: border-box; display: flex; flex-direction: column; justify-content: center; gap: 12px; }
.sf-rec2-btxt { max-width: min(600px, 56%); }
.sf-rec2-crumbs { font-size: 13px; color: var(--r-muted); } .sf-rec2 .sf-rec2-crumbs a { color: var(--r-muted); }
html[data-ui-theme] body .main-content .sf-rec2-hero h1 { margin: 0; font: 800 52px/1 var(--b-font-display); letter-spacing: -.02em; }
.sf-rec2-dot { color: var(--r-corner); }
.sf-rec2-lead { margin: 0; color: var(--r-body); font-size: 17px; line-height: 1.5; }
.sf-rec2-hero .sf-rec-credit { margin: 2px 0 0; padding: 0; border: 0; background: none; font-size: 13px; color: var(--r-muted); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.sf-rec2-hero .sf-rec-credit-brand { display: inline-flex; align-items: center; gap: 6px; color: var(--r-text) !important; font-size: 15px; text-decoration: none; }

.sf-rec2-note { margin: 20px 0 0; padding: 12px 16px; border-radius: 12px; border: 1px solid var(--r-line); background: var(--r-surface); color: var(--r-text); }
.sf-rec2-note.is-err { border-color: var(--r-danger); }

/* przyciski */
.sf-rec2-btn { position: relative; min-height: 46px; padding: 0 18px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; font: 600 14px var(--b-font); text-decoration: none; cursor: pointer; box-sizing: border-box; white-space: nowrap; }
.sf-rec2 .sf-rec2-btn.is-primary, html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-btn.is-primary { border: 0; background: var(--r-primary); color: #fff; font-weight: 700; box-shadow: none; }
.sf-rec2 .sf-rec2-btn.is-outline, html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-btn.is-outline { border: 1px solid var(--r-line2); background: transparent; color: var(--r-text); box-shadow: none; }
.sf-rec2-btn.is-grow { flex: 1; }
.sf-rec2-btn.is-sm { min-height: 36px; padding: 0 12px; font-size: 13px; }
.sf-rec2-btn input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }

/* rozpoznawanie: kadr po lewej, „Ostatni wynik” po prawej */
.sf-rec2-work { display: flex; gap: 24px; flex-wrap: wrap; align-items: flex-start; margin-top: 28px; }
.sf-rec2-left { flex: 2 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.sf-rec2-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.sf-rec2-seg { display: inline-flex; gap: 2px; padding: 4px; background: var(--r-surface); border: 1px solid var(--r-line); border-radius: 12px; flex-wrap: wrap; }
.sf-rec2 .sf-rec2-seg a { min-height: 40px; padding: 0 16px; border-radius: 9px; display: inline-flex; align-items: center; color: var(--r-body); font: 600 14px var(--b-font); text-decoration: none; }
.sf-rec2 .sf-rec2-seg a[aria-current="page"] { background: var(--r-sel-bg); color: var(--r-sel-text); font-weight: 700; }
.sf-rec2-hint { font-size: 13px; color: var(--r-muted); }
.sf-rec2-form { display: flex; flex-direction: column; gap: 14px; margin: 0; }
.sf-rec2-stage { position: relative; aspect-ratio: 16 / 9; background: var(--r-stage); border: 1px solid var(--r-line); border-radius: 22px; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 24px; box-sizing: border-box; }
.sf-rec2-form.is-dragover .sf-rec2-stage { border-color: var(--r-corner); box-shadow: inset 0 0 0 3px var(--r-corner); }
.sf-rec2-corner { position: absolute; width: 44px; height: 44px; border: 0 solid var(--r-corner); }
.sf-rec2-corner.is-tl { left: 22px; top: 22px; border-left-width: 4px; border-top-width: 4px; border-top-left-radius: 10px; }
.sf-rec2-corner.is-tr { right: 22px; top: 22px; border-right-width: 4px; border-top-width: 4px; border-top-right-radius: 10px; }
.sf-rec2-corner.is-bl { left: 22px; bottom: 22px; border-left-width: 4px; border-bottom-width: 4px; border-bottom-left-radius: 10px; }
.sf-rec2-corner.is-br { right: 22px; bottom: 22px; border-right-width: 4px; border-bottom-width: 4px; border-bottom-right-radius: 10px; }
.sf-rec2-sil { color: var(--r-sil); flex: none; }
.sf-rec2-stage-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: var(--r-stage); }
.sf-rec2-form.has-photos .sf-rec2-sil, .sf-rec2-form.has-photos .sf-rec2-stage-title { display: none; }
.sf-rec2-form.has-photos .sf-rec2-stage-btns { position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%); }
.sf-rec2-form.has-photos .sf-rec2-stage-btns .sf-rec2-btn.is-outline { background: var(--r-scrim); color: #fff; }
html[data-ui-theme] body .main-content .sf-rec2-stage-title { margin: 0; font: 700 22px var(--b-font-display); text-align: center; position: relative; }
.sf-rec2-stage-btns { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; position: relative; z-index: 1; }
.sf-rec2-stage-btns .sf-rec2-btn { min-height: 48px; font-size: 15px; }
.sf-rec2-guest-note { margin: 0; font-size: 13px; color: var(--r-muted); text-align: center; position: relative; }
.sf-rec2-msg { margin: 0; color: var(--r-danger); font-size: 14px; }
.sf-rec2-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.sf-rec2-slots { display: flex; gap: 10px; flex: 1; min-width: 280px; flex-wrap: wrap; }
.sf-rec2-slot { display: flex; align-items: center; gap: 10px; padding: 6px 8px 6px 6px; background: var(--r-surface); border: 1px solid var(--r-line); border-radius: 12px; }
.sf-rec2-slot img { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; display: block; }
.sf-rec2-slot > span { display: flex; flex-direction: column; font-size: 13px; } .sf-rec2-slot > span span { color: var(--r-muted); }
html[data-ui-theme] body .main-content .sf-rec2-slot button { width: 32px; height: 32px; min-height: 32px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--r-muted); display: flex; align-items: center; justify-content: center; box-shadow: none; cursor: pointer; }
html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-slot-add { display: flex; align-items: center; gap: 10px; min-height: 58px; padding: 6px 14px 6px 6px; background: transparent; border: 1px dashed var(--r-line2); border-radius: 12px; color: var(--r-text); font: 600 13px var(--b-font); box-shadow: none; cursor: pointer; }
.sf-rec2-slot-add span { width: 44px; height: 44px; border-radius: 8px; background: var(--r-surface2); display: flex; align-items: center; justify-content: center; color: var(--r-link); font-size: 22px; font-weight: 400; }
html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-submit { min-height: 56px; padding: 0 34px; border: 0; border-radius: 14px; background: #F7C61A; color: #10141B; font: 800 17px var(--b-font); box-shadow: none; cursor: pointer; }
html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-submit:disabled { opacity: .7; }
.sf-rec2-keep { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--r-body); }
.sf-rec2-keep input { width: 18px; height: 18px; accent-color: var(--r-primary); flex: none; }

.sf-rec2-result { flex: 1 1 340px; min-width: 0; background: var(--r-surface); border: 1px solid var(--r-line); border-radius: 22px; padding: 20px; display: flex; flex-direction: column; gap: 16px; box-sizing: border-box; }
.sf-rec2-result-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
html[data-ui-theme] body .main-content .sf-rec2-result-head h2 { margin: 0; font: 800 22px var(--b-font-display); }
.sf-rec2-result-head span { font-size: 13px; color: var(--r-muted); }
.sf-rec2-cmp { position: relative; aspect-ratio: 1; border-radius: 16px; overflow: hidden; border: 1px solid var(--r-line); background: var(--r-catalog); --split: 55%; }
.sf-rec2-cmp img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; }
.sf-rec2-cmp img.is-catalog { padding: 12px; box-sizing: border-box; }
.sf-rec2-cmp img.is-photo-only { object-fit: cover; }
.sf-rec2-cmp-photo { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--split)) 0 0); background: repeating-linear-gradient(135deg, var(--r-ph1) 0 9px, var(--r-ph2) 9px 18px); }
.sf-rec2-cmp-photo img { object-fit: cover; }
.sf-rec2-cmp-line { position: absolute; top: 0; bottom: 0; left: var(--split); width: 3px; margin-left: -1.5px; background: #F7C61A; pointer-events: none; }
.sf-rec2-cmp-knob { position: absolute; top: 50%; left: var(--split); width: 40px; height: 40px; margin: -20px 0 0 -20px; border-radius: 50%; border: 3px solid #F7C61A; background: #10141B; color: #F7C61A; display: flex; align-items: center; justify-content: center; box-sizing: border-box; pointer-events: none; }
.sf-rec2-cmp input[type=range] { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.sf-rec2-cmp:has(input:focus-visible) .sf-rec2-cmp-knob { outline: 3px solid var(--r-link); outline-offset: 2px; }
.sf-rec2-tag { position: absolute; bottom: 10px; padding: 4px 8px; border-radius: 6px; font-size: 12px; font-weight: 600; color: #fff; pointer-events: none; }
.sf-rec2-tag.is-photo { left: 10px; background: var(--r-scrim); } .sf-rec2-tag.is-cat { right: 10px; background: #10141B; }
html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-cmp-zoom { position: absolute; right: 10px; top: 10px; width: 40px; height: 40px; min-height: 40px; padding: 0; border: 0; border-radius: 10px; background: var(--r-scrim); color: #fff; display: flex; align-items: center; justify-content: center; box-shadow: none; cursor: zoom-in; z-index: 2; }
.sf-rec2-cmp.is-empty { display: flex; background: none; }
.sf-rec2-cmp.is-empty .sf-rec2-ph { width: 55%; background: repeating-linear-gradient(135deg, var(--r-ph1) 0 9px, var(--r-ph2) 9px 18px); }
.sf-rec2-cmp.is-empty .sf-rec2-cat-ph { flex: 1; background: var(--r-catalog); border-left: 3px solid #F7C61A; }
.sf-rec2-best { display: flex; flex-direction: column; gap: 16px; margin: 0; }
.sf-rec2-best-name { display: flex; flex-direction: column; gap: 4px; }
html[data-ui-theme] body .main-content .sf-rec2-best-name h3 { margin: 0; font: 700 19px/1.3 var(--b-font); }
.sf-rec2-best-name p { margin: 0; font-size: 14px; color: var(--r-muted); }
.sf-rec2-score { display: flex; align-items: center; gap: 12px; }
.sf-rec2-bar { flex: 1; height: 8px; background: var(--r-line); border-radius: 999px; overflow: hidden; }
.sf-rec2-bar i { display: block; height: 100%; background: var(--r-good-bar); }
.sf-rec2-score strong { font-size: 14px; color: var(--r-good); white-space: nowrap; }
.sf-rec2-score.is-low .sf-rec2-bar i { background: var(--r-warn-line); } .sf-rec2-score.is-low strong { color: var(--r-warn); }
.sf-rec2-owned { margin: 0; font-size: 14px; color: var(--r-body); display: flex; gap: 8px; align-items: center; }
.sf-rec2-owned svg { color: var(--r-good); flex: none; }
.sf-rec2-opts summary { cursor: pointer; font-size: 13px; color: var(--r-muted); }
.sf-rec2-opts-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.sf-rec2-opts-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--r-muted); }
html[data-ui-theme] body .main-content .sf-rec2-opts-grid :is(input, select) { min-height: 40px; width: 100%; box-sizing: border-box; margin: 0; padding: 0 10px; border-radius: 10px; border: 1px solid var(--r-line2); background: var(--r-bg); color: var(--r-text); font: 600 14px var(--b-font); box-shadow: none; }
.sf-rec2-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.sf-rec2-empty { margin: 0; color: var(--r-body); font-size: 14px; line-height: 1.5; }

/* inne wyniki */
.sf-rec2-others { margin-top: 40px; display: flex; flex-direction: column; gap: 14px; }
html[data-ui-theme] body .main-content .sf-rec2-others h2 { margin: 0; font: 800 24px var(--b-font-display); }
.sf-rec2-others-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.sf-rec2-other { display: flex; flex-direction: column; gap: 10px; padding: 12px; background: var(--r-surface); border: 1px solid var(--r-line); border-radius: 16px; }
.sf-rec2-other.is-best { border-color: #F7C61A; }
.sf-rec2-other-img { aspect-ratio: 4 / 3; background: var(--r-catalog); border-radius: 10px; display: flex; align-items: center; justify-content: center; padding: 8px; box-sizing: border-box; }
.sf-rec2-other-img img { max-width: 100%; max-height: 100%; object-fit: contain; }
html[data-ui-theme] body .main-content .sf-rec2-other h3, .sf-rec2-hitem h3 { margin: 0; font: 700 14px/1.3 var(--b-font); }
.sf-rec2-other p, .sf-rec2-htext p { margin: 0; font-size: 12px; color: var(--r-muted); }
.sf-rec2-pct.is-good { color: var(--r-good) !important; font-weight: 700; } .sf-rec2-pct.is-low { color: var(--r-warn) !important; font-weight: 700; }
.sf-rec2-other-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; }
.sf-rec2-small { margin: 0; font-size: 13px; color: var(--r-muted); }
.sf-rec2-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* historia */
.sf-rec2-history { margin-top: 48px; display: flex; flex-direction: column; gap: 18px; }
.sf-rec2-history-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
html[data-ui-theme] body .main-content .sf-rec2-history-head h2 { margin: 0; font: 800 30px var(--b-font-display); }
.sf-rec2-history-count { font-size: 14px; color: var(--r-muted); }
.sf-rec2-grow { flex: 1; }
.sf-rec2-chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.sf-rec2-chips form { margin: 0; }
html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-chip { min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--r-line2); background: transparent; color: var(--r-body); font: 600 13px var(--b-font); box-shadow: none; cursor: pointer; }
html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-chip[aria-pressed="true"] { background: var(--r-sel-bg); border-color: var(--r-sel-bg); color: var(--r-sel-text); font-weight: 700; }
html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-clear { min-height: 38px; padding: 0 12px; border: 0; background: transparent; color: var(--r-danger); font: 600 13px var(--b-font); box-shadow: none; cursor: pointer; }
.sf-rec2-history-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 22px 16px; }
.sf-rec2-hitem { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.sf-rec2-hitem[hidden], .sf-rec2-history:not(.is-expanded):not(.is-filtered) .sf-rec2-hitem.is-extra { display: none; }
.sf-rec2-himg { position: relative; aspect-ratio: 1; width: 100%; border-radius: 16px; overflow: hidden; cursor: zoom-in; display: block; background: repeating-linear-gradient(135deg, var(--r-ph1) 0 9px, var(--r-ph2) 9px 18px); }
.sf-rec2-himg > img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sf-rec2-hcat { position: absolute; right: 8px; bottom: 8px; width: 46px; height: 46px; border-radius: 10px; background: var(--r-catalog); border: 3px solid var(--r-bg); display: flex; align-items: center; justify-content: center; overflow: hidden; box-sizing: border-box; }
.sf-rec2-hcat img { max-width: 100%; max-height: 100%; object-fit: contain; }
.sf-rec2-hbody { display: flex; gap: 8px; align-items: flex-start; }
.sf-rec2-htext { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.sf-rec2-htext h3 a { color: var(--r-text) !important; text-decoration: none; }
html[data-ui-theme] body .main-content .sf-rec2 .sf-rec2-hsave .sf-save-btn { width: 40px; height: 40px; min-height: 40px; padding: 0; border: 1px solid var(--r-line2); border-radius: 10px; background: transparent; color: var(--r-body); display: flex; align-items: center; justify-content: center; box-shadow: none; }
html[data-ui-theme] body .main-content .sf-rec2 .sf-rec2-hsave .sf-save-btn [data-save-label] { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
html[data-ui-theme] body .main-content .sf-rec2 .sf-rec2-hsave .sf-save-btn svg { fill: none; }
html[data-ui-theme] body .main-content .sf-rec2 .sf-rec2-hsave .sf-save-btn.is-saved { border-color: transparent; background: var(--r-saved-bg); color: var(--r-link); }
html[data-ui-theme] body .main-content .sf-rec2 .sf-rec2-hsave .sf-save-btn.is-saved svg { fill: currentColor; }
.sf-rec2-more { align-self: center; }

/* „Jak rozpoznać” obok FAQ */
.sf-rec2-info { display: flex; gap: 48px; flex-wrap: wrap; border-top: 1px solid var(--r-line); padding-top: 40px; margin-top: 48px; }
.sf-rec2-howto { flex: 1 1 400px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.sf-rec2-faq { flex: 1 1 460px; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
html[data-ui-theme] body .main-content .sf-rec2-info h2 { margin: 0; font: 800 30px/1.1 var(--b-font-display); }
.sf-rec2-faq h2 { margin-bottom: 8px !important; }
.sf-rec2-howto ol { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 16px; }
.sf-rec2-howto li { display: flex; gap: 14px; }
.sf-rec2-howto li > span { flex: none; width: 32px; height: 32px; border-radius: 50%; background: #F7C61A; color: #10141B; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.sf-rec2-howto li p { margin: 4px 0 0; color: var(--r-body); line-height: 1.55; }
.sf-rec2-howto li strong { color: var(--r-text); }
.sf-rec2-faq details { border-bottom: 1px solid var(--r-line); }
.sf-rec2-faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; align-items: center; min-height: 56px; font-weight: 700; font-size: 16px; color: var(--r-text); }
.sf-rec2-faq summary::-webkit-details-marker { display: none; }
.sf-rec2-faq summary::after { content: "+"; font-size: 18px; color: var(--r-text); }
.sf-rec2-faq details[open] summary::after { content: "−"; }
.sf-rec2-faq p { margin: 0 0 16px; color: var(--r-body); line-height: 1.55; }

/* powiększenie zdjęcia z historii */
.sf-rec2-viewer { width: min(1280px, 96vw); max-width: none; height: min(820px, 92vh); padding: 0; border: 0; border-radius: 18px; background: #07090D; color: #EEF2F8; display: none; }
.sf-rec2-viewer[open] { display: flex; }
.sf-rec2-viewer::backdrop { background: rgba(0, 0, 0, .7); }
.sf-rec2-viewer-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 14px; padding: 20px 24px; }
.sf-rec2-viewer-tabs { display: inline-flex; gap: 2px; padding: 4px; background: #171D28; border-radius: 12px; align-self: flex-start; flex-wrap: wrap; }
html[data-ui-theme] body .main-content .sf-rec2-viewer-tabs button, .sf-rec2-viewer-tabs button { min-height: 38px; padding: 0 14px; border: 0; border-radius: 9px; background: transparent; color: #B7C1D0; font-weight: 600; font-size: 13px; box-shadow: none; }
html[data-ui-theme] body .main-content .sf-rec2-viewer-tabs button[aria-selected="true"], .sf-rec2-viewer-tabs button[aria-selected="true"] { background: #EEF2F8; color: #10141B; font-weight: 700; }
.sf-rec2-vstage { position: relative; flex: 1; border-radius: 18px; overflow: hidden; background: #fff; }
.sf-rec2-vstage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.sf-rec2-photo-clip { position: absolute; inset: 0 auto 0 0; overflow: hidden; background: #1E2633; border-right: 3px solid #F7C61A; }
.sf-rec2-photo-clip img { width: calc(100vw); max-width: none; }
.sf-rec2-vstage[data-mode="compare"] .sf-rec2-photo-clip img { width: min(1232px, 92vw); height: 100%; }
.sf-rec2-vstage[data-mode="photo"] .sf-rec2-photo-clip { width: 100% !important; border-right: 0; }
.sf-rec2-vstage[data-mode="catalog"] .sf-rec2-photo-clip { display: none; }
.sf-rec2-vstage:not([data-mode="compare"]) .sf-rec2-split { display: none; }
.sf-rec2-split { position: absolute; left: 0; right: 0; bottom: 14px; width: calc(100% - 28px); margin: 0 14px; accent-color: #F7C61A; }
.sf-rec2-viewer-hint { margin: 0; font-size: 13px; color: #A3AEBF; }
.sf-rec2-viewer-side { width: 320px; flex: none; background: #141A24; border-left: 1px solid #2B3546; padding: 20px 22px; display: flex; flex-direction: column; gap: 14px; }
html[data-ui-theme] body .main-content .sf-rec2-viewer-side h2 { margin: 0; font: 800 24px/1.1 var(--b-font-display); color: #EEF2F8; }
.sf-rec2-viewer-side .sf-rec2-muted { color: #A3AEBF; }
html[data-ui-theme] body .main-content button.sf-rec2-viewer-close, .sf-rec2-viewer-close { align-self: flex-end; width: 44px; height: 44px; min-height: 44px; padding: 0; border: 0; border-radius: 50%; background: #1E2633; color: #EEF2F8; font-size: 24px; line-height: 1; box-shadow: none; }
.sf-rec2-viewer-links { display: flex; flex-direction: column; gap: 10px; }
.sf-rec2-viewer-links .sf-rec2-btn.is-outline { color: #EEF2F8 !important; border: 1px solid #3A4659; }

@media (max-width: 760px) {
  .sf-rec2 { padding: 0 16px 60px; }
  .sf-rec2-hero::before { position: relative; display: block; right: auto; width: 100%; height: 170px; order: 9; background-size: cover; }
  .sf-rec2-hero { display: flex; flex-direction: column; }
  .sf-rec2-btxt { max-width: none; }
  html[data-ui-theme] body .main-content .sf-rec2-hero h1 { font-size: 34px; }
  .sf-rec2-hero-in { min-height: 0; padding-bottom: 20px; }
  .sf-rec2-stage { aspect-ratio: 4 / 5; }
  .sf-rec2-row { flex-direction: column; align-items: stretch; }
  .sf-rec2-slots { min-width: 0; }
  html[data-ui-theme] body .main-content .sf-rec2 button.sf-rec2-submit { width: 100%; }
  .sf-rec2-history-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 12px; }
  .sf-rec2-opts-grid { grid-template-columns: 1fr; }
  .sf-rec2-viewer[open] { flex-direction: column; } .sf-rec2-viewer-side { width: auto; border-left: 0; border-top: 1px solid #2B3546; }
}
/* historia: wyłącza starszy styl wiersza historii (studfolio.css) */
.sf-rec2 .sf-rec2-history .sf-rec2-hitem { display: flex; flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 10px; padding: 0; border: 0; border-radius: 0; background: transparent; overflow: visible; }
.sf-rec2 .sf-rec2-history .sf-rec2-hitem[hidden] { display: none; }
.sf-rec2 .sf-rec2-history.is-filtered .sf-rec2-hitem.is-extra:not([hidden]) { display: flex; }
.sf-rec2 .sf-rec2-history .sf-rec2-himg { display: block; width: 100%; height: auto; aspect-ratio: 1; border-radius: 16px; background: repeating-linear-gradient(135deg, var(--r-ph1) 0 9px, var(--r-ph2) 9px 18px); }
.sf-rec2 .sf-rec2-history .sf-rec2-himg > img { width: 100%; height: 100%; object-fit: cover; }
.sf-rec2 .sf-rec2-history .sf-rec2-hcat img { width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; }
/* 0.99.9: ® przy LEGO w nagłówku i nota o znaku towarowym */
.sf-rec2-hero h1 sup { font: 700 .35em var(--b-font); vertical-align: super; }
.sf-rec2-tm { margin: 0; font-size: 12px; color: var(--r-muted); line-height: 1.5; }

/* 0.99.10: tryb „Klocki” — lista rozpoznanych klocków w stylu makiety */
html[data-ui-theme] body .main-content .sf-rec2-parts h2 span { font: 600 18px var(--b-font); color: var(--r-muted); }
.sf-rec2-part-list { display: flex; flex-direction: column; gap: 12px; }
.sf-rec2-part { display: grid; grid-template-columns: 140px minmax(0, 1fr) minmax(0, 1.1fr); gap: 16px; align-items: start; padding: 12px; background: var(--r-surface); border: 1px solid var(--r-line); border-radius: 16px; }
.sf-rec2-part.is-empty { grid-template-columns: 140px minmax(0, 1fr); opacity: .85; }
.sf-rec2-part-info { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
html[data-ui-theme] body .main-content .sf-rec2-part-info h3 { margin: 0; font: 700 15px/1.3 var(--b-font); }
.sf-rec2-part-info p { margin: 0; font-size: 13px; color: var(--r-muted); }
.sf-rec2-part-info p b { color: var(--r-text); }
.sf-rec2-part-fields { display: grid; grid-template-columns: auto minmax(0, 2fr) minmax(0, 1.2fr) 90px; gap: 8px; align-items: end; }
.sf-rec2-part-fields > label:not(.sf-rec2-keep) { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--r-muted); min-width: 0; }
.sf-rec2-part-fields .sf-rec2-keep { min-height: 40px; }
html[data-ui-theme] body .main-content .sf-rec2-part-fields :is(input[type=number], select) { min-height: 40px; width: 100%; box-sizing: border-box; margin: 0; padding: 0 10px; border-radius: 10px; border: 1px solid var(--r-line2); background: var(--r-bg); color: var(--r-text); font: 600 13px var(--b-font); box-shadow: none; }
.sf-rec2-parts .sf-rec2-actions { align-items: center; }
@media (max-width: 1000px) { .sf-rec2-part { grid-template-columns: 110px minmax(0, 1fr); } .sf-rec2-part-fields { grid-column: 1 / -1; } }
@media (max-width: 600px) { .sf-rec2-part-fields { grid-template-columns: 1fr 1fr; } .sf-rec2-part-fields .sf-rec2-keep { grid-column: 1 / -1; } }
.sf-rec2-hmore { font-size: 12px; color: var(--r-muted); }
.sf-rec2-hmore summary { cursor: pointer; }
.sf-rec2-hmore ol { margin: 6px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 2px; }
.sf-rec2-hmore p { margin: 6px 0 0; }
.sf-rec2-hmore b { color: var(--r-text); font-weight: 600; } .sf-rec2-hmore em { font-style: normal; color: var(--r-good); }
