/*
 * targ.info theme — wariant A „Grafit” (2026-10-13). Hand-written, loaded after app.css (Foundation 6 + 2019 custom, no build).
 * Rules here win by order; selectors copy app.css specificity where they must override it. Breakpoint: 720 px.
 * Never name classes ad-* (EasyList hides them); offers use offer-*.
 */
:root {
    --green: #2f7d1c;          /* 5.2:1 on white */
    --green-d: #256315;
    --green-t: #eef5ea;
    --ink: #1f2421;
    --ink-2: #545b56;          /* 7.0:1 on white */
    --ink-3: #6b716c;          /* 5.0:1 on white, 4.7:1 on --panel */
    --line: #e1e4e0;
    --line-2: #d3d7d2;
    --panel: #f6f7f5;
    --graphite: #2f2f2f;
    --warn-bg: #fff4d6;
    --warn: #7a5200;
    --danger: #b42318;
    --r: 6px;
    --h: 44px;
    --font: Lato, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

/* ---------- base ---------- */
html { background: #fff; }
body { background: #fff; color: var(--ink); font: 400 16px/24px var(--font); -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4, h5, h6 { color: var(--ink); font-family: var(--font); font-weight: 700; line-height: 1.25; }
h1 { font-size: 2rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.125rem; }
a { color: var(--green); }
a:hover, a:focus { color: var(--green-d); }
.content a, .breadcrumbs a { color: var(--green); }
input, textarea { caret-color: var(--green); }
:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }
select:focus-visible, textarea:focus-visible, input:focus-visible { outline: 3px solid var(--green); outline-offset: 1px; }
.skip-link { position: absolute; left: 8px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 8px 12px; border-radius: var(--r); }
.skip-link:focus { top: 8px; color: #fff; }
.sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.nowrap { white-space: nowrap; }
.muted { color: var(--ink-2); }
.i { flex: none; }
.wrap { max-width: none; margin-left: auto; margin-right: auto; padding-left: 24px; padding-right: 24px; }
.title-bar { background: transparent; color: var(--ink); }
.title-bar h1 { border-bottom: 0; }

/* Foundation form controls */
[type=text], [type=email], [type=password], [type=tel], [type=number], [type=search], [type=url], textarea, select {
    height: var(--h); border: 1px solid var(--line-2); border-radius: var(--r); box-shadow: none; background-color: #fff; color: var(--ink); font-size: 1rem;
}
textarea { height: auto; min-height: 6rem; }
[type=text]:focus, [type=email]:focus, [type=password]:focus, [type=tel]:focus, textarea:focus, select:focus { border-color: var(--green); box-shadow: none; }
::placeholder { color: var(--ink-3); opacity: 1; }
label { color: var(--ink); font-size: .9375rem; }
[type=checkbox], [type=radio] { accent-color: var(--green); }

/* buttons: app.css paints .button #54af36 (white on it = 2.9:1) */
.button, button.button { background-color: var(--green); color: #fff; border-radius: var(--r); font-weight: 700; }
.button:hover, .button:focus { background-color: var(--green-d); color: #fff; text-decoration: none; }
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: var(--h); padding: 0 24px; margin: 0;
    border: 1px solid transparent; border-radius: var(--r); font: 700 16px/24px var(--font); text-align: center; white-space: nowrap;
    cursor: pointer; text-decoration: none; transition: background-color .15s, border-color .15s, color .15s;
}
.btn:hover, .btn:focus { text-decoration: none; }
.btn--primary { background: var(--green); color: #fff; }
.btn--primary:hover, .btn--primary:focus { background: var(--green-d); color: #fff; }
.btn--ghost { background: #fff; color: var(--green); border-color: var(--line-2); }
.btn--ghost:hover, .btn--ghost:focus { background: var(--green-t); color: var(--green-d); border-color: var(--green); }
.btn--danger { background: #fff; color: var(--danger); border-color: #f1c0bb; }
.btn--danger:hover, .btn--danger:focus { background: #fdecea; color: var(--danger); }
.btn--small { height: 34px; padding: 0 12px; font-size: .875rem; }
.link-button { color: inherit; font: inherit; cursor: pointer; }

.tag { display: inline-block; padding: 2px 10px; border-radius: 999px; background: var(--green-t); color: var(--green-d); font-size: .8125rem; font-weight: 700; line-height: 1.6; text-decoration: none; }
a.tag:hover { background: #dcebd5; text-decoration: none; }
.tag--warn { background: var(--warn-bg); color: var(--warn); }
.tag--danger { background: #fdecea; color: var(--danger); }

.callout { border-radius: var(--r); font-size: 1rem; text-align: left; color: var(--ink); border-color: var(--line); }
.callout.success { background: var(--green-t); border-color: #c9d9c2; }
.callout.alert { background: #fdecea; border-color: #f1c0bb; }
.callout.warning { background: var(--warn-bg); border-color: #f0dca0; color: var(--warn); }
.notice { margin: 32px 0; padding: 16px 20px; background: #fff; border: 1px solid var(--line); border-radius: 8px; font-size: 1.1rem; }
#page-up, #back-to-top { background-color: var(--green); }

/* text field with a leading icon / select with a chevron (search band, sort) */
.field { position: relative; }
.field > .i { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }
.field input { margin: 0; padding-left: 44px; }
.field--select > .i { left: auto; right: 14px; color: var(--ink-2); }
.field--select select { margin: 0; padding: 0 40px 0 16px; background-image: none; cursor: pointer; }

/* ---------- header ---------- */
.site-header { position: relative; z-index: 20; }
.site-header__bar { display: flex; align-items: center; gap: 24px; height: 80px; background: #fff; }
.site-header { background: #fff; }
.site-header > .site-header__bar { border-bottom: 0; }
.brand { display: flex; align-items: center; gap: 24px; text-decoration: none; margin-right: auto; }
.brand:hover, .brand:focus { text-decoration: none; }
.brand img { height: 40px; width: auto; }
.brand__tagline { padding-left: 24px; border-left: 1px solid var(--line); color: var(--ink); font: 700 14px/20px var(--font); }
.brand__tagline span { display: block; color: var(--green); }
.site-nav { display: flex; align-items: center; gap: 24px; }
.site-nav__account { display: flex; align-items: center; gap: 24px; }
.site-nav__account form { margin: 0; }
.site-nav__login, .site-nav__account a, .site-nav__account .link-button { color: var(--green); font-weight: 700; text-decoration: none; }
.site-nav__account a, .site-nav__account .link-button { color: var(--ink); }
.site-nav__login:hover, .site-nav__account a:hover, .site-nav__account .link-button:hover { color: var(--green-d); text-decoration: underline; }
.nav-toggle { display: none; }

/* ---------- search band (graphite) ---------- */
.search-band { background: var(--graphite); padding: 24px 0; }
.search-bar { display: grid; grid-template-columns: 1fr 1fr 152px 160px; gap: 8px; margin: 0 auto; }
.search-band input, .search-band select { border-color: #fff; }
.search-band :focus-visible, .search-band input:focus-visible, .search-band select:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.search-bar--ask { grid-template-columns: minmax(0, 1fr) 160px; margin-top: 8px; }
.search-bar--ask .field { display: flex; align-items: center; gap: 12px; }
.search-bar--ask label { margin: 0; color: #fff; font-weight: 700; white-space: nowrap; }
.search-bar--ask input { padding-left: 16px; }
.search-band .search-bar--ask .btn--ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .6); }
.search-band .search-bar--ask .btn--ghost:hover { background: rgba(255, 255, 255, .1); }
.targ-understood { margin: 12px auto 0; color: #fff; }

/* ---------- categories: equal tiles, active = green underline ---------- */
.categories-search-bar { display: block; background: #fff; border-bottom: 1px solid var(--line); } /* app.css hides it < 600 px */
.categories-search-bar ul { list-style: none; display: grid; grid-template-columns: repeat(15, minmax(0, 1fr)); max-width: 1392px; margin: 0 auto; padding: 0 16px; }
.categories-search-bar li { margin: 0; }
.categories-search-bar .category, .categories-search-bar button.category {
    display: flex; flex-direction: column; align-items: center; gap: 8px; width: 100%; height: 100%; margin: 0; padding: 16px 4px 14px; float: none;
    background: transparent; border: 0; border-bottom: 2px solid transparent; border-radius: 0; color: var(--ink);
    font: 400 13px/16px var(--font); text-align: center; cursor: pointer;
}
.categories-search-bar .category img { width: 32px; height: 32px; margin: 0; opacity: .88; filter: none; -webkit-filter: none; }
.categories-search-bar .category span { font-size: inherit; }
.category__label { display: block; text-wrap: balance; }
.categories-search-bar .category small { margin-left: 3px; color: var(--ink-3); font-size: 12px; }
.categories-search-bar .category:hover { background: var(--panel); color: var(--ink); }
.categories-search-bar .category:hover img { filter: none; -webkit-filter: none; opacity: 1; }
.categories-search-bar .category[aria-pressed=true], .categories-search-bar .selected-category { border-bottom-color: var(--green); color: var(--green); font-weight: 700; }
.categories-search-bar .category[aria-pressed=true] img, .categories-search-bar .selected-category img { opacity: 1; }
.categories-search-bar .category--empty { color: var(--ink-3); }
.categories-search-bar .category--empty img { opacity: .45; }
.categories-search-bar .category:focus-visible { outline-offset: -3px; }
/* app.js pins this bar to the top on scroll (2019 dark header); this layout keeps it in flow. */
.fixed-categories-search-bar, .fixed-header-search-form { position: static !important; width: auto !important; }

/* ---------- map: edge to edge, no frame ---------- */
.map-band { position: relative; border-bottom: 1px solid var(--line); }
#map-targ { height: 420px; width: 100%; margin: 0; background: #e5e3df; }
.map-band__note {
    position: absolute; left: 24px; top: 16px; margin: 0; padding: 4px 12px; border-radius: var(--r);
    background: rgba(255, 255, 255, .94); box-shadow: 0 1px 2px rgba(0, 0, 0, .12); color: var(--ink-2); font-size: 13px; line-height: 20px; pointer-events: none;
}

/* ---------- results: filters panel + list ---------- */
.results { display: grid; grid-template-columns: 264px minmax(0, 1fr); gap: 32px; align-items: start; padding-top: 32px; }
.results__list { min-width: 0; }
.targ-filter { border: 1px solid var(--line); border-radius: 8px; padding: 24px; background: #fff; }
.targ-filter h2 { font: 700 16px/24px var(--font); margin: 0 0 16px; }
.targ-filter h3 { font: 700 14px/20px var(--font); margin: 0 0 8px; }
.targ-filter h3 label { font: inherit; margin: 0; }
.targ-filter section + section { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 24px; }
.price-range { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.price-range .field { display: flex; align-items: center; gap: 4px; height: var(--h); padding: 0 12px; border: 1px solid var(--line-2); border-radius: var(--r); }
.price-range b { font-weight: 400; }
.price-range em { font-style: normal; color: var(--ink-3); font-size: 14px; }
#slider-range.ui-slider { position: relative; height: 4px; margin: 24px 10px 8px; border: 0; border-radius: 2px; background: var(--line-2); }
#slider-range .ui-slider-range { top: 0; height: 100%; border: 0; border-radius: 2px; background: var(--green); }
#slider-range .ui-slider-handle {
    top: -8px; width: 20px; height: 20px; margin-left: -10px; border: 2px solid var(--green); border-radius: 50%; background: #fff; cursor: grab; outline: none;
}
#slider-range .ui-slider-handle:focus-visible { box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--green); }
.targ-filter .check { display: flex; align-items: center; gap: 12px; min-height: 32px; margin: 0; font-size: 15px; line-height: 20px; cursor: pointer; }
.targ-filter .check + .check { margin-top: 4px; }
.targ-filter .check input { width: 20px; height: 20px; margin: 0; flex: none; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-form { float: none; margin: 0; }
.tag-item, button.tag-item {
    display: inline-flex; align-items: center; height: 32px; margin: 0; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 16px;
    background: #fff; color: var(--ink-2); font-size: 14px; line-height: 1; cursor: pointer;
}
.tag-item:hover, button.tag-item:hover { background: #fff; border-color: var(--green); color: var(--green); }
.tag-item.selected-tag, .tag-item.selected-tag:hover { background: var(--green-t); border-color: var(--green); color: var(--green-d); font-weight: 700; }
.partner-logo { display: block; width: 160px; height: auto; margin-top: 8px; }

.list-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--h); margin: 0 0 16px; }
.list-head__title { font: 700 24px/32px var(--font); margin: 0; }
.list-head__title span { margin-left: 8px; color: var(--ink-2); font-size: 16px; font-weight: 400; }
.list-head__tools { display: flex; gap: 8px; }
.list-head .sort { width: 232px; }
.list-head .sort label { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); margin: 0; font-size: 1rem; color: var(--ink); pointer-events: none; }
.list-head .sort select { padding-left: 70px; }
.filters-btn { display: none; }
.wyszukiwanie-dla { color: var(--ink-2); margin: -4px 0 16px; }

/* ---------- offer card ---------- */
.offer-list { display: grid; gap: 16px; }
.offer-card {
    position: relative; display: grid; grid-template-columns: 176px minmax(0, 1fr); gap: 24px; padding: 16px;
    background: #fff; border: 1px solid var(--line); border-radius: 8px; transition: border-color .15s, box-shadow .15s;
}
.offer-card:hover { border-color: var(--line-2); box-shadow: 0 2px 8px rgba(0, 0, 0, .06); }
.offer-card.is-active { border-color: var(--green); box-shadow: 0 0 0 1px var(--green); }
.offer-card__thumb { aspect-ratio: 4 / 3; border-radius: 4px; overflow: hidden; background: var(--panel); }
.offer-card__thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.offer-card__thumb--empty { display: grid; place-items: center; }
.offer-card__thumb--empty img { width: 72px; height: 72px; object-fit: contain; opacity: .7; mix-blend-mode: multiply; }
.offer-card__body { display: flex; flex-direction: column; min-width: 0; }
.offer-card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; }
.offer-card__title { margin: 0; font: 700 18px/24px var(--font); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.offer-card__title a { color: var(--ink); text-decoration: none; }
.offer-card__title a::after { content: ""; position: absolute; inset: 0; border-radius: 8px; }
.offer-card:hover .offer-card__title a { color: var(--green); text-decoration: underline; }
.offer-card__title a:focus-visible { outline: none; }
.offer-card__title a:focus-visible::after { outline: 3px solid var(--green); outline-offset: 2px; }
.offer-card__price { margin: 0; font: 900 20px/24px var(--font); color: var(--green); white-space: nowrap; text-align: right; }
.offer-card__price span { font-weight: 400; font-size: 14px; color: var(--ink-2); }
.offer-card__price--none { font: 400 14px/24px var(--font); color: var(--ink-3); }
.offer-card__desc { margin: 8px 0 0; font-size: 14px; line-height: 20px; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.offer-card__meta { display: flex; align-items: center; min-width: 0; margin: auto 0 0; padding-top: 12px; font-size: 13px; line-height: 20px; color: var(--ink-3); white-space: nowrap; }
.offer-card__meta > span:not(.offer-card__stale) { overflow: hidden; text-overflow: ellipsis; }
.offer-card__meta > span:not(.offer-card__stale) + span:not(.offer-card__stale)::before { content: "·"; margin: 0 8px; color: #9aa09b; }
.offer-card__rating { color: var(--warn); font-weight: 700; flex: none; }
.offer-card__stale { display: inline-flex; align-items: center; gap: 4px; margin-left: auto; padding-left: 16px; color: var(--warn); font-size: 12px; }
.offer-card__stale .i { color: #a87a1e; }
.offer-card__actions { position: relative; z-index: 1; display: flex; gap: 8px; margin-top: 12px; }
.offer-card__actions form { margin: 0; }

.pager { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 32px 0 0; padding: 0; list-style: none; }
.pager li { margin: 0; padding: 0; border: 0; border-radius: 0; background: none; }
.pager li a, .pager li span {
    display: grid; place-items: center; min-width: var(--h); height: var(--h); padding: 0 12px;
    border: 1px solid var(--line-2); border-radius: var(--r); background: #fff; color: var(--ink-2); font-weight: 700; text-decoration: none;
}
.pager li a[rel] { color: var(--green); }
.pager li.active, .pager li:not(.disabled):hover { background: none; }
.pager li.active span { background: var(--green); border-color: var(--green); color: #fff; }
.pager li:not(.disabled):not(.active) a:hover { border-color: var(--green); color: var(--green); }
.pager li.disabled span { border: 0; min-width: 24px; padding: 0; color: var(--ink-3); font-weight: 400; }
.pager li.disabled:first-child, .pager li.disabled:last-child { display: none; }
.brak-ofert, .nic-nie-sprzedajesz { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 24px; margin-bottom: 16px; }

/* ---------- list pages: Sprzedaję, Ulubione ---------- */
.list-page__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin: 0 0 24px; }
.list-page__head h1 { margin: 0; font: 700 32px/40px var(--font); }
.list-page .dodaj-oferte { float: none; }
.list-page .offer-list { max-width: 960px; }

/* ---------- ad page ---------- */
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 24px 0 16px; margin: 0; font-size: 14px; line-height: 20px; color: var(--ink-3); }
.crumbs a { color: var(--green); }
.crumbs a:hover { text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink-2); }
.offer-page__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 48px; align-items: start; }
.offer-page__photo { display: block; aspect-ratio: 4 / 3; border-radius: 8px; overflow: hidden; background: var(--panel); border: 1px solid var(--line); }
.offer-page__photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.offer-page__photo--empty { display: grid; place-items: center; aspect-ratio: 16 / 9; }
.offer-page__photo--empty img { width: 128px; height: 128px; object-fit: contain; opacity: .7; mix-blend-mode: multiply; }
.offer-page__thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; margin-top: 8px; }
.offer-page__thumbs a { display: block; aspect-ratio: 4 / 3; border-radius: 4px; overflow: hidden; border: 1px solid var(--line); }
.offer-page__thumbs img { width: 100%; height: 100%; object-fit: cover; }
.out-of-stock-tag { margin: 0 0 8px; }
.offer-page__sec { margin-top: 32px; }
.offer-page__sec h2 { margin: 0 0 8px; font: 700 20px/28px var(--font); }
.offer-page__sec h3 { margin: 16px 0 8px; font: 700 16px/24px var(--font); }
.offer-page__desc { max-width: 65ch; overflow-wrap: anywhere; }
.offer-page__reviews .btn { margin-top: 16px; white-space: normal; height: auto; min-height: var(--h); }
.offer-page__info { padding: 32px; background: #fff; border: 1px solid var(--line); border-radius: 8px; }
.offer-page__category { font-size: 14px; line-height: 20px; font-weight: 700; color: var(--green); text-decoration: none; }
.offer-page__category:hover { text-decoration: underline; }
.offer-page__info h1 { margin: 8px 0 0; font: 700 32px/40px var(--font); overflow-wrap: anywhere; }
.offer-page__price { margin: 16px 0 0; font: 900 32px/40px var(--font); color: var(--green); }
.offer-page__price span { margin-left: 4px; font: 400 16px/24px var(--font); color: var(--ink-2); }
.offer-page__price--none { font: 400 18px/28px var(--font); color: var(--ink-2); }
.offer-dates { margin: 8px 0 0; font-size: 14px; line-height: 20px; color: var(--ink-3); }
.offer-stale { display: flex; align-items: flex-start; gap: 8px; margin: 16px 0 0; padding: 12px 16px; border-radius: var(--r); background: var(--warn-bg); color: var(--warn); font-size: 14px; line-height: 20px; }
.offer-stale .i { color: #a87a1e; }
.offer-page__tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 16px 0 0; }
.offer-page__actions { display: grid; gap: 8px; margin-top: 24px; }
.offer-page__actions form { margin: 0; }
.offer-page__actions .btn { width: 100%; }
.offer-page__loc { margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--line); }
.offer-page__loc h2 { margin: 0; font: 700 16px/24px var(--font); }
.offer-page__address { margin: 4px 0 0; font-size: 15px; line-height: 24px; color: var(--ink-2); }
#map { height: 224px; margin-top: 16px; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; background: #e5e3df; }
.offer-page__admin { display: flex; gap: 8px; margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--line); }
.offer-page__admin form { margin: 0; }
.offer-contact-form h2 { margin-bottom: 16px; }

/* ---------- cards: login / register ---------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 32px; }
.card h2 { font-size: 1.25rem; }
.auth-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; padding-top: 32px; align-items: start; }
.auth-card h1, .auth-card h2 { margin: 0 0 16px; font: 700 28px/36px var(--font); }
.auth-card__lead { color: var(--ink-2); margin: -8px 0 16px; }
.auth-card input[type=email], .auth-card input[type=password], .auth-card input[type=text] { margin-bottom: 16px; }
.auth-card .check { display: flex; align-items: flex-start; gap: 12px; margin: 0 0 8px; font-size: .9375rem; line-height: 1.45; }
.auth-card .check input { width: 18px; height: 18px; margin: 2px 0 0; flex: 0 0 auto; }
.auth-card .check span { color: inherit; } /* app.css paints every "label span" red (required asterisk) */
.auth-card__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 16px; }
.auth-card__social { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.auth-card__social img { height: 44px; width: auto; }
.invalid-feedback { display: block; color: var(--danger); font-size: .875rem; margin: -10px 0 12px; }
.is-invalid { border-color: var(--danger) !important; }

/* ---------- footer ---------- */
.site-footer { margin-top: 64px; border-top: 1px solid var(--line); background: #fff; color: var(--ink); }
.site-footer__grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.5fr; gap: 48px; padding-top: 48px; padding-bottom: 48px; }
.site-footer__logo img { display: block; height: 32px; width: auto; }
.site-footer__about p { margin: 16px 0 0; max-width: 280px; font-size: 14px; line-height: 20px; color: var(--ink-2); }
.site-footer__title { margin: 0 0 16px; font: 700 14px/20px var(--font); color: var(--ink); }
.site-footer__title label { font: inherit; color: inherit; margin: 0; }
.site-footer ul { list-style: none; display: grid; gap: 8px; margin: 0; padding: 0; font-size: 15px; line-height: 24px; }
.site-footer li { margin: 0; }
.site-footer ul a { color: var(--ink); }
.site-footer ul a:hover, .site-footer ul a:focus { color: var(--green); text-decoration: underline; }
.site-footer__newsletter p { margin: 0 0 16px; font-size: 14px; line-height: 20px; color: var(--ink-2); }
.newsletter-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.newsletter-row input.email { margin: 0; }
.newsletter-row .button { height: var(--h); margin: 0; padding: 0 24px; font: 700 16px/24px var(--font); }
.site-footer__bottom { border-top: 1px solid var(--line); }
.site-footer__bottom .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; min-height: 64px; font-size: 14px; color: var(--ink-3); }
.site-footer__social { display: flex; flex-wrap: wrap; gap: 24px; margin-left: auto; }
.site-footer__social a { color: var(--ink-2); }
.site-footer__social a:hover, .site-footer__social a:focus { color: var(--green); }

/* ---------- cookie bar ---------- */
.js-cookie-consent {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; margin: 0; padding: 10px 16px;
    display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 16px;
    background: var(--graphite); color: #fff; font-size: .9rem; text-align: left; box-shadow: 0 -2px 12px rgba(0, 0, 0, .15);
}
.js-cookie-consent button { margin: 0; padding: 8px 16px; border-radius: var(--r); font: 700 .875rem/1.2 var(--font); cursor: pointer; }
.js-cookie-consent .cookie-consent__agree { background: #fff; color: var(--ink); border: 1px solid #fff; }
.js-cookie-consent .cookie-consent__reject { background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, .6); }
.js-cookie-consent button:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }

/* ---------- legacy pages (create/edit): only the worst 2019 leftovers ---------- */
h1.naglowek { text-transform: none; margin: 24px 0 12px; }
.save-button-holder button.zapisz-oferte { right: 24px; bottom: 24px; z-index: 40; box-shadow: 0 4px 14px rgba(0, 0, 0, .18); }

/* ---------- medium: 15 category tiles no longer fit ---------- */
@media (max-width: 1100px) {
    .categories-search-bar ul { display: flex; overflow-x: auto; padding: 0 8px; scrollbar-width: none; }
    .categories-search-bar ul::-webkit-scrollbar { display: none; }
    .categories-search-bar li { flex: 0 0 88px; }
    .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 32px 24px; }
}
@media (max-width: 900px) {
    .offer-page__grid { grid-template-columns: 1fr; gap: 24px; }
    .auth-grid { grid-template-columns: 1fr; }
}

/* ---------- mobile ---------- */
.short { display: none; }
@media (max-width: 720px) {
    .wrap { padding-left: 16px; padding-right: 16px; }
    .site-header__bar { height: 64px; gap: 16px; }
    .brand img { height: 30px; }
    .brand__tagline, .long { display: none; }
    .short { display: inline; }
    .site-nav { gap: 16px; }
    .header-cta { padding: 0 16px; }
    .nav-toggle {
        display: inline-flex; align-items: center; justify-content: center; width: var(--h); height: var(--h); margin: 0; padding: 0;
        background: #fff; border: 1px solid var(--line-2); border-radius: var(--r); cursor: pointer;
    }
    .nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after { display: block; width: 20px; height: 2px; background: var(--ink); border-radius: 2px; position: relative; transition: transform .2s; }
    .nav-toggle__bars::before, .nav-toggle__bars::after { content: ""; position: absolute; left: 0; }
    .nav-toggle__bars::before { top: -6px; }
    .nav-toggle__bars::after { top: 6px; }
    .nav-toggle[aria-expanded=true] .nav-toggle__bars { background: transparent; }
    .nav-toggle[aria-expanded=true] .nav-toggle__bars::before { transform: translateY(6px) rotate(45deg); }
    .nav-toggle[aria-expanded=true] .nav-toggle__bars::after { transform: translateY(-6px) rotate(-45deg); }
    .site-nav__account {
        display: none; position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; padding: 8px 16px 16px;
        background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 8px 16px rgba(0, 0, 0, .08);
    }
    .site-nav__account.is-open { display: flex; }
    .site-nav__account a, .site-nav__account .link-button { display: block; width: 100%; padding: 12px 0; border-bottom: 1px solid var(--line); text-align: left; }

    .search-band { padding: 16px 0; }
    .search-bar { grid-template-columns: 1fr 1fr; }
    .search-bar > .field:nth-child(-n+2) { grid-column: 1 / -1; }
    .search-bar--ask { grid-template-columns: 1fr; }
    .search-bar--ask .field { flex-direction: column; align-items: stretch; gap: 4px; }

    .categories-search-bar li { flex-basis: 84px; }
    #map-targ { height: 300px; }
    .map-band__note { left: 16px; top: 12px; }

    /* list first; the filter panel opens right under its heading (results__list flattened into the grid) */
    .results { grid-template-columns: minmax(0, 1fr); gap: 0; padding-top: 24px; }
    .results__list { display: contents; }
    .results .list-head { order: -1; }
    .targ-filter { display: none; margin-bottom: 16px; }
    .targ-filter.is-open { display: block; }
    .list-head { flex-wrap: wrap; gap: 8px; }
    .list-head__title { width: 100%; font-size: 20px; line-height: 28px; }
    .list-head__tools { width: 100%; display: grid; grid-template-columns: 1fr 1fr; }
    .list-head .sort { width: auto; }
    .list-head .sort label { width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
    .list-head .sort select { padding-left: 16px; }
    .filters-btn { display: inline-flex; padding: 0 16px; }

    .offer-list { gap: 0; border-top: 1px solid var(--line); }
    .offer-card { grid-template-columns: 112px minmax(0, 1fr); gap: 16px; padding: 16px 0; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; }
    .offer-card:hover { box-shadow: none; }
    .offer-card.is-active { box-shadow: none; background: var(--green-t); }
    .offer-card__head { flex-direction: column; gap: 4px; }
    .offer-card__title { font-size: 16px; line-height: 22px; }
    .offer-card__price { text-align: left; font-size: 18px; }
    .offer-card__price--none { font-size: 14px; line-height: 20px; }
    .offer-card__desc, .offer-card__category, .offer-card__date { display: none; }
    .offer-card__meta { flex-wrap: wrap; padding-top: 4px; }
    .offer-card__city::before { display: none; }
    .offer-card__stale { width: 100%; margin-left: 0; padding-left: 0; }

    .site-footer__grid { padding-top: 40px; padding-bottom: 40px; }
    .site-footer__about, .site-footer__newsletter { grid-column: 1 / -1; }
    .site-footer__bottom .wrap { padding-top: 16px; padding-bottom: 16px; }
    .site-footer__social { margin-left: 0; }

    .offer-page__info { padding: 0; border: 0; }
    .offer-page__info h1, .offer-page__price { font-size: 26px; line-height: 32px; }
    .list-page__head h1 { font-size: 26px; line-height: 32px; }
    .card { padding: 20px; }
    .js-cookie-consent { justify-content: flex-start; padding: 10px 12px; }
    .cookie-consent__message { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .offer-card, .btn, .nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after { transition: none; }
}
