/* ============================================================================
   21-oferta.css — MINIATURA KONSTRUKCJI W OFERCIE, KARTOTEKA „ATRAKCJE”, SPACER 360
   ----------------------------------------------------------------------------
   Okno oferty konsultacji (wersje w zakładkach, karty konstrukcji, filtry) ma od 18.10.2026 własne arkusze:
   4-widoki/21c-oferta-okno.css (komputer, tablet) i 9-telefon/24-oferta-okno.css (telefon); panel ceny i kosztów — 21b-oferta-dodatki.css.
   Tu zostały: stany miniatury karty (zdjęcie, PDF, brak zdjęcia, błąd ładowania), formularz kartoteki Atrakcje i podgląd spaceru 360.
   Czego TU NIE MA: popover z listą atrakcji i konfigurator prezentacji — oba siedzą w 18-prezentacje.css.
   ============================================================================ */
/* === 1. MINIATURA KARTY KONSTRUKCJI (rozmiar i ramka: 21c) === */
.offer-thumb-card { position: relative; display: grid; place-items: center; overflow: hidden; color: var(--accent-strong); }
.offer-thumb-card.placeholder { color: var(--text-faint); }
/* Podgląd PDF rysuje się na <canvas> z własnym tłem — karta nie może go zakryć. */
.offer-thumb-card.has-document { background: none; }
.offer-thumb-image { display: block; width: 100%; height: 100%; object-fit: contain; }
/* Zapasowa ikona wchodzi dopiero, gdy podgląd nie wstał (klasę dokłada JS). */
.offer-thumb-fallback { display: none; place-items: center; gap: var(--s-1); width: 100%; height: 100%; background: var(--surface-3); }
.offer-thumb-fallback .icon { width: var(--s-7); height: var(--s-7); }
.offer-thumb-fallback small { color: var(--text-muted); font-size: var(--t-xs); font-weight: var(--w-bold); text-align: center; }
.offer-thumb-fallback.is-empty { display: grid; background: transparent; color: var(--text-faint); }
.thumb-failed .offer-thumb-image { display: none; }
.thumb-failed .offer-thumb-fallback { display: grid; }
/* === 8. KARTOTEKA ATRAKCJE — formularz z tabelą tłumaczeń =================
   Klasy `af-*` występują wyłącznie w tym formularzu, więc nie potrzebują
   przedrostka — dzięki temu selektory zostają płytkie. */
.attraction-form { display: grid; gap: var(--s-3); }
.af-card { padding: var(--s-3) var(--s-4); border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); }
.af-card-head { margin-bottom: var(--s-3); }
.af-card-head-row { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-3); }
/* Nagłówek sekcji z pionową kreską akcentu — czyta się jak zakładka segregatora. */
.attraction-form h4 { display: flex; align-items: center; gap: var(--s-2); color: var(--text-muted); font-size: var(--t-sm); font-weight: var(--w-bold); }
.attraction-form h4::before { content: ""; width: 3px; height: var(--s-3); border-radius: var(--r-sm); background: var(--accent); }
.af-card-sub { margin-top: var(--s-1); color: var(--text-muted); font-size: var(--t-xs); line-height: var(--lh-base); }
/* Tabela języków: jedna ramka wokół całości, wiersze rozdzielone włosem. */
.af-lang-table { display: grid; overflow: hidden; border: 1px solid var(--line); border-radius: var(--r); }
.af-lang-row { display: grid; grid-template-columns: 136px minmax(0, 1fr) 104px; align-items: center; gap: var(--s-2); padding: var(--s-2) var(--s-3); border-top: 1px solid var(--line); }
.af-lang-row:first-child { border-top: 0; }
/* Wiersz źródłowy (EN) wyróżniony tłem — z niego tłumaczy się całą resztę. */
.af-lang-base { background: var(--accent-soft); }
.af-flag { display: flex; align-items: center; gap: var(--s-2); min-width: 0; }
.af-flag b { display: inline-flex; align-items: center; justify-content: center; min-width: 36px; height: var(--h-control-sm); padding: 0 var(--s-2); border: 1px solid var(--line-strong); border-radius: var(--r-sm); background: var(--surface-3); font-size: var(--t-xs); font-weight: var(--w-bold); }
.af-lang-base b { border-color: var(--accent-strong); background: var(--accent); color: var(--text-invert); }
.af-flag span { color: var(--text-muted); font-size: var(--t-xs); }
.af-lang-base .af-input { border-color: var(--accent-strong); font-weight: var(--w-bold); }
/* Pole świeżo uzupełnione tłumaczeniem — widać, CO właśnie się zmieniło. */
.af-just-filled { border-color: var(--accent-strong); background: var(--accent-soft); transition: background var(--wolno), border-color var(--wolno); }
/* Znacznik „źródło" i guzik pojedynczego tłumaczenia stoją przy prawej krawędzi. */
.af-src-tag, .af-tr-one { justify-self: end; height: var(--h-control-sm); padding: 0 var(--s-3); border-radius: var(--r-pill); font-size: var(--t-xs); font-weight: var(--w-bold); white-space: nowrap; }
.af-src-tag { display: inline-grid; place-items: center; border: 1px solid var(--accent-strong); background: var(--accent); color: var(--text-invert); }
.af-tr-one { border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text-muted); cursor: pointer; }
.af-tr-one:hover { border-color: var(--accent-strong); background: var(--accent-soft); color: var(--accent-strong); }
.af-tr-all { display: inline-flex; align-items: center; gap: var(--s-2); flex: 0 0 auto; height: var(--h-control); padding: 0 var(--s-3); border: 1px solid var(--accent); border-radius: var(--r); background: var(--accent); color: var(--text-invert); font-size: var(--t-xs); font-weight: var(--w-bold); white-space: nowrap; cursor: pointer; }
.af-tr-all:hover { border-color: var(--accent-hover); background: var(--accent-hover); }
.af-tr-all:disabled, .af-tr-one:disabled { opacity: .6; cursor: default; }
/* Pulsowanie = „tłumaczę". Bez niego przycisk wygląda na zawieszony. */
.af-tr-all.is-loading, .af-tr-one.is-loading { animation: oferta-puls 1s ease-in-out infinite; }
@keyframes oferta-puls {
  50% { opacity: .55; }
}
:where(:root[data-ui="mobile"]) .af-lang-row { grid-template-columns: auto minmax(0, 1fr); }
:where(:root[data-ui="mobile"]) .af-flag span { display: none; }
:where(:root[data-ui="mobile"]) .af-src-tag, :where(:root[data-ui="mobile"]) .af-tr-one { grid-column: 1 / -1; justify-self: start; }
/* --- Spacer 360 w ofercie (z dawnego 28, K17) --- */
.tour3d-item { grid-template-columns: 96px minmax(0, 1fr) var(--h-control) var(--h-control); }
.tour3d-thumb { display: flex; align-items: center; justify-content: center; background: var(--accent-soft); color: var(--accent-strong); }
.tour3d-thumb svg { width: 40px; height: var(--h-row); }
.tour3d-open { color: var(--accent-strong); }
.tour3d-open svg { width: 18px; height: 18px; }
